Class: Twilio::REST::Numbers::V2::RegulatoryComplianceList::BundleInstance
- Inherits:
-
InstanceResource
- Object
- InstanceResource
- Twilio::REST::Numbers::V2::RegulatoryComplianceList::BundleInstance
- Defined in:
- lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb
Instance Method Summary collapse
-
#account_sid ⇒ String
The SID of the [Account](www.twilio.com/docs/iam/api/account) that created the Bundle resource.
-
#bundle_copies ⇒ bundle_copies
Access the bundle_copies.
-
#context ⇒ BundleContext
Generate an instance context for the instance, the context is capable of performing various actions.
-
#date_created ⇒ Time
The date and time in GMT when the resource was created specified in [ISO 8601](en.wikipedia.org/wiki/ISO_8601) format.
-
#date_updated ⇒ Time
The date and time in GMT when the resource was last updated specified in [ISO 8601](en.wikipedia.org/wiki/ISO_8601) format.
-
#delete ⇒ Boolean
Delete the BundleInstance.
-
#email ⇒ String
The email address that will receive updates when the Bundle resource changes status.
-
#evaluations ⇒ evaluations
Access the evaluations.
-
#fetch ⇒ BundleInstance
Fetch the BundleInstance.
-
#friendly_name ⇒ String
The string that you assigned to describe the resource.
-
#initialize(version, payload, sid: nil) ⇒ BundleInstance
constructor
Initialize the BundleInstance.
-
#inspect ⇒ Object
Provide a detailed, user friendly representation.
-
#item_assignments ⇒ item_assignments
Access the item_assignments.
-
#links ⇒ Hash
The URLs of the Assigned Items of the Bundle resource.
-
#regulation_sid ⇒ String
The unique string of a regulation that is associated to the Bundle resource.
-
#replace_items ⇒ replace_items
Access the replace_items.
-
#sid ⇒ String
The unique string that we created to identify the Bundle resource.
- #status ⇒ Status
-
#status_callback ⇒ String
The URL we call to inform your application of status changes.
-
#to_s ⇒ Object
Provide a user friendly representation.
-
#update(status: :unset, status_callback: :unset, friendly_name: :unset, email: :unset) ⇒ BundleInstance
Update the BundleInstance.
-
#url ⇒ String
The absolute URL of the Bundle resource.
-
#valid_until ⇒ Time
The date and time in GMT in [ISO 8601](en.wikipedia.org/wiki/ISO_8601) format when the resource will be valid until.
Constructor Details
#initialize(version, payload, sid: nil) ⇒ BundleInstance
Initialize the BundleInstance
426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 426 def initialize(version, payload , sid: nil) super(version) # Marshaled Properties @properties = { 'sid' => payload['sid'], 'account_sid' => payload['account_sid'], 'regulation_sid' => payload['regulation_sid'], 'friendly_name' => payload['friendly_name'], 'status' => payload['status'], 'valid_until' => Twilio.deserialize_iso8601_datetime(payload['valid_until']), 'email' => payload['email'], 'status_callback' => payload['status_callback'], 'date_created' => Twilio.deserialize_iso8601_datetime(payload['date_created']), 'date_updated' => Twilio.deserialize_iso8601_datetime(payload['date_updated']), 'url' => payload['url'], 'links' => payload['links'], } # Context @instance_context = nil @params = { '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 Bundle resource.
469 470 471 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 469 def account_sid @properties['account_sid'] end |
#bundle_copies ⇒ bundle_copies
Access the bundle_copies
574 575 576 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 574 def bundle_copies context.bundle_copies end |
#context ⇒ BundleContext
Generate an instance context for the instance, the context is capable of performing various actions. All instance actions are proxied to the context
454 455 456 457 458 459 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 454 def context unless @instance_context @instance_context = BundleContext.new(@version , @params['sid']) end @instance_context end |
#date_created ⇒ Time
Returns The date and time in GMT when the resource was created specified in [ISO 8601](en.wikipedia.org/wiki/ISO_8601) format.
511 512 513 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 511 def date_created @properties['date_created'] end |
#date_updated ⇒ Time
Returns The date and time in GMT when the resource was last updated specified in [ISO 8601](en.wikipedia.org/wiki/ISO_8601) format.
517 518 519 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 517 def date_updated @properties['date_updated'] end |
#delete ⇒ Boolean
Delete the BundleInstance
536 537 538 539 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 536 def delete context.delete end |
#email ⇒ String
Returns The email address that will receive updates when the Bundle resource changes status.
499 500 501 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 499 def email @properties['email'] end |
#evaluations ⇒ evaluations
Access the evaluations
595 596 597 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 595 def evaluations context.evaluations end |
#fetch ⇒ BundleInstance
Fetch the BundleInstance
544 545 546 547 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 544 def fetch context.fetch end |
#friendly_name ⇒ String
Returns The string that you assigned to describe the resource.
481 482 483 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 481 def friendly_name @properties['friendly_name'] end |
#inspect ⇒ Object
Provide a detailed, user friendly representation
608 609 610 611 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 608 def inspect values = @properties.map{|k, v| "#{k}: #{v}"}.join(" ") "<Twilio.Numbers.V2.BundleInstance #{values}>" end |
#item_assignments ⇒ item_assignments
Access the item_assignments
588 589 590 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 588 def item_assignments context.item_assignments end |
#links ⇒ Hash
Returns The URLs of the Assigned Items of the Bundle resource.
529 530 531 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 529 def links @properties['links'] end |
#regulation_sid ⇒ String
Returns The unique string of a regulation that is associated to the Bundle resource.
475 476 477 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 475 def regulation_sid @properties['regulation_sid'] end |
#replace_items ⇒ replace_items
Access the replace_items
581 582 583 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 581 def replace_items context.replace_items end |
#sid ⇒ String
Returns The unique string that we created to identify the Bundle resource.
463 464 465 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 463 def sid @properties['sid'] end |
#status ⇒ Status
487 488 489 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 487 def status @properties['status'] end |
#status_callback ⇒ String
Returns The URL we call to inform your application of status changes.
505 506 507 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 505 def status_callback @properties['status_callback'] end |
#to_s ⇒ Object
Provide a user friendly representation
601 602 603 604 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 601 def to_s values = @params.map{|k, v| "#{k}: #{v}"}.join(" ") "<Twilio.Numbers.V2.BundleInstance #{values}>" end |
#update(status: :unset, status_callback: :unset, friendly_name: :unset, email: :unset) ⇒ BundleInstance
Update the BundleInstance
556 557 558 559 560 561 562 563 564 565 566 567 568 569 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 556 def update( status: :unset, status_callback: :unset, friendly_name: :unset, email: :unset ) context.update( status: status, status_callback: status_callback, friendly_name: friendly_name, email: email, ) end |
#url ⇒ String
Returns The absolute URL of the Bundle resource.
523 524 525 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 523 def url @properties['url'] end |
#valid_until ⇒ Time
Returns The date and time in GMT in [ISO 8601](en.wikipedia.org/wiki/ISO_8601) format when the resource will be valid until.
493 494 495 |
# File 'lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb', line 493 def valid_until @properties['valid_until'] end |