import type { Server as HTTPServer } from "node:http";
import type { Server as HTTPSServer } from "node:https";
import { GrafservBase } from "../../../core/base.ts";
import type { GrafservBody, GrafservConfig, RequestDigest, Result } from "../../../interfaces.ts";
import type { OptionsFromConfig } from "../../../options.ts";
export declare function getBodyFromRequest(req: Request, maxLength: number): Promise<GrafservBody>;
declare global {
    namespace Grafast {
        interface RequestContext {
            whatwgv0: {
                request: Request;
            };
        }
    }
}
/** @experimental */
export declare class WhatwgGrafserv extends GrafservBase {
    protected whatwgRequestToGrafserv(dynamicOptions: OptionsFromConfig, request: Request): RequestDigest;
    protected processHeaders(headers: Headers): Record<string, string>;
    protected grafservResponseToWhatwg(response: Result | null): Response;
    createHandler(): import("@whatwg-node/server").ServerAdapter<{}, import("@whatwg-node/server").ServerAdapterBaseObject<{}, (request: Request) => Promise<Response>>>;
    addTo(server: HTTPServer | HTTPSServer): void;
    protected processWhatwgRequest(_request: Request, request: RequestDigest): import("grafast").PromiseOrDirect<Result | null>;
}
/** @experimental */
export declare function grafserv(config: GrafservConfig): WhatwgGrafserv;
//# sourceMappingURL=index.d.ts.map