Exception: Paubox::FormsClient::Error
- Inherits:
-
StandardError
- Object
- StandardError
- Paubox::FormsClient::Error
- Defined in:
- lib/paubox/forms_client.rb
Overview
Raised on any non-2xx response from the Forms API. Carries only status_code / url / response_body so error reporters that capture raising-frame locals never see the Authorization header or api_key.
Instance Attribute Summary collapse
-
#response_body ⇒ Object
readonly
Returns the value of attribute response_body.
-
#status_code ⇒ Object
readonly
Returns the value of attribute status_code.
-
#url ⇒ Object
readonly
Returns the value of attribute url.
Instance Method Summary collapse
-
#initialize(message, status_code: nil, url: nil, response_body: nil) ⇒ Error
constructor
A new instance of Error.
Constructor Details
#initialize(message, status_code: nil, url: nil, response_body: nil) ⇒ Error
Returns a new instance of Error.
26 27 28 29 30 31 |
# File 'lib/paubox/forms_client.rb', line 26 def initialize(, status_code: nil, url: nil, response_body: nil) super() @status_code = status_code @url = url @response_body = response_body end |
Instance Attribute Details
#response_body ⇒ Object (readonly)
Returns the value of attribute response_body.
24 25 26 |
# File 'lib/paubox/forms_client.rb', line 24 def response_body @response_body end |
#status_code ⇒ Object (readonly)
Returns the value of attribute status_code.
24 25 26 |
# File 'lib/paubox/forms_client.rb', line 24 def status_code @status_code end |
#url ⇒ Object (readonly)
Returns the value of attribute url.
24 25 26 |
# File 'lib/paubox/forms_client.rb', line 24 def url @url end |