The Moflay API gives your backend direct access to M-Pesa payment, customer, and transaction workflows over HTTPS.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.
Base URL
Authentication
Send your API key in theAuthorization header:
Core API areas
| Area | Purpose |
|---|---|
| Express payments | Create M-Pesa Express STK push payment requests with POST /v1/express |
| Payments | Read the current status of a payment attempt with GET /v1/payments/{id} |
| Customers | Create, update, list, and delete customer records |
| Transactions | List transactions and fetch individual transaction records |
| Webhooks | Receive signed payment and customer events in your backend |
Payment status flow
- Call
POST /v1/express. - Store the returned
paymentIdandtransactionId. - Use
GET /v1/payments/{id}for status checks (this reads Moflay’s stored state; see Transaction statuses). - Use Moflay webhooks for production-grade asynchronous status updates.
Amounts
Send payment amounts as integer minor currency units. For example,amount: 1000 means KES 10.00.
Supporting behavior
- Cursor-based pagination for list endpoints
- Environment-specific API keys
- Permission-based access control
- Standardized JSON error responses
- Rate limit headers on public API responses