The easypoint9ja Airtime API is a RESTful interface that enables you to seamlessly integrate a range of services from the easypoint9ja platform into your web or mobile application.
Use this endpoint to send airtime to a Nigerian mobile number.
| Parameter | Type | Required | Description |
|---|---|---|---|
| api_key | string | R | Your API key. |
| request_id | string | O | Transaction reference (optional for custom tracking). |
| serviceID | string | R | Service ID as specified by Easypoint9ja. In this case, it is mtn |
| phone | Number | R | The phone number of the recipient of this service . |
| amount | Number | R | The amount you wish to topup |
Live: https://easypoint9ja.com/api/airtime/
Sandbox: https://sandbox.easypoint9ja.com/api/airtime/
$url = "https://easypoint9ja.com/api/airtime";
$data = [
"api_key" => "YOUR_API_KEY",
"request_id" => 63634570027309,
"serviceID" => "mtn",
"phone" => "09011111111",
"amount" => 100
];
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data));
curl_setopt($ch, CURLOPT_HTTPHEADER, [
"Content-Type: application/json"
]);
$response = curl_exec($ch);
curl_close($ch);