What is x402? The HTTP Payment Protocol for AI Agents
The x402 protocol is an open standard that brings native payments to the HTTP layer. Built on the long-dormant HTTP 402 status code ("Payment Required"), x402 enables machines—particularly autonomous AI agents—to negotiate and execute payments without human intervention. It is the foundational payment rail for the emerging agentic commerce stack, and Syndicate Links provides the attribution layer that sits on top of it.
The Origin of HTTP 402
When the HTTP specification was drafted in the 1990s, its authors reserved status code 402 for future use. The intent was clear: the web would eventually need a native way to handle payments at the protocol level. For decades, 402 remained unimplemented. Payments were handled out-of-band through redirects to checkout pages, iframes, and JavaScript-heavy flows—all designed for humans operating browsers.
The x402 protocol finally activates this reserved status code. When a server returns a 402 Payment Required response, it includes a structured payment request in the response headers. The requesting client—whether a browser, an API consumer, or an autonomous AI agent—can parse that request, execute payment, and retry the original request with a payment proof attached. No redirects. No checkout pages. No cookies. Just HTTP.
This matters because the next wave of internet commerce will not be mediated by humans clicking buttons. It will be mediated by AI agents making autonomous decisions—comparing prices, evaluating quality, and executing transactions on behalf of users. These agents need a payment protocol that speaks their language: HTTP request-response cycles, structured headers, and cryptographic proofs.
Who Is Behind x402
The x402 protocol is an open standard under the Linux Foundation. Its development and adoption are backed by a coalition of the most significant companies in payments and technology:
- Coinbase — One of the original architects of the x402 specification, providing the crypto-native payment settlement infrastructure.
- Stripe — The dominant internet payments processor, bringing fiat payment rail integration to x402.
- Google — Contributing to the protocol's integration with web standards and AI agent frameworks.
- Visa — Ensuring x402 compatibility with existing card network infrastructure.
- Mastercard — Collaborating on interoperability between traditional payment networks and protocol-native payments.
This coalition signals that x402 is not a niche crypto experiment. It is a serious infrastructure standard designed to unify fiat and crypto payment rails under a single protocol-level interface. The involvement of both traditional payment networks (Visa, Mastercard, Stripe) and crypto-native infrastructure (Coinbase) means that agents using x402 can settle payments in whatever medium the merchant accepts.
How x402 Works: The Technical Flow
A standard x402 transaction follows a deterministic flow:
- Agent makes an HTTP request to a resource (an API endpoint, a product page, a data source).
- Server returns 402 Payment Required with a structured payment request in the
X-Paymentresponse header. This includes the price, accepted payment methods, and a payment address or session identifier. - Agent evaluates the payment request against its budget, authorization policies, and the user's preferences.
- Agent executes payment via the specified rail (on-chain transfer, Stripe token, card network token).
- Agent retries the original request with a
X-Payment-Proofheader containing the transaction receipt or cryptographic proof of payment. - Server validates the proof and returns the requested resource with a
200 OKresponse.
The entire cycle happens in milliseconds. No browser is opened. No human is prompted. The agent autonomously decides whether the resource is worth the price, pays for it, and consumes the result.
This is fundamentally different from every existing payment flow on the internet. There is no checkout page. There is no session. There is no cookie. The payment is embedded in the protocol itself.
Attribution on Top of x402: Where Syndicate Links Fits
Payments solve the settlement problem—how value moves from buyer to seller. But they do not solve the attribution problem—how the entity that drove the transaction gets credit and compensation.
When an AI agent recommends a product, compares services, or routes a user to a merchant, that agent has created economic value. The merchant acquired a customer they would not otherwise have reached. In the human web, this attribution function is handled by publisher networks using cookies, redirect chains, and pixel tracking. None of those mechanisms work for autonomous agents operating via APIs.
Syndicate Links provides the attribution layer purpose-built for x402 transactions. The integration works through two complementary mechanisms:
SLAT tokens (Syndicate Links Attribution Tokens): When a publisher agent generates a recommendation, it creates a signed slat_v1 token using HMAC-SHA256. This token encodes the agent's identity (aff_agent_ key), the merchant, the product or service being recommended, and a timestamp. The token is cryptographically verifiable and does not depend on browser state.
atxp_reference (x402 Attribution Reference): When the purchasing agent executes a payment via x402, the SLAT token is included as an atxp_reference in the payment proof. This embeds attribution data directly into the payment transaction. The merchant's server can verify both the payment proof and the attribution claim in a single validation step.
This architecture means that attribution is not a separate tracking system bolted onto the side of a payment flow. It is embedded in the payment itself. Every x402 transaction can carry a cryptographic proof of who drove it, verified at the protocol level rather than inferred from browser cookies.
The Agent Commerce Stack
x402 and Syndicate Links together form two critical layers of the emerging agent commerce stack:
| Layer | Function | Protocol/System |
|---|---|---|
| Discovery | Agent finds products and services | Web search, APIs, MCP servers |
| Evaluation | Agent compares options and makes recommendations | Agent reasoning, tool use |
| Attribution | The recommending agent gets credit | Syndicate Links (SLAT tokens) |
| Payment | Value transfers from buyer to seller | x402 protocol |
| Settlement | Funds clear and commissions distribute | On-chain settlement, Stripe payouts |
This stack is fully machine-readable. No step requires a human to click, no step requires a browser, and no step depends on client-side state. It is the infrastructure layer for a world where AI agents are the primary economic actors on the internet.
The x402 protocol solves payments. Syndicate Links solves attribution. Together, they enable a complete commercial transaction—from recommendation to payment to commission—executed entirely by autonomous software agents.
Related Docs
- Agentic Commerce Infrastructure — How x402, attribution, and settlement form the full agent commerce stack.
- What is Agent Attribution? — The foundational concept behind tracking AI agent referrals.
- x402 Attribution Integration — Technical specification for embedding SLAT tokens in x402 payment flows.