About Gatewards
Gatewards is an MCP server for agents that discover and call paid APIs through its gateway. It supports per-agent spending limits and cross-agent deduplication, with proxy and self-custody x402 payment modes.
Key features
- 01Discover paid API services
- 02Call APIs through the gateway
- 03Enforce per-agent spend caps
- 04Cache responses and deduplicate calls
- 05Settle x402 payments in self-custody
Use cases
- 01Limit agent spending on API calls
- 02Avoid duplicate requests across agents
- 03Pay for an API call through x402
MCP support
Gatewards exposes tools for discovering services, calling APIs, checking budgets, viewing plans, and subscribing. In proxy mode the gateway enforces budgets and handles caching and deduplication; x402 mode lets the agent sign USDC payments itself.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
npx -y @gatewards/mcp-serverGATEWARDS_API_KEYSecretGatewards agent API key (gw_agent_…). Required for authenticated proxy calls; the server starts without it but cannot reach the gateway.GATEWARDS_GATEWAY_URLGateway base URL. Defaults to http://localhost:3001; set to https://api.gatewards.com for the hosted gateway.Local servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.
Tools
Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.
Details
From the project README@gatewards/mcp-server
An MCP server that lets any agent (Claude Desktop, Cursor, VS Code, or your own MCP client) discover and call paid APIs through Gatewards — with per-agent spend caps, cross-agent dedup, and non-custodial x402 settlement.
The agent keeps its own API key and wallet. Gatewards enforces the spend limit in the request path: a call over budget is refused before it fires, not logged after.
Install
npx @gatewards/mcp-server --api-key=gw_agent_xxx --gateway=https://api.gatewards.com
Claude Desktop
Add to your claude_desktop_config.json:
{
"mcpServers": {
"gatewards": {
"command": "npx",
"args": [
"@gatewards/mcp-server",
"--api-key=gw_agent_xxx",
"--gateway=https://api.gatewards.com"
]
}
}
}
Get an agent key from your Gatewards dashboard.
Two modes
| Mode | How | What you get |
|---|---|---|
| Proxy (default) | --api-key=gw_agent_xxx | Routes calls through the gateway. Per-agent budget enforcement, response caching, and cross-agent dedup. No wallet, no on-chain payment. |
| x402 (self-custody) | --private-key=0x... --rpc-url=... --usdc-address=... | The agent signs USDC payments itself. When an API returns 402, payment is settled on-chain and the request retries with a receipt. Keys never leave your machine. |
Pick proxy mode for governance and caching. Add x402 only when you actually need to pay per call on-chain.
Tools
| Tool | What it does |
|---|---|
gatewards_discover_services | List paid API services on the marketplace (name, endpoint, price). |
gatewards_call_api | Make a GET/POST call. Returns status, data, and cost if a payment was made. |
gatewards_check_budget | Current daily spend, remaining budget, and active subscriptions. |
gatewards_get_plans | List prepaid credit plans for a service. |
gatewards_subscribe | Buy a credit bundle for a service (proxy mode only). |
Configuration
Flags or environment variables (flags win):
| Flag | Env | Default | Notes |
|---|---|---|---|
--gateway | GATEWARDS_GATEWAY_URL | http://localhost:3001 | Gateway base URL. |
--api-key | GATEWARDS_API_KEY | — | Agent key. Enables proxy mode. |
--private-key | GATEWARDS_PRIVATE_KEY | — | 0x-prefixed key for x402 mode. Never sent anywhere. |
--rpc-url | GATEWARDS_RPC_URL | — | Required for x402 mode. |
--usdc-address | GATEWARDS_USDC_ADDRESS | — | Required for x402 mode. |
--network | GATEWARDS_NETWORK | base-sepolia | e.g. base, base-sepolia. |
--merchant | GATEWARDS_MERCHANT_URL | — | Restrict absolute URLs to this origin. |
Either --api-key or --private-key is required.
License
Apache-2.0
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.