Skip to content

feat(payments): add Solana x402 and BTC rail readiness - #77

Draft
Svaag wants to merge 1 commit into
mainfrom
codex/solana-btc-payments
Draft

feat(payments): add Solana x402 and BTC rail readiness#77
Svaag wants to merge 1 commit into
mainfrom
codex/solana-btc-payments

Conversation

@Svaag

@Svaag Svaag commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Add x402 v2 exact SVM support for Solana mainnet alongside the existing EVM schemes.
  • Gate every advertised x402 network against the facilitator supported-kind response; Solana additionally requires facilitator fee-payer metadata.
  • Add explicit per-network receiver configuration and expose family-specific wallet metadata through quotes, the payment catalog, and MCP.
  • Add a durable worker heartbeat, native-rail kill switch, provider health checks, pending-intent/scan-lag metrics, and fail-closed BTC intent advertisement.
  • Add Alembic migration 016 for service heartbeats and update the facilitator verification script.

Why

Solana cannot safely share EVM signing assumptions, and native payment intents must not be advertised when their scanner is stale or unhealthy. This gives both rails explicit capability and readiness contracts.

Impact

Application defaults keep Solana disabled. Production activation requires an explicit Solana receiver, a configured network entry, CDP support with feePayer metadata, the companion web adapter, and the infrastructure rollout gate. BTC remains receive-only through an xpub and is advertised only after a fresh successful worker scan.

Zcash is intentionally excluded. The prior research PR #31 is deferred and closed.

Validation

  • uv run ruff check .
  • uv run mypy hyrule_cloud/ — 96 source files
  • uv run pytest -q — 452 passed
  • PYTHONPATH=. .venv/bin/alembic upgrade 015:016 --sql
  • Focused payment, quote, intent, MCP, runtime, and launch-proof tests

Rollout

Merge with the companion web and infrastructure PRs, deploy with reviewed Vault values, and complete the paid EVM/Solana/BTC canary before declaring the rails promoted.

Companion PRs

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