Send SMS

Sends an SMS message. This endpoint supports multiple different ways to send an SMS message with many fields that are mutually exclusive.

For the destination phone number either the to field or the contactId field must be provided. If a contactId is provided, the destination number will be looked up from their contact information.

For the source phone number either the from field or the numberSetId field must be provided. If the numberSetId field is used, a number will be chosen from the number set at random.

For the message body either the text field or the smsTemplateId field must be provided. If using a template, the extData field will be used for any template replacements. If a contact is specified, the provided extData will be used preferentially over the data in the contact when expanding the template.

If sending an MMS message, the mediaUrl property must be provided. In this case the body fields are optional.

Setting the deliveryStatusEnabled flag (default false) will result in a DLR callback.

Setting the messageStatusCallback will result in a POST of json data once the message is sent.

We recommend using number sets, contacts, and sms templates for API usage since these will result in fewer changes over time.

Language
URL
Click Try It! to start a request and see the response here!