Class: Twilio::REST::Preview::Studio::FlowContext::EngagementContext::StepContext
- Inherits:
-
InstanceContext
- Object
- InstanceContext
- Twilio::REST::Preview::Studio::FlowContext::EngagementContext::StepContext
- Defined in:
- lib/twilio-ruby/rest/preview/studio/flow/engagement/step.rb
Overview
PLEASE NOTE that this class contains preview products that are subject to change. Use them with caution. If you currently do not have developer preview access, please contact [email protected].
Instance Method Summary collapse
-
#fetch ⇒ StepInstance
Fetch a StepInstance.
-
#initialize(version, flow_sid, engagement_sid, sid) ⇒ StepContext
constructor
Initialize the StepContext.
-
#to_s ⇒ Object
Provide a user friendly representation.
Constructor Details
#initialize(version, flow_sid, engagement_sid, sid) ⇒ StepContext
Initialize the StepContext
165 166 167 168 169 170 171 |
# File 'lib/twilio-ruby/rest/preview/studio/flow/engagement/step.rb', line 165 def initialize(version, flow_sid, engagement_sid, sid) super(version) # Path Solution @solution = {flow_sid: flow_sid, engagement_sid: engagement_sid, sid: sid, } @uri = "/Flows/#{@solution[:flow_sid]}/Engagements/#{@solution[:engagement_sid]}/Steps/#{@solution[:sid]}" end |
Instance Method Details
#fetch ⇒ StepInstance
Fetch a StepInstance
176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 |
# File 'lib/twilio-ruby/rest/preview/studio/flow/engagement/step.rb', line 176 def fetch params = Twilio::Values.of({}) payload = @version.fetch( 'GET', @uri, params, ) StepInstance.new( @version, payload, flow_sid: @solution[:flow_sid], engagement_sid: @solution[:engagement_sid], sid: @solution[:sid], ) end |
#to_s ⇒ Object
Provide a user friendly representation
196 197 198 199 |
# File 'lib/twilio-ruby/rest/preview/studio/flow/engagement/step.rb', line 196 def to_s context = @solution.map {|k, v| "#{k}: #{v}"}.join(',') "#<Twilio.Preview.Studio.StepContext #{context}>" end |