SMS Status API

GET Method

Description

Using this API you will be able to request message status.

Base URL

<https://api.kaleyra.io/v1/><SID>

To get SMS status, follow the below steps:

  1. Signup or Login to Kaleyra.io and create your API key.

Refer to the Create an API Key page for steps to create your API key. To view the API Key and the SID, see View API Key and SID.

📘

Note:

After you sign up, your account will be on the trial version. You must complete the KYC to access all the features in Kaleyra.io.

  1. API command to get SMS Status

Use the following command:

Request Format

To get SMS status, use the /messages endpoints.

curl -X GET "https://api.kaleyra.io/v1/<SID>/messages/status?message_ids=<MESSAGE_IDS>" \
     -H "api-key: <API_KEY>"

📘

Note:

Ensure to replace the parameter values with the proper inputs in the above code.

Parameters and Variables

Below is the list of parameters and variables used:

ParameterVariableDescriptionExampleMandatory
SIDStringAccount SID (Security Identifier)HXXXXXXX071USTrue
MESSAGE_IDSStringMessage ID that was generated by Kaleyra.io send sms apiee8aXXXX-XXXX-XXXX-XXXX-9b717XXXX30d:1, ee8aXXXX-XXXX-XXXX-XXXX-9b717XXXX30d:2True
API_KEYStringAPI Key generated by Kaleyra.ioAc4XXXXX21fTrue
  1. Response Format

This section provides you the success and failure JSON response format for different scenarios.

Success Response

{
   "data": [
       {
           "campaign_id": "507XXXX-XXX-XXXX-XXXX-b8f6b452c04a:1",
           "status": "Delivered",
           "status_details": "DELIVERED"
       }
   ],
   "error": {}
}

📘

Note:

In case of an error, ensure that the parameter values are correct in the above code. Refer to the SMS Status and Status Trace Codes page for detailed information.

Sample Request

curl -X GET "https://api.kaleyra.io/v1/HXXXXXXX071US/messages/status?message_ids=<MESSAGE_IDS>" \
     -H "api-key: Ac4XXXXX21f"