class Twilio::REST::Messaging::V1::ServiceContext::AlphaSenderContext

PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.

Public Class Methods

new(version, service_sid, sid) click to toggle source

Initialize the AlphaSenderContext @param [Version] version Version that contains the resource @param [String] service_sid The SID of the

{Service}[https://www.twilio.com/docs/chat/rest/service-resource] to fetch the
resource from.

@param [String] sid The SID of the AlphaSender resource to fetch. @return [AlphaSenderContext] AlphaSenderContext

Calls superclass method Twilio::REST::InstanceContext::new
    # File lib/twilio-ruby/rest/messaging/v1/service/alpha_sender.rb
175 def initialize(version, service_sid, sid)
176   super(version)
177 
178   # Path Solution
179   @solution = {service_sid: service_sid, sid: sid, }
180   @uri = "/Services/#{@solution[:service_sid]}/AlphaSenders/#{@solution[:sid]}"
181 end

Public Instance Methods

delete() click to toggle source

Delete the AlphaSenderInstance @return [Boolean] true if delete succeeds, false otherwise

    # File lib/twilio-ruby/rest/messaging/v1/service/alpha_sender.rb
200 def delete
201    @version.delete('DELETE', @uri)
202 end
fetch() click to toggle source

Fetch the AlphaSenderInstance @return [AlphaSenderInstance] Fetched AlphaSenderInstance

    # File lib/twilio-ruby/rest/messaging/v1/service/alpha_sender.rb
186 def fetch
187   payload = @version.fetch('GET', @uri)
188 
189   AlphaSenderInstance.new(
190       @version,
191       payload,
192       service_sid: @solution[:service_sid],
193       sid: @solution[:sid],
194   )
195 end
inspect() click to toggle source

Provide a detailed, user friendly representation

    # File lib/twilio-ruby/rest/messaging/v1/service/alpha_sender.rb
213 def inspect
214   context = @solution.map {|k, v| "#{k}: #{v}"}.join(',')
215   "#<Twilio.Messaging.V1.AlphaSenderContext #{context}>"
216 end
to_s() click to toggle source

Provide a user friendly representation

    # File lib/twilio-ruby/rest/messaging/v1/service/alpha_sender.rb
206 def to_s
207   context = @solution.map {|k, v| "#{k}: #{v}"}.join(',')
208   "#<Twilio.Messaging.V1.AlphaSenderContext #{context}>"
209 end