Releases: aeroxy/chrome-devtools-cli
chrome-devtools-cli v0.1.2
This release focuses on significantly improving reliability, interaction robustness, and the Developer/AI Agent Experience (Agent UX).
What's new
- Agent UX & Help Improvements: Automatically dumps the full help menu to stderr on invalid commands, preventing AI agents from wasting tokens on "guess-and-check" loops.
- In-band Agent Hints: The
evaluatecommand now detects common DOM traversal scripts (querySelector, etc.) and JavaScript exceptions, providing dynamic hints to use the token-efficientsnapshot,click, andfillcommands instead. - Rock-solid Daemon: The background daemon now binds its Unix socket instantly and connects to Chrome lazily. This eliminates timeouts caused by macOS "Allow Incoming Network Connections" dialogs. The daemon also automatically shuts down and recovers if Chrome crashes or the WebSocket closes.
- Advanced Form Filling: The
fillcommand natively handles<select>dropdowns (by value or text) and toggles<input type="checkbox">and<input type="radio">using"true"/"false"strings. - Global Dialog Prevention: Proactively detects open JavaScript dialogs (alerts, confirms). Commands like
clickorfillwill now fail immediately with a helpful error rather than hanging indefinitely, andevaluatesuggests using--dialog-action.
chrome-devtools-cli v0.1.1
This release introduces new interaction capabilities and improves asynchronous event handling.
What's new
- Coordinate clicking: New
click-at <x> <y>command for precise interaction when element selectors aren't sufficient. - Auto-dialog handling: New
--dialog-action <accept|dismiss|text>flag for theevaluatecommand to automatically handle JavaScript alerts, confirms, and prompts. - Enhanced typing: Added
--submit-key <key>flag totype-textto press keys likeEnterorTabimmediately after typing. - Asynchronous events: Refactored the internal CDP client to support listening for protocol events (like dialogs) during command execution.
Core benefits
- Native performance: Lightweight native binary with zero runtime dependencies.
- Agent-first architecture: Deterministic
[target:word-pair]page pinning and accessibility treesnapshotcommand for low-token-cost context. - Persistent connection: Background daemon maintains a single WebSocket connection to Chrome.
chrome-devtools-cli v0.1.0
Control Chrome from the terminal.
How it works
The CLI auto-connects to an existing Chrome browser by reading DevToolsActivePort from Chrome's user data directory — no manual WebSocket URL needed. On first run it spawns a background daemon that holds a persistent connection, so Chrome only prompts for DevTools access once. Subsequent commands reuse that connection with near-zero latency.
Page targeting
Every command prints a [target:red-snake]-style name — a deterministic word-pair derived from the page's internal ID. Pass --target red-snake to subsequent commands to stay on the same tab regardless of how Chrome reorders its pages.
Commands
Navigation: navigate, navigate --back/--forward/--reload, new-page, close-page, select-page, list-pages
Inspection: screenshot, screenshot --full-page, evaluate, snapshot
Interaction: click, fill, type-text, press-key, hover
Viewport: resize, wait-for
Prerequisites
Enable remote debugging in Chrome: open chrome://inspect/#remote-debugging and turn on the remote debugging server.
Installation
Homebrew (macOS)
brew tap aeroxy/chrome-devtools-cli
brew install chrome-devtoolsCargo
cargo install chrome-devtools-cliBuild from source
cargo build --release