Get all History
GET
/sms/history
SMS
|---|---|---|
|
Completed
| Added to delivery queue. Waiting to be sent to the network.||
Sent
| Message sent to the network.||
Cancelled
| Message cancelled.||
Scheduled
| Message scheduled.||
WaitApproval
| Waiting approval by our team. This is temporary and will change to 'Sent' once approved. This only happens for a few messages that are flagged for approval by our automated spam-detection system.|Code | Text | Description |
---|---|---|
200 | Sent by network | Temporary success |
201 | Received on handset | Permanent success |
300 | Delivery failure | Permanent failure |
301 | Delivery failure | Permanent failure |
302 | Delivery failure | Temporary failure - supplier routing issue |
Request Request Example
Shell
JavaScript
Java
Swift
curl --location -g --request GET 'https://rest.clicksend.com/v3/sms/history?date_from={date_from}&date_to={date_to}'
Response Response Example
{
"data": {
"current_page": 1,
"data": [
{
"_api_username": "johndoe",
"body": "Chocolate bar icing icing oat cake carrot cake jelly cotton 1iQByXxdLN.",
"carrier": "",
"contact_id": 0,
"country": "US",
"custom_string": "this is a test",
"date": "1436932432",
"direction": "out",
"error_code": null,
"error_text": null,
"first_name": "John",
"from": "sendlist",
"from_email": null,
"last_name": "Doe",
"list_id": null,
"message_id": "4E90F4C3-43A3-489D-9AB8-DA1F4332A0C3",
"message_parts": "1.00",
"message_price": "0.070000",
"schedule": "1436879372",
"status": "Completed",
"status_code": null,
"status_text": null,
"subaccount_id": 1,
"to": "+16783270696",
"user_id": 1
},
{
"_api_username": "johndoe",
"body": "Chocolate bar icing icing oat cake carrot cake jelly cotton 1iQByXxdLN.",
"carrier": "",
"contact_id": 0,
"country": "US",
"custom_string": "this is a test",
"date": "1436932432",
"direction": "out",
"error_code": null,
"error_text": null,
"first_name": "John",
"from": "sendlist",
"from_email": null,
"last_name": "Doe",
"list_id": null,
"message_id": "7DA5EB64-29FF-4E8A-AB6B-FE945EC9B45E",
"message_parts": "1.00",
"message_price": "0.070000",
"schedule": "1436879372",
"status": "Completed",
"status_code": null,
"status_text": null,
"subaccount_id": 1,
"to": "+16783275492",
"user_id": 1
},
{
"_api_username": "johndoe",
"body": "Jelly liquorice marshmallow candy carrot cake fgzOlMXuOI.",
"carrier": "Telstra",
"contact_id": 0,
"country": "AU",
"custom_string": "this is a test",
"date": "1436932503",
"direction": "out",
"error_code": null,
"error_text": null,
"from": "sendmobile",
"from_email": null,
"list_id": null,
"message_id": "064AF521-2A27-4B2A-9AB5-C45F555024EA",
"message_parts": "1.00",
"message_price": "0.070000",
"schedule": "1436871976",
"status": "Completed",
"status_code": null,
"status_text": null,
"subaccount_id": 1,
"to": "+61411111111",
"user_id": 1
},
{
"_api_username": "johndoe",
"body": "Chocolate bar icing icing oat cake carrot cake jelly cotton 1iQByXxdLN.",
"carrier": "Telstra",
"contact_id": 0,
"country": "AU",
"custom_string": "this is a test",
"date": "1436932503",
"direction": "out",
"error_code": null,
"error_text": null,
"from": "sendlist",
"from_email": null,
"list_id": null,
"message_id": "25DD465D-2286-45AF-AE25-D7AB36587B57",
"message_parts": "1.00",
"message_price": "0.070000",
"schedule": "1436879372",
"status": "Completed",
"status_code": null,
"status_text": null,
"subaccount_id": 1,
"to": "+61411111111",
"user_id": 1
},
{
"_api_username": "johndoe",
"body": "Chocolate bar icing icing oat cake carrot cake jelly cotton 1iQByXxdLN.",
"carrier": "",
"contact_id": 0,
"country": "US",
"custom_string": "this is a test",
"date": "1436932503",
"direction": "out",
"error_code": null,
"error_text": null,
"first_name": "John",
"from": "sendlist",
"from_email": null,
"last_name": "Doe",
"list_id": null,
"message_id": "CBC8FCF2-78B2-4C7B-ABFB-76B7AC5CB558",
"message_parts": "1.00",
"message_price": "0.070000",
"schedule": "1436879372",
"status": "Completed",
"status_code": null,
"status_text": null,
"subaccount_id": 1,
"to": "+16783270696",
"user_id": 1
},
{
"_api_username": "johndoe",
"body": "Chocolate bar icing icing oat cake carrot cake jelly cotton 1iQByXxdLN.",
"carrier": "",
"contact_id": 0,
"country": "US",
"custom_string": "this is a test",
"date": "1436932503",
"direction": "out",
"error_code": null,
"error_text": null,
"first_name": "John",
"from": "sendlist",
"from_email": null,
"last_name": "Doe",
"list_id": null,
"message_id": "39266530-5430-44AA-B620-FDFC7D4A9184",
"message_parts": "1.00",
"message_price": "0.070000",
"schedule": "1436879372",
"status": "Completed",
"status_code": null,
"status_text": null,
"subaccount_id": 1,
"to": "+16783275492",
"user_id": 1
}
],
"from": 1,
"last_page": 1,
"next_page_url": null,
"per_page": 15,
"prev_page_url": null,
"to": 6,
"total": 6
},
"http_code": 200,
"response_code": "SUCCESS",
"response_msg": "Here are your data."
}
Request
Path Params
date_from
stringÂ
required
Example:
1449459940
date_to
stringÂ
required
Example:
1449659940
Query Params
date_from
stringÂ
required
Example:
{date_from}
date_to
stringÂ
required
Example:
{date_to}