Skip to main content

Module error

Module error 

Source
Expand description

Error taxonomy for the Agent OS client SDK.

Mirrors spec.md §4 / ADR-001 §4. Preserves the TypeScript SDK distinction so callers can still discriminate path-guard violations from kernel errno failures. Public methods return anyhow::Result; the typed ClientError is carried as the source so callers can downcast.

Hard rule (parity): JSON-RPC errors are NOT Rust Err. prompt, cancel_session, set_session_model, set_session_thought_level, respond_permission, raw_session_send, raw_send, and set_session_mode return a crate::json_rpc::JsonRpcResponse whose error field may be populated (including acp_timeout and codex -32601 fallbacks). Do not convert those into Err.

Enums§

ClientError
Typed error taxonomy for the client SDK.

Type Aliases§

ClientResult
Convenience alias for results carrying a typed ClientError.