interface RouteCondition {
    type: 'header' | 'cookie' | 'host' | 'query';
    key: string;
    value?: string;
}
/** Normalized matcher with compiled regex */
interface NormalizedMatcher {
    source: string;
    regex: RegExp;
    has?: RouteCondition[];
    missing?: RouteCondition[];
}
/** Middleware type identifier */
type MiddlewareType = 'middleware' | 'proxy';
/** Loaded and normalized middleware */
interface LoadedMiddleware {
    type: MiddlewareType;
    path: string;
    handler: (request: Request) => Promise<Response | undefined> | Response | undefined;
    matchers: NormalizedMatcher[];
}
/**
 * Options for middleware generation
 */
export interface MiddlewareGenOptions {
    /** Custom header comment */
    header?: string;
    /** Path to middleware file (for import) */
    middlewarePath?: string;
    /** Whether the middleware is async */
    isAsync?: boolean;
}
/**
 * Generated middleware output
 */
export interface GeneratedMiddleware {
    /** middleware.ts content */
    content: string;
}
/**
 * Generate middleware integration file
 */
export declare function generateMiddlewareFile(middleware: LoadedMiddleware, options?: MiddlewareGenOptions): GeneratedMiddleware;
/**
 * Generate empty middleware file when no middleware exists
 */
export declare function generateEmptyMiddlewareFile(options?: MiddlewareGenOptions): GeneratedMiddleware;
/**
 * Generate middleware that wraps multiple middleware handlers
 */
export declare function generateComposedMiddlewareFile(middlewares: LoadedMiddleware[], options?: MiddlewareGenOptions): GeneratedMiddleware;
export {};
//# sourceMappingURL=middleware-gen.d.ts.map