Prerequisites
- A valid till or paybill approved for your business
- Access to the Safaricom Daraja portal
- A Moflay organization with access to the production environment
What you need from Safaricom
Before you open the Moflay dashboard, collect:- Consumer key
- Consumer secret
- Business shortcode
- Passkey
- The business type for the shortcode, such as till or paybill
Connect the credentials
Open the production environment
Go to Credentials and switch from
sandbox to production.
Enter the live Daraja values
Paste your consumer key, consumer secret, shortcode, and passkey, then
choose the right business type.
Important behavior
Moflay handles the Safaricom callback side of the payment flow internally. Your own backend should consume Moflay webhooks for business events such aspayment.completed and payment.failed.
Verify the result
Your production setup is complete when:- The credentials save successfully in the production environment
- A production API key can authenticate successfully
- You can complete a controlled live payment test
Troubleshooting
- The payment request fails immediately: Recheck the consumer key, consumer secret, shortcode, passkey, and business type.
- Sandbox works but production does not: Confirm you switched both the credentials page and your API key to production.