Class ServiceUpdater


  • public class ServiceUpdater
    extends Updater<Service>
    PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
    • Constructor Detail

      • ServiceUpdater

        public ServiceUpdater​(String pathSid)
        Construct a new ServiceUpdater.
        Parameters:
        pathSid - The unique string that identifies the resource
    • Method Detail

      • setFriendlyName

        public ServiceUpdater setFriendlyName​(String friendlyName)
        A descriptive string that you create to describe the resource. It can be up to 64 characters long..
        Parameters:
        friendlyName - A string to describe the resource
        Returns:
        this
      • setApnCredentialSid

        public ServiceUpdater setApnCredentialSid​(String apnCredentialSid)
        The SID of the [Credential](https://www.twilio.com/docs/notify/api/credential-resource) to use for APN Bindings..
        Parameters:
        apnCredentialSid - The SID of the Credential to use for APN Bindings
        Returns:
        this
      • setGcmCredentialSid

        public ServiceUpdater setGcmCredentialSid​(String gcmCredentialSid)
        The SID of the [Credential](https://www.twilio.com/docs/notify/api/credential-resource) to use for GCM Bindings..
        Parameters:
        gcmCredentialSid - The SID of the Credential to use for GCM Bindings
        Returns:
        this
      • setMessagingServiceSid

        public ServiceUpdater setMessagingServiceSid​(String messagingServiceSid)
        The SID of the [Messaging Service](https://www.twilio.com/docs/sms/send-messages#messaging-services) to use for SMS Bindings. This parameter must be set in order to send SMS notifications..
        Parameters:
        messagingServiceSid - The SID of the Messaging Service to use for SMS Bindings
        Returns:
        this
      • setFacebookMessengerPageId

        public ServiceUpdater setFacebookMessengerPageId​(String facebookMessengerPageId)
        Deprecated..
        Parameters:
        facebookMessengerPageId - Deprecated
        Returns:
        this
      • setDefaultApnNotificationProtocolVersion

        public ServiceUpdater setDefaultApnNotificationProtocolVersion​(String defaultApnNotificationProtocolVersion)
        The protocol version to use for sending APNS notifications. Can be overridden on a Binding by Binding basis when creating a [Binding](https://www.twilio.com/docs/notify/api/binding-resource) resource..
        Parameters:
        defaultApnNotificationProtocolVersion - The protocol version to use for sending APNS notifications
        Returns:
        this
      • setDefaultGcmNotificationProtocolVersion

        public ServiceUpdater setDefaultGcmNotificationProtocolVersion​(String defaultGcmNotificationProtocolVersion)
        The protocol version to use for sending GCM notifications. Can be overridden on a Binding by Binding basis when creating a [Binding](https://www.twilio.com/docs/notify/api/binding-resource) resource..
        Parameters:
        defaultGcmNotificationProtocolVersion - The protocol version to use for sending GCM notifications
        Returns:
        this
      • setFcmCredentialSid

        public ServiceUpdater setFcmCredentialSid​(String fcmCredentialSid)
        The SID of the [Credential](https://www.twilio.com/docs/notify/api/credential-resource) to use for FCM Bindings..
        Parameters:
        fcmCredentialSid - The SID of the Credential to use for FCM Bindings
        Returns:
        this
      • setDefaultFcmNotificationProtocolVersion

        public ServiceUpdater setDefaultFcmNotificationProtocolVersion​(String defaultFcmNotificationProtocolVersion)
        The protocol version to use for sending FCM notifications. Can be overridden on a Binding by Binding basis when creating a [Binding](https://www.twilio.com/docs/notify/api/binding-resource) resource..
        Parameters:
        defaultFcmNotificationProtocolVersion - The protocol version to use for sending FCM notifications
        Returns:
        this
      • setLogEnabled

        public ServiceUpdater setLogEnabled​(Boolean logEnabled)
        Whether to log notifications. Can be: `true` or `false` and the default is `true`..
        Parameters:
        logEnabled - Whether to log notifications
        Returns:
        this
      • setAlexaSkillId

        public ServiceUpdater setAlexaSkillId​(String alexaSkillId)
        Deprecated..
        Parameters:
        alexaSkillId - Deprecated
        Returns:
        this
      • setDefaultAlexaNotificationProtocolVersion

        public ServiceUpdater setDefaultAlexaNotificationProtocolVersion​(String defaultAlexaNotificationProtocolVersion)
        Deprecated..
        Parameters:
        defaultAlexaNotificationProtocolVersion - Deprecated
        Returns:
        this
      • update

        public Service update​(TwilioRestClient client)
        Make the request to the Twilio API to perform the update.
        Specified by:
        update in class Updater<Service>
        Parameters:
        client - TwilioRestClient with which to make the request
        Returns:
        Updated Service