send sms or mms message

API Docs by APIMATIC

Send SMS or MMS Message

Use this method to send SMS or MMS message. An SMS message can be sent with a numeric or alphanumeric Sender ID registered on the Wavix platform, while MMS can be only sent to the U.S. and Canadian phone numbers only using 10-digit numeric or short code as Sender ID. If the callback_url parameter is specified in the request, the platform automatically forwards a DLR report to it once the message is received by the destination phone number.

You can send up to 20 SMS/MMS messages to a single destination phone number per 24 hours.

This endpoint requires authentication.

POST /messages
  • EXPLORER
  • PARAMETERS
Endpoint Arguments*
Parameters*
body (SendMessageRequestbody)*

Sender ID registered on your account. Can be numeric or alphanumeric.

Destination phone number.

message_body (MessageBody)*

Message text.

media

An array of URLs to a media attachments. If the parameters contains any value other that `null`, the message is considered to be an MMS, SMS otherwise.

Callback URL for delivery reports.

Validity period of the message, in seconds. The platform stops sending the message after the validity period expires.

An optional field normally used to identify a group of SMS, e.g. messages associated with a certain campaign.

Server

Messaging

Response Type

Errors

HTTP Status CodeError DescriptionException Class
403
Request failed. Outbound SMS messaging service is disabled.
422
Request failed. The response indicates the reason of failure.
429
Request failed. The message cannot be sent because the per second rate limit has been reached
Default
Request failed. Outbound SMS messaging service is disabled.
curl -X POST \
  --url 'https://api.wavix.com/v2/messages?appid=appid' \
  -H 'Accept: application/json'\
  -H 'Content-Type: application/json' \
  --data-raw '{
  "from": "Wavix",
  "to": "447712345661",
  "message_body": {
    "text": "SMS message"
  }
}'