Skip to main content

Commands

Enum Commands 

Source
pub enum Commands {
Show 59 variants Doctor { offline: bool, quick: bool, fix: bool, json: bool, }, Commands { json: bool, }, Schema { cmd: Option<String>, cmd_positional: Option<String>, }, Version, Goto { url: String, init_script: Option<String>, handle_before_unload: Option<BeforeUnloadAction>, navigation_timeout_ms: Option<u64>, }, View { verbose: bool, path: Option<PathBuf>, allow_empty: bool, }, Press { target: String, dblclick: bool, include_snapshot: bool, }, ClickAt { x: f64, y: f64, dblclick: bool, include_snapshot: bool, }, Write { target: String, value: String, include_snapshot: bool, }, Keys { key: String, include_snapshot: bool, }, Type { text: String, target: Option<String>, clear: bool, submit: Option<String>, focus_only: bool, }, Wait { ms: u64, text: Vec<String>, selector: Option<String>, state: Option<String>, wait_timeout_ms: Option<u64>, include_snapshot: bool, }, Hover { target: String, include_snapshot: bool, }, Drag { from: String, to: String, include_snapshot: bool, }, FillForm { json: String, include_snapshot: bool, }, Upload { target: String, path: PathBuf, include_snapshot: bool, }, Back, Forward, Reload { ignore_cache: bool, init_script: Option<String>, handle_before_unload: Option<BeforeUnloadAction>, }, Eval { expression: String, args: Option<String>, dialog_action: Option<String>, file_path: Option<PathBuf>, service_worker_id: Option<String>, }, Grab { path: Option<PathBuf>, format: GrabFormat, full_page: bool, quality: Option<i32>, element: Option<String>, }, PrintPdf { path: Option<PathBuf>, url: Option<String>, }, Monitor { action: MonitorAction, }, Run { script: PathBuf, }, Exec { args: Vec<String>, }, Extract { target: String, attr: Option<String>, llm: bool, question: Option<String>, schema_json: Option<PathBuf>, }, Text { target: String, }, Scroll { target: Option<String>, delta_x: f64, delta_y: f64, }, Cookie { action: CookieAction, }, Attr { target: String, name: String, }, Assert { kind: AssertKind, }, Console { action: ConsoleAction, }, Net { action: NetAction, }, Page { action: Option<PageAction>, }, Dialog { action: DialogAction, }, Scrape { url: String, format: Vec<String>, engine: String, only_main_content: bool, webhook_url: Option<String>, }, BatchScrape { urls_file: PathBuf, format: String, concurrency: usize, engine: String, }, Crawl { url: String, limit: usize, max_depth: usize, format: String, same_host: bool, engine: String, }, Map { url: String, limit: usize, max_depth: usize, }, Search { query: String, limit: usize, }, Parse { path: PathBuf, redact_pii: bool, }, Qr { action: QrAction, }, FindPaths { pattern: Option<String>, paths: Vec<String>, extension: Option<String>, hidden: bool, no_ignore: bool, max_depth: Option<usize>, entry_type: Option<String>, limit: usize, glob: Option<String>, }, SgScan { paths: Vec<String>, limit: usize, }, SgRewrite { paths: Vec<String>, apply: bool, }, SheetWrite { input: PathBuf, out: PathBuf, sheet: String, }, Mitm { action: MitmAction, }, Workflow { action: WorkflowAction, }, Config { action: ConfigAction, }, Emulate { user_agent: Option<String>, locale: Option<String>, timezone: Option<String>, offline: bool, latitude: Option<f64>, longitude: Option<f64>, media: Option<String>, network_conditions: Option<String>, cpu_throttling_rate: Option<f64>, color_scheme: Option<String>, extra_headers: Option<String>, viewport: Option<String>, }, Resize { width: i32, height: i32, scale: f64, mobile: bool, }, Perf { action: PerfAction, }, Lighthouse { url: String, out_dir: Option<PathBuf>, device: String, mode: String, lighthouse_path: Option<PathBuf>, }, Screencast { action: ScreencastAction, }, Heap { action: HeapAction, }, Extension { action: ExtensionAction, }, Devtools3p { action: Devtools3pAction, }, Webmcp { action: WebmcpAction, }, Completions { shell: CompletionShell, },
}

