Class: Twilio::REST::Content::V1::ContentList::WhatsappCard
- Inherits:
-
Object
- Object
- Twilio::REST::Content::V1::ContentList::WhatsappCard
- Defined in:
- lib/twilio-ruby/rest/content/v1/content.rb,
lib/twilio-ruby/rest/content/v1/content.rb
Instance Attribute Summary collapse
Instance Method Summary collapse
-
#initialize(payload) ⇒ WhatsappCard
constructor
A new instance of WhatsappCard.
- #to_json(options = {}) ⇒ Object
Constructor Details
#initialize(payload) ⇒ WhatsappCard
Returns a new instance of WhatsappCard.
591 592 593 594 595 596 597 |
# File 'lib/twilio-ruby/rest/content/v1/content.rb', line 591 def initialize(payload) @body = payload["body"] @footer = payload["footer"] @media = payload["media"] @header_text = payload["header_text"] @actions = payload["actions"] end |
Instance Attribute Details
#actions ⇒ Object
590 591 592 |
# File 'lib/twilio-ruby/rest/content/v1/content.rb', line 590 def actions @actions end |
#body ⇒ Object
590 591 592 |
# File 'lib/twilio-ruby/rest/content/v1/content.rb', line 590 def body @body end |
#footer ⇒ Object
590 591 592 |
# File 'lib/twilio-ruby/rest/content/v1/content.rb', line 590 def @footer end |
#header_text ⇒ Object
590 591 592 |
# File 'lib/twilio-ruby/rest/content/v1/content.rb', line 590 def header_text @header_text end |
#media ⇒ Object
590 591 592 |
# File 'lib/twilio-ruby/rest/content/v1/content.rb', line 590 def media @media end |
Instance Method Details
#to_json(options = {}) ⇒ Object
598 599 600 601 602 603 604 605 606 |
# File 'lib/twilio-ruby/rest/content/v1/content.rb', line 598 def to_json( = {}) { "body": @body, "footer": @footer, "media": @media, "header_text": @header_text, "actions": @actions, }.to_json() end |