API stands for Application Programming Interface. An API is a software intermediary that allows two applications to talk to each other. In other words, an API is the messenger that delivers your request to the provider that you're requesting it from and then delivers the response back to you.
BAHARUNADADATA provides a standard API which developers can use to connect their websites or applications with no activation fee
Our HTTPS POST API is excellent option to integrate with various e-channels such as Website, Mobile App or CMS Applications e.t.c. without using our website to order for any product
Since we are using the POST API, each of the responses would be sent back in JSON.
We have also provided a test endpoint to test our products and services before using our live endpoint. While using the testing endpoint you will need to copy the same api key from your account profile which can be used for both live and test environment
Live Url: https://bahrunadadata.com.ng/api/v1/
Test Url: https://bahrunadadata.com.ng/api/test/
Available services includes:
To get started Click Here
This section contains checking user wallet balance
Live Url: https://bahrunadadata.com.ng/api/v1/user
Test Url: Not Available
Parameter | Description |
username | Your registered username |
password | Your registered password |
api token | You can get it from your account profile |
$options = [ 'username' => '{your username}', 'password' => '{your password}' ]; $url = "https://bahrunadadata.com.ng/api/v1/user/"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
{"statuscode":"000","status":"success","message":"Transaction was successful","response":"Transaction Successful","details":{"username":"Elisco","name":"Elijah Odufuwa","apitoken":"pk_live_3b9580da4dedbf45552058f45ec18174","email":"eliscotech@gmail.com","phone":"08163540288","balance":"833080.29","accounttype":"PREMIUM","regtime":"Wed, 04 Jan 2023. 09:41:44 am"}}
Status Code | Status | Response | Description |
000 | success | Transaction Successful | The transaction was successful/request successful |
01 | Fail | Request Failed | Unable to decode |
02 | Fail | Invalid Token | Empty token or invalid token |
03 | Fail | Invalid Username | Empty username or username not valid |
04 | Fail | Token and Username not matching | The token and username did not match |
05 | Fail | Invalid Password | Empty password or invalid password |
06 | Fail | User Suspended | The user account is suspended |
07 | Fail | Service Unavailable | The service is not available at the moment |
For more enquiry, request or complaint kindly contact us
This section contains purchase of data bundle
Live Url: https://bahrunadadata.com.ng/api/v1/data
Test Url: https://bahrunadadata.com.ng/api/test/data
NOTE: For testing purpose, use 08160101010 for mtn, 08080101010 for airtel, 09050101010 for glo and 09090101010 for 9mobile. To run a failed transaction, use any number apart from the one provided.
Parameter | Description |
network | The network ID. You can check this link to get the network id in json response https://bahrunadadata.com.ng/api/json/networkid.php |
phoneno | Enter the mobile number to receive the data |
planid | The plan ID for the data plan. You can check this link to get all available plan id in json response https://bahrunadadata.com.ng/api/json/data.php |
api token | You can get it from your account profile |
$options = [ 'network' => 'mtn', 'phoneno' => '08160101010', 'planid' => '20' ]; $url = "https://bahrunadadata.com.ng/api/v1/data/"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"statuscode":"000","status":"success", "message":"transaction was successful", "response":"Transaction Successful", "details":{"service":"Data Bundle", "network":"MTN","data_type":"MTN CORPORATE DATA", "data_plan":"MTN 150mb Corporate Gifting", "data_size":"150MB","phone_no":"08163540288", "validity":"30 Days","amount_paid":"65.00", "order_time":" Thu, 20 Jul 2023 08:33:17 pm ", "approve_time":" Thu, 20 Jul 2023 08:33:34 pm ", "transid":"Data_2007202308331764b98bfde15f8", "status":"Approved","old_balance":"856,943.69", "new_balance":"856,878.69", "remark":"Dear Customer, You have gifted 150MB, please dial *312*4*7*5# to check your balance. Thankyou."} }
{"statuscode":"111","status":"fail","message":"transaction failed please try again later!.","response":"Transaction Failed"}
Status Code | Status | Response | Description |
000 | success | Transaction Successful | The transaction was successful/request successful |
01 | Fail | Request Failed | Unable to decode |
02 | Fail | Invalid Token | Empty token or invalid token |
111 | Fail | Transaction Failed | The transaction was failed |
112 | Fail | Duplicate Transaction | Duplicate transaction occurred |
08 | Fail | Empty Network | Network is required |
09 | Fail | Empty Phone Number | Phone number is required |
13 | Fail | Numeric Required Only | Phone number must be in numeric format |
14 | Fail | Invalid Phone Number | Phone number is invalid |
15 | Fail | Phone_Number_11 | Phone number must be 11 digits |
18 | Fail | Invalid Network | Network is invalid |
19 | Fail | MTN Not Available | Mtn network is not availble |
20 | Fail | GLO Not Available | Glo network is not available |
21 | Fail | AIRTEL Not Available | Airtel network is not available |
22 | Fail | 9MOBILE Not Available | 9mobile network is not available |
23 | Fail | Invalid (mtn/glo/airtel/9mobile) Number | The phone number is not (mtn/glo/airtel/9mobile) |
24 | Fail | Insufficient Wallet Balance | Your wallet balance is not sufficient to buy this product |
34 | Fail | Empty Plan ID | Plan ID is required |
35 | Fail | Invalid Plan ID | Plan ID is invalid |
36 | Fail | Data Type Not Available | The data type for the plan or network is not available |
06 | Fail | User Suspended | The user account is suspended |
07 | Fail | Service Unavailable | The service is not available at the moment |
For more enquiry, request or complaint kindly contact us
This section contains purchase of airtime vtu
Live Url: https://bahrunadadata.com.ng/api/v1/airtime
Test Url: https://bahrunadadata.com.ng/api/test/airtime
NOTE: For testing purpose, use 08160101010 for mtn, 08080101010 for airtel, 09050101010 for glo and 09090101010 for 9mobile. To run a failed transaction, use any number apart from the one provided.
Parameter | Description |
network | The network ID. You can check this link to get the network id in json response https://bahrunadadata.com.ng/api/json/networkid.php |
phoneno | Enter the mobile number to receive the airtime vtu |
amount | Airtime amount to purchase |
airtime_type | Airtime Type i.e VTU for virtual top up |
api token | You can get it from your account profile |
$options = [ 'network' => 'mtn', 'phoneno' => '08160101010', 'amount' => '100', 'airtime_type' => 'VTU' ]; $url = "https://bahrunadadata.com.ng/api/v1/airtime/"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"service":"Airtime Topup","network":"MTN", "airtime_type":"VTU","phone_no":"08163540288", "amount":"20","amount_paid":"19.60", "order_time":" Mon, 17 Jul 2023 10:26:47 pm ", "approve_time":" Mon, 17 Jul 2023 10:26:56 pm ", "transid":"2023071722264764b5b217c2635", "status":"Approved","old_balance":"869,301.29", "new_balance":"869,281.69", "remark":"Airtime VTU purchased successfully"} }
{"statuscode":"111","status":"fail","message":"transaction failed please try again later!.","response":"Transaction Failed"}
Status Code | Status | Response | Description |
000 | success | Transaction Successful | The transaction was successful/request successful |
01 | Fail | Request Failed | Unable to decode |
02 | Fail | Invalid Token | Empty token or invalid token |
111 | Fail | Transaction Failed | The transaction was failed |
112 | Fail | Duplicate Transaction | Duplicate transaction occurred |
08 | Fail | Empty Network | Network is required |
09 | Fail | Empty Phone Number | Phone number is required |
10 | Fail | Empty Amount | Amount is required |
11 | Fail | Empty Airtime Type | Airtime type is required |
12 | Fail | Invalid Airtime Type | Airtime type is invalid. It must be VTU |
13 | Fail | Numeric Required Only | Phone number must be in numeric format |
14 | Fail | Invalid Phone Number | Phone number is invalid |
15 | Fail | Phone_Number_11 | Phone number must be 11 digits |
16 | Fail | Minimum 100 Required | Minimum airtime purchase is 100 |
17 | Fail | Maximum 5000 Required | Maximum airtime purchase is 5000 |
18 | Fail | Invalid Network | Network is invalid |
19 | Fail | MTN Not Available | Mtn network is not availble |
20 | Fail | GLO Not Available | Glo network is not available |
21 | Fail | AIRTEL Not Available | Airtel network is not available |
22 | Fail | 9MOBILE Not Available | 9mobile network is not available |
23 | Fail | Invalid (mtn/glo/airtel/9mobile) Number | The phone number is not (mtn/glo/airtel/9mobile) |
24 | Fail | Insufficient Wallet Balance | Your wallet balance is not sufficient to buy this product |
28 | Fail | Numeric Amount Required | Amount must be in numeric format |
06 | Fail | User Suspended | The user account is suspended |
07 | Fail | Service Unavailable | The service is not available at the moment |
For more enquiry, request or complaint kindly contact us
This section contains purchase of data card and coupon
Live Url: https://bahrunadadata.com.ng/api/v1/datacard
Test Url: https://bahrunadadata.com.ng/api/test/datacard
NOTE: For testing purpose, use tester as name. To run a failed transaction, use another name apart from the one provided.
Parameter | Description |
network | The network ID. You can check this link to get the network id in json response https://bahrunadadata.com.ng/api/json/networkid.php |
quantity | The total quantity to purchase. Minimum of 1 to Maximum of 5 |
planid | The plan ID for the datacard plan. You can check this link to get all available plan id in json response https://bahrunadadata.com.ng/api/json/datacard.php |
name | Enter your preferred card name. For testing, you can use tester as name |
api token | You can get it from your account profile |
$options = [ 'network' => 'mtn', 'quantity' => '2', 'planid' => '1500', 'name' => 'tester' ]; $url = "https://bahrunadadata.com.ng/api/v1/datacard/"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"statuscode":"000","status":"success", "message":"transaction was successful", "response":"Transaction Successful", "details":{"service":"Data Card PIN","network":"MTN", "data_type":"MTN CORPORATE DATA CARD", "data_plan":"MTN CORPORATE 1500MB | 30 DAYS", "data_size":"1.5GB","coupon":"56377366S,3578836537S", "serial":"273748393782,3637373763377", "dial_code":"*460*6*1#", "quantity":"2","validity":"30 DAYS", "amount_paid":"700.00", "order_time":" Sat, 22 Jul 2023 02:22:19 pm ", "approve_time":" Sat, 22 Jul 2023 02:22:19 pm ", "transid":"DC_PIN_2207202302221964bbd80b93e82", "status":"Approved","old_balance":"856,528.69", "new_balance":"855,828.69", "remark":"Data Card Coupon purchased successfully"} }
{"statuscode":"111","status":"fail","message":"transaction failed please try again later!.","response":"Transaction Failed"}
Status Code | Status | Response | Description |
000 | success | Transaction Successful | The transaction was successful/request successful |
01 | Fail | Request Failed | Unable to decode |
02 | Fail | Invalid Token | Empty token or invalid token |
111 | Fail | Transaction Failed | The transaction was failed |
112 | Fail | Duplicate Transaction | Duplicate transaction occurred |
08 | Fail | Empty Network | Network is required |
18 | Fail | Invalid Network | Network is invalid |
19 | Fail | MTN Not Available | Mtn network is not availble |
20 | Fail | GLO Not Available | Glo network is not available |
21 | Fail | AIRTEL Not Available | Airtel network is not available |
22 | Fail | 9MOBILE Not Available | 9mobile network is not available |
24 | Fail | Insufficient Wallet Balance | Your wallet balance is not sufficient to buy this product |
34 | Fail | Empty Plan ID | Plan ID is required |
35 | Fail | Invalid Plan ID | Plan ID is invalid |
36 | Fail | Data Type Not Available | The data type for the plan or network is not available |
37 | Fail | Empty Quantity | Quantity is required |
38 | Fail | Numeric Required Only | Quantity must be in numeric format |
39 | Fail | Minimum 1 Required | Minimum of 1 quantity is required |
40 | Fail | Maximum 5 Required | Maximum of 5 quantity is required |
41 | Fail | Empty Card Name | Name on card is required |
42 | Fail | Quantity Unavailable | Quantity not available at the moment |
06 | Fail | User Suspended | The user account is suspended |
07 | Fail | Service Unavailable | The service is not available at the moment |
For more enquiry, request or complaint kindly contact us
This section contains verification and payment of cable tv service
Live Url: https://bahrunadadata.com.ng/api/v1/cabletv/verify_cable.php
Test Url: https://bahrunadadata.com.ng/api/test/cabletv/verify_cable.php
NOTE: For testing purpose, use 1212121212 as the smartcard/iuc number. To run a failed transaction, use any number apart from the one provided.
Parameter | Description |
cable_name | Enter the cable name. You can check this link to get the cable id in json response https://bahrunadadata.com.ng/api/json/cableid.php |
customer_id | Enter the smarcard/iuc number in this field |
api token | You can get it from your account profile |
$options = [ 'cable_name' => 'dstv', 'customer_id' => '7017017321' ]; $url = "https://bahrunadadata.com.ng/api/v1/cabletv/verify_cable.php"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"statuscode":"000","status":"success", "message":"transaction was successful", "response":"Transaction Successful", "customer_name":"ODUFUWA ODUFUWA"}
{"statuscode":"31","status":"fail","message":"the customer id is not valid","response":"Invalid Customer ID"}
Status Code | Status | Response | Description |
000 | success | Transaction Successful | The transaction was successful/request successful |
01 | Fail | Request Failed | Unable to decode |
02 | Fail | Invalid Token | Empty token or invalid token |
26 | Fail | Empty Customer ID | Customer ID is required |
32 | Fail | Empty Cable Name | Cable name is required |
33 | Fail | Invalid Cable ID | Cable ID is invalid |
31 | Fail | Invalid Customer ID | The customer ID is not valid |
06 | Fail | User Suspended | The user account is suspended |
07 | Fail | Service Unavailable | The service is not available at the moment |
Live Url: https://bahrunadadata.com.ng/api/v1/cabletv/
Test Url: https://bahrunadadata.com.ng/api/test/cabletv/
NOTE: For testing purpose, use 1212121212 as the smartcard/iuc number. To run a failed transaction, use any number apart from the one provided.
Parameter | Description |
cable_name | Enter the cable name. You can check this link to get the cable id in json response https://bahrunadadata.com.ng/api/json/cableid.php |
customer_id | Enter the smarcard/iuc number in this field |
plan_id | The plan ID for the cable plan. You can check this link to get all available plan id in json response https://bahrunadadata.com.ng/api/json/cable.php |
api token | You can get it from your account profile |
$options = [ 'cable_name' => 'dstv', 'customer_id' => '1212121212', 'plan_id' => '30' ]; $url = "https://bahrunadadata.com.ng/api/v1/cabletv/"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"statuscode":"000","status":"success", "message":"transaction was successful", "response":"Transaction Successful", "details":{"service":"Cable TV Payment", "cable_name":"DSTV","cable_bousquet":"Dstv Padi Bouquet", "customer_id":"7017017321","customer_name":"Sten Mockett", "bousquet_amount":"2500","charges":"2", "discount":"4","duration":"1 MONTH", "amount_paid":"2,398.00", "order_time":" Wed, 19 Jul 2023 02:34:00 am ", "approve_time":" Wed, 19 Jul 2023 02:34:16 am ", "transid":"2023071902340064b73d88ace63","status":"Approved", "old_balance":"864,359.69", "new_balance":"861,961.69", "remark":"Subscribed Cable TV successfully"} }
{"statuscode":"111","status":"fail","message":"transaction failed please try again later!.","response":"Transaction Failed"}
Status Code | Status | Response | Description |
000 | success | Transaction Successful | The transaction was successful/request successful |
111 | Fail | Transaction Failed | The transaction was failed |
112 | Fail | Duplicate Transaction | Duplicate transaction occurred |
01 | Fail | Request Failed | Unable to decode |
02 | Fail | Invalid Token | Empty token or invalid token |
26 | Fail | Empty Customer ID | Customer ID is required |
31 | Fail | Invalid Customer ID | The customer ID is not valid |
32 | Fail | Empty Cable Name | Cable name is required |
33 | Fail | Invalid Cable ID | Cable ID is invalid |
34 | Fail | Empty Plan ID | Plan ID is required |
35 | Fail | Invalid Plan ID | Plan ID is invalid |
24 | Fail | Insufficient Wallet Balance | Your wallet balance is not sufficient to buy this product |
06 | Fail | User Suspended | The user account is suspended |
07 | Fail | Service Unavailable | The service is not available at the moment |
For more enquiry, request or complaint kindly contact us
This section contains verification and payment of electricity service
Live Url: https://bahrunadadata.com.ng/api/v1/electricity/verify_meter.php
Test Url: https://bahrunadadata.com.ng/api/test/electricity/verify_meter.php
NOTE: For testing purpose, use 02020202020 (both prepaid and postpaid) as the meter number. To run a failed transaction, use any number apart from the one provided.
Parameter | Description |
disco | Enter the disco name. You can check this link to get the electricity id in json response https://bahrunadadata.com.ng/api/json/elect.php |
type | use prepaid or postpaid any other is invalid. |
customer_id | Enter the meter number in this field |
api token | You can get it from your account profile |
$options = [ 'disco' => 'ikedc', 'type' => 'prepaid', 'customer_id' => '02020202020' ]; $url = "https://bahrunadadata.com.ng/api/v1/electricity/verify_meter.php"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"statuscode":"000","status":"success", "message":"transaction was successful", "response":"Transaction Successful", "customer_name":"ROTIMI ODUFUWA"}
{"statuscode":"31","status":"fail","message":"the customer id is not valid","response":"Invalid Customer ID"}
Status Code | Status | Response | Description |
000 | success | Transaction Successful | The transaction was successful/request successful |
01 | Fail | Request Failed | Unable to decode |
02 | Fail | Invalid Token | Empty token or invalid token |
26 | Fail | Empty Customer ID | Customer ID is required |
31 | Fail | Invalid Customer ID | The customer ID is not valid |
43 | Fail | Invalid Disco Name | Disco name is invalid |
44 | Fail | Empty Disco Name | Disco name is required |
45 | Fail | Empty Meter Type | Meter type is required |
46 | Fail | Invalid Meter Type | The meter type is invalid |
06 | Fail | User Suspended | The user account is suspended |
07 | Fail | Service Unavailable | The service is not available at the moment |
Live Url: https://bahrunadadata.com.ng/api/v1/electricity/
Test Url: https://bahrunadadata.com.ng/api/test/electricity/
NOTE: For testing purpose, use 02020202020 (both prepaid and postpaid) as the meter number. To run a failed transaction, use any number apart from the one provided.
Parameter | Description |
disco | Enter the disco name. You can check this link to get the electricity id in json response https://bahrunadadata.com.ng/api/json/elect.php |
type | use prepaid or postpaid any other is invalid. |
customer_id | Enter the meter number in this field |
amount | Enter the amount to purchase |
api token | You can get it from your account profile |
$options = [ 'disco' => 'ikedc', 'type' => 'prepaid', 'customer_id' => '02020202020', 'amount' => '500' ]; $url = "https://bahrunadadata.com.ng/api/v1/electricity/"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"statuscode":"000","status":"success", "message":"transaction was successful", "response":"Transaction Successful", "details":{"service":"Electricity Payment", "disco_name":"Ikeja Electric Payment - PHCN", "meter_type":"PREPAID","meter_number":"04285904175", "token":"Token : 26362054405982757802", "unit":"79.9 kWh","customer_name":"ODUFUWA ROTIMI", "charges":"00","discount":"3", "token_amount":"500","amount_paid":"485.00", "order_time":" Sun, 23 Jul 2023 05:34:01 pm ", "approve_time":" Sun, 23 Jul 2023 05:34:09 pm ", "transid":"2023072317340164bd5679a6b0d", "status":"Approved","old_balance":"854,778.69", "new_balance":"854,293.69", "remark":"Electricity Bills purchased successfully"} }
{"statuscode":"111","status":"fail","message":"transaction failed please try again later!.","response":"Transaction Failed"}
Status Code | Status | Response | Description |
000 | success | Transaction Successful | The transaction was successful/request successful |
111 | Fail | Transaction Failed | The transaction was failed |
112 | Fail | Duplicate Transaction | Duplicate transaction occurred |
01 | Fail | Request Failed | Unable to decode |
02 | Fail | Invalid Token | Empty token or invalid token |
26 | Fail | Empty Customer ID | Customer ID is required |
31 | Fail | Invalid Customer ID | The customer ID is not valid |
43 | Fail | Invalid Disco Name | Disco name is invalid |
44 | Fail | Empty Disco Name | Disco name is required |
45 | Fail | Empty Meter Type | Meter type is required |
46 | Fail | Invalid Meter Type | The meter type is invalid |
34 | Fail | Empty Plan ID | Plan ID is required |
35 | Fail | Invalid Plan ID | Plan ID is invalid |
28 | Fail | Numeric Amount Required | Amount must be in numeric format |
10 | Fail | Empty Amount | Amount is required |
47 | Fail | Minimum 500 Required | Minimum amount should be 500 |
24 | Fail | Insufficient Wallet Balance | Your wallet balance is not sufficient to buy this product |
06 | Fail | User Suspended | The user account is suspended |
07 | Fail | Service Unavailable | The service is not available at the moment |
For more enquiry, request or complaint kindly contact us
Live Url: https://bahrunadadata.com.ng/api/v1/exam/verify_jamb.php
Test Url: https://bahrunadadata.com.ng/api/test/exam/verify_jamb.php
NOTE: For testing purpose, use 1010101010 as the jamb profile ID. To run a failed transaction, use any number apart from the one provided.
Parameter | Description |
exam_name | Enter the exam id in this field. You can check this link to get the exam id in json response https://bahrunadadata.com.ng/api/json/examid.php |
customer_id | Enter the jamb id or code in this field |
api token | You can get it from your account profile |
$options = [ 'exam_name' => 'jamb', 'customer_id' => '0123456789' ]; $url = "https://bahrunadadata.com.ng/api/v1/exam/verify_jamb.php"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"statuscode":"000","status":"success", "message":"transaction was successful", "response":"Transaction Successful", "customer_name":"ROTIMI JOSEPH"}
{"statuscode":"31","status":"fail","message":"the customer id is not valid","response":"Invalid Customer ID"}
Status Code | Status | Response | Description |
000 | success | Transaction Successful | The transaction was successful/request successful |
01 | Fail | Request Failed | Unable to decode |
02 | Fail | Invalid Token | Empty token or invalid token |
26 | Fail | Empty Customer ID | Customer ID is required |
31 | Fail | Invalid Customer ID | The customer ID is not valid |
55 | Fail | Invalid Exam Name | Exam name is not vaild |
48 | Fail | Empty Exam Name | exam name is required |
06 | Fail | User Suspended | The user account is suspended |
07 | Fail | Service Unavailable | The service is not available at the moment |
This section contains purchase of jamb pin only
Live Url: https://bahrunadadata.com.ng/api/v1/exam/jamb.php
Test Url: https://bahrunadadata.com.ng/api/test/exam/jamb.php
NOTE: For testing purpose, use 1010101010 as the jamb profile ID. To run a failed transaction, use any number apart from the one provided.
Parameter | Description |
exam_name | Enter the exam id in this field. You can check this link to get the exam id in json response https://bahrunadadata.com.ng/api/json/examid.php |
exam_type | Enter the exam type in this field. use exam-rc as the code, which stands as result checker |
customer_id | Enter the jamb id or code in this field |
api token | You can get it from your account profile |
$options = [ 'exam_name' => 'jamb', 'exam_type' => 'exam-rc', 'customer_id' => '0123456789' ]; $url = "https://bahrunadadata.com.ng/api/v1/exam/jamb.php"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"statuscode":"000","status":"success", "message":"transaction was successful", "response":"Transaction Successful", "details":{"service":"Exam PIN", "exam_name":"JAMB","exam_type":"Result Checker", "pin":"Pin : 367574683050773","serial":"N\/A", "quantity":"0123456789","amount_paid":"1,500.00", "order_time":" Tue, 24 Oct 2023 03:41:35 am ", "approve_time":" Tue, 24 Oct 2023 03:41:43 am ", "transid":"2023102403413565372edf48faa","status":"Approved", "old_balance":"58,600.00","new_balance":"57,100.00", "remark":"Exam PIN purchased successfully"}}
{"statuscode":"111","status":"fail","message":"transaction failed please try again later!.","response":"Transaction Failed"}
This section contains purchase of exam pin for waec,neco and nabteb only
Live Url: https://bahrunadadata.com.ng/api/v1/exam
Test Url: https://bahrunadadata.com.ng/api/test/exam
NOTE: For testing purpose, use tester as name. To run a failed transaction, use another name apart from the one provided.
Parameter | Description |
exam_name | Enter the exam id in this field. You can check this link to get the exam id in json response https://bahrunadadata.com.ng/api/json/examid.php |
exam_type | Enter the exam type in this field. use exam-rc as the code, which stands as result checker |
quantity | The total quantity to purchase. Minimum of 1 to Maximum of 5 |
name | Enter your preferred card name. For testing, you can use tester as name |
api token | You can get it from your account profile |
$options = [ 'exam_name' => 'waec', 'exam_type' => 'exam-rc', 'quantity' => '2', 'name' => 'tester' ]; $url = "https://bahrunadadata.com.ng/api/v1/exam/"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"statuscode":"000","status":"success", "message":"transaction was successful", "response":"Transaction Successful", "details":{"service":"Exam PIN", "exam_name":"WAEC","exam_type":"Result Checker", "pin":"787846464246488,525839887412388", "serial":"8757573348448018466,5222369808774145555", "quantity":"2","amount_paid":"2,400.00", "order_time":" Tue, 25 Jul 2023 11:25:52 pm ", "approve_time":" Tue, 25 Jul 2023 11:25:52 pm ", "transid":"EX_PIN_2507202311255264c04bf0cce78", "status":"Approved","old_balance":"854,293.69", "new_balance":"851,893.69", "remark":"Exam PIN purchased successfully"} }
{"statuscode":"111","status":"fail","message":"transaction failed please try again later!.","response":"Transaction Failed"}
Status Code | Status | Response | Description |
000 | success | Transaction Successful | The transaction was successful/request successful |
01 | Fail | Request Failed | Unable to decode |
02 | Fail | Invalid Token | Empty token or invalid token |
111 | Fail | Transaction Failed | The transaction was failed |
112 | Fail | Duplicate Transaction | Duplicate transaction occurred |
48 | Fail | Empty Exam Name | Exam name is required |
49 | Fail | Empty Exam Type | Exam type is required |
50 | Fail | Invalid Exam Type | Exam type is invalid |
26 | Fail | Empty Customer ID | Customer ID is required |
31 | Fail | Invalid Customer ID | The customer ID is not valid |
51 | Fail | WAEC PIN Not Available | Waec pin is not available |
52 | Fail | NECO PIN Not Available | Neco pin is not available |
53 | Fail | JAMB PIN Not Available | Jamb pin is not available |
54 | Fail | NABTEB Not Available | Nabteb pin is not available |
55 | Fail | Invalid Exam Name | Exam name is not vaild |
37 | Fail | Empty Quantity | Quantity is required |
38 | Fail | Numeric Required Only | Quantity must be in numeric format |
39 | Fail | Minimum 1 Required | Minimum of 1 quantity is required |
40 | Fail | Maximum 5 Required | Maximum of 5 quantity is required |
41 | Fail | Empty Card Name | Name on card is required |
42 | Fail | Quantity Unavailable | Quantity not available at the moment |
24 | Fail | Insufficient Wallet Balance | Your wallet balance is not sufficient to buy this product |
06 | Fail | User Suspended | The user account is suspended |
07 | Fail | Service Unavailable | The service is not available at the moment |
For more enquiry, request or complaint kindly contact us
This section contains verification and subscription for internet service
Live Url: https://bahrunadadata.com.ng/api/v1/internet/verify_smile.php
Test Url: https://bahrunadadata.com.ng/api/test/internet/verify_smile.php
NOTE: For testing purpose, use 0810101010 as the customer number for smile verification. To run a failed transaction, use any number apart from the one provided.
Parameter | Description |
internet_name | Enter the internet name. You can check this link to get the internet id in json response https://bahrunadadata.com.ng/api/json/internetid.php |
customer_id | Enter the customer number in this field |
api token | You can get it from your account profile |
$options = [ 'internet_name' => 'smile', 'customer_id' => '0810101010' ]; $url = "https://bahrunadadata.com.ng/api/v1/internet/verify_smile.php"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"statuscode":"000", "status":"success", "message":"transaction was successful", "response":"Transaction Successful", "customer_name":"Sunday Ojo"}
{"statuscode":"31","status":"fail","message":"the customer id is not valid","response":"Invalid Customer ID"}
Live Url: https://bahrunadadata.com.ng/api/v1/internet/smile.php
Test Url: https://bahrunadadata.com.ng/api/test/internet/smile.php
NOTE: For testing purpose, use 0810101010 as the customer number for smile payment. To run a failed transaction, use any number apart from the one provided.
Parameter | Description |
internet_name | Enter the internet name. You can check this link to get the internet id in json response https://bahrunadadata.com.ng/api/json/internetid.php |
customer_id | Enter the customer number in this field |
plan_id | The plan ID for the internet plan. You can check this link to get all available plan id in json response https://bahrunadadata.com.ng/api/json/internet.php |
api token | You can get it from your account profile |
$options = [ 'internet_name' => 'smile', 'customer_id' => '0810101010', 'plan_id' => '80' ]; $url = "https://bahrunadadata.com.ng/api/v1/internet/smile.php"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"statuscode":"000","status":"success", "message":"transaction was successful", "response":"Transaction Successful", "details":{"service":"Internet Services", "internet_name":"SMILE", "plan_name":"3GB Weekend ONLY for 3days - 1,530 Naira", "customer_id":"1911001220", "customer_name":"Sunday Ojo", "plan_amount":"1530.00","pin":"NULL", "serial":"NULL","quantity":null, "discount":"2","duration":"3 DAYS", "amount_paid":"1,499.40", "order_time":" Thu, 27 Jul 2023 12:42:37 pm ", "approve_time":" Thu, 27 Jul 2023 12:42:47 pm ", "transid":"2023072712423764c2582d8ac0f", "status":"Approved","old_balance":"834,693.69", "new_balance":"833,194.29", "remark":"Internet Service Subscribed successfully"} }
{"statuscode":"111","status":"fail","message":"transaction failed please try again later!.","response":"Transaction Failed"}
Live Url: https://bahrunadadata.com.ng/api/v1/internet/spectranet.php
Test Url: https://bahrunadadata.com.ng/api/test/internet/spectranet.php
NOTE: For testing purpose, use 0810101010 as the customer number for spectranet payment. To run a failed transaction, use any number apart from the one provided.
Parameter | Description |
internet_name | Enter the internet name. You can check this link to get the internet id in json response https://bahrunadadata.com.ng/api/json/internetid.php |
customer_id | Enter the customer number in this field |
quantity | The total quantity to purchase. Minimum of 1 to Maximum of 5 |
plan_id | The plan ID for the internet plan. You can check this link to get all available plan id in json response https://bahrunadadata.com.ng/api/json/internet.php |
api token | You can get it from your account profile |
$options = [ 'internet_name' => 'spectranet', 'customer_id' => '0810101010', 'quantity' => '2', 'plan_id' => '100' ]; $url = "https://bahrunadadata.com.ng/api/v1/internet/spectranet.php"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"statuscode":"000","status":"success", "message":"transaction was successful", "response":"Transaction Successful", "details":{"service":"Internet Services", "internet_name":"SPECTRANET", "plan_name":"Spectranet N5000","customer_id":"46765437", "customer_name":"NULL","plan_amount":"5000", "pin":"08999186","serial":"81560189", "quantity":"2","discount":"4","duration":"30 DAYS", "amount_paid":"9,600.00", "order_time":" Thu, 27 Jul 2023 12:31:26 pm ", "approve_time":" Thu, 27 Jul 2023 12:31:32 pm ", "transid":"2023072712312664c2558ef2eea", "status":"Approved","old_balance":"844,293.69", "new_balance":"834,693.69", "remark":"Internet Service Subscribed successfully"} }
{"statuscode":"111","status":"fail","message":"transaction failed please try again later!.","response":"Transaction Failed"}
Status Code | Status | Response | Description |
000 | success | Transaction Successful | The transaction was successful/request successful |
111 | Fail | Transaction Failed | The transaction was failed |
112 | Fail | Duplicate Transaction | Duplicate transaction occurred |
01 | Fail | Request Failed | Unable to decode |
02 | Fail | Invalid Token | Empty token or invalid token |
26 | Fail | Empty Customer ID | Customer ID is required |
31 | Fail | Invalid Customer ID | The customer ID is not valid |
56 | Fail | Invalid Internet ID | Internet ID is invalid |
57 | Fail | Empty Internet Name | Internet name is required |
58 | Fail | SMILE Not Available | Smile network is not available |
59 | Fail | SPECTRANET Not Available | Spectranet network is not available |
34 | Fail | Empty Plan ID | Plan ID is required |
35 | Fail | Invalid Plan ID | Plan ID is invalid |
37 | Fail | Empty Quantity | Quantity is required |
38 | Fail | Numeric Required Only | Quantity must be in numeric format |
39 | Fail | Minimum 1 Required | Minimum of 1 quantity is required |
40 | Fail | Maximum 5 Required | Maximum of 5 quantity is required |
24 | Fail | Insufficient Wallet Balance | Your wallet balance is not sufficient to buy this product |
06 | Fail | User Suspended | The user account is suspended |
07 | Fail | Service Unavailable | The service is not available at the moment |
For more enquiry, request or complaint kindly contact us
This section contains purchase of recharge card pin
Live Url: https://bahrunadadata.com.ng/api/v1/rechargepin
Test Url: https://bahrunadadata.com.ng/api/test/rechargepin
NOTE: For testing purpose, use tester as name. To run a failed transaction, use another name apart from the one provided.
Parameter | Description |
network | The network ID. You can check this link to get the network id in json response https://bahrunadadata.com.ng/api/json/networkid.php |
quantity | The total quantity to purchase. Minimum of 1 to Maximum of 5 |
amount | The recharge amount. Use 100,200,400,500,1000 as the amount |
name | Enter your preferred card name. For testing, you can use tester as name |
api token | You can get it from your account profile |
$options = [ 'network' => 'mtn', 'amount' => '100', 'quantity' => '2', 'name' => 'tester' ]; $url = "https://bahrunadadata.com.ng/api/v1/rechargepin/"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"statuscode":"000","status":"success", "message":"transaction was successful", "response":"Transaction Successful", "details":{"service":"Recharge Card PIN", "network":"MTN","amount":"100", "pin":"9246545452248843,85536689087445", "serial":"53368842221455580,88522338800966547", "quantity":"2","dial_code":"*311*PIN#", "instruction":"Dial *311*PIN# to load pin", "amount_paid":"99.00", "order_time":" Fri, 28 Jul 2023 07:21:45 am ", "approve_time":" Fri, 28 Jul 2023 07:21:45 am ", "transid":"RC_PIN_2807202307214564c35e791fd0a", "status":"Approved","old_balance":"833,194.29", "new_balance":"833,095.29", "remark":"Recharge Card PIN purchased successfully"} }
{"statuscode":"111","status":"fail","message":"transaction failed please try again later!.","response":"Transaction Failed"}
Status Code | Status | Response | Description |
000 | success | Transaction Successful | The transaction was successful/request successful |
01 | Fail | Request Failed | Unable to decode |
02 | Fail | Invalid Token | Empty token or invalid token |
111 | Fail | Transaction Failed | The transaction was failed |
112 | Fail | Duplicate Transaction | Duplicate transaction occurred |
08 | Fail | Empty Network | Network is required |
18 | Fail | Invalid Network | Network is invalid |
19 | Fail | MTN Not Available | Mtn network is not availble |
20 | Fail | GLO Not Available | Glo network is not available |
21 | Fail | AIRTEL Not Available | Airtel network is not available |
22 | Fail | 9MOBILE Not Available | 9mobile network is not available |
24 | Fail | Insufficient Wallet Balance | Your wallet balance is not sufficient to buy this product |
37 | Fail | Empty Quantity | Quantity is required |
38 | Fail | Numeric Required Only | Quantity must be in numeric format |
39 | Fail | Minimum 1 Required | Minimum of 1 quantity is required |
40 | Fail | Maximum 5 Required | Maximum of 5 quantity is required |
41 | Fail | Empty Card Name | Name on card is required |
42 | Fail | Quantity Unavailable | Quantity not available at the moment |
10 | Fail | Empty Amount | Amount is required |
28 | Fail | Numeric Amount Required | Amount must be in numeric format |
60 | Fail | Invalid Amount Type | Amount should be 100,200,400,500 and 1000 |
06 | Fail | User Suspended | The user account is suspended |
07 | Fail | Service Unavailable | The service is not available at the moment |
For more enquiry, request or complaint kindly contact us
This section contains sending single or bulk sms
Live Url: https://bahrunadadata.com.ng/api/v1/sms
Test Url: https://bahrunadadata.com.ng/api/test/sms
NOTE: For testing purpose, use tester as sender name. To run a failed transaction, use another name apart from the one provided.
Parameter | Description |
sender | Enter a sender name |
phoneno | Enter the recipient phone number to recieve message. If multiple phone numbers, they must be seperated by comma(,). Format: 080 or 23480 only |
route | This is the path the message is passing through. use normal |
message | Enter your message in this field. kindly note that you are allowed to send maximum of 5 pages at once |
api token | You can get it from your account profile |
$options = [ 'sender' => 'tester', 'phoneno' => '09048770721', 'route' => 'normal', 'message' => 'welcome to ecvservices' ]; $url = "https://bahrunadadata.com.ng/api/v1/sms/"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"statuscode":"000","status":"success", "message":"transaction was successful", "response":"Transaction Successful", "details":{"service":"Bulk SMS Service", "sender_name":"esvtu","route":"NORMAL", "receipient":"09048770721", "message":"welcome to ecvservices", "total_phone":1,"total_pages":1, "delivery":"Sent","amount_paid":"2.50", "order_time":" Fri, 28 Jul 2023 11:18:58 am ", "approve_time":" Fri, 28 Jul 2023 11:19:28 am ", "transid":"2023072811185864c3961276964", "status":"Approved","old_balance":"833,095.29", "new_balance":"833,092.79", "remark":"SMS Sent Successfully!"} }
{"statuscode":"111","status":"fail","message":"transaction failed please try again later!.","response":"Transaction Failed"}
Status Code | Status | Response | Description |
000 | success | Transaction Successful | The transaction was successful/request successful |
01 | Fail | Request Failed | Unable to decode |
02 | Fail | Invalid Token | Empty token or invalid token |
111 | Fail | Transaction Failed | The transaction was failed |
112 | Fail | Duplicate Transaction | Duplicate transaction occurred |
61 | Fail | Empty Sender Name | Sender name is required |
62 | Fail | Empty SMS Route | Sms route is required |
63 | Fail | Empty Message | Message is required |
64 | Fail | Phone_Number_Min_1 | Minimum of 1 phone number is required |
65 | Fail | Phone_Number_Max_50 | Maximum of 50 phone numbers is required |
66 | Fail | Sender_Name_Max_11 | Sender name must not be more than 11 |
67 | Fail | Message_Max_5 | Message must not be more than 5 Pages |
68 | Fail | Invalid SMS Route | Sms route is not valid |
69 | Fail | Sender Name Not Allowed | Blocked words were found in the sender id |
70 | Fail | Message Content Not Allowed | Blocked words were found in the message body |
09 | Fail | Empty Phone Number | Phone number is required |
14 | Fail | Invalid Phone Number | Phone number is invalid |
06 | Fail | User Suspended | The user account is suspended |
07 | Fail | Service Unavailable | The service is not available at the moment |
For more enquiry, request or complaint kindly contact us
This section contains verification and payment of betting service
Live Url: https://bahrunadadata.com.ng/api/v1/betting/verify_betting.php
Test Url: https://bahrunadadata.com.ng/api/test/betting/verify_betting.php
NOTE: For testing purpose, use 1010101010 as the customer number. To run a failed transaction, use any number apart from the one provided.
Parameter | Description |
betting_name | Enter the betting name. You can check this link to get the betting id in json response https://bahrunadadata.com.ng/api/json/betting.php |
customer_id | Enter the customer number in this field |
api token | You can get it from your account profile |
$options = [ 'betting_name' => 'betking', 'customer_id' => '1010101010' ]; $url = "https://bahrunadadata.com.ng/api/v1/betting/verify_betting.php"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"statuscode":"000","status":"success", "message":"transaction was successful", "response":"Transaction Successful", "customer_name":"Kudus Ramos"}
{"statuscode":"31","status":"fail","message":"the customer id is not valid","response":"Invalid Customer ID"}
Live Url: https://bahrunadadata.com.ng/api/v1/betting/
Test Url: https://bahrunadadata.com.ng/api/test/betting/
NOTE: For testing purpose, use 1010101010 as the customer number. To run a failed transaction, use any number apart from the one provided.
Parameter | Description |
betting_name | Enter the betting name. You can check this link to get the betting id in json response https://bahrunadadata.com.ng/api/json/betting.php |
customer_id | Enter the customer number in this field |
amount | Enter the amount to pay |
api token | You can get it from your account profile |
$options = [ 'betting_name' => 'betking', 'customer_id' => '1010101010', 'amount' => '100' ]; $url = "https://bahrunadadata.com.ng/api/v1/betting/"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($options)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ "Authorization: Token {Your Token Here}", 'Content-Type: application/json' ]; curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); $response = curl_exec($ch); curl_close($ch); echo $response;
Our HTTPS POST API will provide a JSON output format
If Successful{"statuscode":"000","status":"success", "message":"transaction was successful", "response":"Transaction Successful", "details":{"service":"Betting Service", "betting_name":"BANGBET","betting_type":"Wallet Funding", "customer_id":"34382","customer_name":"Test Account 2", "amount":"100","amount_paid":"98.00", "order_time":" Tue, 18 Jul 2023 02:34:08 am ", "approve_time":" Tue, 18 Jul 2023 02:34:26 am ", "transid":"2023071802340864b5ec10ee688", "status":"Approved","old_balance":"869,379.69", "new_balance":"869,281.69", "remark":"Betting Wallet Funded successfully"} }
{"statuscode":"111","status":"fail","message":"transaction failed please try again later!.","response":"Transaction Failed"}
Status Code | Status | Response | Description |
000 | success | Transaction Successful | The transaction was successful/request successful |
111 | Fail | Transaction Failed | The transaction was failed |
112 | Fail | Duplicate Transaction | Duplicate transaction occurred |
01 | Fail | Request Failed | Unable to decode |
02 | Fail | Invalid Token | Empty token or invalid token |
25 | Fail | Empty Betting Name | Betting name is required |
26 | Fail | Empty Customer ID | Customer ID is required |
10 | Fail | Empty Amount | Amount is required |
28 | Fail | Numeric Amount Required | Amount must be in numeric format |
29 | Fail | Minimum 100 Required | Minimum amount should be 100 |
30 | Fail | Invalid Betting Code | Betting code is invalid |
31 | Fail | Invalid Customer ID | The customer ID is not valid |
24 | Fail | Insufficient Wallet Balance | Your wallet balance is not sufficient to buy this product |
06 | Fail | User Suspended | The user account is suspended |
07 | Fail | Service Unavailable | The service is not available at the moment |
For more enquiry, request or complaint kindly contact us