Local test console
This BFF sends X-Api-Key for you. The browser never sees JazzCash secrets or the product API key. Pick one workflow at a time.
GET /v1/users/:userId/status — shared across workflows. Polls during link and first charge.
Choose a workflow below.
First-time path. JazzCash MPIN starts the plan trial automatically. Do not call subscribe after success.
Pick a plan, then link. After JazzCash, the trial starts on its own.
Wallet stays linked. Pause, resume, change plan, or cancel the current trial/paid plan.
No open subscription. Finish Link & trial first, or use Resubscribe after a cancel.
Wallet must already be linked and there must be no open subscription. First-time users should use Link & trial instead.
Deletes the JazzCash token, cancels every open sub for this user, and stops all future debits. This is not “cancel one plan”.
Not a user checkout path. Upsert plans (amounts are paisas: 22900 = PKR 229). Refunds hit JazzCash for completed txns only.
Operator only. Create a product tenant, copy the API key once, then give it to that storefront as X-Api-Key. Keys are stored hashed; JazzCash merchant secrets are encrypted.
Ready.