import type { WorkspaceContext } from '../engines/workspace-resolver.js';
import { type DaemonLockRecord } from './lock.js';
export declare class NexusDaemonServer {
    private readonly workspace;
    private readonly host;
    private readonly httpServer;
    private readonly authToken;
    private readonly sessionAdapters;
    private readonly queuedRuns;
    private readonly cleanupTimer;
    private nexus;
    private lockPath;
    private lockRecord;
    private heartbeatTimer;
    private stopping;
    private runtimeReady;
    constructor(workspace: WorkspaceContext);
    private installProcessErrorHandlers;
    /**
     * Live read of the lock record (port + token) so supervisors and other
     * callers can re-fetch credentials after a stop()/start() cycle without
     * holding stale references.
     */
    getLockRecord(): DaemonLockRecord | null;
    private startHeartbeat;
    start(): Promise<{
        started: boolean;
        record: DaemonLockRecord;
    }>;
    private installSignalHandlers;
    private releaseLock;
    private getSessionAdapter;
    private pruneState;
    private isAuthorized;
    private handleToolCall;
    private handleRequest;
    stop(signal?: string): Promise<void>;
}
