Skip to content

feat(payments): add AgentCore Payments module#457

Merged
tejaskash merged 1 commit intomainfrom
feat/payments
May 7, 2026
Merged

feat(payments): add AgentCore Payments module#457
tejaskash merged 1 commit intomainfrom
feat/payments

Conversation

@aidandaly24
Copy link
Copy Markdown
Contributor

Summary

  • Add comprehensive payment processing support for AI agents via the x402 protocol
  • PaymentManager: high-level orchestration (instruments, sessions, process_payment, generate_payment_header)
  • PaymentClient: control plane CRUD for managers/connectors with rollback-safe orchestration
  • AgentCorePaymentsPlugin: Strands framework integration with automatic HTTP 402 interception and retry
  • Payment handlers: protocol-agnostic extraction for HTTP, MCP, and generic tool responses
  • Multi-blockchain support (Ethereum, Solana) with configurable network preferences
  • Bearer token auth for CUSTOM_JWT authorization flows
  • Multi-vendor credential providers: CoinbaseCDP and StripePrivy

Components

Component Path Purpose
PaymentManager payments/manager.py High-level payment orchestration, x402 header generation
PaymentClient payments/client.py Control plane manager/connector lifecycle
Plugin payments/integrations/strands/plugin.py Strands framework hooks for auto-402
Handlers payments/integrations/handlers.py Tool response parsing (HTTP, MCP, generic)
Config payments/integrations/config.py Plugin configuration dataclass
Constants payments/constants.py Network preferences, status enums

Test plan

  • 483 unit tests passing (tests/bedrock_agentcore/payments/)
  • Integration test collection verified (26 tests in tests_integ/payments/)
  • Bearer token auth integ tests pass with self-provisioning Cognito infrastructure
  • No hardcoded account IDs, personal ARNs, or internal endpoints
  • CI pipeline validation

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 7, 2026

✅ No Breaking Changes Detected

No public API breaking changes found in this PR.

Add comprehensive payment processing support for AI agents via the x402
protocol. Includes PaymentManager (high-level orchestration), PaymentClient
(control plane operations), Strands plugin integration with automatic 402
interception, and multi-blockchain support (Ethereum, Solana).

Key components:
- PaymentManager: instrument/session lifecycle, process_payment, generate_payment_header
- PaymentClient: manager/connector CRUD with rollback-safe orchestration
- AgentCorePaymentsPlugin: Strands framework integration with before/after tool hooks
- Payment handlers: protocol-agnostic extraction for HTTP, MCP, and generic tool responses
- Bearer token auth support for CUSTOM_JWT authorization flows
- Multi-vendor support: CoinbaseCDP and StripePrivy credential providers
Copy link
Copy Markdown
Contributor

@tejaskash tejaskash left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@tejaskash tejaskash merged commit a4d73c7 into main May 7, 2026
41 of 42 checks passed
Copy link
Copy Markdown

@rajuans rajuans left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants