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 - A unique identifier for this service instance.
    • Method Detail

      • setWebhookUrl

        public ServiceUpdater setWebhookUrl​(URI webhookUrl)
        A URL that will receive event updates when objects are manipulated..
        Parameters:
        webhookUrl - A URL that will receive event updates when objects are manipulated.
        Returns:
        this
      • setWebhookUrl

        public ServiceUpdater setWebhookUrl​(String webhookUrl)
        A URL that will receive event updates when objects are manipulated..
        Parameters:
        webhookUrl - A URL that will receive event updates when objects are manipulated.
        Returns:
        this
      • setFriendlyName

        public ServiceUpdater setFriendlyName​(String friendlyName)
        Human-readable name for this service instance.
        Parameters:
        friendlyName - Human-readable name for this service instance
        Returns:
        this
      • setReachabilityWebhooksEnabled

        public ServiceUpdater setReachabilityWebhooksEnabled​(Boolean reachabilityWebhooksEnabled)
        True or false - controls whether this instance fires webhooks when client endpoints connect to Sync Defaults to false..
        Parameters:
        reachabilityWebhooksEnabled - True or false - controls whether this instance fires webhooks when client endpoints connect to Sync
        Returns:
        this
      • setAclEnabled

        public ServiceUpdater setAclEnabled​(Boolean aclEnabled)
        `true` or `false` - determines whether token identities must be granted access to Sync objects via the [Permissions API](https://www.twilio.com/docs/api/sync/rest/sync-rest-api-permissions) in this Service..
        Parameters:
        aclEnabled - true or false - determines whether token identities must be granted access to Sync objects via the Permissions API in this Service.
        Returns:
        this
      • setReachabilityDebouncingEnabled

        public ServiceUpdater setReachabilityDebouncingEnabled​(Boolean reachabilityDebouncingEnabled)
        `true` or `false` - If false, every endpoint disconnection immediately yields a reachability webhook (if enabled). If true, then 'disconnection' webhook events will only be fired after a configurable delay. Intervening reconnections would effectively cancel that webhook. Defaults to false..
        Parameters:
        reachabilityDebouncingEnabled - true or false - Determines whether transient disconnections (i.e. an immediate reconnect succeeds) cause reachability webhooks.
        Returns:
        this
      • setReachabilityDebouncingWindow

        public ServiceUpdater setReachabilityDebouncingWindow​(Integer reachabilityDebouncingWindow)
        Reachability webhook delay period in milliseconds. Determines the delay after which a Sync identity is declared actually offline, measured from the moment the last running client disconnects. If all endpoints remain offline throughout this delay, then reachability webhooks will be fired (if enabled). A reconnection by any endpoint during this window — from the same identity — means no reachability webhook would be fired. Must be between 1000 and 30000. Defaults to 5000..
        Parameters:
        reachabilityDebouncingWindow - Determines how long an identity must be offline before reachability webhooks fire.
        Returns:
        this
      • setWebhooksFromRestEnabled

        public ServiceUpdater setWebhooksFromRestEnabled​(Boolean webhooksFromRestEnabled)
        `true` or `false` - controls whether this instance fires webhooks when Sync objects are updated through REST. Defaults to false..
        Parameters:
        webhooksFromRestEnabled - true or false - controls whether this instance fires webhooks when Sync objects are updated through REST
        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