Skip to main content

API Integration

The direct API integration gives you full control over the payment flow.

Base URL

https://core-prod.malipopay.co.tz

Every path carries its version. These docs describe v2, so a collection is POST /api/v2/payment/collection.

Collection flow

Your Server → POST /api/v2/payment/collection → MALIPOPAY → MNO/Bank

Your Webhook ← POST (payment status) ← MALIPOPAY

Disbursement flow

Your Server → POST /api/v2/payment/disbursement → AWAITING_APPROVAL
Your Server → POST /api/v2/payment/approve → APPROVED → MNO/Bank
(from a whitelisted IP) ↓
Your Webhook ← POST (payout status) ← MALIPOPAY

Request format

All requests use a JSON body with Content-Type: application/json and your key in the apiToken header.

Response format

All responses follow this structure:

{
"success": true,
"code": 1109,
"message": "Collection request sent successfully",
"data": { }
}

code is a MALIPOPAY status code and is more specific than the HTTP status. The ones you will meet most often:

CodeMeaning
1109Collection accepted
1120Disbursement created, awaiting approval
1111Disbursement or batch accepted
1117Disbursement approved and dispatched
1112Disbursement rejected

Error responses

{
"success": false,
"code": 400,
"message": "Invalid phone number format"
}

See Error Handling for a full list of error codes.