MCP server

agent402-mcp · npm · MIT

An MCP server for any MCP client (Claude Desktop, Claude Code, Cursor and others). Flagship tools are listed as first-class MCP tools and the rest of the catalog is reachable through catalog.search, catalog.find and catalog.call, with skill packs surfaced as MCP prompts. The hosted connector at /mcp needs no install at all.

Install

npx -y agent402-mcp

Example

{
  "mcpServers": {
    "agent402": {
      "command": "npx",
      "args": ["-y", "agent402-mcp"],
      "env": { "AGENT_KEY": "0xYOUR_EVM_PRIVATE_KEY" }
    }
  }
}

What it exposes

  • Flagship tools under dotted names: web.search, web.answer, web.news, browser.render, market.quote, audio.transcribe, memory.read, memory.write.
  • catalog.search / catalog.find + catalog.call for the rest of the catalog, keeping the context window small.
  • payment.info, server.describe and sellers.list for orientation, spend caps and the live seller leaderboards.
  • Skill packs as MCP prompts (prompts/list, prompts/get).

How payment works

  • AGENT_KEY (EVM) or SOLANA_AGENT_KEY: the server signs an x402 payment on a chain the tool accepts and retries.
  • AGENT402_CREDITS_KEY: a credits key bought earlier, sent as Authorization: Bearer a402_...; the list price is debited only on a 200.
  • Neither: the pure-CPU tools pay with proof-of-work (about 0.2 s of CPU).
  • AGENT402_MAX_PER_CALL and AGENT402_BUDGET are enforced before a payment is signed. The hosted /mcp connector is also payable over MPP from an mppx-wrapped MCP client.
# Claude Code, hosted connector (no install; proof-of-work tools)
claude mcp add --transport http agent402 https://agent402.tools/mcp

# Claude Code, local server paying from a wallet
claude mcp add agent402 -e AGENT_KEY=0x... -- npx -y agent402-mcp

# no AGENT_KEY: the local server still runs the pure-CPU tools by proof-of-work

A call that fails is not charged: settlement runs after the tool and only on a successful response. Background: Payments over MCP · MPP (Machine Payments Protocol).

Tools to try first

Every tool, price and input schema: our tools.

Links