declare class MiddlewareSettings {
    settings: {};
    constructor(settings: any);
    get(name: any): any;
}
/**
 * Middleware functions must implement this signature.
 * They must accept a `req` and a `next` parameter, and return a `Rseponse`.
 * @function middlewareFn
 * @callback middlewareFn
 * @param {Request} request The HTTP request to operate on
 * @param {function} next A function to process subsequent middleware
 * @returns {Response} The response to serve to the user
 * @hidden
 */
/**
 * A single Middleware. Middleware accepts a request, does its business, and then returns a Response.
 * @param {Object} props
 * @param {string} [props.type] Key for a prebuilt middleware
 * @param {string} [props.fn] A function to use as middleware
 * @param {Object.<string,Object>} [props.settings] Settings to hand off to the middleware
 * @hidden
 */
export declare class Middleware {
    type: any;
    settings: MiddlewareSettings;
    fn: any;
    constructor(props: any);
    /**
     * Runs a single middleware instance
     * @param {Middleware} mw  The middleware to run
     * @param {Object.<string,Object>} settings Settings for this middleware run
     * @param {Request} req The HTTP request to operate on
     */
    static run(mw: any, settings: any, req: any): Promise<Response>;
}
/**
 * A chain of middleware to execute in order
 * @hidden
 */
export declare class MiddlewareChain {
    currentPos: number;
    chain: any[];
    constructor();
    /**
     * Appends middleware to the chain
     * @param {Middleware} mw Middleware to add to the chain
     * @param {Object.<string,Object>} settings Settings for this middleware
     */
    use(mw: any, settings: any): void;
    /**
     * Runs the chain of middleware
     * @param {Request} req The HTTP request to thread through the chain
     * @returns {Response} The resulting response
     */
    run(req: any): Promise<Response>;
    buildNext(mw: any, pos: any): any;
    runMiddleware(mw: any, req: any, next: any): Promise<any>;
    lastNextFunc(): Response;
}
export {};
