hook-engine
Version:
Production-grade webhook engine with comprehensive adapter support, security, reliability, structured logging, and CLI tools.
41 lines (40 loc) • 1.17 kB
TypeScript
/**
* Base error class for all hook-engine errors
*/
export declare abstract class HookEngineError extends Error {
readonly code: string;
readonly context: Record<string, any>;
readonly retryable: boolean;
readonly timestamp: Date;
constructor(message: string, code: string, context?: Record<string, any>, retryable?: boolean);
/**
* Serialize error for logging/debugging
*/
toJSON(): {
name: string;
message: string;
code: string;
context: Record<string, any>;
retryable: boolean;
timestamp: string;
stack: string | undefined;
};
}
/**
* Configuration-related errors
*/
export declare class ConfigurationError extends HookEngineError {
constructor(message: string, context?: Record<string, any>);
}
/**
* Network-related errors that might be retryable
*/
export declare class NetworkError extends HookEngineError {
constructor(message: string, context?: Record<string, any>, retryable?: boolean);
}
/**
* Timeout errors
*/
export declare class TimeoutError extends HookEngineError {
constructor(message: string, context?: Record<string, any>);
}