x402 Payments
HTTP has had a status code for payments since 1997:402 Payment Required. Nobody used it because there was no standard way to actually pay.
x402 makes it real: a resource declares a price; the client pays in USDC on-chain by signing a payment payload; the server verifies and settles it, all inside ordinary HTTP requests. Qopper implements this natively.
The flow
What a 402 looks like
maxAmountRequired is in USDC base units (6 decimals): 10000 = $0.01.
Where you’ll find it in Qopper
Why businesses care
- No Qopper account needed on the payer side. Any wallet works.
- No chargebacks. Settlement is final.
- One code path for humans and agents alike: it’s just HTTP.
The demo route settles against the public CDP facilitator on Base Sepolia. For production, configure your own treasury address (
X402_PAY_TO) and network via environment variables provided by your Qopper operator.Supported networks
Qopper can hold, pay, and settle USDC on these chains. Deposits and withdrawals work on any of them:
Each chain has its own USDC contract address, so funds must be sent on the same network as the address you’re using — sending USDC to the wrong chain loses it and cannot be recovered. The console’s deposit and withdrawal flows show these networks and let you pick.
For x402 settlement the network is not a per-request choice: a deployment settles on the single network it is configured for (
X402_NETWORK, or the one implied by its chain environment), and the facilitator in use has to support that chain. The network field in the 402 response is what tells the payer where to settle — always read it rather than assuming.