v2

latestOpenAPI 3.1.0Proprietary2026-07-26127193620.1 KB
Payments

Create a payment challenge

Create an x402 payment challenge (the payee side of a payment). The pay_to address is resolved server-side from your registered default payout address for the network, never from the request. The response carries the nonce_binding and payment_requirements the payer needs to sign; hand the whole challenge object to the payer (for example in an email reply). Amounts are in token base units (USDC has 6 decimals, so "10000" is 0.01 USDC).

post/x402/challenges

Headers

Idempotency-Keystring

Optional client-supplied idempotency key. Retrying a request with the same key returns the original result instead of performing the action a second time; if omitted the server derives one from the canonical payload hash. Safe to retry network failures without duplicating side effects.

Request body

amountstring required

Amount to collect, in token base units. USDC has 6 decimals, so "10000" is 0.01 USDC.

network'base' | 'base-sepolia' required
payer_orgstring uuid

The org id allowed to pay this challenge (on-net binding). Optional.

expires_ininteger

Seconds until the challenge expires. Defaults to 3600.

resourcestring uri

Optional URL identifying what is being paid for. Defaults to a synthetic x402:challenge:<id> identifier.

descriptionstring

Optional human-readable description of the payment.

Response

Challenge created

successtrue required

Example response

{
  "data": {
    "payment_requirements": {
      "scheme": "exact"
    }
  }
}