Drop-in HTTP 402 + MCP paywall. Point it at any existing API; agents pay USDC per call.
接入配置
选择客户端,复制配置,再按项目文档补齐环境变量。
claude mcp add x402-micro-tollgate --env CDP_API_KEY_ID='<CDP_API_KEY_ID>' --env CDP_API_KEY_SECRET='<CDP_API_KEY_SECRET>' -- npx -y x402-micro-tollgate~/.codex/config.toml
[mcp_servers.x402-micro-tollgate]
command = "npx"
args = ["-y", "x402-micro-tollgate"]
env = { CDP_API_KEY_ID = "<CDP_API_KEY_ID>", CDP_API_KEY_SECRET = "<CDP_API_KEY_SECRET>" }
# codex mcp add x402-micro-tollgate --env CDP_API_KEY_ID='<CDP_API_KEY_ID>' --env CDP_API_KEY_SECRET='<CDP_API_KEY_SECRET>' -- npx -y x402-micro-tollgate~/.cursor/mcp.json
{
"mcpServers": {
"x402-micro-tollgate": {
"command": "npx",
"args": [
"-y",
"x402-micro-tollgate"
],
"env": {
"CDP_API_KEY_ID": "<CDP_API_KEY_ID>",
"CDP_API_KEY_SECRET": "<CDP_API_KEY_SECRET>"
}
}
}
}.vscode/mcp.json
{
"servers": {
"x402-micro-tollgate": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"x402-micro-tollgate"
],
"env": {
"CDP_API_KEY_ID": "<CDP_API_KEY_ID>",
"CDP_API_KEY_SECRET": "<CDP_API_KEY_SECRET>"
}
}
}
}~/.gemini/settings.json
{
"mcpServers": {
"x402-micro-tollgate": {
"command": "npx",
"args": [
"-y",
"x402-micro-tollgate"
],
"env": {
"CDP_API_KEY_ID": "<CDP_API_KEY_ID>",
"CDP_API_KEY_SECRET": "<CDP_API_KEY_SECRET>"
}
}
}
}claude_desktop_config.json
{
"mcpServers": {
"x402-micro-tollgate": {
"command": "npx",
"args": [
"-y",
"x402-micro-tollgate"
],
"env": {
"CDP_API_KEY_ID": "<CDP_API_KEY_ID>",
"CDP_API_KEY_SECRET": "<CDP_API_KEY_SECRET>"
}
}
}
}.trae/mcp.json
{
"mcpServers": {
"x402-micro-tollgate": {
"command": "npx",
"args": [
"-y",
"x402-micro-tollgate"
],
"env": {
"CDP_API_KEY_ID": "<CDP_API_KEY_ID>",
"CDP_API_KEY_SECRET": "<CDP_API_KEY_SECRET>"
}
}
}
}需要的环境变量
CDP_API_KEY_IDCDP_API_KEY_SECRET
把占位值换成你自己的密钥;不要把密钥提交到代码仓库。