Class: Twilio::REST::Knowledge::V2::KnowledgeList::KnowledgeErrorInstance
- Inherits:
-
Object
- Object
- Twilio::REST::Knowledge::V2::KnowledgeList::KnowledgeErrorInstance
- Defined in:
- lib/twilio-ruby/rest/knowledge/v2/knowledge.rb
Instance Attribute Summary collapse
Instance Method Summary collapse
-
#initialize(payload) ⇒ KnowledgeErrorInstance
constructor
A new instance of KnowledgeErrorInstance.
- #to_json(options = {}) ⇒ Object
Constructor Details
#initialize(payload) ⇒ KnowledgeErrorInstance
Returns a new instance of KnowledgeErrorInstance.
63 64 65 66 67 68 |
# File 'lib/twilio-ruby/rest/knowledge/v2/knowledge.rb', line 63 def initialize(payload) @type = payload["type"] @code = payload["code"] @instance = payload["instance"] @detail = payload["detail"] end |
Instance Attribute Details
#code ⇒ Object
62 63 64 |
# File 'lib/twilio-ruby/rest/knowledge/v2/knowledge.rb', line 62 def code @code end |
#detail ⇒ Object
62 63 64 |
# File 'lib/twilio-ruby/rest/knowledge/v2/knowledge.rb', line 62 def detail @detail end |
#instance ⇒ Object
62 63 64 |
# File 'lib/twilio-ruby/rest/knowledge/v2/knowledge.rb', line 62 def instance @instance end |
#type ⇒ Object
62 63 64 |
# File 'lib/twilio-ruby/rest/knowledge/v2/knowledge.rb', line 62 def type @type end |
Instance Method Details
#to_json(options = {}) ⇒ Object
69 70 71 72 73 74 75 76 |
# File 'lib/twilio-ruby/rest/knowledge/v2/knowledge.rb', line 69 def to_json( = {}) { "type": @type, "code": @code, "instance": @instance, "detail": @detail, }.to_json() end |