Class: Twilio::REST::Insights::V2::ReportList::StirShaken
- Inherits:
-
Object
- Object
- Twilio::REST::Insights::V2::ReportList::StirShaken
- Defined in:
- lib/twilio-ruby/rest/insights/v2/report.rb
Instance Attribute Summary collapse
Instance Method Summary collapse
-
#initialize(payload) ⇒ StirShaken
constructor
A new instance of StirShaken.
- #to_json(options = {}) ⇒ Object
Constructor Details
#initialize(payload) ⇒ StirShaken
Returns a new instance of StirShaken.
345 346 347 348 349 |
# File 'lib/twilio-ruby/rest/insights/v2/report.rb', line 345 def initialize(payload) @call_count = payload["call_count"] @percentage = payload["percentage"] @answer_rate = payload["answer_rate"] end |
Instance Attribute Details
#answer_rate ⇒ Object
344 345 346 |
# File 'lib/twilio-ruby/rest/insights/v2/report.rb', line 344 def answer_rate @answer_rate end |
#call_count ⇒ Object
344 345 346 |
# File 'lib/twilio-ruby/rest/insights/v2/report.rb', line 344 def call_count @call_count end |
#percentage ⇒ Object
344 345 346 |
# File 'lib/twilio-ruby/rest/insights/v2/report.rb', line 344 def percentage @percentage end |
Instance Method Details
#to_json(options = {}) ⇒ Object
350 351 352 353 354 355 356 |
# File 'lib/twilio-ruby/rest/insights/v2/report.rb', line 350 def to_json( = {}) { "call_count": @call_count, "percentage": @percentage, "answer_rate": @answer_rate, }.to_json() end |