import Fastify, { type FastifyInstance } from 'fastify';
import { type ServiceUpdateController } from './service-update.js';
import type { ProjectStatusRecord, StartProjectResult } from './types.js';
type MaybePromise<T> = T | Promise<T>;
export type RuntimeManagerLike = {
    listProjectStatuses: () => MaybePromise<ProjectStatusRecord[]>;
    getProjectStatus: (projectId: string) => MaybePromise<ProjectStatusRecord>;
    startProject: (projectId: string) => MaybePromise<StartProjectResult>;
    stopProject: (projectId: string) => MaybePromise<ProjectStatusRecord>;
    noteProjectActivity?: (projectId: string) => MaybePromise<ProjectStatusRecord | void>;
    acquireProjectSession?: (projectId: string) => {
        touchActivity?: (at?: number) => MaybePromise<ProjectStatusRecord | void>;
        release: () => void;
    };
    dispose?: () => MaybePromise<void>;
    config?: {
        server: {
            host: string;
            port: number;
        };
    };
};
export type HttpServerOptions = {
    clientBundleDir?: string | null;
    attachmentsRootDir?: string | null;
    serviceUpdateController?: ServiceUpdateController | null;
};
export declare const createHttpServer: (manager: RuntimeManagerLike, options?: HttpServerOptions) => Promise<FastifyInstance>;
export declare const startHttpServer: (manager?: import("./process-manager.js").RuntimeManager) => Promise<Fastify.FastifyInstance<Fastify.RawServerDefault, import("http").IncomingMessage, import("http").ServerResponse<import("http").IncomingMessage>, Fastify.FastifyBaseLogger, Fastify.FastifyTypeProviderDefault>>;
export {};
