Exception: A2A::Errors::HTTPError

Inherits:
ClientError show all
Defined in:
lib/a2a/errors.rb

Overview

HTTP-related errors

Instance Attribute Summary collapse

Attributes inherited from A2AError

#code, #data

Instance Method Summary collapse

Methods inherited from A2AError

#to_json_rpc_error

Constructor Details

#initialize(message, status_code: nil, response_body: nil, **options) ⇒ HTTPError

Returns a new instance of HTTPError.



174
175
176
177
178
# File 'lib/a2a/errors.rb', line 174

def initialize(message, status_code: nil, response_body: nil, **options)
  super(message, **options)
  @status_code = status_code
  @response_body = response_body
end

Instance Attribute Details

#response_bodyObject (readonly)

Returns the value of attribute response_body.



172
173
174
# File 'lib/a2a/errors.rb', line 172

def response_body
  @response_body
end

#status_codeObject (readonly)

Returns the value of attribute status_code.



172
173
174
# File 'lib/a2a/errors.rb', line 172

def status_code
  @status_code
end