AP2 — Agent Payments Protocol
Google's payment authorisation protocol. AstraSync issues AP2 v0.2 Checkout and Payment mandates to merchants that speak AP2.
Google's payment authorisation protocol. Authority for a purchase is carried in mandates: SD-JWT credentials that bind a checkout (what is being bought, from whom, for how much) and its payment to a verified agent and the human it acts for.
AP2 v0.2 mandates from AstraSync
AstraSync issues AP2 v0.2 Checkout + Payment mandates to merchants that speak AP2. They arrive
on the verification result as result.mandates (Verification Gateway SDK 5.15.0 and later):
interface AstraSyncMandates {
kid: string; // AstraSync signing key, in AstraSync's JWKS
mode: 'closed' | 'open';
checkout: string; // SD-JWT: mandate.checkout.1 / mandate.checkout.open.1
payment?: string; // SD-JWT: mandate.payment.1 / mandate.payment.open.1
}Mandates are issued only when both hold:
- your endpoint lists
ap2in its supported protocols, and - the request was granted (the policy allowed it).
There are two modes:
- Closed (
mode: 'closed'): bound to one signed checkout. Issued when your verification call carries the merchant's signed checkout ascheckoutJwtand thetransactionValue. On the purchase leg that isclient.confirmCheckout({ ..., checkoutJwt, transactionValue }). The authority is the owner's approval card (human present) or the agent's autonomous limit (human not present). A UCP platform can also receive closed mandates on the quote leg, to complete the checkout with. - Open (
mode: 'open'): issued on the quote leg (commercePhase: 'quote') with checkout items, for an agent that has a registered signing key. The open mandate is bound to that key and caps the amount at the transaction value (or the agent's autonomous limit).
Without checkoutJwt and transactionValue, a purchase leg gets no closed mandates.
Verify a mandate with verifyAp2Mandate() against AstraSync's JWKS, using the kid on the
result. Mandates are merchant-lane material: never forward them to the agent.
For agents: declare AP2
You declare: agent DID, max transaction value, allowed currencies, allowed regions, mandate types, delegation flag.
PDLSS pre-fill: max transaction value flows to both autonomous and hard limits (the protocol-authorised amount is the autonomous ceiling); allowed regions to jurisdictions; currency from the first allowed currency; delegation enables self-instantiation.
{
"protocols": ["a2a", "ap2"],
"ap2": {
"agentDid": "did:web:agent.example.com",
"policyClaims": {
"maxTransactionValue": 500,
"allowedCurrencies": ["USD"],
"allowedRegions": ["US", "GB"]
},
"delegationEnabled": true,
"mandateTypes": ["checkout", "payment"]
}
}The UCP checkout kit handles AP2 for you when your profile enables the AP2 mandates extension. See Merchant commerce kit.

