<?php // using cURL POST $key="YOUR-ACCOUNT-KEY"; $ref_id="REFERENCE-ID"; $response = httpPost("https://api.textng.xyz/carrier_transaction_status/" ,array("key"=>"$key","ref_id"=>"$ref_id")); // using php curlfunction httpPost($url, $data) { $curl =curl_init ($url);curl_setopt ($curl, CURLOPT_POST, true);curl_setopt ($curl, CURLOPT_POSTFIELDS, http_build_query($data));curl_setopt ($curl, CURLOPT_RETURNTRANSFER, true); $response = curl_exec($curl); curl_close($curl);echo $response; } ?>
Parameters | Example | Description |
---|---|---|
Key | XXXXX-XXXX-XXXXX | This can be found in the Developers page of your dashboard. The key authorizes the transaction. |
ref_id |
XXXXXXXXXX | This is the "ref_id" parameter returned on each query / transaction you pushed |
{
"D": {
"details":[{
"status":"QUERY STATUS",
"ref_id":"XXXXXXXXXXXXXXX",
"query":"*XXX#",
"query_response":"THE RESPONSE FROM THE NETWORK",
"type":"XXXX",
"bypasscode":"23490XXXXXXXXX",
"amount_paid":"0"
}]
}
}
{
"D":{
"details":[
{
"status":"error -key-invalid"
}
]
}
}