import { MiddlewarePipeline } from "../../middleware/core/pipeline/index.js"; import type { MiddlewareHandler } from "../../middleware/core/types.js"; import type { RuntimeAdapter } from "../../platform/adapters/base.js"; import type { VeryfrontConfig } from "../../config/index.js"; export type MiddlewareFunction = MiddlewareHandler; interface MiddlewareLoadOptions { throwOnError?: boolean; /** Explicit host-owned capability for a trusted local or dedicated runtime. */ allowHostProjectCodeExecution?: boolean; } /** * Internal control signal used when project middleware exists but the current * runtime is not permitted to evaluate it in the host process. */ export declare class ProjectMiddlewareHostExecutionDeniedError extends TypeError { constructor(); } export declare function loadMiddlewareFile(projectDir: string, adapter: RuntimeAdapter, options?: MiddlewareLoadOptions): Promise; export declare function setupMiddleware(pipeline: MiddlewarePipeline, config: VeryfrontConfig, requestHandler: (req: Request) => Promise): Promise; export {}; //# sourceMappingURL=middleware.d.ts.map