Developer builds pay-per-call API for AI agents using USDC and HTTP 402 protocol
A developer has built and deployed an Express-based API on Base mainnet that allows AI agents or any HTTP client to pay per API call in USDC, with no signup or API key required. The system revives the long-dormant HTTP 402 Payment Required status code as a real payment handshake between client and server. When a client hits a paid endpoint, the server returns a 402 response with payment details, the client signs a USDC transfer on Base, and a facilitator verifies and settles the transaction on-chain before the resource is served. The API currently runs 27 live paid endpoints, with real settled transactions already completed, using Coinbase's CDP service as the payment facilitator on mainnet. The wallet address serves as the sole identity, making payment itself the authentication mechanism.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.
Discussion (0)
Log in to join the discussion and vote.
Log in