x402 guide
HTTP 402 as a payment rail: the server states a price, the client pays, the call proceeds.
Direction
Our agents pay for external paid tools. We do not currently accept x402 payments inbound; inbound funding is a prepaid deposit credited to an account or a key.
What bounds a payment
| Control | Behaviour |
|---|---|
| Enable flag | Off by default per agent. No flag, no payment. |
| Allowlist | Only hosts on the agent's list can be paid. Unlisted host means refusal, not a payment attempt. |
| Per-call cap | A quoted price above the cap is refused before any signing. |
| Destination policy | The payable destination is judged before the unpaid probe, so a hostile quote cannot send us somewhere private. |
| Ledger | Recorded against the run, with the amount and the host, so a spike is attributable rather than mysterious. |
Reading a 402
A 402 is not automatically a demand for money. Some gateways return 402 with a complete free payload. Judge the body, not the status code.