Class: Twilio::REST::Assistants::V1::AssistantContext::FeedbackList::AssistantsV1ServiceCreateFeedbackRequest
- Inherits:
-
Object
- Object
- Twilio::REST::Assistants::V1::AssistantContext::FeedbackList::AssistantsV1ServiceCreateFeedbackRequest
- Defined in:
- lib/twilio-ruby/rest/assistants/v1/assistant/feedback.rb
Instance Attribute Summary collapse
Instance Method Summary collapse
-
#initialize(payload) ⇒ AssistantsV1ServiceCreateFeedbackRequest
constructor
A new instance of AssistantsV1ServiceCreateFeedbackRequest.
- #to_json(options = {}) ⇒ Object
Constructor Details
#initialize(payload) ⇒ AssistantsV1ServiceCreateFeedbackRequest
Returns a new instance of AssistantsV1ServiceCreateFeedbackRequest.
30 31 32 33 34 35 |
# File 'lib/twilio-ruby/rest/assistants/v1/assistant/feedback.rb', line 30 def initialize(payload) @message_id = payload["message_id"] @score = payload["score"] @session_id = payload["session_id"] @text = payload["text"] end |
Instance Attribute Details
#message_id ⇒ Object
29 30 31 |
# File 'lib/twilio-ruby/rest/assistants/v1/assistant/feedback.rb', line 29 def @message_id end |
#score ⇒ Object
29 30 31 |
# File 'lib/twilio-ruby/rest/assistants/v1/assistant/feedback.rb', line 29 def score @score end |
#session_id ⇒ Object
29 30 31 |
# File 'lib/twilio-ruby/rest/assistants/v1/assistant/feedback.rb', line 29 def session_id @session_id end |
#text ⇒ Object
29 30 31 |
# File 'lib/twilio-ruby/rest/assistants/v1/assistant/feedback.rb', line 29 def text @text end |
Instance Method Details
#to_json(options = {}) ⇒ Object
36 37 38 39 40 41 42 43 |
# File 'lib/twilio-ruby/rest/assistants/v1/assistant/feedback.rb', line 36 def to_json( = {}) { "message_id": @message_id, "score": @score, "session_id": @session_id, "text": @text, }.to_json() end |