Class: Twilio::REST::Api::V2010::AccountContext::RecordingContext::AddOnResultContext::PayloadInstance
- Inherits:
-
InstanceResource
- Object
- InstanceResource
- Twilio::REST::Api::V2010::AccountContext::RecordingContext::AddOnResultContext::PayloadInstance
- Defined in:
- lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb
Instance Method Summary collapse
-
#account_sid ⇒ String
The SID of the [Account](www.twilio.com/docs/iam/api/account) that created the Recording AddOnResult Payload resource.
-
#add_on_configuration_sid ⇒ String
The SID of the Add-on configuration.
-
#add_on_result_sid ⇒ String
The SID of the AddOnResult to which the payload belongs.
-
#add_on_sid ⇒ String
The SID of the Add-on to which the result belongs.
-
#content_type ⇒ String
The MIME type of the payload.
-
#context ⇒ PayloadContext
Generate an instance context for the instance, the context is capable of performing various actions.
-
#data ⇒ data
Access the data.
-
#date_created ⇒ Time
The date and time in GMT that the resource was created specified in [RFC 2822](www.ietf.org/rfc/rfc2822.txt) format.
-
#date_updated ⇒ Time
The date and time in GMT that the resource was last updated specified in [RFC 2822](www.ietf.org/rfc/rfc2822.txt) format.
-
#delete ⇒ Boolean
Delete the PayloadInstance.
-
#fetch ⇒ PayloadInstance
Fetch the PayloadInstance.
-
#initialize(version, payload, account_sid: nil, reference_sid: nil, add_on_result_sid: nil, sid: nil) ⇒ PayloadInstance
constructor
Initialize the PayloadInstance.
-
#inspect ⇒ Object
Provide a detailed, user friendly representation.
-
#label ⇒ String
The string provided by the vendor that describes the payload.
-
#reference_sid ⇒ String
The SID of the recording to which the AddOnResult resource that contains the payload belongs.
-
#sid ⇒ String
The unique string that that we created to identify the Recording AddOnResult Payload resource.
-
#subresource_uris ⇒ Hash
A list of related resources identified by their relative URIs.
-
#to_s ⇒ Object
Provide a user friendly representation.
Constructor Details
#initialize(version, payload, account_sid: nil, reference_sid: nil, add_on_result_sid: nil, sid: nil) ⇒ PayloadInstance
Initialize the PayloadInstance
434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 434 def initialize(version, payload , account_sid: nil, reference_sid: nil, add_on_result_sid: nil, sid: nil) super(version) # Marshaled Properties @properties = { 'sid' => payload['sid'], 'add_on_result_sid' => payload['add_on_result_sid'], 'account_sid' => payload['account_sid'], 'label' => payload['label'], 'add_on_sid' => payload['add_on_sid'], 'add_on_configuration_sid' => payload['add_on_configuration_sid'], 'content_type' => payload['content_type'], 'date_created' => Twilio.deserialize_rfc2822(payload['date_created']), 'date_updated' => Twilio.deserialize_rfc2822(payload['date_updated']), 'reference_sid' => payload['reference_sid'], 'subresource_uris' => payload['subresource_uris'], } # Context @instance_context = nil @params = { 'account_sid' => account_sid ,'reference_sid' => reference_sid || @properties['reference_sid'] ,'add_on_result_sid' => add_on_result_sid || @properties['add_on_result_sid'] ,'sid' => sid || @properties['sid'] , } end |
Instance Method Details
#account_sid ⇒ String
Returns The SID of the [Account](www.twilio.com/docs/iam/api/account) that created the Recording AddOnResult Payload resource.
483 484 485 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 483 def account_sid @properties['account_sid'] end |
#add_on_configuration_sid ⇒ String
Returns The SID of the Add-on configuration.
501 502 503 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 501 def add_on_configuration_sid @properties['add_on_configuration_sid'] end |
#add_on_result_sid ⇒ String
Returns The SID of the AddOnResult to which the payload belongs.
477 478 479 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 477 def add_on_result_sid @properties['add_on_result_sid'] end |
#add_on_sid ⇒ String
Returns The SID of the Add-on to which the result belongs.
495 496 497 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 495 def add_on_sid @properties['add_on_sid'] end |
#content_type ⇒ String
Returns The MIME type of the payload.
507 508 509 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 507 def content_type @properties['content_type'] end |
#context ⇒ PayloadContext
Generate an instance context for the instance, the context is capable of performing various actions. All instance actions are proxied to the context
462 463 464 465 466 467 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 462 def context unless @instance_context @instance_context = PayloadContext.new(@version , @params['account_sid'], @params['reference_sid'], @params['add_on_result_sid'], @params['sid']) end @instance_context end |
#data ⇒ data
Access the data
554 555 556 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 554 def data context.data end |
#date_created ⇒ Time
Returns The date and time in GMT that the resource was created specified in [RFC 2822](www.ietf.org/rfc/rfc2822.txt) format.
513 514 515 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 513 def date_created @properties['date_created'] end |
#date_updated ⇒ Time
Returns The date and time in GMT that the resource was last updated specified in [RFC 2822](www.ietf.org/rfc/rfc2822.txt) format.
519 520 521 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 519 def date_updated @properties['date_updated'] end |
#delete ⇒ Boolean
Delete the PayloadInstance
538 539 540 541 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 538 def delete context.delete end |
#fetch ⇒ PayloadInstance
Fetch the PayloadInstance
546 547 548 549 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 546 def fetch context.fetch end |
#inspect ⇒ Object
Provide a detailed, user friendly representation
567 568 569 570 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 567 def inspect values = @properties.map{|k, v| "#{k}: #{v}"}.join(" ") "<Twilio.Api.V2010.PayloadInstance #{values}>" end |
#label ⇒ String
Returns The string provided by the vendor that describes the payload.
489 490 491 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 489 def label @properties['label'] end |
#reference_sid ⇒ String
Returns The SID of the recording to which the AddOnResult resource that contains the payload belongs.
525 526 527 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 525 def reference_sid @properties['reference_sid'] end |
#sid ⇒ String
Returns The unique string that that we created to identify the Recording AddOnResult Payload resource.
471 472 473 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 471 def sid @properties['sid'] end |
#subresource_uris ⇒ Hash
Returns A list of related resources identified by their relative URIs.
531 532 533 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 531 def subresource_uris @properties['subresource_uris'] end |
#to_s ⇒ Object
Provide a user friendly representation
560 561 562 563 |
# File 'lib/twilio-ruby/rest/api/v2010/account/recording/add_on_result/payload.rb', line 560 def to_s values = @params.map{|k, v| "#{k}: #{v}"}.join(" ") "<Twilio.Api.V2010.PayloadInstance #{values}>" end |