import { EventToken } from '../events';
import type { HttpRoutePlan } from './router';
import type { HttpRequest } from './request';
import type { HttpResponse } from './response';
export declare class HttpWorkflowToken<TEvent> extends EventToken<TEvent> {
    readonly event: TEvent;
}
export interface HttpWorkflowEvent {
    request: HttpRequest;
    response: HttpResponse;
    sent: boolean;
    hasNext(): boolean;
    send(response: Response | string | Buffer): Promise<void>;
}
export interface HttpRouteWorkflowEvent extends HttpWorkflowEvent {
    route?: HttpRoutePlan;
}
export interface HttpControllerWorkflowEvent extends HttpRouteWorkflowEvent {
}
export interface HttpResponseWorkflowEvent extends HttpRouteWorkflowEvent {
}
export interface HttpRouteNotFoundWorkflowEvent extends HttpWorkflowEvent {
}
export declare const httpWorkflow: {
    onRoute: HttpWorkflowToken<HttpRouteWorkflowEvent>;
    onController: HttpWorkflowToken<HttpControllerWorkflowEvent>;
    onResponse: HttpWorkflowToken<HttpResponseWorkflowEvent>;
    onRouteNotFound: HttpWorkflowToken<HttpRouteNotFoundWorkflowEvent>;
};
export declare function createHttpWorkflowEvent(request: HttpRequest, response: HttpResponse, options?: {
    route?: HttpRoutePlan;
    hasNext?: () => boolean;
}): HttpWorkflowEvent;
//# sourceMappingURL=workflow.d.ts.map