Skip to content

Message delivery status

Request

Retrieve the delivery status for a specific SMS using its Message ID. The Message ID is provided in the Send Message API response as the third parameter in the data string.

The API returns an object with a data field containing the message ID and delivery status in the following format:

{
    "timestamp": 1782969745,
    "exection": 0.0013545999526978,
    "error": false,
    "data": {
        "message_id": "12345",
        "status": "sent"
    }
}

Errors

Error CodeError TypeError Message
-1000ACCESS-DENIEDAccess Denied
-1040MISSING-MESSAGE-IDID field missing
-1041INVALID-MESSAGE-IDID field has invalid value or not found
-1042NOT-AVAILABLE-STATUSThe message status is not available
-1043ACCESS-DENIED-TO-MESSAGE-IDAccess denied to the message ID

Supported Statuses

TypeStatusDescription
Processing Statesnot_sentThe message is in the sending queue.
Processing StatessentThe message has been sent successfully. Delivery confirmation pending.
Terminal StatesdeliveredThe message was successfully delivered.
Terminal StatesfailedThe message failed to send.
Terminal StatesundeliveredThe message was sent but not delivered.
Security
accessToken
Query
idintegerrequired

The message ID that you have received in the Send Message API.

Example:id=12345
curl -i -X POST \
  'https://p3.avanser.com/app/deliverystatus?id=12345&token=YOUR_API_KEY_HERE'

Responses

Delivery status.

Bodyapplication/json
timestampintegerrequired

The time that the API response left the server, represented as the number of seconds since the UNIX epoch.

Example:1508903167
exectionnumber

The number of seconds that it took to process the API request.

Example:0.00041531896591187
errorbooleanrequired

Boolean indicating whether there was an error returned by the API request.

Example:false
dataobjectrequired

The data returned by the API. The format varies depending on the API function that was called.

Response
{ "timestamp": 1782969745, "exection": 0.0013545999526978, "error": false, "data": { "message_id": "12345", "status": "sent" } }