Domain 03: Cryptographic Trust & Mandates | /.well-known/ap2/mandates.json
AP2: Agent Payments Protocol (AP2) Hub
Agent Payments Protocol (AP2) solves the enterprise trust barrier in autonomous commerce: proving that a human or corporate principal authorized an agent to transact up to a specific dollar ceiling with real-time revocation control.
Canonical Answer-First Definition
Agent Payments Protocol (AP2) publishes public ECDSA P-256 JWK keys at /.well-known/ap2/mandates.json and issues ES256 JSON Web Signatures over Intent and Cart mandates, providing offline-verifiable authorization and real-time PostgreSQL revocation.
Core Architectural Capabilities
- Dedicated ECDSA P-256 keypair provisioning with public JWK served at /.well-known/ap2/mandates.json
- Intent Mandates pre-authorizing category spend within strict dollar ceilings and TTL expiration windows
- Cart Mandates signing exact line items, mobilization totals, and settlement rails prior to execution
- POST /api/ap2/mandates verification endpoint checking both cryptographic signature and PostgreSQL revocation status
Production Implementation Checklist
- Provision an isolated ECDSA P-256 keypair and publish the public JWK at /.well-known/ap2/mandates.json.
- Sign the live registry payload dynamically so verifiers can confirm active key possession.
- Store every issued Cart and Intent mandate in PostgreSQL with issued_at, expires_at, and revoked_at columns.
- Expose a public POST verification endpoint so buyer agents and finance auditors can validate any JWS receipt.
AP2 Technical Specification Matrix
| Component | Cryptographic Standard | Verification Mechanism | Compliance Benefit |
|---|---|---|---|
| Signing Keypair | ECDSA P-256 (prime256v1) | Public JWK published with key ID (kid) | Zero shared-secret exposure |
| Mandate Signature | JWS Compact (ES256) | SHA-256 digest verified against public JWK | Tamper-evident line items & totals |
| Revocation Ledger | PostgreSQL ap2_mandates | Real-time revoked_at check on mandate_id | Instant corporate kill-switch |
| Audit Receipt | Immutable JSONB proof | Timestamped iat/exp + principal subject binding | Chargeback & dispute non-repudiation |
Corresponding LeverageIQ Implementation Modules
AP2 Engineering FAQ
Why is standard HTTPS/TLS insufficient for autonomous agent transactions?
TLS only encrypts the transport pipe between two servers. AP2 produces a portable, cryptographically signed receipt proving which principal authorized which line items, at what dollar ceiling, and within what time window.