AgentSmithx402

Agents pay for services on Stellar. And find them first.

Open-source x402 payments and discovery for Stellar, letting AI agents find and pay for services they were never integrated with.

Sellers charge per request without touching Soroban. Buyers — usually software — search a native Bazaar catalog, pay for what they find, and get the result in one loop.

Read the docs→ Browse the Bazaar→
What it is

Two sides, four steps

AgentSmith sits between an agent that has a task and a service that charges for it. Neither side needs an account with the other, an API key, or a prior integration — the four steps below are the whole relationship.

01 · LIST 02 · FIND 03 · PAY 04 · DELIVER Buyer / agent AgentSmith Bazaar · facilitator Resource server Wrap a route with a price Bazaar catalog Describe the task Bazaar search Sign one authorization Verify and settle Return the response Get the result and a short description no registration step in natural language ranked, payable results for that exact call network fee sponsored and a settlement hash auto-listed query ranked results signed auth entry payment settled result and settlement hash

Steps 2 and 3 are a single call from the agent's side — the diagram separates them because each is a point where a payment can be refused, and every refusal comes back with a machine-readable reason.

Our solution

Three things we do better

Settlement on Stellar is largely solved — we compose the Apache-2.0 @x402/stellar package rather than reimplement it. What decides whether any of this is usable sits in three places.

Higher natural-language accuracy

We parse an agent's request into the capability it wants and the constraints it must respect before we retrieve anything, so intent and budget are matched separately instead of competing. Accuracy is scored on a golden set of agent-phrased queries in CI.

Ranking backed by a confidence score

Every result carries a calibrated confidence, not just a position, so an agent can tell a strong match from the best of a weak field — and decline to spend below its threshold.

A payment flow built for Stellar

The buyer signs a Soroban auth entry scoped to one exact call rather than handing over a pre-signed transaction, and we sponsor the network fee. We are never the source of funds and never take custody.

Integrate payments with the AgentSmith SDK

One package for Seller payment middleware and Node Buyer paid fetch. Use exact pricing or experimental upto metering with official x402 components. Requires Node.js 24+; discovery helpers are a future delivery.

It points at the AgentSmith Facilitator, which runs on both Stellar testnet and mainnet:

Install
npm install agentsmith-x402-sdk
Environment Facilitator Authentication
Testnet https://testnet.agentsmith.xyz/facilitator No API key required
Mainnet https://mainnet.agentsmith.xyz/facilitator Seller API key required

SDK quick start →   Seller integration →   Buyer integration →   View on npm →

Where to start

Pick the side you are on

Buyer / agent

Find and pay for services →

Use the payment SDK to call paid services. Discovery over HTTP and MCP is a separate workflow. Pay per call with exact, or authorize a cap and settle actual usage with upto.

Seller

Charge per request →

Protect an Express API route with the SDK, set a token price, and let the Facilitator verify and settle payments. Bazaar discovery is a separate integration.

Open source

The ecosystem should not depend on one operator

Shipped under a permissive OSI-approved licence, with every dependency checked for compatible redistribution and for operating the code as a network service. No strong copyleft anywhere in the dependency path.

Fork it

Run the whole facilitator yourself, on either network, with your own fee policy or none.

Embed it

Self-facilitate inside your own resource server when you would rather not run a second service.

Upstream

The Stellar upto network spec and its implementation go to the x402 repository, not into a private fork.

From the docs to a paid, discoverable endpoint

The target is well under an hour, from a clean machine, following the guide.

Quickstart→ Browse the Bazaar→