All SkillsGet Started Free
Browser Trace
Capture a full DevTools-protocol trace of any browser automation — CDP firehose, screenshots, and DOM dumps — then bisect the stream into per-page searchable buckets. Use when the user wants to debug a failed run, audit network/console/DOM activity, attach a trace to an in-progress session, or feed structured per-page summaries back into an agent loop so its next iteration learns from the last one.
MCP get_skill({ skillId: "browser-trace-a21656f7" })Use this skill with your agent
Create a free account and connect via MCP
# Browser Trace Attach a **second, read-only CDP client** to a browser session that is already being driven by your main automation. The trace records the full DevTools firehose to NDJSON, polls for screenshots and DOM dumps in parallel, and slices everything into a directory tree that bash tools can search. This skill does **not** drive pages — it only listens. Pair it with the `browser` skill, `browse`, Stagehand, Playwright, or anything else that speaks CDP. ## When to use - The user wants to debug a browser-automation run (failing form, missing element, hung navigation, JS exception). - The user has a running automation and wants to attach a trace mid-flight without restarting it. - The user wants to split a CDP firehose into network / console / DOM / page buckets. - The user wants screenshots + DOM snapshots over time, joined to CDP events by timestamp. If the user just wants to **drive** the browser, use the `browser` skill instead. ## Setup check ```bash node --version # require Node 18+ which browse || npm install -g browse which jq || true # optional — used only for ad-hoc querying ``` Verify `browse cdp` exists: ```bash browse --help | grep -q "^\s*cdp " || echo "browse cdp not available — update browse" ``` ## How it works Every Chrome DevTools target accepts **multiple concurrent CDP clients**. Your main automation is one client; this skill adds a second one that only enables observation domains (Network, Console, Runtime, Log, Page) and never sends action commands. The tracer has three pieces: 1. **Firehose**: `browse cdp <target>` streams every CDP event as one JSON object per line to `cdp/raw.ndjson`. 2. **Sampler**: a polling loop calls `browse screenshot --cdp <target> --path <file>` and `browse get html body --cdp <target>` on an interval (default 2s). The helper passes `--cdp` when it samples so it can attach to the traced target from its own process; once a browse daemon session is attached to a CDP target, follow-up commands in that session do not need to repeat `--cdp`. 3. **Bisector**: after the run, `bisect-cdp.mjs` walks `raw.ndjson` once, slices it into per-bucket JSONL files keyed by CDP method, and additionally bisects per page using top-level `Page.frameNavigated` events as boundaries. ## Quickstart ### Local Chrome ```bash # 1. Launch Chrome with a debugger port (any user-data-dir keeps it isolated). "/Applications/Google Chrome.app/Contents/MacOS/Google Chrome" \ --remote-debugging-port=9222 \ --user-data-dir=/tmp/chrome-o11y \ about:blank &
#broad-capability#browser-automation#web-search#headless-chrome#browser#automationnodejsbrowse