AP2 and x402 are both called agent payment protocols, but they answer different questions. AP2 (Agent Payments Protocol) proves what a customer approved: signed mandates for a purchase and its payment, which merchants and payment services can verify. x402 lets software pay for a single resource over HTTP: the server answers an unpaid request with HTTP 402 and payment requirements, the client returns payment evidence and gets the service. AP2 is about authority for a shopping purchase; x402 is about paying per request for digital services.
AP2 vs x402 at a glance
| AP2 | x402 | |
|---|---|---|
| Question it answers | What did the customer authorise the agent to buy and pay? | How does software pay for this one request? |
| Publisher | Developed by Google; contributed to FIDO standardisation work | x402 Foundation |
| Mechanism | Checkout Mandate and Payment Mandate | HTTP 402 response with payment requirements, then payment evidence |
| Typical use | A shopping agent buying from a merchant | An agent paying for an API call or a data request |
| Payment route | Works alongside existing payment methods | Determined by the payment scheme and network in the requirements |
| Current state | Release 0.2.0 | Specification family v2 |
| Licence | Apache-2.0 | Apache-2.0 |
Sources and versions: AP2 profile and x402 profile.
When does a merchant need x402?
When it sells something software buys in small units: a search query, a dataset, an API call. AWS Marketplace now lets agents pay per request for selected services through Amazon Bedrock AgentCore with x402; a first request gets HTTP 402 with a signed quote and AgentCore checks the session budget before issuing a payment token (our analysis). In Chapter 8 I describe our x402 research preview, in which a Shopware plugin links an order to a payment request that software can read.
When does a merchant need AP2?
When a customer delegates a purchase and the merchant or payment service must be able to show later what was approved. AP2 is integrated into UCP checkout through a mandate extension and is also available as an A2A extension. It does not move money by itself; it records the authority behind the payment.
Can they be combined?
Yes, in principle, because they sit at different points: approval on one side, a payment request for a resource on the other. Google's agentic commerce organisation on GitHub, home of AP2, also hosts an A2A x402 extension that adds x402 payments to agent-to-agent conversations. For a typical retail shop, AP2-style approval matters first; x402 becomes relevant for digital, per-request offers.