Setup

What is x402? How an AI agent pays with HTTP 402

What is x402: the open protocol that lets an AI agent pay an API inside the HTTP request, with stablecoins. The headers, the facilitator, who accepts it.

The looot team · , updated · 6 min read

On this page

x402 is an open protocol that lets a client, often an AI agent, pay for an API inside the HTTP request itself. The server answers with status 402 and its price, the agent signs a stablecoin payment and sends the request again, and the server returns the data. There is no account, no API key and no checkout page.

This post explains what x402 is, how the 402 and the payment headers work, what a facilitator does, who accepts x402 today, and what looot does instead. Every fact comes from the x402 repository, x402.org and Coinbase's developer docs, read on 2026-10-14.

What is x402, in one paragraph

HTTP has had a status code for payment since the early web. MDN calls 402 Payment Required "a nonstandard response status code reserved for future use", created "to enable digital cash or (micro) payment systems" (MDN). x402 gives that code a format. x402.org calls it "an open, neutral standard for internet-native payments" (x402.org). The reference code is open source under the Apache 2.0 license, now in the x402 Foundation repository.

How an x402 payment works, step by step

The x402 repository lists the flow. In short:

  1. The agent sends a normal request, for example `GET /company?domain=stripe.com`.
  2. The server answers `402 Payment Required` with a `PAYMENT-REQUIRED` header. It holds, base64 encoded, the payment options it accepts: network, token, amount and where to pay.
  3. The agent picks one option and signs a payment payload with its wallet.
  4. The agent sends the same request again with a `PAYMENT-SIGNATURE` header that carries the signed payload.
  5. The server checks the payload, on its own or through a facilitator's `/verify` endpoint, then does the work.
  6. The server settles the payment through the facilitator and returns the data with a `PAYMENT-RESPONSE` header that holds the settlement result.

The agent never holds an account with the seller. Its wallet signature is the proof of payment, and the signed payload limits what can move. The repository says no scheme may let "the facilitator or resource server to move funds, other than in accordance with client intentions".

What a facilitator does in x402

A facilitator is the service that checks and settles payments so the seller's server does not talk to a blockchain itself. Coinbase runs one. Its docs say it "validates signed payments, screens transactions, submits settlement onchain", with OFAC checks (CDP facilitator).

  • Networks: Base, Polygon, Arbitrum, World and Solana, among others listed on the same page.
  • Tokens: any ERC-20 token on its EVM networks through EIP-3009 or Permit2, and SPL tokens on Solana.
  • Price for the seller: the first 1,000 onchain transactions a month are free, then $0.001 each, and verification is free (CDP facilitator, read 2026-10-14).

x402.org itself says the protocol charges "zero protocol fees". Network fees and a facilitator's fee are separate.

Who accepts x402 today

Sellers can list x402 endpoints in Coinbase's Bazaar, which its docs call a marketplace for x402 endpoints. Coinbase says it "has processed more than 100 million x402 payments across Base and Solana" (CDP x402 overview).

On the buyer side, some agent wallets speak it:

  • Ramp lets an agent pay x402 from "a separately funded x402 wallet" (Ramp agents).
  • The AgentCard CLI from Alchemy has an `x402 fetch` command that pays from its USDC wallet (AgentCard skill page).
  • Stripe and Tempo's MPP added "x402 exact flows" to its SDK on June 8, 2026 (mpp.dev).

Our agentic payments roundup ranks these wallets by setup steps.

x402 vs a prepaid balance

x402Prepaid balance
Account with the sellerNoneOne workspace
MoneyStablecoins from the agent's walletCard on a hosted checkout, paid by a person
When money movesEach callOnce per top-up
What the agent holdsA wallet keyAn API key
Who approves a paymentNobody, the wallet signsA person, once per top-up

A prepaid balance asks a person once, then the agent runs alone until it is empty. x402 asks nobody, but the agent must hold funds and a key that can sign. That key is money: anyone who reads it can spend the wallet.

Is the 402 that looot returns an x402 payment?

No. When a looot workspace runs out of credit, a run answers `402 insufficient_balance` with a Stripe Checkout link, as the skill file says. That 402 is a message for a person. It has no `PAYMENT-REQUIRED` header, and an x402 wallet cannot pay it.

What it cannot do

x402 moves stablecoins only. A buyer with cards and no wallet cannot use it. The seller must accept it, and many data APIs do not yet. A signed payment cannot be reversed by a card network, so a buyer has no chargeback. On looot, x402 does not work today. Last checked 2026-10-14.

Try it

Prompt for your agent

Check how an API wants to be paid

Check how an API wants to be paid
Use looot to search for an API that returns company data from a domain, and tell me how it bills. First set up https://looot.ai/skill.md. Searching is free. If a paid run is needed and the balance is too low, call top_up and show me the Checkout link instead of paying.

For x402 marketplaces next to other API marketplaces, see RapidAPI alternatives for AI agents. For the card and Stripe side, read the MPP explainer.

Questions

x402 is an open protocol for paying inside an HTTP request. A server answers 402 with its price, the client signs a stablecoin payment and retries, and a facilitator settles it.

It is an HTTP status that MDN calls nonstandard and "reserved for future use", meant for digital cash. x402 is one protocol that defines what a 402 response must carry.

The server sends `PAYMENT-REQUIRED` with the 402. The client retries with `PAYMENT-SIGNATURE`. The server confirms with `PAYMENT-RESPONSE`. Each holds base64-encoded JSON.

No. x402.org says it needs "no accounts or personal information". The agent needs a funded wallet that can sign.

Coinbase's facilitator is free for the first 1,000 onchain transactions a month, then a tenth of a cent each, paid by the seller. Verification is free.

Not yet. looot sells a prepaid balance paid on Stripe Checkout. Its 402 carries a Checkout link for a person, not x402 terms.

No. Both use HTTP 402. x402 is crypto only. MPP, from Stripe and Tempo, also carries card payments and can run x402 flows through its SDK.
ShareXLinkedInEmail

Try it with the agent you already use

Start your workspace, top up, and paste one prompt into your agent.