Variants§

§

Doctor

Diagnose Chrome install and one-shot readiness

Fields

§offline: bool
§quick: bool
§fix: bool
§json: bool
§

Commands

List available commands

Fields

§json: bool
§

Schema

JSON Schema fragment for a command (agent discovery) GAP-022: accepts schema run or schema --cmd run.

Fields

§cmd: Option<String>

Command name via –cmd

§cmd_positional: Option<String>

Command name as positional (preferred agent UX)

§

Version

Print CLI version

§

Goto

Navigate to a URL (one-shot)

Fields

§init_script: Option<String>

JS to evaluate before navigation (tool-ref initScript)

§handle_before_unload: Option<BeforeUnloadAction>

Auto-handle beforeunload: accept | dismiss (GAP-003; flag alone = accept)

§navigation_timeout_ms: Option<u64>

Navigation timeout override in milliseconds

§

View

Accessibility snapshot with @eN refs

Fields

§verbose: bool
§allow_empty: bool

Allow empty about:blank snapshots (GAP-012)

§

Press

Click an element (selector or @eN)

Fields

§target: String
§dblclick: bool
§include_snapshot: bool

Attach slim a11y snapshot in the same process after the action

§

ClickAt

Click at page CSS coordinates (requires –experimental-vision)

Fields

§dblclick: bool
§include_snapshot: bool

Attach slim a11y snapshot after the click

§

Write

Fill an input value (select/checkbox/radio/text smart fill)

Fields

§target: String
§value: String
§include_snapshot: bool

Attach slim a11y snapshot after fill

§

Keys

Press a keyboard key

Fields

§include_snapshot: bool

Attach slim a11y snapshot after the key press

§

Type

Type text (tool-ref type_text). Use –target or –focus-only.

Fields

§text: String

Text to type (required positional)

§target: Option<String>

CSS selector or @eN (optional; use –focus-only for focused element)

§clear: bool
§submit: Option<String>

Optional key to press after typing (e.g. Enter)

§focus_only: bool

Type into currently focused element without resolving a target

§

Wait

Wait for ms and/or text and/or selector and/or load state

Fields

§ms: u64
§text: Vec<String>

Text to wait for (repeatable; resolves when any value appears — tool-ref OR)

§selector: Option<String>
§state: Option<String>

Page lifecycle: load | domcontentloaded | networkidle | none

§wait_timeout_ms: Option<u64>

Max wait time in milliseconds for text/selector/state (0 = default)

§include_snapshot: bool

Attach slim a11y snapshot after the wait succeeds

§

Hover

Hover an element

Fields

§target: String
§include_snapshot: bool

Attach slim a11y snapshot after hover

§

Drag

Drag from one target to another

Fields

§from: String
§include_snapshot: bool

Attach slim a11y snapshot after drag

§

FillForm

Fill multiple form fields from JSON [{target|uid,value},...]

Fields

§json: String
§include_snapshot: bool

Attach slim a11y snapshot after fill-form

§

Upload

Upload a file to a file input

Fields

§target: String
§path: PathBuf
§include_snapshot: bool

Attach slim a11y snapshot after upload

§

Back

History back

§

Forward

History forward

§

Reload

Reload current page

Fields

§ignore_cache: bool
§init_script: Option<String>

JS to run before navigation/reload (tool-ref initScript)

§handle_before_unload: Option<BeforeUnloadAction>

Auto-handle beforeunload: accept | dismiss (GAP-003; flag alone = accept)

§

Eval

Evaluate JavaScript (expression or function declaration)

Fields

§expression: String

JS expression or function declaration () => ...

§args: Option<String>

Snapshot uids (@eN) passed as function args (JSON array of strings)

§dialog_action: Option<String>

accept | dismiss | prompt response text (default accept)

§file_path: Option<PathBuf>

Write evaluate result JSON to this path

