import type { PatchConflict, PatchRejection } from "@oscharko-dev/keiko-contracts";
export declare const TOOL_CODES: {
    readonly ARGUMENT: "TOOL_ARGUMENT";
    readonly UNKNOWN: "TOOL_UNKNOWN";
    readonly COMMAND_DENIED: "TOOL_COMMAND_DENIED";
    readonly COMMAND_TIMEOUT: "TOOL_COMMAND_TIMEOUT";
    readonly COMMAND_CANCELLED: "TOOL_COMMAND_CANCELLED";
    readonly OUTPUT_LIMIT: "TOOL_OUTPUT_LIMIT";
    readonly PATCH_INVALID: "TOOL_PATCH_INVALID";
    readonly PATCH_APPLY_DISABLED: "TOOL_PATCH_APPLY_DISABLED";
    readonly PATCH_APPLY_FAILED: "TOOL_PATCH_APPLY_FAILED";
};
export type ToolCode = (typeof TOOL_CODES)[keyof typeof TOOL_CODES];
export declare abstract class ToolError extends Error {
    abstract readonly code: ToolCode;
    constructor(message: string, secrets?: readonly string[]);
}
export declare class ToolArgumentError extends ToolError {
    readonly code: "TOOL_ARGUMENT";
    readonly toolName: string;
    constructor(message: string, toolName: string, secrets?: readonly string[]);
}
export declare class UnknownToolError extends ToolError {
    readonly code: "TOOL_UNKNOWN";
    readonly toolName: string;
    constructor(message: string, toolName: string, secrets?: readonly string[]);
}
export declare class CommandDeniedError extends ToolError {
    readonly code: "TOOL_COMMAND_DENIED";
    readonly executable: string;
    constructor(message: string, executable: string, secrets?: readonly string[]);
}
export declare class CommandTimeoutError extends ToolError {
    readonly code: "TOOL_COMMAND_TIMEOUT";
    readonly timeoutMs: number;
    constructor(message: string, timeoutMs: number, secrets?: readonly string[]);
}
export declare class CommandCancelledError extends ToolError {
    readonly code: "TOOL_COMMAND_CANCELLED";
}
export declare class OutputLimitError extends ToolError {
    readonly code: "TOOL_OUTPUT_LIMIT";
    readonly limitBytes: number;
    constructor(message: string, limitBytes: number, secrets?: readonly string[]);
}
export declare class PatchValidationError extends ToolError {
    readonly code: "TOOL_PATCH_INVALID";
    readonly reasons: readonly PatchRejection[];
    readonly conflicts: readonly PatchConflict[];
    constructor(message: string, reasons: readonly PatchRejection[], conflicts: readonly PatchConflict[], secrets?: readonly string[]);
}
export declare class PatchApplyDisabledError extends ToolError {
    readonly code: "TOOL_PATCH_APPLY_DISABLED";
}
export declare class PatchApplyError extends ToolError {
    readonly code: "TOOL_PATCH_APPLY_FAILED";
    readonly path: string;
    constructor(message: string, path: string, secrets?: readonly string[]);
}
//# sourceMappingURL=tools.d.ts.map