Method: Sendgrid::Web::Response#initialize
- Defined in:
- lib/sendgrid/web/response.rb
#initialize(status_code, body) ⇒ Response
Returns a new instance of Response.
5 6 7 8 9 |
# File 'lib/sendgrid/web/response.rb', line 5 def initialize(status_code, body) @status_code = status_code.to_i @raw_body = body.to_s @parsed_body = ::Oj.safe_load(raw_body) end |