Test mode
A completely separate environment: separate keys, separate payments, separate webhooks, separate dashboard data. Nothing in test mode can touch live money.
How modes are separated
There is no mode parameter to set, and therefore none to get wrong. Your key's prefix
decides everything:
- A
sk_test_key can only see and create test payments. - A
sk_live_key can only see and create live payments.
Asking for a live payment with a test key returns 404, not 403 — from a
test key's point of view, live objects do not exist.
The dashboard follows the same rule. The environment switch in the top bar changes which set of payments, keys, webhooks and events you are looking at, and a persistent amber band across the top makes test mode impossible to mistake for live.
What you need
Nothing beyond a sk_test_ key. Test mode is simulated end to end: it never contacts
Fonepay, so it needs no Fonepay account and works before your business is verified.
What is and is not simulated
| Behaviour | In test mode |
|---|---|
| QR generation | A demo QR. It opens a Qora "this is a test" page; no banking app can pay it. |
| Confirmation | You decide the outcome — see below. It then runs the same confirmation path as live. |
| Webhooks | Real, signed with your test endpoint's own secret. |
| Money movement | None. Nothing settles anywhere. |
| Qora software fees | Never charged. Test traffic is free. |
Settle a test payment
Nobody can pay a test QR, so you play the customer: mark it paid or failed from the payment's page in the dashboard, or from your own test suite:
curl -X POST https://qora.laayo.com.np/v1/payments/pay_7Fh2.../simulate \
-H "Authorization: Bearer sk_test_YOUR_KEY" \
-d outcome=succeeded
outcome is succeeded or failed. The response is the payment, and the
usual webhooks follow: payment.succeeded, or payment.failed (which only test mode
sends). Simulating succeeded on an expired or canceled test payment shows what a late
payment looks like. Live keys get 403 test_mode_only.
Going live
- Complete business verification.
- Add live Fonepay credentials.
- Change
sk_test_tosk_live_in your environment. - Add a live webhook endpoint — it gets its own signing secret, distinct from the test one.
Test and live webhook endpoints have different signing secrets. Verifying live deliveries with your test secret fails every signature. Keep them in separate environment variables.