import { Command } from 'commander'; type ExitFn = (code: number) => never; export interface CoreProjectPaths { projectRoot: string; dataDir: string; teamDir: string; dbPath?: string; projectId?: string; } export interface CoreTeamsConfig { team: string; autoSpawn?: boolean; agents: Array<{ name: string; cli: string; task?: string; }>; } export interface BridgeProject { id: string; path: string; leadName: string; cli?: string; } export interface SpawnedProcess { pid?: number; killed?: boolean; kill: (signal?: NodeJS.Signals | number) => void; unref?: () => void; } export interface CoreRelay { spawn: (input: { name: string; cli: string; channels: string[]; args?: string[]; task?: string; team?: string; shadowOf?: string; shadowMode?: 'subagent' | 'process'; }) => Promise; getStatus: () => Promise; shutdown: () => Promise; /** Relaycast workspace API key, available after the hello handshake. */ workspaceKey?: string; /** PID of the underlying broker process, when available. */ brokerPid?: number; } export interface CoreFileSystem { existsSync: (path: string) => boolean; readFileSync: (path: string, encoding: BufferEncoding) => string; writeFileSync: (path: string, data: string, encoding?: BufferEncoding) => void; unlinkSync: (path: string) => void; readdirSync: (path: string) => string[]; mkdirSync: (path: string, options?: { recursive?: boolean; }) => void; rmSync: (path: string, options?: { recursive?: boolean; force?: boolean; }) => void; accessSync: (path: string, mode?: number) => void; } type UpdateInfo = { updateAvailable: boolean; latestVersion?: string; error?: string; }; export interface CoreDependencies { getProjectPaths: () => CoreProjectPaths; loadTeamsConfig: (projectRoot: string) => CoreTeamsConfig | null; resolveBridgeProjects: (projectPaths: string[], cli?: string) => BridgeProject[]; validateBridgeBrokers: (projects: BridgeProject[]) => { valid: BridgeProject[]; missing: BridgeProject[]; }; getAgentOutboxTemplate: () => string; createRelay: (cwd: string, apiPort?: number, brokerName?: string) => CoreRelay | Promise; findDashboardBinary: () => string | null; spawnProcess: (command: string, args: string[], options?: Record) => SpawnedProcess; execCommand: (command: string) => Promise<{ stdout: string; stderr: string; }>; killProcess: (pid: number, signal?: NodeJS.Signals | number) => void; fs: CoreFileSystem; generateAgentName: () => string; checkForUpdates: (version: string) => Promise; getVersion: () => string; env: NodeJS.ProcessEnv; argv: string[]; execPath: string; cliScript: string; pid: number; now: () => number; sleep: (ms: number) => Promise; onSignal: (signal: NodeJS.Signals, handler: () => void | Promise) => void; holdOpen: () => Promise; resolveTemplatesDir: () => string; isPortInUse: (port: number) => Promise; findBrokerApiPort: () => Promise; log: (...args: unknown[]) => void; error: (...args: unknown[]) => void; warn: (...args: unknown[]) => void; exit: ExitFn; } export declare function registerCoreCommands(program: Command, overrides?: Partial): void; export {}; //# sourceMappingURL=core.d.ts.map