a402 pay mcp for VS Code
io.github.agent402-dev/a402-pay-mcp
Pay x402 APIs (USDC, PREQ) and run Agent402 Bond deals from your own wallet. Refuses by default.
client:VS Code
transport:stdio
runtime:npm
Install a402 pay mcp in VS Code
.vscode/mcp.json
{
"inputs": [
{
"type": "promptString",
"id": "x402-keypair-path",
"description": "X402_KEYPAIR_PATH",
"password": true
},
{
"type": "promptString",
"id": "x402-allowed-domains",
"description": "X402_ALLOWED_DOMAINS",
"password": true
},
{
"type": "promptString",
"id": "x402-trusted-pay-to",
"description": "X402_TRUSTED_PAY_TO",
"password": true
},
{
"type": "promptString",
"id": "x402-allowed-assets",
"description": "X402_ALLOWED_ASSETS",
"password": true
},
{
"type": "promptString",
"id": "x402-max-usd",
"description": "X402_MAX_USD",
"password": true
},
{
"type": "promptString",
"id": "x402-max-usd-per-day",
"description": "X402_MAX_USD_PER_DAY",
"password": true
},
{
"type": "promptString",
"id": "x402-max-payments-per-day",
"description": "X402_MAX_PAYMENTS_PER_DAY",
"password": true
},
{
"type": "promptString",
"id": "x402-max-usd-per-recipient-per-day",
"description": "X402_MAX_USD_PER_RECIPIENT_PER_DAY",
"password": true
},
{
"type": "promptString",
"id": "x402-max-preq-atomic",
"description": "X402_MAX_PREQ_ATOMIC",
"password": true
},
{
"type": "promptString",
"id": "x402-max-preq-per-day-atomic",
"description": "X402_MAX_PREQ_PER_DAY_ATOMIC",
"password": true
},
{
"type": "promptString",
"id": "x402-max-preq-per-recipient-per-day-atomic",
"description": "X402_MAX_PREQ_PER_RECIPIENT_PER_DAY_ATOMIC",
"password": true
},
{
"type": "promptString",
"id": "x402-confirm-above-usd",
"description": "X402_CONFIRM_ABOVE_USD",
"password": true
},
{
"type": "promptString",
"id": "x402-confirm-above-preq-atomic",
"description": "X402_CONFIRM_ABOVE_PREQ_ATOMIC",
"password": true
},
{
"type": "promptString",
"id": "x402-require-lock",
"description": "X402_REQUIRE_LOCK",
"password": true
},
{
"type": "promptString",
"id": "x402-require-lock-above-usd",
"description": "X402_REQUIRE_LOCK_ABOVE_USD",
"password": true
},
{
"type": "promptString",
"id": "x402-min-lock-days",
"description": "X402_MIN_LOCK_DAYS",
"password": true
},
{
"type": "promptString",
"id": "x402-min-lock-preq-atomic",
"description": "X402_MIN_LOCK_PREQ_ATOMIC",
"password": true
},
{
"type": "promptString",
"id": "x402-min-lock-usdc-atomic",
"description": "X402_MIN_LOCK_USDC_ATOMIC",
"password": true
},
{
"type": "promptString",
"id": "x402-min-lock-sol-atomic",
"description": "X402_MIN_LOCK_SOL_ATOMIC",
"password": true
},
{
"type": "promptString",
"id": "x402-bond-sellers",
"description": "X402_BOND_SELLERS",
"password": true
},
{
"type": "promptString",
"id": "x402-bond-max-usd",
"description": "X402_BOND_MAX_USD",
"password": true
},
{
"type": "promptString",
"id": "x402-bond-min-seller-bond-bps",
"description": "X402_BOND_MIN_SELLER_BOND_BPS",
"password": true
},
{
"type": "promptString",
"id": "x402-bond-max-days",
"description": "X402_BOND_MAX_DAYS",
"password": true
},
{
"type": "promptString",
"id": "x402-bond-confirm-above-usd",
"description": "X402_BOND_CONFIRM_ABOVE_USD",
"password": true
},
{
"type": "promptString",
"id": "x402-bond-max-preq-atomic",
"description": "X402_BOND_MAX_PREQ_ATOMIC",
"password": true
},
{
"type": "promptString",
"id": "x402-bond-confirm-above-preq-atomic",
"description": "X402_BOND_CONFIRM_ABOVE_PREQ_ATOMIC",
"password": true
},
{
"type": "promptString",
"id": "x402-bond-directory-url",
"description": "X402_BOND_DIRECTORY_URL",
"password": true
},
{
"type": "promptString",
"id": "x402-network",
"description": "X402_NETWORK",
"password": true
},
{
"type": "promptString",
"id": "x402-rpc-url",
"description": "X402_RPC_URL",
"password": true
},
{
"type": "promptString",
"id": "x402-pay-with",
"description": "X402_PAY_WITH",
"password": true
},
{
"type": "promptString",
"id": "x402-preq-mint",
"description": "X402_PREQ_MINT",
"password": true
},
{
"type": "promptString",
"id": "x402-history-path",
"description": "X402_HISTORY_PATH",
"password": true
}
],
"servers": {
"a402-pay-mcp": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@agent402-dev/pay-mcp"
],
"env": {
"X402_KEYPAIR_PATH": "${input:x402-keypair-path}",
"X402_ALLOWED_DOMAINS": "${input:x402-allowed-domains}",
"X402_TRUSTED_PAY_TO": "${input:x402-trusted-pay-to}",
"X402_ALLOWED_ASSETS": "${input:x402-allowed-assets}",
"X402_MAX_USD": "${input:x402-max-usd}",
"X402_MAX_USD_PER_DAY": "${input:x402-max-usd-per-day}",
"X402_MAX_PAYMENTS_PER_DAY": "${input:x402-max-payments-per-day}",
"X402_MAX_USD_PER_RECIPIENT_PER_DAY": "${input:x402-max-usd-per-recipient-per-day}",
"X402_MAX_PREQ_ATOMIC": "${input:x402-max-preq-atomic}",
"X402_MAX_PREQ_PER_DAY_ATOMIC": "${input:x402-max-preq-per-day-atomic}",
"X402_MAX_PREQ_PER_RECIPIENT_PER_DAY_ATOMIC": "${input:x402-max-preq-per-recipient-per-day-atomic}",
"X402_CONFIRM_ABOVE_USD": "${input:x402-confirm-above-usd}",
"X402_CONFIRM_ABOVE_PREQ_ATOMIC": "${input:x402-confirm-above-preq-atomic}",
"X402_REQUIRE_LOCK": "${input:x402-require-lock}",
"X402_REQUIRE_LOCK_ABOVE_USD": "${input:x402-require-lock-above-usd}",
"X402_MIN_LOCK_DAYS": "${input:x402-min-lock-days}",
"X402_MIN_LOCK_PREQ_ATOMIC": "${input:x402-min-lock-preq-atomic}",
"X402_MIN_LOCK_USDC_ATOMIC": "${input:x402-min-lock-usdc-atomic}",
"X402_MIN_LOCK_SOL_ATOMIC": "${input:x402-min-lock-sol-atomic}",
"X402_BOND_SELLERS": "${input:x402-bond-sellers}",
"X402_BOND_MAX_USD": "${input:x402-bond-max-usd}",
"X402_BOND_MIN_SELLER_BOND_BPS": "${input:x402-bond-min-seller-bond-bps}",
"X402_BOND_MAX_DAYS": "${input:x402-bond-max-days}",
"X402_BOND_CONFIRM_ABOVE_USD": "${input:x402-bond-confirm-above-usd}",
"X402_BOND_MAX_PREQ_ATOMIC": "${input:x402-bond-max-preq-atomic}",
"X402_BOND_CONFIRM_ABOVE_PREQ_ATOMIC": "${input:x402-bond-confirm-above-preq-atomic}",
"X402_BOND_DIRECTORY_URL": "${input:x402-bond-directory-url}",
"X402_NETWORK": "${input:x402-network}",
"X402_RPC_URL": "${input:x402-rpc-url}",
"X402_PAY_WITH": "${input:x402-pay-with}",
"X402_PREQ_MINT": "${input:x402-preq-mint}",
"X402_HISTORY_PATH": "${input:x402-history-path}"
}
}
}
}
VS Code prompts for each input the first time the server starts, so no secret is written to the file. VS Code docs