import { Tt as BrowserProfileConfig, r as DexConfig, wt as BrowserConfig } from "./types.openclaw-Brl_kTLA.js";
import { o as SsrFPolicy } from "./ssrf-skjEI_i5.js";
//#region src/plugin-sdk/browser-profiles.d.ts
declare const DEFAULT_DEX_BROWSER_ENABLED = true;
declare const DEFAULT_BROWSER_EVALUATE_ENABLED = true;
declare const DEFAULT_DEX_BROWSER_COLOR = "#FF4500";
declare const DEFAULT_DEX_BROWSER_PROFILE_NAME = "openclaw";
declare const DEFAULT_BROWSER_DEFAULT_PROFILE_NAME = "openclaw";
declare const DEFAULT_BROWSER_ACTION_TIMEOUT_MS = 60000;
declare const DEFAULT_AI_SNAPSHOT_MAX_CHARS = 80000;
declare const DEFAULT_UPLOAD_DIR: string;
type ResolvedBrowserTabCleanupConfig = {
  enabled: boolean;
  idleMinutes: number;
  maxTabsPerSession: number;
  sweepMinutes: number;
};
type ResolvedBrowserConfig = {
  enabled: boolean;
  evaluateEnabled: boolean;
  controlPort: number;
  cdpPortRangeStart: number;
  cdpPortRangeEnd: number;
  cdpProtocol: "http" | "https";
  cdpHost: string;
  cdpIsLoopback: boolean;
  remoteCdpTimeoutMs: number;
  remoteCdpHandshakeTimeoutMs: number;
  localLaunchTimeoutMs: number;
  localCdpReadyTimeoutMs: number;
  actionTimeoutMs: number;
  color: string;
  executablePath?: string;
  headless: boolean;
  noSandbox: boolean;
  attachOnly: boolean;
  defaultProfile: string;
  profiles: Record<string, BrowserProfileConfig>;
  tabCleanup: ResolvedBrowserTabCleanupConfig;
  ssrfPolicy?: SsrFPolicy;
  extraArgs: string[];
};
type ResolvedBrowserProfile = {
  name: string;
  cdpPort: number;
  cdpUrl: string;
  cdpHost: string;
  cdpIsLoopback: boolean;
  userDataDir?: string;
  color: string;
  driver: "openclaw" | "existing-session";
  headless?: boolean;
  attachOnly: boolean;
};
declare function resolveBrowserConfig(cfg: BrowserConfig | undefined, rootConfig?: DexConfig): ResolvedBrowserConfig;
declare function resolveProfile(resolved: ResolvedBrowserConfig, profileName: string): ResolvedBrowserProfile | null;
//#endregion
//#region src/plugin-sdk/browser-cdp.d.ts
declare function parseBrowserHttpUrl(raw: string, label: string): {
  parsed: URL;
  port: number;
  hasExplicitPort: boolean;
  normalized: string;
  normalizedWithPort: string;
};
declare function redactCdpUrl(cdpUrl: string | null | undefined): string | null | undefined;
//#endregion
//#region src/plugin-sdk/browser-control-auth.d.ts
type BrowserControlAuth = {
  token?: string;
  password?: string;
};
type EnsureBrowserControlAuthParams = {
  cfg: DexConfig;
  env?: NodeJS.ProcessEnv;
};
type EnsureBrowserControlAuthResult = {
  auth: BrowserControlAuth;
  generatedToken?: string;
};
declare function resolveBrowserControlAuth(cfg?: DexConfig, env?: NodeJS.ProcessEnv): BrowserControlAuth;
declare function ensureBrowserControlAuth(params: EnsureBrowserControlAuthParams): Promise<EnsureBrowserControlAuthResult>;
//#endregion
export { resolveBrowserConfig as _, redactCdpUrl as a, DEFAULT_BROWSER_DEFAULT_PROFILE_NAME as c, DEFAULT_DEX_BROWSER_ENABLED as d, DEFAULT_DEX_BROWSER_PROFILE_NAME as f, ResolvedBrowserTabCleanupConfig as g, ResolvedBrowserProfile as h, parseBrowserHttpUrl as i, DEFAULT_BROWSER_EVALUATE_ENABLED as l, ResolvedBrowserConfig as m, ensureBrowserControlAuth as n, DEFAULT_AI_SNAPSHOT_MAX_CHARS as o, DEFAULT_UPLOAD_DIR as p, resolveBrowserControlAuth as r, DEFAULT_BROWSER_ACTION_TIMEOUT_MS as s, BrowserControlAuth as t, DEFAULT_DEX_BROWSER_COLOR as u, resolveProfile as v };