# Agent Tollbooth 402

> Agent Tollbooth 402 is a freemium MCP server for developer tools. HTTP 402 and x402 pay-per-call billing for APIs and MCP servers, with Stripe top-ups. It runs as a hosted remote server, so there is nothing to install locally.

- **Kind:** MCP server
- **Pricing:** Freemium
- **Platforms:** API, CLI, self-hosted, vscode
- **Website:** https://tollbooth.redcenterstudio.com/pay
- **Repository:** https://github.com/red-center-studio/agent-tollbooth-402
- **MCP Registry name:** io.github.Red-Center-Studio/agent-tollbooth-402
- **Categories:** developer tools
- **Listing updated:** 2026-11-18

## About

The README describes Agent Tollbooth 402 as a way to put pay-per-call pricing in front of Cloudflare Workers, Hono apps, Next.js routes and MCP servers. A route is wrapped so that unpaid requests receive an HTTP 402 challenge, while agents can settle either with x402 V2 USDC payments on Base or with prepaid Fiat Agent Wallets that use signed rcs_receipt tokens checked at the edge.

The package ships with a remote Streamable HTTP MCP endpoint offering pricing quotes, wallet balance checks, receipt issuance, x402 header verification and Stripe checkout link creation. A set of Claude Code and Antigravity plugin skills scans existing routes, injects the middleware, and runs a local sandbox test of the 402, signing, retry and nonce-replay flow without wallets or Stripe keys.

It suits developers who run paid APIs or agent-facing endpoints and want to charge per request. The site lists a 0% fee for self-hosted crypto payments, a 7% fee for hosted Fiat Agent Wallet clearing, and a 3% fee with the Pro or Agency passes.

## Features

- **Per-call HTTP 402 gating:** Wraps a route so unpaid requests receive a 402 challenge with price and accepted payment rails.
- **Dual payment rails:** Accepts x402 V2 USDC payments on Base or prepaid Fiat Agent Wallet receipts.
- **Edge receipt verification:** Checks HMAC-SHA256 or Ed25519 receipts locally with Web Crypto, with D1 nonce replay protection.
- **Local sandbox testing:** Runs the 402, signing and retry loop offline using sandbox mode, without keys or wallets.
- **Remote MCP tools:** Exposes pricing quote, wallet balance, receipt issuance, x402 verification and top-up checkout tools.
- **Route scanning skill:** Plugin skill that scans Workers, Hono, Next.js, Express and MCP endpoints for billable routes.

## Good for

- Charging AI agents a small fee per API call
- Monetizing a Cloudflare Worker or Hono endpoint without building a billing system
- Adding pay-per-request access to an MCP server
- Testing a paywall flow locally before accepting real payments

## Install

### Claude Code (Terminal)

```sh
claude mcp add --transport http agent-tollbooth-402 https://tollbooth.redcenterstudio.com/mcp
```

### Claude Desktop (Settings → Connectors → Add custom connector)

```sh
https://tollbooth.redcenterstudio.com/mcp
```

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "agent-tollbooth-402": {
      "url": "https://tollbooth.redcenterstudio.com/mcp"
    }
  }
}
```

### VS Code (.vscode/mcp.json)

```json
{
  "servers": {
    "agent-tollbooth-402": {
      "type": "http",
      "url": "https://tollbooth.redcenterstudio.com/mcp"
    }
  }
}
```

### Windsurf (~/.codeium/windsurf/mcp_config.json)

```json
{
  "mcpServers": {
    "agent-tollbooth-402": {
      "serverUrl": "https://tollbooth.redcenterstudio.com/mcp"
    }
  }
}
```

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "agent-tollbooth-402": {
      "type": "http",
      "url": "https://tollbooth.redcenterstudio.com/mcp"
    }
  }
}
```

## Tools

- `tollbooth_pricing_quote`: Estimates net earnings across Free, Hybrid and Pro/Agency fee tiers.
- `tollbooth_wallet_balance`: Checks remaining Fiat Agent Wallet credit balance in USD and micro-dollars.
- `tollbooth_issue_receipt`: Issues a short-lived signed rcs_receipt bearer token for agent requests.
- `tollbooth_verify_x402`: Inspects or verifies an x402 V2 PAYMENT-SIGNATURE header payload.
- `tollbooth_create_topup_checkout`: Creates a Stripe Checkout or Payment Link URL for wallet top-ups or passes.

## FAQ

### Can I use x402 V2 without paying any platform fee?

Yes. Setting your own payTo wallet address on Base (eip155:8453) in the middleware config sends USDC payments directly to you, and the site lists a 0% platform fee for this option.

### Can I test locally without a Stripe key or crypto wallet?

Yes. Setting mode to sandbox or running the test-agent skill exercises the 402 headers, signed receipts and nonce replay blocking offline.

### How fast is the Fiat Agent Wallet receipt check?

The site says edge verification uses Web Crypto to validate the receipt locally in under 1ms, without waiting for an external checkout round-trip.

### Is Agent Tollbooth 402 free?

Agent Tollbooth 402 has a free plan, with paid plans for more usage or features.

### How do I add Agent Tollbooth 402 to Claude Code?

Run this command in your terminal: claude mcp add --transport http agent-tollbooth-402 https://tollbooth.redcenterstudio.com/mcp

### What are the best alternatives to Agent Tollbooth 402?

The closest alternatives to Agent Tollbooth 402 are REA, Codebase Memory, GitHub, Serena MCP: the IDE for your agent and XERJ.

## Where this comes from

- Description: written from the project's README, the project's website and its MCP Registry entry.
- Install steps: from the official MCP Registry entry.

## Alternatives

- [REA](https://ai-powered.com/mcp/rea): REA is an open-source MCP server for developer tools.
- [Codebase Memory](https://ai-powered.com/mcp/codebase-memory): Codebase Memory is an open-source MCP server for knowledge and memory.
- [GitHub](https://ai-powered.com/mcp/github-2): GitHub is an open-source MCP server for developer tools.
- [Serena MCP: the IDE for your agent](https://ai-powered.com/mcp/serena-mcp-the-ide-for-your-agent): Serena MCP: the IDE for your agent is an open-source MCP server for developer tools.
- [XERJ](https://ai-powered.com/mcp/xerj): XERJ is an open-source MCP server for knowledge and memory.
- [Ouroboros](https://ai-powered.com/mcp/ouroboros): Ouroboros is an open-source MCP server for developer tools.
- [Claude Code Ultimate Guide](https://ai-powered.com/mcp/claude-code-ultimate-guide): Claude Code Ultimate Guide is an open-source MCP server for ai models and llm tooling.
- [Concord MCP](https://ai-powered.com/mcp/concord-mcp): Concord MCP is a freemium MCP server for developer tools.

---
Source: https://ai-powered.com/mcp/agent-tollbooth-402
