class Twilio::REST::Proxy::V1::ServiceContext::SessionContext::ParticipantContext::MessageInteractionContext
PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.
Public Class Methods
new(version, service_sid, session_sid, participant_sid, sid)
click to toggle source
Initialize the MessageInteractionContext
@param [Version] version Version
that contains the resource @param [String] service_sid The SID of the parent
{Service}[https://www.twilio.com/docs/proxy/api/service] of the resource to fetch.
@param [String] session_sid The SID of the parent
{Session}[https://www.twilio.com/docs/proxy/api/session] of the resource to fetch.
@param [String] participant_sid The SID of the
{Participant}[https://www.twilio.com/docs/proxy/api/participant] resource.
@param [String] sid The Twilio-provided string that uniquely identifies the
MessageInteraction resource to fetch.
@return [MessageInteractionContext] MessageInteractionContext
Calls superclass method
Twilio::REST::InstanceContext::new
# File lib/twilio-ruby/rest/proxy/v1/service/session/participant/message_interaction.rb 197 def initialize(version, service_sid, session_sid, participant_sid, sid) 198 super(version) 199 200 # Path Solution 201 @solution = { 202 service_sid: service_sid, 203 session_sid: session_sid, 204 participant_sid: participant_sid, 205 sid: sid, 206 } 207 @uri = "/Services/#{@solution[:service_sid]}/Sessions/#{@solution[:session_sid]}/Participants/#{@solution[:participant_sid]}/MessageInteractions/#{@solution[:sid]}" 208 end
Public Instance Methods
fetch()
click to toggle source
Fetch the MessageInteractionInstance
@return [MessageInteractionInstance] Fetched MessageInteractionInstance
# File lib/twilio-ruby/rest/proxy/v1/service/session/participant/message_interaction.rb 213 def fetch 214 payload = @version.fetch('GET', @uri) 215 216 MessageInteractionInstance.new( 217 @version, 218 payload, 219 service_sid: @solution[:service_sid], 220 session_sid: @solution[:session_sid], 221 participant_sid: @solution[:participant_sid], 222 sid: @solution[:sid], 223 ) 224 end
inspect()
click to toggle source
Provide a detailed, user friendly representation
# File lib/twilio-ruby/rest/proxy/v1/service/session/participant/message_interaction.rb 235 def inspect 236 context = @solution.map {|k, v| "#{k}: #{v}"}.join(',') 237 "#<Twilio.Proxy.V1.MessageInteractionContext #{context}>" 238 end
to_s()
click to toggle source
Provide a user friendly representation
# File lib/twilio-ruby/rest/proxy/v1/service/session/participant/message_interaction.rb 228 def to_s 229 context = @solution.map {|k, v| "#{k}: #{v}"}.join(',') 230 "#<Twilio.Proxy.V1.MessageInteractionContext #{context}>" 231 end