x402 MCP server: give your agent paid tools

The @2sio/mcp server exposes every 2s endpoint as a Model Context Protocol tool. Point Claude Desktop (or any MCP host) at it and your agent can call real APIs and pay per call — no per-tool API keys.

Add the server to your MCP host

Drop this into your MCP host config (Claude Desktop shown). The wallet key funds x402 payments; each endpoint becomes a callable tool:

MCP configjson
// Add @2sio/mcp to any MCP host (Claude Desktop shown). Every 2s endpoint
// becomes a tool the model can call; payments settle per call from your wallet.
{
  "mcpServers": {
    "2sio": {
      "command": "npx",
      "args": ["-y", "@2sio/mcp"],
      "env": { "EVM_PRIVATE_KEY": "0x..." }
    }
  }
}

Or connect by URL (hosted)

Don’t want to run anything? Point your MCP host at the hosted server at https://2s.io/mcp (streamable-HTTP) and set the header X-EVM-Private-Key to an EVM key funded with USDC on Base — the server signs and settles each call. One tradeoff to know: with the hosted server your private key passes through 2s’s infrastructure to sign, so for keys that never leave your machine, prefer the local config above or the SDK.

Hosted MCP endpointbash
https://2s.io/mcp   # header: X-EVM-Private-Key: 0x… (USDC on Base)

Try it free

Run the server in trial mode to let the agent make free real calls (one per endpoint per hour) before you fund a wallet:

MCP — trial modebash
npx -y @2sio/mcp --trial   # or set TWOS_TRIAL=1

What the agent gets

Every endpoint in the catalog shows up as a tool with a typed input schema, so the model knows when and how to call it — weather, patents, sanctions screening, SEC filings, CVEs, geocoding, and the rest. Payment happens automatically per call; you stay in control of the wallet.

Call a live x402 API right now — no signup.

Browse the full endpoint directory, grab the quickstart, or read the llms.txt manifest. Every endpoint is keyless and pay-per-call.

FAQ

What is an x402 MCP server?
An MCP server that exposes x402-payable APIs as tools for an AI agent. @2sio/mcp turns every 2s endpoint into an MCP tool and pays per call from your wallet, so the agent needs no per-API keys.
How do I add it to Claude Desktop?
Add a "2sio" entry to mcpServers in claude_desktop_config.json with command npx and args ["-y", "@2sio/mcp"], plus your EVM_PRIVATE_KEY in env. Restart the host and the tools appear.
Can the agent try tools for free?
Yes. Run npx -y @2sio/mcp --trial (or set TWOS_TRIAL=1) and each tool can make one free real call per hour before you fund a wallet.

Related

Topics: x402 mcp · x402 mcp server · mcp x402 · x402 model context protocol · paid mcp tools · mcp pay per call