- Moflay statuses
- Daraja ResultCodes
- Webhooks & polling
Moflay transaction status
Each Express payment has a transaction status drawn from this set:| Status | Meaning | Typical next step |
|---|---|---|
initiating | Moflay is creating the payment attempt and sending the STK request to Daraja. | Wait; poll GET /v1/payments/{id} or use webhooks when the status advances. |
pending | STK was accepted; waiting for the customer or for a final callback/reconciliation result. | Wait for webhook or poll; customer may still complete or cancel on the phone. |
completed | Payment succeeded; Moflay recorded success. | Fulfill the order; handle payment.completed if subscribed. |
failed | Payment did not complete (M-Pesa rejection, timeout, limits, etc.). | Allow retry; handle payment.failed if subscribed. |
canceled | The customer canceled the STK prompt (for example Daraja result 1032). | Handle payment.canceled if subscribed; optionally offer a new attempt. |
unknown | Moflay could not determine a definitive outcome after reconciliation (for example missing or non-final Daraja signal). | Manual review; no standard payment.* webhook is sent for this status. |