Skip to content

error

A2A v1.0 Error Types

type A2AResult = Result<T, A2AError>;

A2A Protocol Error

Variants

VariantDescription
MethodNotFound { ... }
InvalidParams { ... }
AgentUnavailable { ... }
CapabilityValidationFailed { ... }
MethodExecutionFailed { ... }
RegistryError { ... }
ProtocolValidationError { ... }
JsonRpcError(anyhow::Error)
SerializationError(serde_json::Error)
Internal { ... }
TaskNotFound { ... }
TaskNotCancelable { ... }
PushNotificationNotSupported
UnsupportedOperation { ... }
ContentTypeNotSupported { ... }
InvalidAgentResponse { ... }
VersionNotSupported { ... }

Methods

fn to_jsonrpc_error(&self) -> JsonRpcError
fn method_not_found<impl Into<String>>(method: impl Into) -> Self
fn invalid_params<impl Into<String>, impl Into<String>>(method: impl Into, details: impl Into) -> Self
fn agent_unavailable<impl Into<String>, impl Into<String>>(agent_id: impl Into, reason: impl Into) -> Self
fn capability_validation_failed<impl Into<String>>(details: impl Into) -> Self
fn method_execution_failed<impl Into<String>, impl Into<String>>(method: impl Into, details: impl Into) -> Self
fn registry_error<impl Into<String>>(details: impl Into) -> Self
fn protocol_validation_error<impl Into<String>>(details: impl Into) -> Self
fn internal<impl Into<String>>(details: impl Into) -> Self
fn task_not_found<impl Into<String>>(task_id: impl Into) -> Self
fn task_not_cancelable<impl Into<String>>(task_id: impl Into) -> Self
fn unsupported_operation<impl Into<String>>(details: impl Into) -> Self
fn version_not_supported<impl Into<String>>(version: impl Into) -> Self