inziLog in
ENES
x402 Live Demo

Pay $0.01, unlock a resource.

This page makes a live call to /api/v1/x402-demo/premium. The server answers with HTTP 402 Payment Required. You send a tiny USDC transfer, submit the proof, and the server returns the content. No account, no setup — just HTTP + a wallet.

This is the exchange your server and the payer go through — two requests, one header.

GET /api/v1/checkout/{short_code}
→ 402 Payment Required
   { "requirements": { "payTo": "…", "maxAmountRequired": "0.01", "network": "…" } }

GET /api/v1/checkout/{short_code}
X-Payment: <base64({ txHash, chain, token, amount, payerAddress })>
→ 200 OK

How it works

  1. Browser GETs /api/v1/x402-demo/premium. Server returns HTTP 402 with a JSON body describing payTo, amount, asset, resource.
  2. You send 0.01 USDC on-chain to the returned address. Solana takes ~400ms and costs ~$0.00025 in fees.
  3. Browser retries with X-Payment header containing base64(JSON) of your transaction hash.
  4. Server reads the header, calls the inzi facilitator to verify the tx on-chain (recipient, token contract, amount, confirmations), and returns 200 with the resource.

Build this into your own API with @inzi/x402 SDK pointed at our facilitator.

Essential cookies keep the site working. With your permission, analytics cookies help us understand how the public website is used and improve it.

We save your choice for 12 months. Analytics cookies (_ga and _ga_*) expire after 12 months. We do not use advertising cookies.

Essential cookies

Always active

Required for security, signing in and remembering your cookie preferences. These cannot be switched off here.

Google Analytics 4 measures visits and how people use our public website. It receives device and page data and your IP address. Analytics never runs in the dashboard or on checkout pages.

We save your choice for 12 months. Analytics cookies (_ga and _ga_*) expire after 12 months. We do not use advertising cookies.

x402 Demo — HTTP Micropayments Live | inzi