Skip to main content
With x402, an AI agent pays in USDC for each API call and gets the same labeled wallet data as with an API key. There is no account, no signup and no key. The wallet is the identity. x402 builds on the HTTP status code 402 Payment Required: the server answers a request with a price, the client pays and repeats the request with proof of payment.

Install

Quick start

The returned object is a full CabalSpy client, the same as in the SDKs. Only the payment differs.

Spend limits

A funded wallet handed to an autonomous agent is a standing authorisation to spend. Both limits are on unless you turn them off. The price is read from the 402 response and checked before the wallet signs anything. A server asking for more than expected is refused without spending.

Payment networks

CabalSpy accepts USDC on Solana, Base, Polygon and Arbitrum and offers all of them in the same response. The payment chain is independent of the data: a question about a Base wallet can be paid for in Solana USDC. To test without real money, restrict the client to solana-devnet. The flow is identical.

Source

cabalspy-x402 (TypeScript)

npm package and source.

cabalspy-x402 (Python)

PyPI package and source.
Prefer a monthly plan with predictable cost? Use an API key instead. Both return the same data.