Agent payments, with a clear receipt.
Use x402 to buy $5 of prepaid MCP credit with native USDC on Base. Successful MCP model-help calls cost $0.001 each. Direct gateway routing stays free. Your NVIDIA key, provider eligibility and quota are separate.
Before paying
- Sign in, enable free gateway access and create a private router token. Attach an authorized NVIDIA key to use model help.
- The owner must explicitly enable paid MCP calls in the workspace. Buying credit does not change that choice.
- Use a wallet with native USDC on Base and an x402 v2 client. Obtain the owner's approval for the $5 purchase or use an existing, explicit spending allowance. RouteMyAgent never needs the wallet seed or private key.
- Check service discovery for
products.mcp_helper.x402.available. If unavailable, use the existing Stripe credit checkout in the workspace.
The payment flow
- Send an unsigned
POST https://routemyagent.dev/api/x402/mcp-creditto obtain HTTP 402, the JSON quote and the base64-encodedPAYMENT-REQUIREDheader. Omit the payment signature for this check; it does not spend money.GETreturns an HTTP 200 preview withpurchase_method,purchase_urlandquote; that preview is never a payment receipt. Signed GET requests are rejected without settlement. - Confirm the quote uses x402 v2,
exact, Baseeip155:8453, native USDC0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913and amount5000000(5 USDC). Check the receiving address against service discovery and the owner's authorization. - Generate and save a unique purchase ID of 16–100 letters, digits, hyphens or underscores. Save it before signing. Your x402 client signs the exact quote with EIP-3009, preserving the resource and Bazaar extension.
- Send
POST /api/x402/mcp-creditwithContent-Type: application/json, your privateAuthorization: Bearer …router token, the client'sPAYMENT-SIGNATUREheader and body{"idempotency_key":"your-saved-unique-purchase-id"}. Keep both credentials and signed payment out of chat and logs. - The server authenticates your account, verifies and settles with Coinbase's facilitator, then credits your existing balance once. A settled response is HTTP 200 with
state: settled,cents: 500, transaction hash andPAYMENT-RESPONSEheader. Check authenticatedGET /api/agent/statusfor balance and MCP readiness.
If a response is interrupted
Keep the saved purchase ID. With the same router token, request GET /api/x402/mcp-credit/{idempotency_key}. settled means credit was recorded. HTTP 202 with settling or unknown does not mean payment failed: preserve the wallet transaction and contact support before paying again. No automatic settlement replay or refill occurs. A missing receipt does not authorize a new payment; reconcile the original attempt first.
Repeated requests with the same purchase ID return its existing result. A signed authorization cannot fund a different account or purchase. Signing a new authorization after an uncertain response risks a second payment.
Where the money goes
This is prepaid software-use credit, separate from optional support tips and provider charges. Funds are settled to the service's configured receiving wallet. Blockchain payments and transaction metadata are public and generally irreversible. Coinbase verifies and settles the signed payment; RouteMyAgent stores the account-linked purchase, authorization identity and settlement receipt for accounting and recovery.
Never transfer funds directly to a wallet address expecting automatic credit. Only the authenticated x402 purchase flow associates a payment with your account.