devtools
SKILL.md
Use CDP at localhost:9222.
For exploration, use tmux with websocat, or wscat, or uv run --with playwright,markdownify,httpx,readability python -m asyncio (starts Python REPL with top-level await).
For automation, npm install playwright and code in node.
Capabilities:
- For DOM HTML to Markdown: turndown, markdownify, or
uvx markitdown file.html - Log progress via console:
page.on("console", msg => console.log("LOG:", msg.type(), msg.text())). Use CDP'sConsole.enablefor replay - Log screenshots via
(page||locator).screenshot({ path, fullPage, type, quality, ... }) - Intercept fetch/XHR, parse JSON directly, cache for repeat runs
- HAR traces:
context.tracing.start({ screenshots: true, snapshots: true })...context.tracing.stop({ path: "trace.zip" }) - Inject JS into existing tabs via a
blob:URL created in the page context. CSP may block inline scripts.url = URL.createObjectURL(new Blob([code], { type: "text/javascript" }))- Append
<script src="blob:..."> - Avoid
page.addScriptTag({content: ...})on CSP-heavy sites (e.g. WhatsApp, Google apps).
Uses: