Skip to content

feat: add reusable payment runtime - #201

Draft
parvahuja wants to merge 2 commits into
mainfrom
parv/minimal-payment-runtime
Draft

feat: add reusable payment runtime#201
parvahuja wants to merge 2 commits into
mainfrom
parv/minimal-payment-runtime

Conversation

@parvahuja

@parvahuja parvahuja commented Jul 30, 2026

Copy link
Copy Markdown
Member

Summary

  • Add a transport-neutral, caller-loop PaymentRuntime for method matching, challenge expiry validation, credential creation, and shared lifecycle events.
  • Let Client and PaymentTransport share an explicit runtime while preserving the existing methods= API.
  • Reuse the core Method protocol in the existing MCP client instead of maintaining a duplicate.
  • Constrain the optional MCP dependency to its supported v1 API (mcp<2); MCP 2 renamed symbols imported by the existing integration.

This is intentionally only the core primitive. It adds no thread/loop ownership, sync bridge, origin policy, global HTTPX patching, or MCP instrumentation.

Stack: 1 of 2.

Validation

  • 790 passed, 41 skipped
  • Ruff check and format check
  • Pyright
  • Clean diff check

@parvahuja
parvahuja force-pushed the parv/minimal-payment-runtime branch from aadc1b9 to d380a50 Compare July 30, 2026 19:43
@socket-security

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Addedpypi/​mcp@​1.29.099100100100100

View full report

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.

1 participant