SMS

Sends an SMS

Sends SMS to a single recipient number. The sender and the template must be pre-configured for the sending agent.

The base message template is a pre-approved SMS template of the sender, addressed by template_key or template_alias. The merge_info is used to resolve the final content by merging the template with values. Params left unresolved are sent literally. sender_key identifies the sender of the SMS. ‘to’ is exactly a single recipient, whose mobile_no must include the country code.

post/sms

Request

  • Base URL
    https://cpaas.zoho.com/v1.1
  • Auth
    API key in header Authorization

Request body

sender_keystring required

Key of the SMS sender the message goes out as. The sender must be configured for the sending agent.

template_keystring uuid

Key of a pre-approved SMS template of the sender. Provide this or template_alias.

template_aliasstring

Alias of a pre-approved SMS template. Provide this or template_key.

merge_infoSmsMergeInfo

Key-value map that resolves the template's {{merge_tags}}. Tags left unresolved are sent literally in the message text.

client_referencestring

Client-supplied reference identifier, echoed in the SMS logs.

Example request

{
  "sender_key": "2d6f4a1b9c35",
  "to": [
    {
      "mobile_no": "+919876543210"
    }
  ],
  "template_key": "6200ca60-921a-11f1-92c4-2a30dd3b833c",
  "merge_info": {
    "otp": "482913"
  },
  "client_reference": "otp-482913"
}

Response

SMS queued for delivery.

statusstring

Example response

{
  "data": {
    "code": "MSG_101",
    "message_id": "7fff7400-b676-11f1-b0ad-b6d94062a427",
    "message": "Message queued",
    "request_id": "2d6f.14350939.i1.7fff7400-b676-11f1-b0ad-b6d94062a427.1a0c8d13740"
  },
  "status": "success"
}

Changes

No recorded changes to this operation across all 1 revision of this API.