NotifyService

Create Service

POST
/v1/Services

Authorization

accountSid_authToken
AuthorizationBasic <token>

In: header

Request Body

application/x-www-form-urlencoded

FriendlyName?string

A descriptive string that you create to describe the resource. It can be up to 64 characters long.

ApnCredentialSid?string

The SID of the Credential to use for APN Bindings.

Match^CR[0-9a-fA-F]{32}$
Length34 <= length <= 34
GcmCredentialSid?string

The SID of the Credential to use for GCM Bindings.

Match^CR[0-9a-fA-F]{32}$
Length34 <= length <= 34
MessagingServiceSid?string

The SID of the Messaging Service to use for SMS Bindings. This parameter must be set in order to send SMS notifications.

Match^MG[0-9a-fA-F]{32}$
Length34 <= length <= 34
FacebookMessengerPageId?string

Deprecated.

DefaultApnNotificationProtocolVersion?string

The protocol version to use for sending APNS notifications. Can be overridden on a Binding by Binding basis when creating a Binding resource.

DefaultGcmNotificationProtocolVersion?string

The protocol version to use for sending GCM notifications. Can be overridden on a Binding by Binding basis when creating a Binding resource.

FcmCredentialSid?string

The SID of the Credential to use for FCM Bindings.

Match^CR[0-9a-fA-F]{32}$
Length34 <= length <= 34
DefaultFcmNotificationProtocolVersion?string

The protocol version to use for sending FCM notifications. Can be overridden on a Binding by Binding basis when creating a Binding resource.

LogEnabled?boolean

Whether to log notifications. Can be: true or false and the default is true.

AlexaSkillId?string

Deprecated.

DefaultAlexaNotificationProtocolVersion?string

Deprecated.

DeliveryCallbackUrl?string

URL to send delivery status callback.

DeliveryCallbackEnabled?boolean

Callback configuration that enables delivery callbacks, default false

Response Body

application/json

curl -X POST "https://example.com/v1/Services" \  -H "Content-Type: application/x-www-form-urlencoded" \  -d 'FriendlyName=friendly_name&ApnCredentialSid=CRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa&GcmCredentialSid=ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa&MessagingServiceSid=MGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa&FacebookMessengerPageId=4&DefaultApnNotificationProtocolVersion=3&DefaultGcmNotificationProtocolVersion=3&DefaultFcmNotificationProtocolVersion=3&LogEnabled=True&Type=S&DeliveryCallbackUrl=Hello&DeliveryCallbackEnabled=True'
{  "sid": "ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",  "friendly_name": "733c7f0f-6541-42ec-84ce-e2ae1cac588c",  "date_created": "2016-03-09T20:22:31Z",  "date_updated": "2016-03-09T20:22:31Z",  "apn_credential_sid": null,  "gcm_credential_sid": null,  "fcm_credential_sid": null,  "messaging_service_sid": "MGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",  "facebook_messenger_page_id": "4",  "alexa_skill_id": null,  "default_apn_notification_protocol_version": "3",  "default_gcm_notification_protocol_version": "3",  "default_fcm_notification_protocol_version": "3",  "default_alexa_notification_protocol_version": "3",  "log_enabled": true,  "delivery_callback_url": "Hello",  "delivery_callback_enabled": true,  "url": "https://notify.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",  "links": {    "bindings": "https://notify.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Bindings",    "notifications": "https://notify.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Notifications",    "segments": "https://notify.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Segments",    "users": "https://notify.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Users"  }}