In order to help you process our responses in a better and faster way, we have a structured way of sending responses, whether successful or errenous responses.
All our responses will be a json Object, with KEY data, as shown below
Key | Type | Description |
---|---|---|
Status | boolean |
The Request status. true for a successful request otherwise false |
message | string (required) |
A description of the request, or an explanation of why the request failed |
data | array,object,disctionary |
Contains all the data requested by an endpoint/all the data necesaary for a successful reconciliation in a future request |
StatusCode 200
Content
{
"status": true,
"message": "Message successfully queued!",
"data": {
"correlator": 2,
"uniqueId": "unique-string",
"phone": "254XXXXXXXXX",
"sms_units": 1
}
}
StatusCode 401
Reason Invalid or Missing Token
Content
{
"status": false,
"message": "Unauthenticated."
}
{info} As with HTTP Restful APIs', always check the response code too