What is x402Direct?
Internet-Native Micropayments for the Agentic Economy
x402 is an open payments protocol that activates the HTTP 402 "Payment Required" status code to enable instant, blockchain-based payments for web resources and APIs. Our implementation uses the x402Direct schema, which requires no separate payment processor or third-party intermediaries.
Built on permissionless blockchain infrastructure, x402Direct eliminates traditional payment inefficiencies by enabling direct buyer-to-vendor transfers via smart contracts. Payments settle instantly using stablecoins like USDC on Layer-2 networks like Base with minimal transaction fees.
How x402Direct Works
Request & Nonce Generation
A buyer (AI agent or user) wants to make a payment to a vendor. The vendor provides a unique nonce (a one-time-use identifier) to the buyer along with payment details including amount, currency (typically USDC), and the smart contract address.
Direct Payment via Smart Contract
The buyer sends a message to the x402Direct smart contract with the nonce, requesting payment be made to the vendor. The smart contract moves funds directly from buyer to vendor on-chain and emits a transaction event with a unique transaction ID.
Payment Proof Submission
The buyer requests access again, this time providing both the nonce and the transaction ID received from the smart contract. The vendor receives this proof of payment via query parameter or HTTP header.
Verification & Access Granted
The vendor checks the smart contract event to confirm that the transaction ID corresponds to the provided nonce and that payment was successfully received. Upon verification, the vendor grants access to the requested resource or service.
Why x402 Matters for AI Agents
Autonomous Commerce
AI agents can discover payment requirements, execute blockchain transactions, and complete purchases without human intervention. No API keys, accounts, or pre-existing relationships required.
Global & Permissionless
Available worldwide without costly currency conversions or access to traditional financial rails. Any agent, anywhere, can transact instantly using cryptocurrency.
Micropayment Economics
Payments made via x402Direct are very inexpensive. True pay-per-use pricing becomes practical without the burden of traditional payment processing fees.
Direct Settlement
Payments move directly from buyer to vendor via smart contract in seconds on Layer-2 networks like Base. No third-party payment processors, no chargebacks, no delays. Vendors receive funds immediately in their wallet.
Real-World Use Cases
Premium Content & News
Publishers can gate articles behind micropayments. AI agents and readers pay per article rather than committing to full subscriptions, creating flexible monetization for quality journalism.
API Access & Data Feeds
Services charge per API call instead of monthly subscriptions. An AI agent needing real-time stock data or weather information pays only for the specific requests it makes, with instant payment verification.
Cloud Computing Resources
AI agents can autonomously purchase compute time, storage, or GPU cycles on demand. Pay-per-second pricing becomes practical with micropayment infrastructure.
E-Commerce & Tool Discovery
An AI shopping assistant can browse multiple merchants, compare prices, and complete purchases across platforms without requiring pre-configured accounts or payment methods at each vendor.
Research & Academic Papers
Researchers and AI systems can pay per paper access instead of expensive journal subscriptions, democratizing access to scientific knowledge.
Why x402Direct?
The x402Direct schema eliminates intermediaries and provides true peer-to-peer payment capabilities on the blockchain. By using smart contract events and nonce-based verification, the system ensures:
- No third-party dependencies - Payments flow directly from buyer to vendor without payment processors or escrow services
- Cryptographically verifiable payments - Smart contract events provide immutable proof of payment tied to unique nonces
- Minimal trust requirements - The blockchain acts as the source of truth, eliminating the need for trusted intermediaries
- Cost efficiency - No middleman fees beyond minimal gas costs on Layer-2 networks like Base
Industry analysts predict that autonomous agent commerce could exceed$50 billion annually by 2027, with protocols like x402Direct enabling seamless machine-to-machine transactions in USDC on Layer-2 networks.
Payment Processing Fee Comparison
See how x402Direct compares to traditional payment processing solutions:
| Payment Method | Fee Structure | Cost on $10 | Cost on $100 |
|---|---|---|---|
| Credit Card (US) | 2.9% + $0.30 | $0.59 | $3.20 |
| Credit Card (International) | 4.5% + $0.30 | $0.75 | $4.80 |
x402Direct Stablecoin Payments (US & International) | ...* | ... | ... |
Why x402Direct is cheaper: By eliminating payment processors and using direct smart contract transfers on Layer-2 networks like Base, x402Direct provides significantly lower fees than traditional payment methods. The same low rate applies to both US and international transactions.
* Current x402 rates: Loading... per transaction
Technical Specifications
HTTP Status Code
402 Payment Required
Currency Standard
USDC (USD Coin) Stablecoin
Primary Network
Base (Layer-2, ~2 second blocks)
Typical Confirmation Time
~6 seconds (3 blocks on Base)
Transaction Fees
~$0.01 gas fee (flat, regardless of amount)
Response Format
JSON (agents) or HTML (browsers)
x402Direct on AgentPMT
AgentPMT has implemented the x402Direct schema to enable direct, peer-to-peer payments for premium content and services. Our implementation includes:
- Smart contract integration for direct buyer-to-vendor USDC transfers on the Base network
- Nonce-based payment verification that ties each payment request to a unique identifier
- Blockchain event monitoring to verify transaction IDs against nonces in real-time
- No intermediary fees - Payments flow directly from buyer wallets to vendor wallets
- Hybrid response system serving JSON to AI agents and styled HTML to browsers
- Support for multiple proof methods via query parameters or HTTP headers
This infrastructure enables AI agents to discover our premium content, receive payment nonces from vendors, execute smart contract transactions, and gain access autonomously without any third-party involvement.
One Connection for All Tools
Connect once and enable access to any tool from your dashboard. Your agents can start using new tools instantly.
Centralized Management
Manage all agent tools for your entire organization from one dashboard with just a few clicks.
Complete Auditability
Every tool call and response is logged and traceable. Perfect for compliance and debugging.
How Agent Payments Work
API / MCP Accessible Wallets
When you activate your account, a digital wallet is automatically deployed on your behalf. Our backend smart contract infrastructure gives you the ability to spend with your MCP server or directly through API calls to approved addresses, providing ultimate security and flexbility. With customizable rule sets and limits for each agent, you are always in charge.
Granular Budget Control
Create multiple budgets that use the same wallet. Each budget includes powerful controls, including spending limits and custom tool access. Experience the freedom to play, experiment, and create, while knowing your spend limits will always be enforced.
Instant Payments
Blockchain payments are settled nearly instantly, opening up a world of opportunity. Agents can now pay and earn with real time cashflow visibility and a smooth seamless experience. Minimal transaction fees and a faster settlement means more efficiency, more value, and lower costs across the board.
Verifiable Records
Every payment is gated through our backend smart contract infrastructure and verified against your rules, only passing through if it meets the criteria you have set. Records are saved and available instantly on the Base chain, providing an immutable, auditable record of every payment with complete transparency and accountability for all agent transactions.
Built on Enterprise Infrastructure
Secure, regulated, and scalable foundation for the agentic economy
USDC Stablecoin
The worlds largest regulated digital dollar with 1:1 USD backing, used by global finance worldwide
Recorded On Base
Layer 2 blockchain with low fees and high speed, built by Coinbase and backed by Ethereum.
Hosted By Circle
Enterprise-grade wallet infrastructure with institutional security standards
X402 Direct Payments
Secure direct payment protocol enabling instant agent-to-agent transactions with complete auditability
Programmable Money + Your AI
Launch and connect in under 10 minutes.
Sign Up
It's free to sign up! Deploy your wallet and complete the setup with only a few clicks. Fund your wallet with USDC through Stripe's fiat onramp or instantly transfer from an existing digital wallet.
Define Permissions
Easily create a new budget with custom spending rules and approved vendors through our intuitive dashboard. Give each agent it's own credentials and spend permissions.
Connect Your Agent
Download our MCP installer to host your own Claude Desktop connection, or send calls instantly through API. Each tool includes custom code samples and documentation to get your agent going in no time.