HTTP 402 Payment Protocol
🚀 Curated list of x402 resources: HTTP 402 Payment Required protocol for blockchain payments, crypto micropayments, AI agents, API monetization. Includes SDKs (TypeScript, Python, Rust), examples, facilitators (Coinbase, Cloudflare), MCP integration,
What is HTTP 402 Payment Protocol?
HTTP 402 Payment Protocol is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to 🚀 curated list of x402 resources: http 402 payment required protocol for blockchain payments, crypto micropayments, ai agents, api monetization. includes sdks (typescript, python, rust), examples, fa...
🚀 Curated list of x402 resources: HTTP 402 Payment Required protocol for blockchain payments, crypto micropayments, AI agents, API monetization. Includes SDKs (TypeScript, Python, Rust), examples, facilitators (Coinbase, Cloudflare), MCP integration,
This server falls under the Finance & Fintech category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- 🚀 Curated list of x402 resources: HTTP 402 Payment Required
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx awesome-x402Configuration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use HTTP 402 Payment Protocol
Awesome X402 is a curated resource hub covering the x402 HTTP payment protocol, which uses the HTTP 402 'Payment Required' status code to enable instant blockchain micropayments for API calls and AI agent transactions. The project documents SDKs in TypeScript, Python, Rust, and Go; hosted facilitators including Coinbase CDP and Cloudflare; 80+ MCP servers that accept x402 payments; and 1,000+ payable API endpoints across data, AI/ML, finance, and content domains. It serves as the definitive reference for developers building payment-gated APIs, autonomous agent economics, or USDC-based micropayment systems on Base L2.
Prerequisites
- Node.js 18+ (for TypeScript SDK: npm install x402-express or x402-next)
- Python 3.8+ (for Python SDK: pip install x402)
- A Coinbase CDP account or self-hosted facilitator for processing payments
- A wallet with USDC on Base L2 for making payments as an agent
- Familiarity with HTTP middleware concepts for server-side integration
Explore the awesome-x402 resource index
Visit the GitHub repository to browse the full curated list of x402 SDKs, MCP servers, example projects, facilitators, and payable endpoints organized by category.
# Repository: https://github.com/xpaysh/awesome-x402Install an x402 SDK for your language
Choose the SDK matching your server or client language. The TypeScript packages integrate as Express or Next.js middleware; the Python package wraps requests.
# TypeScript (Express):
npm install x402-express
# TypeScript (Next.js):
npm install x402-next
# Python:
pip install x402Connect to a facilitator for payment processing
Sign up for a Coinbase CDP account to use their hosted facilitator, or deploy a self-hosted facilitator using the Rust or Go implementations listed in the awesome-x402 repository.
Configure an MCP server to use x402 payment gating
Add an x402-compatible MCP server to your client configuration. The server will require USDC micropayments for each tool call, debiting your agent's wallet automatically.
{
"mcpServers": {
"awesome-x402": {
"command": "npx",
"args": ["awesome-x402"]
}
}
}Test with a free-tier payable endpoint
Use one of the 1,000+ endpoints indexed in the repository. Many have free tiers or charge as little as $0.001 USDC per call. The agentsvc.io suite is a good starting point with ip-lookup, dns-lookup, weather, and crypto-prices tools.
HTTP 402 Payment Protocol Examples
Client configuration
Basic MCP client config for the awesome-x402 server. Actual payment wallet configuration depends on the specific x402 MCP server you connect to.
{
"mcpServers": {
"awesome-x402": {
"command": "npx",
"args": ["awesome-x402"]
}
}
}Prompts to try
These prompts are relevant when working with x402-enabled MCP servers or building payment-gated APIs.
- "Look up the current weather using an x402-payable weather API endpoint"
- "What are the best x402 MCP servers for accessing real-time crypto price data?"
- "Show me how to add x402 payment gating to an Express.js API route"
- "Find x402-compatible endpoints for OFAC sanctions screening"
- "List all x402 SDKs and their GitHub repositories from the awesome list"Troubleshooting HTTP 402 Payment Protocol
Payment fails with 'insufficient balance' even though wallet has USDC
Ensure your wallet USDC is on Base L2 (not Ethereum mainnet or other chains). x402 uses Base L2 for 2-second settlement. Bridge USDC to Base via Coinbase or bridge.base.org before attempting payments.
x402 middleware returns 402 but agent does not know how to pay
The AI agent must be connected through an x402-aware MCP client or SDK that can parse the 402 response, extract the payment details from the X-Payment-Required header, sign a payment, and retry the request with the X-Payment header.
TypeScript SDK types are not found after npm install
Ensure you install the correct package for your framework (x402-express for Express, x402-next for Next.js). Run 'npm install --save-dev @types/node' if TypeScript cannot find Node.js types, and restart your TypeScript language server.
Frequently Asked Questions about HTTP 402 Payment Protocol
What is HTTP 402 Payment Protocol?
HTTP 402 Payment Protocol is a Model Context Protocol (MCP) server that 🚀 curated list of x402 resources: http 402 payment required protocol for blockchain payments, crypto micropayments, ai agents, api monetization. includes sdks (typescript, python, rust), examples, facilitators (coinbase, cloudflare), mcp integration, It connects AI assistants to external tools and data sources through a standardized interface.
How do I install HTTP 402 Payment Protocol?
Follow the installation instructions on the HTTP 402 Payment Protocol GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with HTTP 402 Payment Protocol?
HTTP 402 Payment Protocol works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is HTTP 402 Payment Protocol free to use?
Yes, HTTP 402 Payment Protocol is open source and available under the CC0-1.0 license. You can use it freely in both personal and commercial projects.
HTTP 402 Payment Protocol Alternatives — Similar Finance & Fintech Servers
Looking for alternatives to HTTP 402 Payment Protocol? Here are other popular finance & fintech servers you can use with Claude, Cursor, and VS Code.
ValueCell
★ 10.7kValueCell is a community-driven, multi-agent platform for financial applications.
Vibe Trading
★ 8.1k'Vibe-Trading: Your Personal Trading Agent'
Quantdinger
★ 6.2kAI quantitative trading platform for crypto, stocks, and forex with backtesting, live trading, market data, and multi-agent research.vibe-trading ,trading-agents,ai-trader,ai-trading
TradingView
★ 2.8kReal-time crypto & stock screening, advanced technical indicators, Bollinger Bands intelligence, candlestick patterns + native Claude Desktop integration. Multi-exchange (Binance, KuCoin, Bybit+). Open-source AI trading infrastructure.
Financial Datasets
★ 2.1kProvides access to comprehensive financial data including income statements, balance sheets, cash flow statements, stock prices, company news, SEC filings, and cryptocurrency information with built-in financial ratio analysis.
Stripe
★ 1.6kThe Stripe Model Context Protocol server allows you to integrate with Stripe APIs through function calling. This protocol supports various tools to interact with different Stripe services.
Browse More Finance & Fintech MCP Servers
Explore all finance & fintech servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up HTTP 402 Payment Protocol in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use HTTP 402 Payment Protocol?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.