Skip to main content

Module browser

Module browser 

Source
Expand description

Browser management for browser automation.

This module provides utilities for:

  • Launching browser instances
  • Navigation operations

Re-exports§

pub use browser_process::BrowserProcess;
pub use cdp_endpoint::fetch_cdp_version;
pub use cdp_endpoint::read_dev_tools_active_port;
pub use cdp_endpoint::wait_for_cdp_endpoint;
pub use cdp_endpoint::CdpEndpointRequest;
pub use chromiumoxide_adapter::ChromiumoxidePage;
pub use connector::connect_browser;
pub use connector::ConnectOptions;
pub use debugging_port::assert_fixed_debugging_port;
pub use debugging_port::reserve_loopback_port;
pub use debugging_port::PortRaceError;
pub use launcher::launch_browser;
pub use launcher::Browser;
pub use launcher::LaunchMode;
pub use launcher::LaunchOptions;
pub use launcher::LaunchResult;
pub use launcher::LAUNCH_MODES;
pub use media::emulate_media;
pub use media::ColorScheme;
pub use media::EmulateMediaOptions;
pub use navigation_ops::goto;
pub use navigation_ops::verify_navigation;
pub use navigation_ops::wait_for_navigation;
pub use navigation_ops::wait_for_url_stabilization;
pub use navigation_ops::NavigationOptions;
pub use navigation_ops::NavigationResult;
pub use navigation_ops::NavigationVerificationResult;
pub use navigation_ops::WaitUntil;
pub use node_bridge::NodeBridgePage;
pub use open_in_user_browser::build_open_command;
pub use open_in_user_browser::open_in_user_browser;
pub use open_in_user_browser::validate_open_url;
pub use open_in_user_browser::OpenInUserBrowserResult;
pub use profile_directory::create_temporary_user_data_dir;
pub use profile_directory::prepare_user_data_dir;
pub use profile_directory::remove_user_data_dir;
pub use raw_cdp::RawCdpCommand;
pub use real_browser::build_real_browser_args;
pub use real_browser::launch_and_connect_real_browser;
pub use real_browser::launch_real_browser;
pub use real_browser::resolve_system_browser_executable;
pub use real_browser::RealBrowserLaunchResult;
pub use real_browser::RealBrowserOptions;
pub use real_browser::DEFAULT_CLOSE_TIMEOUT;
pub use real_browser::DEFAULT_PORT_ATTEMPTS;
pub use restrictions::launch_restriction_preset;
pub use restrictions::launch_restriction_presets;
pub use restrictions::launch_restrictions;
pub use restrictions::merge_feature_switches;
pub use restrictions::resolve_restrictions;
pub use restrictions::LaunchRestriction;
pub use restrictions::ResolvedRestrictions;
pub use restrictions::LAUNCH_RESTRICTIONS_SOURCE;
pub use system_browser::assert_dedicated_user_data_dir;
pub use system_browser::default_real_browser_user_data_dir;
pub use system_browser::known_default_user_data_dirs;
pub use system_browser::resolve_browser_executable;

Modules§

browser_process
The spawned browser process handle shared by the real-browser launcher and LaunchResult.
cdp_endpoint
Waiting for a spawned browser’s DevTools endpoint and proving it is ours (issue #101).
chromiumoxide_adapter
Chromiumoxide-backed EngineAdapter implementation.
connector
Connect to an already-running Chromium-family browser over CDP.
debugging_port
Fixed remote debugging ports for the real browser (issue #101).
launcher
Browser launcher for browser automation.
media
Media emulation for browser automation.
migration
Profile migration, mirroring js/src/browser/migration/index.js.
navigation_ops
Navigation operations for browser automation.
node_bridge
Node.js CLI bridge for Playwright and Puppeteer engines.
open_in_user_browser
Open a URL with the operating system’s default browser, without automation.
profile_directory
Fresh user data directories for every launch (issues #101 and #103).
raw_cdp
Sending a CDP command chromiumoxide has no generated type for.
real_browser
Launch genuine installed Chrome-family browsers and attach over CDP.
restrictions
Named, opt-in launch restrictions (issue #103).
system_browser
Discovery of installed Chrome-family browsers and their default profiles.

Structs§

BrowserCookie
A browser cookie in the shape accepted by Playwright/Puppeteer contexts.
BrowserCookieReadOptions
Options for read_browser_cookies.
BrowserProfile
Metadata for a cookie-bearing installed browser profile.
BrowserProfileOptions
Options for list_browser_profiles.

Constants§

SUPPORTED_COOKIE_BROWSERS
Browsers whose on-disk cookie stores can be imported.

Functions§

clear_browser_cookie_memory_cache
Clear only the current process’s derived-key cache.
list_browser_profiles
Discover cookie-bearing profiles for Chrome, Edge, Brave, Chromium, and Firefox.
read_browser_cookies
Read cookies from an installed Chrome, Edge, Brave, Chromium, or Firefox profile.