Class: Keycardai::A2A::InvocationError

Inherits:
Error
  • Object
show all
Defined in:
lib/keycardai/a2a/errors.rb

Overview

The JSON-RPC invocation returned an HTTP error or a JSON-RPC error response. Carries the JSON-RPC error payload when one was returned.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message, rpc_error: nil) ⇒ InvocationError

Returns a new instance of InvocationError.



15
16
17
18
# File 'lib/keycardai/a2a/errors.rb', line 15

def initialize(message, rpc_error: nil)
  super(message)
  @rpc_error = rpc_error
end

Instance Attribute Details

#rpc_errorHash? (readonly)

Returns the JSON-RPC error object, when present.

Returns:

  • (Hash, nil)

    the JSON-RPC error object, when present



13
14
15
# File 'lib/keycardai/a2a/errors.rb', line 13

def rpc_error
  @rpc_error
end