Exception: A2A::UnsupportedOperationError

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

Overview

The requested operation or a specific aspect of it is not supported by this server agent implementation.

Instance Attribute Summary

Attributes inherited from Error

#code, #http_status

Instance Method Summary collapse

Methods inherited from Error

#to_h

Constructor Details

#initialize(message: "Unsupported operation") ⇒ UnsupportedOperationError

Returns a new instance of UnsupportedOperationError.



111
112
113
# File 'lib/a2a/errors.rb', line 111

def initialize(message: "Unsupported operation")
  super(message, code: -32004, http_status: 400)
end

Instance Method Details

#error_dataObject



115
116
117
118
119
120
121
# File 'lib/a2a/errors.rb', line 115

def error_data
  [{
    "@type"  => "type.googleapis.com/google.rpc.ErrorInfo",
    "reason" => "UNSUPPORTED_OPERATION",
    "domain" => "a2a-protocol.org",
  }]
end