import { FastifyReply, FastifyRequest } from 'fastify'; export type HookName = "onTimeout" | "onRequest" | "preParsing" | "preValidation" | "preSerialization" | "preHandler" | "onSend" | "onResponse" | "onError" | "onRequestAbort"; export type HookHandler = (request: FastifyRequest, reply: FastifyReply) => Promise; export type FileRouteOptions = { dir: string; patterns: string | string[]; prefix: string; hooks?: { [key in HookName]: HookHandler; }; };