§service_worker_id: Option<String>

Evaluate inside an extension service worker target (tool-ref serviceWorkerId)

§

Grab

Capture a screenshot

Fields

§format: GrabFormat
§full_page: bool
§quality: Option<i32>
§element: Option<String>

CSS selector or @eN element to capture

§

PrintPdf

Print current page to PDF via CDP Page.printToPDF (one-shot)

Fields

§path: Option<PathBuf>

Output path for the PDF artifact

§url: Option<String>

Optional URL to navigate before printing (one-shot)

§

Monitor

One-shot change check against a baseline file (hash/text)

Fields

§

Run

Run multi-step NDJSON script in one process

Fields

§script: PathBuf
§

Exec

Single-step inline command (same surface as run steps: goto, wait, view, press, …)

Fields

§args: Vec<String>
§

Extract

Extract text/attribute from a target, or LLM extract with –llm

Fields

§target: String

Selector, @eN ref, about:blank target, or http(s) URL for LLM/text path

§llm: bool

Opt-in LLM HTTP extract (requires XDG openrouter_api_key)

§question: Option<String>

Question for LLM extract

§schema_json: Option<PathBuf>

Path to JSON schema file for structured LLM extract

§

Text

Extract visible text from a target (PRD §7 text)

Fields

§target: String
§

Scroll

Scroll page or element by delta pixels (PRD §7 scroll)

Fields

§target: Option<String>

CSS selector or @eN (optional; omit for window scroll)

§delta_x: f64
§delta_y: f64
§

Cookie

Cookie jar helpers for the active page (Network domain)

Fields

§

Attr

Read one attribute from a target

Fields

§target: String
§name: String
§

Assert

Assertions (url / text / console)

Fields

§

Console

Captured console messages (–capture-console)

Fields

§

Net

Captured network requests (–capture-network)

Fields

§action: NetAction
§

Page

Page info or multi-tab management

Fields

§

Dialog

Accept or dismiss dialogs

Fields

§

Scrape

Navigate and return body text / formats (local HTTP or CDP scrape)

Fields

§format: Vec<String>

text | markdown | html | links | metadata | … (CSV or repeatable; alias –formats)

§engine: String

http (reqwest+scraper) or browser (CDP)

§only_main_content: bool

Prefer main/article content heuristics

§webhook_url: Option<String>

Optional one-shot webhook POST of the result envelope data (127.0.0.1/operator URL)

§

BatchScrape

Scrape many URLs from a file (HTTP or browser engine, one-shot)

Fields

§urls_file: PathBuf
§format: String
§concurrency: usize
§engine: String

http (default) or browser (CDP per URL; GAP-010)

§

Crawl

Crawl from a seed URL (HTTP BFS or browser, one-shot)

Fields

§limit: usize
§max_depth: usize
§format: String
§same_host: bool

Stay on seed host

§engine: String

http (default) or browser (GAP-010)

§

Map

Map site URLs from a seed (HTTP)

Fields

§limit: usize
§max_depth: usize
§

Search

Local search (HTTP SERP links or URL map)

Fields

§query: String
§limit: usize
§

Parse

Parse a local file (html/md/txt/pdf/docx/xlsx text extract)

Fields

§path: PathBuf
§redact_pii: bool

Mask email/phone/card-like patterns in text output

§

Qr

QR encode/decode one-shot (no Chrome)

Fields

§action: QrAction
§

FindPaths

Discover filesystem paths (fd-like UX; binary remains browser-automation-cli)

Fields

§pattern: Option<String>

Regex pattern on name/path (optional)

§paths: Vec<String>

Root paths to search

§extension: Option<String>

Filter by extension (e.g. rs, html)

§hidden: bool

Include hidden files

§no_ignore: bool

Do not respect .gitignore

§max_depth: Option<usize>

Max directory depth

§entry_type: Option<String>

Entry type: f|d

§limit: usize

Max results

§glob: Option<String>

