class Twilio::REST::Studio::V2::FlowContext::ExecutionContext::ExecutionStepInstance

Public Class Methods

new(version, payload, flow_sid: nil, execution_sid: nil, sid: nil) click to toggle source

Initialize the ExecutionStepInstance @param [Version] version Version that contains the resource @param [Hash] payload payload that contains response from Twilio @param [String] flow_sid The SID of the Flow. @param [String] execution_sid The SID of the Step's Execution resource. @param [String] sid The SID of the ExecutionStep resource to fetch. @return [ExecutionStepInstance] ExecutionStepInstance

Calls superclass method Twilio::REST::InstanceResource::new
    # File lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb
223 def initialize(version, payload, flow_sid: nil, execution_sid: nil, sid: nil)
224   super(version)
225 
226   # Marshaled Properties
227   @properties = {
228       'sid' => payload['sid'],
229       'account_sid' => payload['account_sid'],
230       'flow_sid' => payload['flow_sid'],
231       'execution_sid' => payload['execution_sid'],
232       'name' => payload['name'],
233       'context' => payload['context'],
234       'transitioned_from' => payload['transitioned_from'],
235       'transitioned_to' => payload['transitioned_to'],
236       'date_created' => Twilio.deserialize_iso8601_datetime(payload['date_created']),
237       'date_updated' => Twilio.deserialize_iso8601_datetime(payload['date_updated']),
238       'url' => payload['url'],
239       'links' => payload['links'],
240   }
241 
242   # Context
243   @instance_context = nil
244   @params = {
245       'flow_sid' => flow_sid,
246       'execution_sid' => execution_sid,
247       'sid' => sid || @properties['sid'],
248   }
249 end

Public Instance Methods

account_sid() click to toggle source

@return [String] The SID of the Account that created the resource

    # File lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb
275 def account_sid
276   @properties['account_sid']
277 end
context() click to toggle source

Generate an instance context for the instance, the context is capable of performing various actions. All instance actions are proxied to the context @return [ExecutionStepContext] ExecutionStepContext for this ExecutionStepInstance

    # File lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb
255 def context
256   unless @instance_context
257     @instance_context = ExecutionStepContext.new(
258         @version,
259         @params['flow_sid'],
260         @params['execution_sid'],
261         @params['sid'],
262     )
263   end
264   @instance_context
265 end
date_created() click to toggle source

@return [Time] The ISO 8601 date and time in GMT when the resource was created

    # File lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb
317 def date_created
318   @properties['date_created']
319 end
date_updated() click to toggle source

@return [Time] The ISO 8601 date and time in GMT when the resource was last updated

    # File lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb
323 def date_updated
324   @properties['date_updated']
325 end
execution_sid() click to toggle source

@return [String] The SID of the Execution

    # File lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb
287 def execution_sid
288   @properties['execution_sid']
289 end
fetch() click to toggle source

Fetch the ExecutionStepInstance @return [ExecutionStepInstance] Fetched ExecutionStepInstance

    # File lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb
342 def fetch
343   context.fetch
344 end
flow_sid() click to toggle source

@return [String] The SID of the Flow

    # File lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb
281 def flow_sid
282   @properties['flow_sid']
283 end
inspect() click to toggle source

Provide a detailed, user friendly representation

    # File lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb
362 def inspect
363   values = @properties.map{|k, v| "#{k}: #{v}"}.join(" ")
364   "<Twilio.Studio.V2.ExecutionStepInstance #{values}>"
365 end
name() click to toggle source

@return [String] The event that caused the Flow to transition to the Step

    # File lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb
293 def name
294   @properties['name']
295 end
sid() click to toggle source

@return [String] The unique string that identifies the resource

    # File lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb
269 def sid
270   @properties['sid']
271 end
step_context() click to toggle source

Access the step_context @return [step_context] step_context

    # File lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb
349 def step_context
350   context.step_context
351 end
to_s() click to toggle source

Provide a user friendly representation

    # File lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb
355 def to_s
356   values = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
357   "<Twilio.Studio.V2.ExecutionStepInstance #{values}>"
358 end
transitioned_from() click to toggle source

@return [String] The Widget that preceded the Widget for the Step

    # File lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb
305 def transitioned_from
306   @properties['transitioned_from']
307 end
transitioned_to() click to toggle source

@return [String] The Widget that will follow the Widget for the Step

    # File lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb
311 def transitioned_to
312   @properties['transitioned_to']
313 end
url() click to toggle source

@return [String] The absolute URL of the resource

    # File lib/twilio-ruby/rest/studio/v2/flow/execution/execution_step.rb
329 def url
330   @properties['url']
331 end