Class: Twilio::REST::Studio::V1::FlowContext::EngagementContext::EngagementContextContext
- Inherits:
-
InstanceContext
- Object
- InstanceContext
- Twilio::REST::Studio::V1::FlowContext::EngagementContext::EngagementContextContext
- Defined in:
- lib/twilio-ruby/rest/studio/v1/flow/engagement/engagement_context.rb
Instance Method Summary collapse
-
#fetch ⇒ EngagementContextInstance
Fetch the EngagementContextInstance.
-
#initialize(version, flow_sid, engagement_sid) ⇒ EngagementContextContext
constructor
Initialize the EngagementContextContext.
-
#inspect ⇒ Object
Provide a detailed, user friendly representation.
-
#to_s ⇒ Object
Provide a user friendly representation.
Constructor Details
#initialize(version, flow_sid, engagement_sid) ⇒ EngagementContextContext
Initialize the EngagementContextContext
52 53 54 55 56 57 58 59 60 |
# File 'lib/twilio-ruby/rest/studio/v1/flow/engagement/engagement_context.rb', line 52 def initialize(version, flow_sid, engagement_sid) super(version) # Path Solution @solution = { flow_sid: flow_sid, engagement_sid: engagement_sid, } @uri = "/Flows/#{@solution[:flow_sid]}/Engagements/#{@solution[:engagement_sid]}/Context" end |
Instance Method Details
#fetch ⇒ EngagementContextInstance
Fetch the EngagementContextInstance
64 65 66 67 68 69 70 71 72 73 |
# File 'lib/twilio-ruby/rest/studio/v1/flow/engagement/engagement_context.rb', line 64 def fetch payload = @version.fetch('GET', @uri) EngagementContextInstance.new( @version, payload, flow_sid: @solution[:flow_sid], engagement_sid: @solution[:engagement_sid], ) end |
#inspect ⇒ Object
Provide a detailed, user friendly representation
85 86 87 88 |
# File 'lib/twilio-ruby/rest/studio/v1/flow/engagement/engagement_context.rb', line 85 def inspect context = @solution.map{|k, v| "#{k}: #{v}"}.join(',') "#<Twilio.Studio.V1.EngagementContextContext #{context}>" end |
#to_s ⇒ Object
Provide a user friendly representation
78 79 80 81 |
# File 'lib/twilio-ruby/rest/studio/v1/flow/engagement/engagement_context.rb', line 78 def to_s context = @solution.map{|k, v| "#{k}: #{v}"}.join(',') "#<Twilio.Studio.V1.EngagementContextContext #{context}>" end |