Skip to main content
x402 is an open standard for adding per-request payments to HTTP, so APIs and services can charge without checkout pages, subscriptions, or separate billing integrations. Payment becomes a client-server handshake: the server quotes a price in its response, the client pays, and the same interaction completes with the resource.

The payment flow

x402 payment flow between a client, resource server, and facilitator
  1. The client requests a resource.
  2. The server responds that payment is required and includes the price, who should receive it, and which payment options it accepts.
  3. The client signs a payment and sends the request again with proof of payment attached.
  4. The server asks the CDP Facilitator to verify the payment.
  5. The facilitator returns the verification result.
  6. The server performs the requested work.
  7. The server asks the facilitator to settle the payment.
  8. The facilitator returns the settlement result.
  9. The server returns the resource and confirms the payment.

Flexible by design

x402 defines the payment handshake without prescribing a single payment rail. Sellers can choose how payment messages travel, where payments settle, which assets they accept, and how they charge:
  • Transport agnostic. Payment messages can travel over different protocols. These docs focus on HTTP, where payment details travel with the request and response.
  • Network agnostic. The same handshake works across chains, including EVM networks and Solana.
  • Flexible assets. USDC is the most common asset, but sellers can accept any ERC-20 token on EVM networks or SPL token on Solana.
  • Flexible pricing. Sellers can charge a fixed price, authorize a maximum and settle only what was used, or defer settlement for a batch of payments.
The seller advertises the combinations it accepts, and the buyer chooses a supported option. A facilitator can then verify and settle the payment on the seller’s behalf. See the CDP Facilitator for the networks and assets supported by CDP. For protocol-level detail, see the x402 docs on HTTP 402 and payment schemes. Pick the path that matches your goal:

Seller (SDK)

Charge for your endpoints with x402 and the CDP SDK.

Buyer (SDK)

Pay for an API or resource with x402 and the CDP SDK.

Agentic Accounts

Give your own agent an account it can use to pay for x402 services.

Integrations

Connect x402 to a supported platform where you build and run agents.