post
https://message-dev.aylanetworks.com/messageservice/v1/destinations.json
Recent Requests
Log in to see full request history
| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||
Loading…
{
"destination": {
"type": "email",
"body": "Your downstairs leak detector at 1234 Ayla Avenue has a low battery",
"message_template_id": "TestTemplateId",
"deliver_to": nulla,
"contact_id" : 123,
"title": "Hello Ayla User",
"provider": "smtp",
"user_message": "Hello Ayla User",
"user_name": "Methew Hedan",
"repeat_freq": 30
}
}{
"destination": {
"type": "sms",
"body": "Leak detector battery is low.",
"country_code": "+91",
"deliver_to": "9100008888",
"provider": "twilio",
"repeat_freq": 30
}
}{
"destination": {
"app_id": "app_XXXXXX_0-sA-id",
"body": "Your downstairs leak detector at 1234 Ayla Avenue has a low battery",
"deliver_to": "18610E3F420EXXXXXXXXXXXXXXXXXXBAC80FC9A529FF48C2ADE28EC892",
"meta_data": "{\"metadata\":\"push metadata\",\"attributes.fcm\":{\"priority\":\"normal\",\"ttl\":20}}",
"provider": "fcm",
"sound": "chime",
"title": "Auro-App Notification",
"type": "push"
}
}{
"destination": {
"type": "push",
"app_id": "app_XXXXX_01-sA-id",
"body": "Your downstairs leak detector at 1234 Ayla Avenue has a low battery",
"deliver_to": "18610E3F42XXXXXXXXXXXXXXXXXXXXXXXXXC80FC9A529FF48C2ADE28EC892",
"meta_data": "{\"metadata\":\"push metadata\",\"attributes.apns\":{\"priority\":10,\"ttl\":501}}",
"provider": "apns",
"repeat_freq": 30,
"sound": "chime",
"title": "Auro-App Notification"
}
}The following table describes the parameters related to the email destination type:
| Parameter name | Mandatory/optional | Description |
|---|---|---|
| type | Mandatory | Type of the destination you want to create. |
| body | Optional if messge_template_id is passed, otherwise mandatory. | The content of the email message. |
| message_template_id | Optional if body is passed, otherwise mandatory. | Unique identifier of the template to be used. The specified template will be used to show the email message to the endusers. |
| deliver_to | Optional if contact_id is passed, otherwise mandatory. | Email address of the user. |
| contact_id | Optional if deliver_to is passed, otherwise mandatory. | Contact ID of the user. |
| title | Optional | Subject of email. |
| provider | Optional | Indicates the networking standard used to send the email. Possible value: smtp |
| user_message | Optional | |
| user_name | Optional | user name. |
| repeat_freq | Optional | Repeat frequency for destinations in seconds. |
400Bad Request
401Unauthorized
403Forbidden
404Not Found
422Unprocessable Entity
