A Playwright browser for Claude Code, packaged as a skill.
bin/pw(bin/pw.cmdon Windows shells) wraps Microsoft's@playwright/cli. It gives you a live, named browser session that you drive one command at a time (open,snapshot,click,fill,screenshot,console,requests, …). It's pinned to the repo's bundled Chromium, and its output goes to.out/.bin/run.mjsis a one-shot script runner. A script default-exportsasync ({ page, context, browser, playwright, args, out }) => result. The runner launches the browser, runs the script, prints the result as JSON and closes the browser. Scripts don't import Playwright, so they can live anywhere.bin/ytdl(bin/ytdl.cmdon Windows shells) wraps a standalone yt-dlp build invendor/for downloading video and audio. Downloads go to.out/downloads/. It needs ffmpeg on PATH for merging and converting (winget install ffmpeg/brew install ffmpeg).skills/browser/is the Claude Code skill. It explains when to use each tool and includes Microsoft's officialplaywright-clidocs inreference/.
npm run setup # npm ci + download the CLI's Chromium build + sync reference docs + download yt-dlp
npm run install-skill # junction skills/browser -> ~/.claude/skills/browser
npm run smoke # end-to-end check via run.mjsRequires Node 18+. The skill's paths assume the repo lives at D:/BrowserUtility.
playwright is pinned to the exact version @playwright/cli depends on, so only one Playwright install and one Chromium build are needed. To upgrade:
npm view @playwright/cli dependencies # find its playwright version
npm install --save-exact @playwright/cli@<new> playwright@<matching>
npm run setup- microsoft/playwright-cli: the official agent CLI and skill. The
pwtool here builds on it. - lackeyjb/playwright-skill: a skill where the agent writes Playwright scripts and runs them through
run.js. It inspiredrun.mjs. - microsoft/playwright-mcp: an MCP server for the same features. The CLI and skill approach uses fewer tokens, because snapshots are saved to files instead of being included in every response.