Class: Twilio::REST::Content::V1::ContentList::FlowsPageComponent

Inherits:
Object
  • Object
show all
Defined in:
lib/twilio-ruby/rest/content/v1/content.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(payload) ⇒ FlowsPageComponent

Returns a new instance of FlowsPageComponent.



219
220
221
222
223
224
# File 'lib/twilio-ruby/rest/content/v1/content.rb', line 219

def initialize(payload)
        @label = payload["label"]
        @type = payload["type"]
        @text = payload["text"]
        @options = payload["options"]
end

Instance Attribute Details

#labelObject

Parameters:

  • : (label)
    String
  • : (type)
    String
  • : (text)
    String
  • : (options)
    Array<ContentList.FlowsPageComponentSelectItem>


218
219
220
# File 'lib/twilio-ruby/rest/content/v1/content.rb', line 218

def label
  @label
end

#optionsObject

Parameters:

  • : (label)
    String
  • : (type)
    String
  • : (text)
    String
  • : (options)
    Array<ContentList.FlowsPageComponentSelectItem>


218
219
220
# File 'lib/twilio-ruby/rest/content/v1/content.rb', line 218

def options
  @options
end

#textObject

Parameters:

  • : (label)
    String
  • : (type)
    String
  • : (text)
    String
  • : (options)
    Array<ContentList.FlowsPageComponentSelectItem>


218
219
220
# File 'lib/twilio-ruby/rest/content/v1/content.rb', line 218

def text
  @text
end

#typeObject

Parameters:

  • : (label)
    String
  • : (type)
    String
  • : (text)
    String
  • : (options)
    Array<ContentList.FlowsPageComponentSelectItem>


218
219
220
# File 'lib/twilio-ruby/rest/content/v1/content.rb', line 218

def type
  @type
end

Instance Method Details

#to_json(options = {}) ⇒ Object



225
226
227
228
229
230
231
232
# File 'lib/twilio-ruby/rest/content/v1/content.rb', line 225

def to_json(options = {})
{
        "label": @label,
        "type": @type,
        "text": @text,
        "options": @options,
}.to_json(options)
end