M-Pay Docs

M-Pay API Documentation

Integrate mobile money deposits and withdrawals into your application using the M-Pay REST API. Designed for speed, security, and scalability.

Get Started View Endpoints

⚡ Quick Start

All requests are authenticated using an API key sent via the Authorization header.

curl https://app.mpayafrica.site/api/v1/mpesa/express \
  -X POST \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "amount": 100,
    "phone": "2547XXXXXXXX",
    "reference": "INV-1001",
    "callback_url": "https://example.com/callback"
  }'
    

🔐 Secure by Default

API key authentication, HTTPS enforcement, and strict validation.

📲 Mobile Money First

STK Push deposits and instant withdrawals to mobile or bank.

⚙️ Developer Friendly

Clean JSON responses, predictable errors, multi-language examples.

📚 Documentation Sections

Authentication

API keys, headers, and security requirements.

Deposit (STK Push)

Initiate mobile money deposits from customers.

Withdrawals

Send funds to mobile numbers or bank accounts.

Errors & Codes

Error handling, validation issues, and retries.