Class: Twilio::REST::Webhooks::V1::RuleList::PostRule
- Inherits:
-
Object
- Object
- Twilio::REST::Webhooks::V1::RuleList::PostRule
- Defined in:
- lib/twilio-ruby/rest/webhooks/v1/rule.rb,
lib/twilio-ruby/rest/webhooks/v1/rule.rb
Instance Attribute Summary collapse
- #description ⇒ Object
- #friendly_name ⇒ Object
- #match_type ⇒ Object
- #prefix ⇒ Object
- #settings ⇒ Object
- #value ⇒ Object
Instance Method Summary collapse
-
#initialize(payload) ⇒ PostRule
constructor
A new instance of PostRule.
- #to_json(options = {}) ⇒ Object
Constructor Details
#initialize(payload) ⇒ PostRule
Returns a new instance of PostRule.
58 59 60 61 62 63 64 65 |
# File 'lib/twilio-ruby/rest/webhooks/v1/rule.rb', line 58 def initialize(payload) @friendly_name = payload["friendly_name"] @description = payload["description"] @match_type = payload["match_type"] @settings = payload["settings"] @prefix = payload["prefix"] @value = payload["value"] end |
Instance Attribute Details
#description ⇒ Object
57 58 59 |
# File 'lib/twilio-ruby/rest/webhooks/v1/rule.rb', line 57 def description @description end |
#friendly_name ⇒ Object
57 58 59 |
# File 'lib/twilio-ruby/rest/webhooks/v1/rule.rb', line 57 def friendly_name @friendly_name end |
#match_type ⇒ Object
57 58 59 |
# File 'lib/twilio-ruby/rest/webhooks/v1/rule.rb', line 57 def match_type @match_type end |
#prefix ⇒ Object
57 58 59 |
# File 'lib/twilio-ruby/rest/webhooks/v1/rule.rb', line 57 def prefix @prefix end |
#settings ⇒ Object
57 58 59 |
# File 'lib/twilio-ruby/rest/webhooks/v1/rule.rb', line 57 def settings @settings end |
#value ⇒ Object
57 58 59 |
# File 'lib/twilio-ruby/rest/webhooks/v1/rule.rb', line 57 def value @value end |
Instance Method Details
#to_json(options = {}) ⇒ Object
66 67 68 69 70 71 72 73 74 75 |
# File 'lib/twilio-ruby/rest/webhooks/v1/rule.rb', line 66 def to_json( = {}) { "friendlyName": @friendly_name, "description": @description, "matchType": @match_type, "settings": @settings, "prefix": @prefix, "value": @value, }.to_json() end |