{
  "markdown": "# chrome-cdp\n\nLet your AI agent see and interact with your **live Chrome session** — the tabs you already have open, your logged-in accounts, your current page state. No browser automation framework, no separate browser instance, no re-login.\n\nWorks out of the box with any Chrome installation. One toggle to enable, nothing else to install.\n\n## Why this matters\n\nMost browser automation tools launch a fresh, isolated browser. This one connects to the Chrome you're already running, so your agent can:\n\n- Read pages you're logged into (Gmail, GitHub, internal tools, ...)\n- Interact with tabs you're actively working in\n- See the actual state of a page mid-workflow, not a clean reload\n\n## Installation\n\n### As a pi skill\n\n```bash\npi install git:github.com/pasky/chrome-cdp-skill@v1.0.1\n```\n\n### For other agents (Amp, Claude Code, Cursor, etc.)\n\nClone or copy the `skills/chrome-cdp/` directory wherever your agent loads skills or context from. The only runtime dependency is **Node.js 22+** — no npm install needed.\n\n### Enable remote debugging in Chrome\n\nNavigate to `chrome://inspect/#remote-debugging` and toggle the switch. That's it.\n\nThe CLI auto-detects Chrome, Chromium, Brave, Edge, and Vivaldi on macOS, Linux, and Windows. If your browser stores `DevToolsActivePort` in a non-standard location, set the `CDP_PORT_FILE` environment variable to the full path.\n\n## Usage\n\n```bash\nscripts/cdp.mjs list                              # list open tabs\nscripts/cdp.mjs shot   <target>                   # screenshot → runtime dir\nscripts/cdp.mjs snap   <target>                   # accessibility tree (compact, semantic)\nscripts/cdp.mjs html   <target> [\".selector\"]     # full HTML or scoped to CSS selector\nscripts/cdp.mjs eval   <target> \"expression\"      # evaluate JS in page context\nscripts/cdp.mjs nav    <target> https://...       # navigate and wait for load\nscripts/cdp.mjs net    <target>                   # network resource timing\nscripts/cdp.mjs click  <target> \"selector\"        # click element by CSS selector\nscripts/cdp.mjs clickxy <target> <x> <y>          # click at CSS pixel coordinates\nscripts/cdp.mjs type   <target> \"text\"            # type at focused element (works in cross-origin iframes)\nscripts/cdp.mjs loadall <target> \"selector\"       # click \"load more\" until gone\nscripts/cdp.mjs evalraw <target> <method> [json]  # raw CDP command passthrough\nscripts/cdp.mjs open   [url]                      # open new tab (triggers Allow prompt)\nscripts/cdp.mjs stop   [target]                   # stop daemon(s)\n```\n\n`<target>` is a unique prefix of the targetId shown by `list`.\n\n## Why not chrome-devtools-mcp?\n\n[chrome-devtools-mcp](https://github.com/ChromeDevTools/chrome-devtools-mcp) reconnects on every command, so Chrome's \"Allow debugging\" modal can re-appear repeatedly and target enumeration times out with many tabs open. `chrome-cdp` holds one persistent daemon per tab — the modal fires once, and it handles 100+ tabs reliably.\n\n## How it works\n\nConnects directly to Chrome's remote debugging WebSocket — no Puppeteer, no intermediary. On first access to a tab, a lightweight background daemon is spawned that holds the session open. Chrome's \"Allow debugging\" modal appears once per tab; subsequent commands reuse the daemon silently. Daemons auto-exit after 20 minutes of inactivity.\n\nThis approach is also why it handles 100+ open tabs reliably, where tools built on Puppeteer often time out during target enumeration.\n",
  "bytes": 3464,
  "sha": "7c6e33cb0ccad5e7af427c2e6fb6642fd52ce45674e50c13673c9940246c9754",
  "repo_slug": "pasky/chrome-cdp-skill",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/skl_pasky_chrome_cdp_skill_chrome_cdp_9b6e0452/readme"
}