Moflay uses saved Daraja credentials to authenticate with Safaricom and send M-Pesa Express payment requests for the selected environment.Documentation Index
Fetch the complete documentation index at: https://docs.moflay.com/llms.txt
Use this file to discover all available pages before exploring further.
What credentials Moflay uses
Depending on the environment and credential type, you may need:- Consumer key
- Consumer secret
- Business shortcode
- Passkey
- Account reference
- Short code type, such as till or paybill
How credentials are used
When your app creates a payment, Moflay selects the credentials for the API key’s business and environment. Moflay then authenticates with Daraja and sends the STK push request to Safaricom.You do not need to build your own Daraja token exchange when you use Moflay.
Sandbox vs production
| Environment | Credential behavior |
|---|---|
| Sandbox | You can usually start with assigned test credentials, then optionally add your own Daraja sandbox credentials. |
| Production | You must provide your own verified live credentials before real payments can be processed. |
Manage credentials in the dashboard
- Open Credentials.
- Select
sandboxorproduction. - Enter or review the credential fields.
- Save the configuration.
- Run an environment-specific payment test.
Verify the result
Your credential setup is working when:- Sandbox payments work with a
mof_test_API key. - Production payments work with a
mof_live_API key after live credentials are verified. - The dashboard shows the payment in the same environment as the API key.