> ## Documentation Index
> Fetch the complete documentation index at: https://a-identity.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# x402

> Pay-per-action over the HTTP 402 status code, settled in stablecoins.

x402 is an open payment standard from Coinbase and the x402 Foundation. It revives
the HTTP 402 status code so a client can pay for a resource in the same request it
asks for it. No accounts, no API keys by default. A-Identity ships a **real x402
rail**: the server answers an unpaid request with 402 + machine-readable payment
requirements, the client pays in a stablecoin on the chain the 402 names, and the
server verifies that payment on-chain (with replay protection) before serving the
resource.

## How One Payment Works

**1. Request**

An agent requests a paid resource.

**2. 402 Payment Required**

The server answers with status 402 and the payment terms.

**3. Pay And Retry**

The agent signs a stablecoin transfer, attaches the proof, and sends the request
again. The server verifies and returns the resource.

Each 402 carries a **single-use, resource-scoped nonce**; the redemption must echo it.
So a payment is bound to the request that quoted it: an unrelated or stockpiled USDC
transfer can't blind-unlock the resource, and every proof is spendable exactly once
(replay protection persisted across restarts).

## Settlement

The x402 standard is asset- and network-agnostic, and so is our use of it. Paid calls
settle in **USDC** on Arc Mainnet, Base, Arbitrum One, Stellar, Algorand and Celo, and in
**USDG** on Robinhood Chain; the Trust Oracle's 120 settlements on X Layer, all from our
own buyer wallet, were in USD₮0. Arc Mainnet leads: gas there is paid in USDC itself and
finality is sub-second. Every 402 challenge states its own price, network and asset. What makes a payment count
differs by rail and is stated, not blurred: on our EIP-3009, Stellar and Algorand rails we
read the transfer back from the chain ourselves; a Circle Gateway nanopayment counts once
Circle's transfers API returns it; on Celo the facilitator Celo operates answers settled,
and we publish the transaction hash it returns rather than re-reading it. Each rail's
evidence, transaction by transaction, is at
[a-identity.xyz/proof](https://a-identity.xyz/proof).

| Property | Value |
| - | - |
| Standard | x402 (HTTP 402) |
| Settlement | USDC on most chains, USDG on Robinhood Chain |
| Primary rail | Arc Mainnet (live since 2026-09-16), rehearsed on Arc testnet |
| Price per call | Stated in each 402 challenge, from 0.001 USDC |

## Two rails, same standard

On Arc, A-Identity ships **two** x402 rails and labels which is which:

1. **On-chain, self-verifying** (this page): each call settles as a real USDC transfer
   on Arc, verified on-chain with replay protection and a request nonce. Provable,
   standalone, no hosted meter.
2. **[Circle Nanopayments](/protocols/nanopayments)**, the same 402 negotiation over
   Circle Gateway's batched scheme: the buyer signs an EIP-3009 authorization off-chain
   (zero gas) and Gateway batches the on-chain settlement, making sub-cent streams
   economical.

> [!NOTE]
>
> We chose the open x402 standard because it is self-verifying: we can **prove**
> settlement on-chain rather than trust a hosted meter. Then we added Circle
> Nanopayments as the gasless, batched rail alongside it. Both are live on Arc Mainnet, and
> on Arc testnet for rehearsal.

## Paid Tools

The `x402-mcp` library puts an x402 paywall in front of a Model Context Protocol
tool. An agent discovers the tool, pays, and calls it, all over HTTP.

> **[Build A Paid Tool](/developers/sdk)**
>
> See the SDK reference for a paid tool in a few lines.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.