import * as bodyParser from "body-parser";
import { Configuration, ExpressCustomizer } from "../../../configuration";
import { AutomationContextAware } from "../../../HandlerContext";
import { AutomationServer } from "../../../server/AutomationServer";
import { GraphClient } from "../../../spi/graph/GraphClient";
import { MessageClient } from "../../../spi/message/MessageClient";
import { RequestProcessor } from "../RequestProcessor";
/**
 * Registers an endpoint for every automation and exposes
 * metadataFromInstance at root. Responsible for marshalling into the appropriate structure
 */
export declare class ExpressServer {
    private readonly automations;
    private readonly configuration;
    private readonly handler;
    private readonly exp;
    constructor(automations: AutomationServer, configuration: Configuration, handler: RequestProcessor);
    run(): Promise<boolean>;
    private exposeCommandHandlerInvocationRoute;
    private exposeEventHandlerInvocationRoute;
    private setupAuthentication;
    private readonly adminRoute;
    private readonly authenticate;
}
export interface ExpressServerOptions {
    port: number;
    host?: string;
    customizers?: ExpressCustomizer[];
    bodyParser?: {
        options?: bodyParser.Options;
    };
    auth?: {
        basic?: {
            enabled?: boolean;
            username?: string;
            password?: string;
        };
        bearer?: {
            enabled?: boolean;
            org?: string;
            adminOrg?: string;
        };
        token?: {
            enabled?: boolean;
            verify?: (token: string) => Promise<boolean>;
        };
    };
    endpoint: {
        graphql: string;
    };
    messageClientFactory?: (aca: AutomationContextAware) => MessageClient;
    graphClientFactory?: (aca: AutomationContextAware) => GraphClient;
}
//# sourceMappingURL=ExpressServer.d.ts.map