Class ChannelCreator

    • Constructor Detail

      • ChannelCreator

        public ChannelCreator​(String pathServiceSid)
        Construct a new ChannelCreator.
        Parameters:
        pathServiceSid - The SID of the Service to create the resource under
    • Method Detail

      • setFriendlyName

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

        public ChannelCreator setUniqueName​(String uniqueName)
        An application-defined string that uniquely identifies the resource. It can be used to address the resource in place of the resource's `sid` in the URL. This value must be 64 characters or less in length and be unique within the Service..
        Parameters:
        uniqueName - An application-defined string that uniquely identifies the resource
        Returns:
        this
      • setAttributes

        public ChannelCreator setAttributes​(String attributes)
        A valid JSON string that contains application-specific data..
        Parameters:
        attributes - A valid JSON string that contains application-specific data
        Returns:
        this
      • setType

        public ChannelCreator setType​(Channel.ChannelType type)
        The visibility of the channel. Can be: `public` or `private` and defaults to `public`..
        Parameters:
        type - The visibility of the channel
        Returns:
        this
      • create

        public Channel create​(TwilioRestClient client)
        Make the request to the Twilio API to perform the create.
        Specified by:
        create in class Creator<Channel>
        Parameters:
        client - TwilioRestClient with which to make the request
        Returns:
        Created Channel