Send-SMS API
Call the Send-SMS API to send a text message to a maximum of 200 phone numbers at one time.
Request
HTTP Method
Post
URL
http(s)://comm.botion.com/sendsms
Content-Type
application/json
Header parameters
Parameter | Value | Required | Description |
---|---|---|---|
Authorization | account_id=xp9mzzxttrrjheg8jtojwskqzz64zq3j,nonce=ui8ghc9nhz4rosqnp8f2ey2fbeb1smog,signature=8b753bc5b5cd1bc58b4bbee2f1f88f6cbfbe66839eb9c57a4b6b9056cc439902,timestamp=1664161826 | Yes | See Authorization Header |
Request body parameters
Parameter | Required | Type | Value Sample | Description |
---|---|---|---|---|
account | Yes | string | xp9mzzxttrrjheg8jtojwskqzz64zq3j | Your account_id |
template_id | Yes | string | T_0000000162 | Text message template ID |
template_param | Yes | object | { "code": "123456"} | Values of placeholders in text message template |
phone_numbers | Yes | string | +85212345678,+63123456789 | Recipient's mobile number. Up to 200 phone numbers. Separate them by commas.Every phone_number must follow the E164 standard |
from | No | string | Botion | Sender ID |
Example of request payload:
{
"account": "xp9mzzxttrrjheg8jtojwskqzz64zq3j",
"template_id": "T_0000000162",
"template_param": {"code": "123456"},
"from": "Botion",
"phone_numbers": "+85212345678",
}
Response
Example of response body:
// Success
{
"data":
{
"message_status": true
},
"status": 200,
"trade_id":"k51m6b51ja0agmivk8nackvq9gieto0n"
}
// Failed
{
"data": "",
"status": 1101,
"trade_id": "573b01fc8f3fb9b17bfac3aa30090cbb",
"error_msg": "illegal timestamp"
}