import type { BackendType } from './backends/types.js'; import type { AgentConfig } from './config.js'; import type { ResolvedExecPaths } from './sdk.js'; export declare const LAUNCH_SPEC_SCHEMA_VERSION = 1; export declare const DEFAULT_NODE_ARGS: readonly ["--max-old-space-size=4096"]; export type LaunchMode = 'foreground' | 'daemon'; export type LaunchHostType = 'standalone' | 'systemd' | 'launchd' | 'windows-startup' | 'winsw'; export interface LaunchSpecConfig { server: string; dir: string; name: string; deviceName?: string; password?: string; entra: boolean; msentra: boolean; entraClientId?: string; entraTenantId?: string; agent: BackendType; msInternal: boolean; } export interface LaunchSpec { schemaVersion: 1; createdAt: string; mode: LaunchMode; host: { type: LaunchHostType; }; config: LaunchSpecConfig; runtime: { ephemeral: boolean; pidFile: string | null; nodeArgs: string[]; resolvedExecPaths: ResolvedExecPaths; }; } export interface LaunchSpecContext { mode: LaunchMode; ephemeral?: boolean; pidFile?: string | null; hostType?: LaunchHostType; nodeArgs?: readonly string[]; resolvedExecPaths?: ResolvedExecPaths; createdAt?: string; } export declare function getLaunchSpecPath(): string; export declare function getLaunchSpecSnapshotPath(): string; export declare function getServiceLaunchSpecPath(): string; export declare function getServiceLaunchHost(platform?: NodeJS.Platform): { hostType: LaunchHostType; mode: LaunchMode; }; export declare function createServiceLaunchSpec(source: LaunchSpec, platform?: NodeJS.Platform): LaunchSpec; export declare function saveServiceLaunchSpec(source: LaunchSpec, platform?: NodeJS.Platform): { path: string; spec: LaunchSpec; }; export declare function computeLaunchSpecDigest(spec: LaunchSpec): string; export declare function detectLaunchHostType(): LaunchHostType; export declare function createLaunchSpec(config: AgentConfig, context: LaunchSpecContext): LaunchSpec; export declare function validateLaunchSpec(value: unknown): LaunchSpec; export declare function saveLaunchSpec(spec: LaunchSpec, filePath?: string): string; export declare function saveLaunchSpecSnapshot(spec: LaunchSpec): string; export declare function loadLaunchSpec(filePath?: string): LaunchSpec;