Shell-style glob filter (e.g. **/*.rs) — GAP-A011 / §5AE

§

SgScan

Structural lint scan for forbidden product patterns (one-shot; §5AC / GAP-A011)

Fields

§paths: Vec<String>

Roots to scan (default: .)

§limit: usize

Max findings (0 = unlimited)

§

SgRewrite

Structural rewrite for known-safe fixes (dry-run default; --apply writes)

Fields

§paths: Vec<String>

Roots to rewrite (default: .)

§apply: bool

Apply changes (default is dry-run report only)

§

SheetWrite

Write a simple XLSX workbook from CSV/JSON (one-shot; §5Z / GAP-A011)

Fields

§input: PathBuf

Input path (.csv or .json array-of-objects)

§out: PathBuf

Output .xlsx path

§sheet: String

Worksheet name

§

Mitm

MITM capture / CA / HAR (one-shot local)

Fields

§action: MitmAction
§

Workflow

Workflow journal DAG (petgraph + SQLite)

Fields

§

Config

XDG config and path management (no .env at runtime)

Fields

§

Emulate

Emulate device / network / UA / geo / CPU

Fields

§user_agent: Option<String>
§locale: Option<String>
§timezone: Option<String>
§offline: bool
§latitude: Option<f64>
§longitude: Option<f64>
§network_conditions: Option<String>

Network preset: Offline, No throttling, Slow 3G, Fast 3G, Slow 4G, Fast 4G

§cpu_throttling_rate: Option<f64>

CPU slowdown factor 1..=20 (1 disables)

§color_scheme: Option<String>

prefers-color-scheme: dark | light | auto

§extra_headers: Option<String>

Extra HTTP headers as JSON object string

§viewport: Option<String>

Viewport WxHxDPR with optional ,mobile, ,touch, ,landscape flags

§

Resize

Resize page viewport

Fields

§width: i32
§height: i32
§scale: f64
§mobile: bool
§

Perf

Performance trace / metrics

Fields

§action: PerfAction
§

Lighthouse

Run Lighthouse audit (external binary)

Fields

§out_dir: Option<PathBuf>
§device: String
§mode: String

navigation (default) or snapshot (maps to navigation in one-shot CLI)

§lighthouse_path: Option<PathBuf>
§

Screencast

Screencast start/stop (experimental)

Fields

§

Heap

Heap snapshot tools (requires –category-memory for deep analysis)

Fields

§action: HeapAction
§

Extension

Chrome extension tools (requires –category-extensions)

Fields

§

Devtools3p

Third-party developer tools surface (requires –category-third-party)

Fields

§

Webmcp

Web surface tools (requires –category-webmcp)

Fields

§

Completions

Generate shell completions (path leve, no Chrome)

Fields

Trait Implementations§

Source§

impl Debug for Commands

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl FromArgMatches for Commands

Source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from ArgMatches, parsing the arguments as needed. Read more
Source§

fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>

Instantiate Self from ArgMatches, parsing the arguments as needed. Read more
Source§

fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>

Assign values from ArgMatches to self.
Source§

fn update_from_arg_matches_mut<'b>( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>

Assign values from ArgMatches to self.
Source§

impl Subcommand for Commands

Source§

fn augment_subcommands<'b>(__clap_app: Command) -> Command

Append to Command so it can instantiate Self via FromArgMatches::from_arg_matches_mut Read more
Source§

fn augment_subcommands_for_update<'b>(__clap_app: Command) -> Command

Append to Command so it can instantiate self via FromArgMatches::update_from_arg_matches_mut Read more
Source§

fn has_subcommand(__clap_name: &str) -> bool

Test whether Self can parse a specific subcommand

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<'a, T, E> AsTaggedExplicit<'a, E> for T
where T: 'a,

Source§

fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

Source§

impl<'a, T, E> AsTaggedImplicit<'a, E> for T
where T: 'a,

Source§

fn implicit( self, class: Class, constructed: bool, tag: u32, ) -> TaggedParser<'a, Implicit, Self, E>

Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<A, B, T> HttpServerConnExec<A, B> for T
where B: Body,

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T> PolicyExt for T
where T: ?Sized,

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more