/** * Browser/tab state for the long-lived MCP server process. Owns the single CDP * connection plus all attached page tabs and the active-tab pointer. * * Adapted from the `chrome-use` skill (skills/chrome-use/scripts/lib/session.ts), * with the cross-invocation /tmp active-file removed: the MCP server is a * long-lived process, so the active-tab pointer lives in memory here. */ import type { CdpClient, TabSession } from './types.js'; export declare class SessionManager { readonly cdp: CdpClient; readonly tabs: Map; activeTargetId: string | null; /** Sessions attached this connection, detached on dispose() to keep Chrome clean. */ private readonly attached; /** Monotonic counter for stable tab ids — a target keeps its id for the whole * connection so a cached `tN` never silently points at a different tab. */ private tabSeq; constructor(cdp: CdpClient); private pages; private attach; /** Detach every session this connection created (best-effort). */ dispose(): Promise; syncTabs(): Promise; getActiveTab(): Promise; getTab(idOrIndex: string): Promise; setActive(targetId: string): void; newTab(url?: string): Promise; closeTab(targetId: string): Promise; } //# sourceMappingURL=session.d.ts.map