import type { AgentConfig } from '../types/index.js'; /** * Save agent configuration. */ export declare function saveConfig(config: AgentConfig): void; /** * Load agent configuration. */ export declare function loadConfig(): AgentConfig | null; /** * Check if agent is configured. */ export declare function isConfigured(): boolean; /** * Save daemon PID. */ export declare function savePid(pid: number): void; /** * Read daemon PID. */ export declare function readPid(): number | null; /** * Remove daemon PID file. */ export declare function removePid(): void; /** * Check if daemon process is running. */ export declare function isDaemonRunning(): boolean; /** * Atomically claim single-daemon-per-machine. Returns true if we are now the only * daemon (pidfile written with our pid), false if another LIVE daemon already holds * it. Race-safe: create-exclusive (O_EXCL); on an existing file we check pid * liveness and reclaim a stale one. This is what prevents two daemons from running * at once and fighting over the WS connection (the cause of 1006 flapping). */ export declare function acquireSingleInstanceLock(): boolean;