JPay Africa API Documentation
Accept and send payments across Africa in minutes.
🚀 Two Core APIs
💰 Accept Payments (Collections)
Receive money from customers via mobile money (M-Pesa, Airtel Money, T-Kash).
POST /payments/collections/checkouts/initiate
💸 Send Money (Payouts)
Send money to customers, vendors, or employees via mobile money or bank transfers.
POST /payments/payouts/initiate
⚡ Quick Start (3 Steps)
1. Get Your API Keys
- Sign up at merchants.jpay.africa
- Navigate to Settings → Applications → Create New App
- Save your
app_keyandapp_secret
2. Get Access Token
curl -X POST https://sandbox.api.jpay.africa/api/v1/auth/app/token \
-H "Content-Type: application/json" \
-d '{
"app_key": "your_app_key",
"app_secret": "your_app_secret"
}'
Response:
{
"access": "eyJ0eXAiOiJKV1QiLCJhbGc...",
"refresh": "eyJ0eXAiOiJKV1QiLCJhbGc...",
"merchant_id": 123
}
3. Accept Your First Payment
curl -X POST https://sandbox.api.jpay.africa/api/v1/payments/collections/checkouts/initiate \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"payfrom": "+254712345678",
"amount": "100.00",
"ref_no": "ORDER-001",
"callback_url": "https://yourdomain.com/webhook"
}'
✅ Done! Customer receives payment prompt on their phone.
📖 API Quick Reference
| What You Need | Endpoint | Documentation |
|---|---|---|
| Accept payment | POST /collections/checkouts/initiate | → Docs |
| Send payment | POST /payouts/initiate | → Docs |
| Check balance | GET /wallets/balance | → Docs |
| List transactions | GET /collections/checkouts | → Docs |
| Get auth token | POST /auth/app/token | → Docs |
🌍 API Base URLs
Sandbox (Testing):
https://sandbox.api.jpay.africa/api/v1
Production:
https://api.jpay.africa/api/v1
🔑 Key Features
✅ Mobile Money Integration - M-Pesa, Airtel Money, T-Kash
✅ Bank Transfers - Direct bank payouts
✅ Real-time Webhooks - Instant transaction notifications
✅ Secure Authentication - JWT-based with token refresh
✅ Simple REST API - Easy integration in any language
📚 Next Steps
- Getting Started Guide - Detailed setup walkthrough
- Authentication - Learn about token management
- Error Handling - Handle API errors gracefully
- Best Practices - Build reliable integrations
💬 Support
- Email: support@jpay.africa
- Phone: +254 726 944 055
- Website: jpay.africa
⚠️ Rate Limits
- 60 requests per minute
- 100 burst limit
Exceeding limits returns 429 Too Many Requests.
🎯 Quick Tips
- Use sandbox environment for testing
- Always validate phone numbers to E.164 format (+254...)
- Use unique reference numbers for each transaction
- Implement webhook handlers for transaction updates
- Enable IP whitelisting for production security