Open-source Infrastructure for MCP and x402
接入配置
选择客户端,复制配置,再按项目文档补齐环境变量。
claude mcp add mcpay --env URLS='<URLS>' -- npx mcpay server --urls https://mcpay.tech/mcp/05599356-7a27-4519-872a-2ebb22467470 --api-key mcpay_YOUR_API_KEY~/.codex/config.toml
[mcp_servers.mcpay]
command = "npx"
args = ["mcpay", "server", "--urls", "https://mcpay.tech/mcp/05599356-7a27-4519-872a-2ebb22467470", "--api-key", "mcpay_YOUR_API_KEY"]
env = { URLS = "<URLS>" }
# codex mcp add mcpay --env URLS='<URLS>' -- npx mcpay server --urls https://mcpay.tech/mcp/05599356-7a27-4519-872a-2ebb22467470 --api-key mcpay_YOUR_API_KEY~/.cursor/mcp.json
{
"mcpServers": {
"mcpay": {
"command": "npx",
"args": [
"mcpay",
"server",
"--urls",
"https://mcpay.tech/mcp/05599356-7a27-4519-872a-2ebb22467470",
"--api-key",
"mcpay_YOUR_API_KEY"
],
"env": {
"URLS": "<URLS>"
}
}
}
}.vscode/mcp.json
{
"servers": {
"mcpay": {
"type": "stdio",
"command": "npx",
"args": [
"mcpay",
"server",
"--urls",
"https://mcpay.tech/mcp/05599356-7a27-4519-872a-2ebb22467470",
"--api-key",
"mcpay_YOUR_API_KEY"
],
"env": {
"URLS": "<URLS>"
}
}
}
}~/.gemini/settings.json
{
"mcpServers": {
"mcpay": {
"command": "npx",
"args": [
"mcpay",
"server",
"--urls",
"https://mcpay.tech/mcp/05599356-7a27-4519-872a-2ebb22467470",
"--api-key",
"mcpay_YOUR_API_KEY"
],
"env": {
"URLS": "<URLS>"
}
}
}
}claude_desktop_config.json
{
"mcpServers": {
"mcpay": {
"command": "npx",
"args": [
"mcpay",
"server",
"--urls",
"https://mcpay.tech/mcp/05599356-7a27-4519-872a-2ebb22467470",
"--api-key",
"mcpay_YOUR_API_KEY"
],
"env": {
"URLS": "<URLS>"
}
}
}
}.trae/mcp.json
{
"mcpServers": {
"mcpay": {
"command": "npx",
"args": [
"mcpay",
"server",
"--urls",
"https://mcpay.tech/mcp/05599356-7a27-4519-872a-2ebb22467470",
"--api-key",
"mcpay_YOUR_API_KEY"
],
"env": {
"URLS": "<URLS>"
}
}
}
}需要的环境变量
URLS
把占位值换成你自己的密钥;不要把密钥提交到代码仓库。