/** Error taxonomy: callers branch on `code`, never on message text. */ export type NightWatchErrorCode = 'CANONICALIZE_FAILED' | 'LEDGER_CORRUPT' | 'LEDGER_LOCKED' | 'STORE_NOT_FOUND' | 'GIT_UNAVAILABLE' | 'CHECKPOINT_FAILED' | 'INVALID_PAYLOAD' | 'SETTINGS_MERGE_FAILED' | 'SIGNING_FAILED' | 'VERIFY_FAILED'; export declare class NightWatchError extends Error { readonly code: NightWatchErrorCode; readonly detail: Readonly>; constructor(code: NightWatchErrorCode, message: string, detail?: Record); } export declare function isNightWatchError(value: unknown): value is NightWatchError; /** Normalize any thrown value into a printable one-line message. */ export declare function describeError(value: unknown): string;