HTTP 402
HTTP 402 is the response status code named Payment Required. RFC 9110 reserves it and defines no payment format, which leaves the meaning of such a response to whatever protocol is layered above it. x402 is one such protocol, and the status code is not the same thing as the protocol.
RFC 9110 lists the code as reserved for future use. No standard header, body or retry behaviour is attached to it, so a bare HTTP 402 tells a client that payment is expected and nothing whatever about how to pay.
x402 supplies the missing half: a machine-readable statement of what would satisfy the request, and a signed authorization carried on the retry. Its current HTTP transport puts both in headers: the quote in PAYMENT-REQUIRED, the authorization in PAYMENT-SIGNATURE. The earlier one carried the quote as a JSON body, with an X-PAYMENT header on the retry. A client that speaks the protocol can therefore complete a payment with no human in the loop, which a status code on its own can never support.
→ Every reading probe402 holds records what an endpoint actually answered, HTTP 402 and its body included — start at the endpoint list.
Sources
- RFC 9110: HTTP SemanticsIETF
- Core concepts: HTTP 402x402 project documentation
- Transports: the HTTP transport (v2)x402 Foundation
- Transports: the HTTP transport (v1)x402 Foundation
Related x402 · accepts array · payTo · status class · payment challenge · L402 · pay per crawl