Get started
Sandbox and going live
Build against the sandbox, then switch the address and the key when your organisation is live.
RadiPay runs two separate systems. The sandbox is for building and testing; the live system moves real money. They do not share accounts, keys, data or addresses, so nothing you do in one can affect the other.
What is different
| Sandbox | Live | |
|---|---|---|
| Address | Has sandbox in it | The live address you are given when your organisation is approved |
| Account and keys | Created on the sandbox | Created again on live. Sandbox keys do not work there. |
| Money | Test money on the bank’s test systems | Real money |
| Webhooks | Sent, signed and retried exactly as on live | The same |
| Errors, limits, answers | The same shapes and codes | The same |
You are reading the live documentation
The examples on these pages use
https://prod.pay.radingtechnologies.co.ke.What to test
A payment has more endings than "paid". Make each of these happen on the sandbox and check your system does the right thing:
| Situation | What your system should do |
|---|---|
| The client pays | Mark the order paid when payment.succeeded arrives. Not before. |
| The client cancels the M-Pesa prompt | Nothing is paid. payment.failed arrives; the link stays open and can be tried again. |
| The client never pays | Nothing arrives. The link becomes expired on its date if you set one. |
| The same webhook arrives twice | Do the work once. Remember each webhook-id you have handled. |
| Your server is down when a webhook is sent | It is retried for about two days. When you are back, also read the record to catch up. |
| Your request times out | Send it again with the same Idempotency-Key. Check that only one link exists. |
| A webhook with a bad signature arrives | Refuse it with a 400 and do nothing else. |
| You are refused with a 422 | Show the message to a person. Do not retry automatically. |
Before you go live
- Create a new API key on live, with only the permissions the system needs.
- Add your live webhook endpoint and store its new signing secret. It must be HTTPS and reachable from the internet.
- Keep the key and the secret in your secret store, never in code or in a browser.
- Verify every webhook signature against the raw body.
- Send an Idempotency-Key on every request that changes something.
- Never mark anything paid from a redirect or a screenshot.
- Log requestId for every failed request.
- Make one small real payment end to end and find it on your wallet statement.
Versions and changes
Every answer carries the header Rading-Api-Version and every webhook has apiVersion, both a date such as 2026-11-24. New fields, new endpoints and new error codes are added without changing that date, so write code that ignores fields it does not know. An endpoint that is going to be withdrawn says so first, in Deprecation and Sunset headers on its answers.