Create destinations in bulk

This API creates new destinations in bulk. The destination types supported are:
email, SMS, and PUSH.

Parameters for email type:

  • type: Type of destination. (Mandatory)
  • body: Email body. (Optional if messge_template_id is passed, otherwise mandatory )
  • message_template_id: Unique ID of the template using which email will be shown to end-user. (Optional if body is passed, otherwise Mandatory )
  • deliver_to: Email address of target user. (Mandatory)
  • title: Subject of email.
  • provider: Service provider (smtp).
  • user_message: Message that will be tied to email.
  • user_name: Name of the user.

Parameters for SMS type: (all the parameters are mandatory)

  • type: Type of destination.
  • body: SMS body.
  • country_code: Country specific code. Example:- +91
  • deliver_to: Phone number of target user.
  • title: Subject of email.
  • provider: Service provider (twilio, yunpian).

Parameters for PUSH type:

  • type: Type of destination. (Mandatory)
  • app_id: app_id of the app on which notification will be send. (Mandatory)
  • body: Body will be tied to notification. (Mandatory)
  • deliver_to: Device token on which notification will be send. (Mandatory)
  • meta_data: Additional information about notification.
  • provider: Service provider (fcm, apns).
  • sound: Sound which will be played along with notification on the device.
  • title: Heading that will be shown with notification.
{
"destination": [
{
"type": "email",
"body": "Your downstairs leak detector at 1234 Ayla Avenue has a low battery",
"message_template_id": "TestTemplateId",
"deliver_to": "[email protected]",
"title": "Hello Ayla User 1",
"provider": "smtp",
"repeat_freq": 30,
"user_message": "Hello Ayla User",
"user_name": "Methew Hedan"
},
{
"type": "email",
"body": "Your downstairs leak detector at 1234 Ayla Avenue has a low battery",
"message_template_id": "TestTemplateId",
"deliver_to": "[email protected]",
"title": "Hello Ayla User 2",
"provider": "smtp",
"repeat_freq": 30,
"user_message": "Hello Ayla User",
"user_name": "Methew Hedan"
},
{
"type": "email",
"body": "Your downstairs leak detector at 1234 Ayla Avenue has a low battery",
"message_template_id": "TestTemplateId",
"deliver_to": "[email protected]",
"title": "Hello Ayla User",
"provider": "smtp",
"repeat_freq": 30,
"user_message": "Hello Ayla User 3",
"user_name": "Methew Hedan"
}
]
}
Language
Authorization
Header
Click Try It! to start a request and see the response here!