Topupnaija API Documentation

Your authorization token

Login to see token

Wallet Balance

You can check your wallet balance using our balance end point

https://topupnaija.com/api/balance

Method: GET

Header 1= 'Content-Type : application/json'

Header 2= 'Authorization-Token : //Your authorization token'

$curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => "https://topupnaija.com/api/balance", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "GET", CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Authorization-Token: JBKhjvY778Yghc5E5Egvj6", //Replace with your token ), )); $response = curl_exec($curl); curl_close($curl); echo $response;

Responses

{"status":"error","message":"Authorization token was not found","data":""}

{"status":"error","message":"Invalid authorization token","data":""}

{"status":"success","message":"Wallet balance fetched successfully","data":{"funds":6740}}

Service Pricings

You can check real time pricing of our all our products

https://topupnaija.com/api/pricing

Method: POST

Header 1= 'Content-Type : application/json'

Header 2= 'Authorization-Token : //Your authorization token'

Post Fields

  • serviceID
  • type //(data, airtime, cable, electricity, education, datacard, airtimepin, smm)
  • $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => "https://topupnaija.com/api/pricing", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_POSTFIELDS =>json_encode(array("serviceID" => 200, "type" => "data") ), CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Authorization-Token: JBKhjvY778Yghc5E5Egvj6", //Replace with your token ), )); $response = curl_exec($curl); curl_close($curl); echo $response;

    Responses

    {"status":"error","message":"Authorization token was not found","data":""}

    {"status":"error","message":"Invalid authorization token","data":""}

    {"status":"error","message":"Incorrect Service ID","data":[]}

    {"status":"success","message":"Price fetched successfully","data":{"amount":"2.5%","type":"airtime","description":"glo airtime"}}

    Buy Airtime

    Our purchase airtime endpoint is straight forward

    https://topupnaija.com/api/airtime

    Method: POST

    Header 1= 'Content-Type : application/json'

    Header 2= 'Authorization-Token : //Your authorization token'

    Post Fields

  • serviceID
  • amount
  • mobileNumber
  • clientReference (if empty, we will create a client reference for you)
  • $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => "https://topupnaija.com/api/airtime", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_POSTFIELDS =>json_encode(array("serviceID" => 100, "amount" => 1000, "mobileNumber" => "09036022177", "clientReference" => "Cldsfsgsdgfnm") ), CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Authorization-Token: JBKhjvY778Yghc5E5Egvj6", //Replace with your token ), )); $response = curl_exec($curl); curl_close($curl); echo $response;

    Responses

    {"status":"error","message":"Authorization token was not found","data":""}

    {"status":"error","message":"Invalid authorization token","data":""}

    {"status":"error","message":"Incorrect Service ID","data":[]}

    {"status":"error","message":"Insufficient funds","data":[]}

    {"status":"success","message":"Airtime purchase successful","data":{"mobileNumber":"09036022177","amount":1000,"amountPaid":975,"network":"Glo", "status" : "pending" , "reference":"v033womfhritpes", "clientReference" : "Cldsfsgsdgfnm", "date":"02-09-2021 12:31:39","type":"airtime"}}

    NOTE: The status in the data object is always pending, you should use our webhook to get the real time status after transaction has taken place.

    Buy Data

    Just like airtime, data purchase is straight forward

    https://topupnaija.com/api/data

    Method: POST

    Header 1= 'Content-Type : application/json'

    Header 2= 'Authorization-Token : //Your authorization token'

    Post Fields

  • serviceID
  • mobileNumber
  • clientReference (if empty, we will create a client reference for you)
  • $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => "https://topupnaija.com/api/data", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_POSTFIELDS =>json_encode(array("serviceID" => 110, "mobileNumber" => "09036022177", "clientReference" => "Cldsfsgsdgfnm") ), CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Authorization-Token: JBKhjvY778Yghc5E5Egvj6", //Replace with your token ), )); $response = curl_exec($curl); curl_close($curl); echo $response;

    Responses

    {"status":"error","message":"Authorization token was not found","data":""}

    {"status":"error","message":"Invalid authorization token","data":""}

    {"status":"error","message":"Incorrect Service ID","data":[]}

    {"status":"error","message":"Insufficient funds","data":[]}

    {"status":"success","message":"Data purchase successful","data":{"mobileNumber":"09036022177","amount":220,"dataPlan":"1GB","network":"MTN", "status" : "pending","reference":"gq220y8i0zcmurd", "clientReference" : "Cldsfsgsdgfnm", "dataType":"sme","date":"06-02-2021 12:53:17","type":"data"}}

    NOTE: The status in the data object is always pending, you should use our webhook to get the real time status after transaction has taken place.

    Webhook

    We send the real time transaction response to the webhook url you provided, this is usual to refund your users for a failed transaction. Expected statuses are "success" and "failed"

    Responses

    Successful transaction

    {"status":"success","message":"Dear Customer, You have successfully shared 2000MB Data to 2349036022177. Your SME data balance is 342.76GB","data":{"type" : "data", "reference":"TW_jkdisuhgj7efs_D","clientReference":"yrhjdaffuyes"}}

    Failed transaction

    {"status":"failed","message":"Transaction was unsuccessful","data":{"type" : "data", "reference":"TW_jkdisuhgj7efs_D","clientReference":"yrhjdaffuyes"}}

    Validate Meter

    https://topupnaija.com/api/validateutility

    Method: POST

    Header 1= 'Content-Type : application/json'

    Header 2= 'Authorization-Token : //Your authorization token'

    Post Fields

  • serviceID
  • amount
  • meterNum
  • meterType (01 = prepaid, 02 = postpaid)
  • $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => "https://topupnaija.com/api/validateutility", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_POSTFIELDS =>json_encode(array("serviceID" => 510, "amount" => 1000, "meterNum" => "3838836372", "meterType" => "01") ), CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Authorization-Token: JBKhjvY778Yghc5E5Egvj6", //Replace with your token ), )); $response = curl_exec($curl); curl_close($curl); echo $response;

    Responses

    {"status":"error","message":"Authorization token was not found","data":""}

    {"status":"error","message":"Invalid authorization token","data":""}

    {"status":"error","message":"Incorrect Service ID","data":[]}

    {"status":"success","message":"validation successful","data":{"customerName":"Samule jaskson","meterNum":"94535633653`","meterType":"prepaid","customerArrears":22737,"minPurchaseAmount":0,"address":"21 okilo way igebu","date":"06-02-2022 13:04:20","type":"electricity"}}

    Pay electric

    https://topupnaija.com/api/payelectric

    Method: POST

    Header 1= 'Content-Type : application/json'

    Header 2= 'Authorization-Token : //Your authorization token'

    Post Fields

  • serviceID
  • amount
  • meterNum
  • meterType (01 = prepaid, 02 = postpaid)
  • clientReference (if empty, we will create a client reference for you)
  • $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => "https://topupnaija.com/api/payelectric", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_POSTFIELDS =>json_encode(array("serviceID" => 510, "amount" => 1000, "meterNum" => "3838836372", "meterType" => "01", "clientReference" => "Cldsfsgsdgfnm") ), CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Authorization-Token: JBKhjvY778Yghc5E5Egvj6", //Replace with your token ), )); $response = curl_exec($curl); curl_close($curl); echo $response;

    Responses

    {"status":"error","message":"Authorization token was not found","data":""}

    {"status":"error","message":"Invalid authorization token","data":""}

    {"status":"error","message":"Incorrect Service ID","data":[]}

    {"status":"error","message":"Insufficient funds","data":[]}

    {"status":"success","message":"Utility payment successful","data":{"productName":"PHED PORT HARCOURT ELECTRIC DISTRIBUTION","meterNum":"73736536373","customerName":"John Doe","token":"92725279204847267257494","tokenValue":1000,"units":23.8,"amount":1000, "reference" : "sdfgdsjsdsdkj", "clientReference" : "Cldsfsgsdgfnm","date":"04-08-2022 13:58:12","type":"electricity"}}

    Validate TV/Cable

    https://topupnaija.com/api/validatecable

    Method: POST

    Header 1= 'Content-Type : application/json'

    Header 2= 'Authorization-Token : //Your authorization token'

    Post Fields

  • serviceID
  • cableNum
  • $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => "https://topupnaija.com/api/validatecable", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_POSTFIELDS =>json_encode(array("serviceID" => 610, "cableNum" => "6532346787544") ), CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Authorization-Token: JBKhjvY778Yghc5E5Egvj6", //Replace with your token ), )); $response = curl_exec($curl); curl_close($curl); echo $response;

    Responses

    {"status":"error","message":"Authorization token was not found","data":""}

    {"status":"error","message":"Invalid authorization token","data":""}

    {"status":"error","message":"Incorrect Service ID","data":[]}

    {"status":"success","message":"validation successful","data":{"customerName":"John Doe","cableStatus":"active","cableType":"GOTV","currentBouquet":"GOTV Jolli","currentBouquetCode":"Gotv Jolli-N2800","renewalAmount":0,"dueDate":"12-02-2022 12:37:22","date":"07-01-2022 14:11:53","type":"cable"}}

    Cable Subscription

    https://topupnaija.com/api/subcable

    Method: POST

    Header 1= 'Content-Type : application/json'

    Header 2= 'Authorization-Token : //Your authorization token'

    Post Fields

  • serviceID
  • cableNum
  • clientReference (if empty, we will create a client reference for you)
  • $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => "https://topupnaija.com/api/subcable", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_POSTFIELDS =>json_encode(array("serviceID" => 610, "cableNum" => "383883637286548", "clientReference" => "Cldsfsgsdgfnm") ), CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Authorization-Token: JBKhjvY778Yghc5E5Egvj6", //Replace with your token ), )); $response = curl_exec($curl); curl_close($curl); echo $response;

    Responses

    {"status":"error","message":"Authorization token was not found","data":""}

    {"status":"error","message":"Invalid authorization token","data":""}

    {"status":"error","message":"Incorrect Service ID","data":"[]"}

    {"status":"error","message":"Insufficient funds","data":"[]"}

    {"status":"success","message":"Cable Subscription successful","data":{"cableType":"GOTV","package":"GOTV JOLLI","iucNum":383883637286548,"amount":2800,"reference":"nd8s6svebri7dshd", "clientReference" : "Cldsfsgsdgfnm", "date":"09-04-2022 14:17:15","type":"cable"}}

    Education Pin

    https://topupnaija.com/api/education

    Method: POST

    Header 1= 'Content-Type : application/json'

    Header 2= 'Authorization-Token : //Your authorization token'

    Post Fields

  • serviceID
  • quantity
  • clientReference (if empty, we will create a client reference for you)
  • $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => "https://topupnaija.com/api/education", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_POSTFIELDS =>json_encode(array("serviceID" => 100, "quantity" => 1, "clientReference" => "Cldsfsgsdgfnm") ), CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Authorization-Token: JBKhjvY778Yghc5E5Egvj6", //Replace with your token ), )); $response = curl_exec($curl); curl_close($curl); echo $response;

    Responses

    {"status":"error","message":"Authorization token was not found","data":""}

    {"status":"error","message":"Invalid authorization token","data":""}

    {"status":"error","message":"Incorrect Service ID","data":[]}

    {"status":"error","message":"Insufficient funds","data":{"status" : "failed"}}

    { "status":"success", "message":"WAEC pin purchase successful", "data":{ "pinType":"waec", "pins":[ { "pin" : "7y46thfyser", "serialNo" : "534354543453" } ], "quantity" : 1, "amount":2500, "reference":"MYTOPUP_gdfu7fd6ygduyr", "clientReference" : "Cldsfsgsdgfnm", "date":"02-09-2021 12:31:39", "type":"education" } }

    Data Card

    https://topupnaija.com/api/datacard

    Method: POST

    Header 1= 'Content-Type : application/json'

    Header 2= 'Authorization-Token : //Your authorization token'

    Post Fields

  • serviceID
  • quantity
  • cardName
  • clientReference (if empty, we will create a client reference for you)
  • $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => "https://topupnaija.com/api/datacard", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_POSTFIELDS =>json_encode(array("serviceID" => 100, "quantity" => 1, "cardName" => "TOPUPWIZARD", "clientReference" => "Cldsfsgsdgfnm") ), CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Authorization-Token: JBKhjvY778Yghc5E5Egvj6", //Replace with your token ), )); $response = curl_exec($curl); curl_close($curl); echo $response;

    Responses

    {"status":"error","message":"Authorization token was not found","data":""}

    {"status":"error","message":"Invalid authorization token","data":""}

    {"status":"error","message":"Incorrect Service ID","data":[]}

    {"status":"error","message":"Insufficient funds","data":{"status" : "failed"}}

    { "status":"success", "message":"GLO datacard purchase successful", "data":{ "network":"glo", "pins":[ { "pin" : "7y46thfyser", "serialNo" : "534354543453" }, { "pin" : "i8d7uyt76es", "serialNo" : "W3455453434" } ], "loadPin" : "*347*383*4*3*PIN# or *347*383*4*PIN*PHONE#", "checkBalance" : "*127*0#", "quantity" : 2, "amount":460, "reference":"MYTOPUP_gdfu7fd6dfeygds", "clientReference" : "Cldsfsgsdgfnm", "date":"02-09-2021 12:31:39", "type":"datacard" } }

    SMM Services

    https://topupnaija.com/api/smm

    Method: POST

    Header 1= 'Content-Type : application/json'

    Header 2= 'Authorization-Token : //You authorization token'

    Post Fields

  • serviceID
  • url
  • quantity
  • clientReference (Your reference. If empty, we will assign one to you.)
  • type (youtube, instagram, facebook, tiktok)
  • $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => "https://topupnaija.com/api/smm", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_POSTFIELDS =>json_encode(array("serviceID" => 100, "url" => "https://youtube.com/Topupnaija", "quantity" => 500) ), CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Authorization-Token: JBKhjvY778Yghc5E5Egvj6", //Replace with your token ), )); $response = curl_exec($curl); curl_close($curl); echo $response;

    Responses

    {"status":"error","message":"Authorization token was not found","data":""}

    {"status":"error","message":"Invalid authorization token","data":""}

    {"status":"error","message":"Incorrect Service ID","data":[]}

    {"status":"error","message":"Insufficient funds","data":[]}

    {"status":"error","message":"Order with the same link is already in progress","data":[]}

    { "status":"success", "message":"YouTube Subscribers purchase successful", "data":{ "serviceType" : "youtube", "quantity": 500, "amount":4690, "url":"https://youtube.com/Topupnaija", "reference":"MYTOPUP_fg98786dmvnn7UYH", "clientReference" : "CLI_x622kr5ahzdajmw", "date": "03-06-2023 12:53:46", "type" : "smm", "status" : "in_progress" } }

    Requery Transaction

    To requery a transaction made on our platform, use our requery endpoint to get real time status of transaction

    https://topupnaija.com/api/requerytrx

    Method: POST

    Header 1= 'Content-Type : application/json'

    Header 2= 'Authorization-Token : //Your authorization token'

    Post Fields

  • reference
  • $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => "https://topupnaija.com/api/requerytrx", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_POSTFIELDS =>json_encode(array("reference" => "iudhkju97wkidz1") ), CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Authorization-Token: JBKhjvY778Yghc5E5Egvj6", //Replace with your token ), )); $response = curl_exec($curl); curl_close($curl); echo $response;

    Responses

    {"status" : "error","message":"Authorization token was not found","data":""}

    {"status":"error","message":"Invalid authorization token","data":""}

    {"status":"error","message":"Transaction Reference is incorrect","data":[]}

    {"status":"error","message":"Enter transaction reference","data":[]}

    {"status":"success","message":"Transaction is still in progress, please wait for at least 30 minutes.","data":{"type":"airtime","reference":"3zv2kju97wkidz1", "clientReference" : "Cldsfsgsdgfnm", "network":"glo","phoneNumber":"08071099713","amount":"50","amountPaid":"47.25","date":"11-07-2022 09:28:49","status":"pending"}}

    Airtime:

    {"status":"success","message":"Transaction was successful","data":{"type":"airtime","reference":"3zv2kju97wkidz1", "clientReference" : "Cldsfsgsdgfnm", "network":"glo","phoneNumber":"08071099713","amount" : 50,"amountPaid":47.25,"date":"11-07-2022 09:28:49","status":"success"}}

    Data:

    {"status":"success","message":"Transaction was successful","data":{"type":"data","reference":"3zv2kju97wkidz1", "clientReference" : "Cldsfsgsdgfnm", "network":"airtel","phoneNumber":"07084204225","dataPlan":"1GB","planType":"cg","amount":238,"date":"10-07-2022 14:42:57","status":"success"}}

    Cable:

    {"status":"success","message":"Transaction failed and user wallet refunded","data":{"type":"cable","reference":"3zv2kju97wkidz1", "clientReference" : "Cldsfsgsdgfnm", "cable":"GOTV","package":"GOTV JOLLI","iucNum":"0829094369","amount":2800,"date":"05-07-2022 14:49:57","status":"failed"}}

    Electric:

    {"status":"success","message":"Transaction failed and user wallet refunded","data":{"type":"electricity","reference":"3zv2kju97wkidz1", "clientReference" : "Cldsfsgsdgfnm", "company":"PHED Port Harcourt Electric","meterNum":"7643334678764","amount":"1000","amountPaid":997,"token" : null, "customerName" : null, "date":"05-07-2022 20:43:37","status":"failed"}}

    Education:

    { "status": "success", "message": "Transaction was successful", "data": { "type": "education", "reference": "MYTOPUP_acbu26xs08ceb", "clientReference": "CLI_dv7nal9hqgtxo08", "pinType": "neco", "pins": [ { "pin": "577698975131", "serialNo": "asdfasdfasf" }, { "pin": "577698975131", "serialNo": "WRN192476073" } ], "quantity": "2", "amount": 1000, "date": "21-01-2023 08:41:44", "status": "success" } }

    Datacard:

    { "status": "success", "message": "Transaction was successful", "data": { "type": "datacard", "reference": "MYTOPUP_qgcwmk0g7pb3t", "clientReference": "CLI_x622kr5ahzdajmw", "network": "mtn", "pins": [ { "pin": "data_card_400mb", "serialNo": "856073001_3" } ], "loadPin": "*1234#", "checkBalance": "*1234#", "planType": "sme", "dataPlan": "1GB", "quantity": "1", "amount": 342, "cardName": "sa", "date": "03-06-2023 12:53:46", "status": "success" } }

    SMM Services

    { "status": "success", "message": "Order has been completed", "data": { "reference": "MYTOPUP_qgcwmk0g7pb3t", "clientReference" : "CLI_x622kr5ahzdajmw", "url": "https://youtube.com/Topupnaija", "quantity" : 100, "amount": 2000, "status": "completed", "date": "03-06-2023 12:53:46", "serviceID": 430 } }

    NOTE: The status in the data object shows the real time transaction status.
    success means transaction was successful.
    pending means transaction is still in progress.
    failed means transaction failed and your wallet was refunded.

    NOTE for SMM services, The statuses in the data object are: in_progress, cancelled or completed
    completed means order was completed.
    in_progress means order is in progress.
    cancelled means order was cancelled and your wallet was refunded.

    Validate Mobile Number

    You can user our validatemobile endpoint to validate any mobile number

    https://topupnaija.com/api/validatemobile

    Method: POST

    Header 1= 'Content-Type : application/json'

    Header 2= 'Authorization-Token : //Your authorization token'

    Post Fields

  • mobileNumber
  • $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => "https://topupnaija.com/api/requerytrx", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_POSTFIELDS =>json_encode(array("mobileNumber" => "09039022177") ), CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Authorization-Token: JBKhjvY778Yghc5E5Egvj6", //Replace with your token ), )); $response = curl_exec($curl); curl_close($curl); echo $response;

    Responses

    {"status" : "error","message":"Authorization token was not found","data":""}

    {"status":"error","message":"Invalid authorization token","data":""}

    {"status":"error","message":"Failed to validate mobile number","data":[]}

    {"status":"success","message":"Mobile number validated successfully","data":{"operator":"MTN","minRechargeAmount":50,"maxRechargeAmount":200000}}