Introduction

Mobile Money Payment API

Welcome to the LimoPay API documentation. Our RESTful API allows you to integrate mobile money payments from MTN, Airtel, and Zamtel into your applications.

Key Features
Multiple Networks

MTN, Airtel, and Zamtel support

Real-time Processing

Instant payment confirmations

Web & Mobile SDKs

Easy integration for all platforms

Secure Transactions

Bank-level encryption

Authentication
API Key Authentication

All API requests require authentication using your API key. Include it in the request headers:

X-API-KEY: YOUR_API_KEY
Note: Keep your API keys secret! Never expose them in client-side code or version control.
Base URL
Environment Base URL
Production https://console.lipila.tech/api/v1
Staging https://sandbox.lipila.tech/api/v1
API Endpoints
POST /payments/mobile-money/{wallet_id}/

Initiate a mobile money payment. Supported providers: AIRTEL_OAPI_ZMB, MTN_MOMO_ZMB, PAWAPAY, ZAMTEL_ZMB.

Note: wallet_id is provided in the URL path. The reference field is auto-generated if not provided.

FieldTypeRequiredDescription
referencestringRequiredreference for partner-facing purposes. Max length: 100
amountdecimalRequiredPayment amount in the specified currency. Min: 0.01
payerstringRequiredZambia standard 12 digit mobile number with country code. Max length: 12
providerchoiceRequiredProvider | Choices: MTN_MOMO_ZMB, AIRTEL_OAPI_ZMB, ZAMTEL_ZMB
payer_emailemailOptionalPayer email. Max length: 254
payer_messagestringOptionalPayer message. Max length: 100
metadatajsonOptionalAdditional payment metadata
Example Request:
curl -X POST https://sandbox.lipila.tech/api/v1/payments/mobile-money/{wallet_id}/ -H "x-api-key: YOUR_API_KEY" -H "Content-Type: application/json" -d '{"amount": "500", "payer": "0761234567", "provider": "MTN_MOMO_ZMB", "payer_email": "customer@example.com", "payer_message": "Payment for order INV-001" }'
Example Response:
{"status": "success", "transaction_id": "TXN-12345", "message": "Payment processed successfully" }
GET /payments/{reference}/

Check the status of a payment using its reference ID.

Example Response:
{ "id": "550e8400-e29b-41d4-a716-446655440000", "reference": "TXN-12345", "amount": "500.00", "currency": "ZMW", "status": "completed", "provider": "MTN_MOMO_ZMB", "payer": "0761234567", "created_at": "2024-05-19T10:30:00Z", "completed_at": "2024-05-19T10:31:00Z" }
GET /status/

Health check endpoint to verify API is running.

Example Response:
{ "status": "ok", "version": "1.0.0", "timestamp": "2024-05-19T10:30:00Z" }
Error Handling
Status Code Description
200 Success - Request processed successfully
400 Bad Request - Invalid parameters
401 Unauthorized - Invalid or missing API key
403 Forbidden - Insufficient permissions
404 Not Found - Resource not found
500 Server Error - Internal server error
SDKs & Libraries
Python SDK
pip install limopay-sdk
JavaScript SDK
npm install @limopay/sdk
PHP SDK
composer require limopay/sdk
Webhooks

Receive real-time notifications for payment events. Subscribe to webhook events and receive POST requests to your configured endpoint.

Available Event Types
deposit.initiated

Fired when a deposit initiated

deposit.accepted

Fired when a deposit accepted

deposit.completed

Fired when a deposit completed

deposit.failed

Fired when a deposit failed

deposit.callback_received

Fired when a deposit callback_received

Webhook Payload Example
{ "event": "deposit.completed", "timestamp": "2024-05-19T10:30:00Z", "data": { "id": "550e8400-e29b-41d4-a716-446655440000", "reference": "TXN-12345", "amount": "500.00", "currency": "ZMW", "provider": "MTN_MOMO_ZMB", "payer": "0761234567", "status": "completed", "created_at": "2024-05-19T10:30:00Z", "completed_at": "2024-05-19T10:31:00Z" } }
Configure Webhooks

To configure webhooks for your API key, navigate to the API Keys page in your dashboard and set your webhook URL and select the events you want to subscribe to.