05 April 2019

One API: Send plain text message

05 April 2019
clock
3 minutes

This command allows you to send one or more messages. Since the channel parameter is optional, the system will use the SMS channel by default if this parameter is not specified. The server will respond with a unique identifier for each message. The Clickatell platform then asynchronously targets the callback URL with status updates.

SMS text message limitations

  • The maximum number of messages in a single batch call is 200
  • The maximum length of a single text message depends on whether your message is sent using the standard GSM character set, or using Unicode. for special characters.

WhatsApp text message limitations

  • The maximum number of messages in a single batch call is 200
  • The maximum length of a single text message is 4096 characters

The base URL for all API call strings is: https://platform.clickatell.com/v1/message

One-way messaging: Request headers


POST /v1/message
Content-Type: application/json Authorization: MC2 integration API KEY

JSON Request


{
   "messages": [
     {
    "to": "27999000001",   
    "content": "Example message using default channel"
     },
     {
       "channel": "whatsapp",
       "to": "27999000002",
       "content": "Example message specifying channel"
     }
   ]
 }

Response


HTTP 202
{
   "messages": [
     {
       "apiMessageId": "fd496adebb6e422587368077937cfb5d",
       "accepted": true,
       "to": "2799900001",
       "error": null
     },
     {
       "apiMessageId": "0a2cbd52d9fd4c3f96e426e8583670a4",
       "accepted": true,
       "to": "2799900002",
       "error": null
     }
   ],
   "error": null 
} 

Two-way messaging: Request headers


POST /v1/message
Content-Type: application/json
Authorization: MC2 integration API KEY

JSON Request


{
   "messages": [
     {       "content": "Example two-way message on SMS Channel",
       "to": "27999000001",
       "channel": "sms",
       "from": "12027530410"
     }
   ]
 } 

Response


HTTP 202
{
   "messages": [
     {
       "apiMessageId": "77fb29998253415fa5d66971d519d362",
       "accepted": true,
       "to": "2799900001",
       "error": null
     }
   ],
   "error": null
 } 

Featured Insight Circle post

Reclaiming Billions in the Digital Economy: James Ronca

Related blogs posts

Reclaiming Billions in the Digital Economy: James Ronca
The 2020s: Decade of Dynamic Payments
Life will never be the same

About Clickatell

Todays’ consumers spend more time on chat like text, Instagram, Facebook Messenger, and WhatsApp than apps, and they expect a high degree of convenience in the way brands serve them. Clickatell makes it possible for brands and consumers to engage and transact via mobile chat and digital channels with industry-leading communications commerce platforms and solutions. With offices in San Francisco, Toronto, Cape Town, and Lagos, Clickatell serves more than 15,000 global brands, ranging from Fortune 500 organizations to well-known consumer brands and small businesses in over 220 countries worldwide.

Read more about Clickatell

Related blogs posts

Reclaiming Billions in the Digital Economy: James Ronca
The 2020s: Decade of Dynamic Payments
Life will never be the same

This website uses cookies to allow us to see how the site is used. The cookies cannot identify you. If you continue to use this site we will assume that you are happy with this. If you want to use the site without cookies or would like to know more, you can do that here.