UNPKG

@athenna/http

Version:

The Athenna Http server. Built on top of fastify.

28 lines (27 loc) 749 B
/** * @athenna/http * * (c) João Lenon <lenon@athenna.io> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ import type { ErrorContext } from '#src/types'; export declare class HttpExceptionHandler { /** * Error codes that should be ignored from logging. */ get ignoreCodes(): string[]; /** * Error statuses that should be ignored from logging. */ get ignoreStatuses(): number[]; /** * The exception handler of all request handlers. */ handle({ error, response }: ErrorContext): Promise<void>; /** * Return a boolean indicating if the error can be logged or not. */ private canBeLogged; }