Skip to main content

Messaging Channels/Routes

ChannelDescription
genericThis channel is used to send promotional messages and messages to phone number not on dnd
dndOn this channel all your messages deliver whether there is dnd restriction or not on the phone number
dnd restrictionThis channel sends messages via WhatsApp

Send message

Endpoint: https://BASE_URL/api/sms/send Request Type: POST Body params:
OptionsRequiredDescription
api*keyyes_string*
Your API key (It can be found on your Termii dashboard).
toyesstring
Represents the destination phone number. Phone number must be in the international format (Example: 23490126727). You can also send to multiple numbers. To do so put numbers in an array (Example: ["23490555546", "23423490126999"]) Please note: the array takes only 100 phone numbers at a time
fromyesstring
Represents a sender ID for sms which can be Alphanumeric or Device name for Whatsapp. Alphanumeric sender ID length should be between 3 and 11 characters (Example:CompanyName)
smsyesstring
Text of a message that would be sent to the destination phone number
typeyesstring
The kind of message that is sent, which is a plain message.
channelyesstring
This is the route through which the message is sent. It is either dnd, whatsapp, or generic
medianoobject
This is a media object, it is only available for the High Volume WhatsApp. When using the media parameter, ensure you are not using the sms parameter
media urlnostring
The url to the file resource
media captionnostring
The caption that should be added to the image
Media Types
FileSupported Format
ImageJPG, JPEG, PNG
AudioMP3, OGG, AMR
DocumentsPDF
VideoMP4 (Note: WhatsApp currently does not support MP4 files without an audio)
Note: For customers sending messages to Nigeria, DND stands for Do-Not-Disturb and phone numbers with DND settings activated are blocked from receiving messages from the generic route by the Mobile Network Operators. To deliver messages to phone numbers on DND, the Termii DND route needs to be activated on your account. Kindly reach out to our support team. Note on special Characters: 1 page = 160 characters Special characters reduces your message count from 160 characters per message to 70 characters per message. Here are a few of them
; // ^ { }  \ [ ~ ] | € ' ”```
{
 "to": "2347880234567",
 "from": "talert",
 "sms": "Hi there, testing Termii",
 "type": "plain",
 "channel": "generic",
 "api_key": "Your API Key",
 "media": {
  "url": "https://media.example.com/file",
  "caption": "your media file"
  }    
}
Response
  {
      "message_id": "9122821270554876574",
      "message": "Successfully Sent",
      "balance": 9,
      "user": "Peter Mcleish"
   }

Send Bulk message

Endpoint: https://BASE_URL/api/sms/send/bulk Request Type: POST Body params
OptionsRequiredDescription
api_keyyesstring
Your API key (It can be found on your Termii dashboard).
toyesstring
Represents the array of phone numbers you are sending to (Example: ["23490555546", "23423490126999","23490555546"]). Phone numbers must be in international format (Example: 23490126727). Please note: the array can take up to 10,000 phone numbers
fromyesstring
Represents a sender ID for sms which can be Alphanumeric or Device name for Whatsapp. Alphanumeric sender ID length should be between 3 and 11 characters (Example: CompanyName)
smsyesstring
Text of a message that would be sent to the destination phone number
typeyesstring
The type of message that is sent, which is a plain message.
channelyesstring
This is the channel through which the message is sent. It is either dnd, whatsapp, or generic
{
 "to": ["23490555546", "23423490126999","23490555546"],
 "from": "talert",
 "sms": "Hi there, testing Termii",
 "type": "plain",
 "channel": "generic",
 "api_key": "Your API Key",
}
Response
  {
      "code": "ok",
      "message_id": "9122821270554876574",
      "message": "Successfully Sent",
      "balance": 9,
      "user": "Peter Mcleish"
   }