export type BrowserId = "chrome" | "chrome-beta" | "chrome-canary" | "chrome-dev" | "msedge" | "msedge-beta" | "msedge-canary" | "msedge-dev" | "brave" | "brave-beta" | "brave-nightly" | "opera" | "opera-gx" | "opera-beta" | "vivaldi" | "arc" | "chromium" | "safari" | "safari-tp" | "firefox" | "firefox-dev" | "firefox-nightly" | "firefox-esr"; export type BrowserFamily = "chromium" | "webkit" | "gecko"; export interface InstalledBrowser { id: BrowserId; name: string; family: BrowserFamily; /** Absolute path to the executable (NOT the .app bundle). */ path: string; /** Best-effort ` --version` output. May be undefined if probe failed. */ version?: string; /** Whether OCC's interactive Portal mode (live CDP screencast) works on this binary. */ interactiveSupported: boolean; } export interface BrowserDetection { installed: InstalledBrowser[]; /** True if at least one chromium-family browser was detected. */ hasChromium: boolean; /** True if Playwright's bundled Chromium is reachable as a last-resort fallback. */ bundledChromiumAvailable: boolean; /** * User-facing warning, only set when interactive mode would be degraded. * Frontend shows this in the portal modal as a banner. */ warning?: string; /** Download URLs for browsers we recommend installing if none are found. */ installGuide: Record; } /** * Probe the filesystem for installed browsers. * * Behavior: * - Returns cached result if `force` is false and the cache hasn't expired. * - For each browser in the catalog, picks the first existing path. * - Best-effort version detection (parallel across binaries; per-binary 3s timeout). * - PORTAL_CHROME_PATH env var is treated as a manual override that always * wins, classified as `chrome` regardless of actual binary. */ export declare function detectInstalledBrowsers(opts?: { force?: boolean; withVersions?: boolean; }): Promise; /** Drop the cache so the next call re-probes the filesystem. */ export declare function clearBrowserCache(): void; /** * Look up a specific browser by id. Returns undefined if not installed. * Used by the portal session manager when the user picks a browser per node. */ export declare function findBrowserById(id: string): Promise; /** * Pick the best chromium-family browser to use as a default when the user * hasn't expressed a preference. Order: Chrome → Brave → Edge → Opera → * Vivaldi → Arc → Chromium. Returns undefined if none installed. */ export declare function pickDefaultChromium(): Promise;