<?php // Using cURL POST $key="YOUR-ACCOUNT-KEY"; $response = httpPost("https://api.textng.xyz/campaigns-get-groups/" ,array("key"=>"$key")); // 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 | xxxxxx-xxxxx-xxxxx | This can be found in the Developers page of your dashboard. The key authorizes the transaction. |
|---|
{"status":true ,"groups":[{"group_id":"180","state":"AKWA IBOM","lga":"UYO","ward":"ETOI
1","active_users":"70784"}...,{"group_id":"603","state":"TEST","lga":"TEST
LGA","ward":"TEST WD","active_users":"2"}]}
{
"D":{
"details":[
{
"status":"key-invalid"
}
]
}
}