SatBotly
step-by-step guide · computed from live 402 probes · data as of 2026-11-13

How to make an AI agent pay for APIs

An AI agent pays for an API the same way a browser loads a page: over HTTP. The server answers an unpaid request with 402 Payment Required and a price, the agent pays from a wallet you gave it, then retries the request with proof of payment. No account, no API key, no card form. SatBotly has probed 527 pay-per-call endpoints without paying; 291 of 527 priced ones ask one cent or less per call. Here is how to set an agent up in five steps.

x402 APIs
357
median $0.01 per call
L402 APIs
133
median 10 sat ($0.008151)
MPP APIs
37
median $0.005125 per call
Agent wallets
199
41 with spending limits

Step 1: pick a payment rail

Three HTTP 402 rails are live today. They differ in what the agent pays with, not in how the request looks.

Counted from data/apis.json (unpaid 402 probes)
RailAgent pays withEndpointsProvidersMedian per callMost common assetStart here
x402stablecoin signed by the agent wallet357189$0.01USDC (Base)cheapest x402
L402a Lightning invoice paid in sats1334710 sat ($0.008151)BTC (Lightning)cheapest L402
MPPthe method named in a Payment challenge3736$0.005125USDC.e (Tempo)cheapest MPP

Rule of thumb: if the agent already holds USDC, start with x402 (largest catalog). If it holds sats on Lightning, start with L402. If you need the gateways sold over MPP, hold the asset its method asks for. L402 USD values use the sat rate stored in data/apis.json (0.00081513 USD per sat).

Step 2: give the agent a wallet with a budget

The agent needs a wallet it can use without a human clicking "approve" on every call, and you need a cap on what it can spend. Of the 199 wallets SatBotly tracks:

Fund the wallet with a small amount first. A spending limit plus a small balance means a looping agent can only burn what you put in. Full ranking: agent wallet leaderboard.

Step 3: handle the 402 response

The flow is the same on every rail:

  1. The agent sends a normal request (GET or POST) with no payment.
  2. The server answers 402 Payment Required with a challenge: the price, the asset and where to pay.
  3. The agent's wallet pays (x402: signs a stablecoin payment matching one of the accepts options; L402: pays the Lightning invoice from the WWW-Authenticate header and keeps the preimage; MPP: pays with the method in the Payment challenge).
  4. The agent repeats the same request with the proof attached and gets the normal response.

Most agent wallets and SDKs wrap steps 2 to 4, so your code just makes the request and sets a maximum price. Check the price in the challenge before paying: never let the agent pay a 402 that asks more than you expect. Want to see a real challenge without paying? Paste any endpoint into try402.

Step 4: start with the cheapest live endpoints

Prices are what each endpoint asked in an unpaid 402 challenge. No API was paid. Prices drift; re-check on try402 before you rely on one.

Step 5: compare rails before you commit

Side-by-side numbers for each pair: x402 vs L402 · x402 vs MPP · L402 vs MPP. The big picture is in the state of agent payments.

FAQ

How do AI agents pay for APIs?

Over HTTP 402 Payment Required. The API answers an unpaid request with a 402 and a price, the agent pays from its own wallet, then repeats the request with proof of payment. SatBotly has probed 527 such endpoints without paying (data as of 2026-11-13): 357 x402, 133 L402 and 37 MPP.

Which payment rail should my agent use?

Pick by what the agent can hold. x402 has the most endpoints here (357 from 189 providers, median $0.01 per call, mostly USDC (Base)). L402 is paid in Lightning sats (133 endpoints, median 10 sat). MPP has 37 endpoints, median $0.005125.

What wallet does an AI agent need?

A wallet the agent can drive from code or tools. Of 199 wallets in the SatBotly directory, 52 can pay x402, 120 pay over Lightning, 38 support Nostr Wallet Connect, 78 ship an MCP server and 41 document a spending limit.

How much does one paid API call cost?

Of 527 priced endpoints, 291 ask one cent or less per call. The cheapest prices seen were $0.0001 on x402, $0.000815 on L402 and $0.0001 on MPP.

Data and method

Each endpoint is probed with an unpaid request and kept only if it answers HTTP 402 with a readable price. Wallet features come from each wallet's own docs, with a source link and quote. Data date 2026-11-13. Browse all pay-per-call APIs or read how entries are checked.