API Integration
The direct API integration gives you full control over the payment flow.
Collection Flow
Your Server → POST /payment/collection → MALIPOPAY → MNO/Bank
↓
Your Webhook ← POST (payment status) ← MALIPOPAY
Request Format
All requests use JSON body with Content-Type: application/json.
Response Format
All responses follow this structure:
{
"success": true,
"code": 1109,
"message": "Collection request sent successfully",
"data": { ... }
}
Error Responses
{
"success": false,
"code": 400,
"message": "Invalid phone number format"
}
See Error Handling for a full list of error codes.