What is the x402 Exact Payment Scheme?

2 min read Updated

The exact payment scheme is the first and primary payment scheme in the x402 protocol. It transfers a specific, predetermined amount of tokens from client to resource server — for example, pay exactly $0.01 USDC to access an API endpoint. On EVM chains, it uses EIP-3009 transferWithAuthorization signatures.

WHY IT MATTERS

The x402 protocol is designed to be extensible across different schemes (logical ways of moving money) and networks (blockchains). The exact scheme is the foundational one — it handles the most common case: pay a fixed price for a resource.

On EVM chains (Base, Ethereum, Arbitrum), the exact scheme leverages EIP-3009 — a token standard that allows gasless transfers via signed authorisations. The client signs a message authorising transfer of exactly X tokens from their address to the recipient. The facilitator then submits this authorisation on-chain via transferWithAuthorization.

Key properties of the exact scheme:

  • Fixed amount — price is known upfront, no variable billing
  • Gasless for clients — the facilitator pays gas to submit the on-chain transaction
  • Non-custodial — the signed authorisation can only transfer the specified amount to the specified recipient
  • Replay-resistant — each authorisation has a unique nonce, usable only once

The x402 roadmap includes additional schemes: upto (authorise up to a maximum, settle actual usage — useful for LLM inference), and Cloudflare's proposed deferred (cryptographic commitment now, settlement later). The protocol also supports Solana via its SVM implementation, with different signing mechanics but the same logical exact semantics.

HOW POLICYLAYER USES THIS

PolicyLayer validates exact scheme payments by checking the authorised amount against per-request limits, daily budgets, and per-endpoint caps. Amount hallucination — where an agent signs for a wildly incorrect amount — is caught by comparing the payment payload's value against the 402 response's stated price and configured maximums.

FREQUENTLY ASKED QUESTIONS

What is EIP-3009 and why does x402 use it?
EIP-3009 defines transferWithAuthorization — a way to transfer ERC-20 tokens using a signed message instead of a direct transaction. The signer doesn't need gas; anyone can submit the signed authorisation. This makes x402 gasless for clients and non-custodial for facilitators.
How does the exact scheme differ from an upto scheme?
Exact transfers a predetermined amount regardless of actual resource consumption. Upto (planned) would authorise a maximum amount, with the actual settlement based on resources consumed — like pay-per-token for LLM inference where the output length varies.
Does the exact scheme work on Solana?
Yes. The x402 SDK includes @x402/svm for Solana support. The signing mechanics differ (Solana uses Ed25519 instead of secp256k1), but the logical flow is identical: authorise an exact amount, verify, then settle.

FURTHER READING

Enforce policies on every tool call

Intercept is the open-source MCP proxy that enforces YAML policies on AI agent tool calls. No code changes needed.

npx -y @policylayer/intercept
github.com/policylayer/intercept →
// GET IN TOUCH

Have a question or want to learn more? Send us a message.

Message sent.

We'll get back to you soon.