ADR-006: mvs-pay-extensions as separate Hono service
ADR-006: mvs-pay-extensions as separate Hono service
Status
Accepted (2026-05-28)
Context
Hyperswitch orchestration could live in apps/mvs-pay’s Next.js API routes. We chose to extract it.
Decision
apps/mvs-pay-extensions is a separate Hono service running in the payments K8s namespace.
Consequences
- Clean PCI / non-PCI boundary (extensions sits outside the PCI ring; only Hyperswitch + card-vault are inside).
- Cross-repo consumers (healthos, mvs-c2) call the extensions service directly.
- Independent scaling, observability, and deployment cadence.
@mvs/mvs-pay-sdkprovides the typed HTTP client.
Alternatives considered
- In-Next.js API routes: simpler for the Next app; rejected because mvs-pay-extensions has cross-repo consumers and the EKS deployment offers operational features (mTLS, network policies) that Vercel functions don’t.