Skip to content

a2a/x402: add AP2 mandate foundation for agent payments #4841

Description

@asim

Goal
Add an opt-in AP2 mandate foundation so agents can carry auditable payment authorization over A2A and settle over x402 without changing defaults.

Scope

  • Define minimal Checkout Mandate and Payment Mandate data structures with signing/verification helpers.
  • Attach verified mandate metadata to A2A/x402 payment flows behind explicit options.
  • Preserve current public defaults and avoid broad API breakage.
  • Include docs/example notes only where needed to make the flow discoverable.

Acceptance criteria

  • Unit tests cover mandate creation, signing, verification failure, and x402 rail metadata.
  • A focused integration or gateway test shows an A2A request carrying mandate metadata into a paid-tool path.
  • go test ./... passes.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions