type RouteDef = { method: string; accepts: string | null; returns: string; needsBody?: "multipart" | "json"; }; type Query = Record; type Params = Record; type RouteModule = { handler: ( request: Request, server: BunServer, requestBody: unknown, query: Query, params: Params, ) => Promise | Response; routeDef: RouteDef; };