import type { HttpContext } from '../http/types'; export type ErrorReporter = (error: Error, ctx: HttpContext) => void | Promise; export declare class ExceptionHandler { private reporters; private ignoredCodes; private ignoredStatuses; private statusPageMap; debug: boolean; /** Ignore these HTTP status codes when reporting */ ignoreStatuses(...statuses: number[]): this; /** Ignore these error codes when reporting */ ignoreCodes(...codes: string[]): this; /** Register an error reporter (logger, Sentry, etc.) */ report(reporter: ErrorReporter): this; /** * Register status pages for specific HTTP error codes. * Renders custom HTML/views instead of JSON for browser requests. * @example * handler.statusPages({ * '404': (ctx) => render(NotFoundPage), * '500..599': (ctx, error) => render(ErrorPage, { error }), * }) */ statusPages(pages: Record any>): this; handle(error: Error, ctx: HttpContext): Promise; private _matchStatusPage; private _report; }