ACP v2 (Preview) TypeScript SDK — EXPERIMENTAL - v2.12.1
    Preparing search index...

    Type Alias ErrorExperimental

    JSON-RPC error object.

    Represents an error that occurred during method execution, following the JSON-RPC 2.0 error object specification with optional additional data.

    See protocol docs: JSON-RPC Error Object

    type Error = {
        code: ErrorCode;
        message: string;
        data?: ErrorData | null;
    }
    Index
    code: ErrorCode

    A number indicating the error type that occurred. This MUST be an integer as defined in the JSON-RPC specification.

    message: string

    A short, human-readable description of the error, in plain text. The sender SHOULD limit the message to a single concise sentence.

    data?: ErrorData | null

    Optional primitive or structured value that contains additional information about the error. This may include debugging information or context-specific details.

    Omitted and null are equivalent and mean no additional data is provided. Some codes define a shape: [UnsupportedProtocolVersionErrorData] for -32022, and [SessionNotFoundErrorData] for -32002 when a session is not found.