v1

latestOpenAPI 3.1.02026-07-2414238909.1 KB

Send an SMS

Sending a single SMS is one of the most common tasks performed on the Routee Platform.

post/sms

Headers

Content-Typestring required

application/json

Authorizationstring required

Bearer {access_token}

Request body

fromstring required

The sender of the message. This can be a telephone number (numeric string with maximum length 16 characters) or an alphanumeric string (maximum length of 11 characters). When you want to use a number, you have to enter it without the '+' before the country code (eg 447123123456).

bodystring required

The message you want to send. Use "\n" to create a new line in your message.

tostring required

The destination phone number. Format with a '+' and country code e.g., +3069485xxxxx (E.164 format).

flashboolean

Indicates if the SMS is a flash SMS. A flash SMS is a type of SMS that appears directly on the main screen without user interaction and is not automatically stored in the inbox. It can be useful in emergencies, such as a fire alarm or cases of confidentiality, as in delivering one-time passwords. Default value false.

labelstring

A generic label which can be used for tagging the SMS. The maximum length is 350 characters.

ttlinteger

The duration in minutes the delivery of an SMS will be attempted. Must be between 1-4320. By default Routee will attempt delivery for 72 hours. If the SMS is not delivered within the validity period, then the SMS status will be "Undelivered", with "detailedStatus": "Expired".

transcodeboolean

If “transcode” is set to true/false, then the message body will be/not be transcoded. If the “transcode” parameter is not set, then the application level setting will be used. In case the message can be sent as UTF in one part, it will not be transcoded.

Response

200

trackingIdstring
statusstring
createdAtstring
fromstring
tostring
bodystring
flashboolean

Example response

{
  "trackingId": "7f09f8cc-725a-4519-a1be-d867502bb732",
  "status": "Queued",
  "createdAt": "2017-02-17T12:23:50.403Z",
  "from": "amdTelecom",
  "to": "+306912345678",
  "body": "A new game has been posted to the MindPuzzle. Check it out",
  "bodyAnalysis": {
    "parts": 1,
    "characters": 58
  }
}