{"id":"4bd1a5aa-5e0e-4660-ba2f-8420799d7586","shortId":"GPfUsL","kind":"skill","title":"playwright-cli","tagline":"Use when a task needs Playwright-backed browser automation from the shell: open or attach to browser sessions, inspect snapshots and element refs, click/type/fill forms, debug Playwright tests, inspect console/network/storage, run Playwright snippets, capture screenshots/traces/v","description":"# playwright-cli\n\n`playwright-cli` is a token-efficient shell interface to Playwright. It keeps browser state across commands, exposes page snapshots with stable element refs such as `e15`, and prints the Playwright code it ran so the interaction can be converted into tests.\n\n## Core Workflow\n\n```bash\nplaywright-cli open https://example.com\nplaywright-cli snapshot\nplaywright-cli click e15\nplaywright-cli fill e5 \"user@example.com\"\nplaywright-cli press Enter\nplaywright-cli close\n```\n\nUse refs from the latest snapshot by default. Re-run `snapshot` after navigation, major DOM changes, or a failed ref action. Use CSS selectors or Playwright locators only when refs are unavailable or unstable.\n\n## Operating Rules\n\n- Discover exact syntax with `playwright-cli --help` and `playwright-cli <command> --help`; the CLI changes quickly.\n- Use `--raw` when piping values into other tools. Use `--json` only if the installed CLI advertises it.\n- Use named sessions with `-s=<name>` for concurrent or long-lived work.\n- Use `open --persistent` only when disk-persisted cookies/storage are needed.\n- Prefer `attach --cdp=chrome`, `attach --cdp=msedge`, or `attach --cdp=http://127.0.0.1:9222` when the task needs an existing browser/session.\n- Close sessions when finished. Reserve `close-all` and `kill-all` for cleanup of stale sessions.\n\n## Common Tasks\n\n```bash\nplaywright-cli open https://example.com --browser=chrome\nplaywright-cli snapshot --depth=4\nplaywright-cli screenshot --filename=page.png\nplaywright-cli console warning\nplaywright-cli network --filter=\"/api/.*\" --request-headers\nplaywright-cli run-code \"async page => await page.context().grantPermissions(['geolocation'])\"\nplaywright-cli tracing-start\nplaywright-cli tracing-stop\n```\n\nFor a broader command map, read `references/cli-reference.md`.\n\n## Playwright Test Debugging\n\nWhen a Playwright test fails, prefer the CLI debug workflow:\n\n```bash\nPLAYWRIGHT_HTML_OPEN=never npx playwright test --debug=cli\n# wait for \"Debugging Instructions\", then attach to the printed session\nplaywright-cli attach tw-abcdef\n```\n\nKeep the test process running while inspecting the paused page. Use snapshots, console/network inspection, and generated Playwright code to identify the fix.\n\n## References\n\nLoad only what the task needs:\n\n- `references/cli-reference.md` — command groups, output modes, and version-sensitive features\n- `references/playwright-tests.md` — running and debugging Playwright tests\n- `references/request-mocking.md` — route mocking and request interception\n- `references/running-code.md` — custom Playwright snippets with `run-code`\n- `references/session-management.md` — named sessions and cleanup\n- `references/storage-state.md` — cookies, localStorage, sessionStorage, auth state\n- `references/test-generation.md` — turning CLI output into tests\n- `references/tracing.md` — trace capture and inspection\n- `references/video-recording.md` — WebM recording and chapter markers\n- `references/element-attributes.md` — inspect IDs/classes/data attributes not shown in snapshots","tags":["playwright","cli","webmaton","appautomaton","agent-skills","ai-agents","browser-automation","claude-code","codex","html-to-markdown","web-automation","web-scraping"],"capabilities":["skill","source-appautomaton","skill-playwright-cli","topic-agent-skills","topic-ai-agents","topic-browser-automation","topic-claude-code","topic-codex","topic-html-to-markdown","topic-playwright","topic-web-automation","topic-web-scraping"],"categories":["webmaton"],"synonyms":[],"warnings":[],"endpointUrl":"https://skills.sh/appautomaton/webmaton/playwright-cli","protocol":"skill","transport":"skills-sh","auth":{"type":"none","details":{"cli":"npx skills add appautomaton/webmaton","source_repo":"https://github.com/appautomaton/webmaton","install_from":"skills.sh"}},"qualityScore":"0.458","qualityRationale":"deterministic score 0.46 from registry signals: · indexed on github topic:agent-skills · 17 github stars · SKILL.md body (3,046 chars)","verified":false,"liveness":"unknown","lastLivenessCheck":null,"agentReviews":{"count":0,"score_avg":null,"cost_usd_avg":null,"success_rate":null,"latency_p50_ms":null,"narrative_summary":null,"summary_updated_at":null},"enrichmentModel":"deterministic:skill-github:v1","enrichmentVersion":1,"enrichedAt":"2026-05-18T19:06:02.684Z","embedding":null,"createdAt":"2026-05-06T01:03:38.647Z","updatedAt":"2026-05-18T19:06:02.684Z","lastSeenAt":"2026-05-18T19:06:02.684Z","tsv":"'/api':280 '127.0.0.1':222 '4':263 '9222':223 'abcdef':354 'across':59 'action':139 'advertis':187 'async':290 'attach':19,213,216,220,343,351 'attribut':445 'auth':423 'autom':13 'await':292 'back':11 'bash':88,250,328 'broader':310 'browser':12,21,57,256 'browser/session':230 'captur':38,433 'cdp':214,217,221 'chang':134,170 'chapter':440 'chrome':215,257 'cleanup':244,418 'cli':3,42,45,91,96,100,105,111,116,161,166,169,186,253,260,266,272,277,286,298,304,325,337,350,427 'click':101 'click/type/fill':28 'close':117,231,237 'close-al':236 'code':75,289,372,413 'command':60,311,385 'common':248 'concurr':195 'consol':273 'console/network':367 'console/network/storage':34 'convert':83 'cooki':420 'cookies/storage':209 'core':86 'css':141 'custom':407 'debug':30,317,326,336,340,397 'default':125 'depth':262 'discov':155 'disk':207 'disk-persist':206 'dom':133 'e15':70,102 'e5':107 'effici':50 'element':26,66 'enter':113 'exact':156 'example.com':93,255 'exist':229 'expos':61 'fail':137,322 'featur':393 'filenam':268 'fill':106 'filter':279 'finish':234 'fix':376 'form':29 'generat':370 'geoloc':295 'grantpermiss':294 'group':386 'header':283 'help':162,167 'html':330 'identifi':374 'ids/classes/data':444 'inspect':23,33,361,368,435,443 'instal':185 'instruct':341 'interact':80 'intercept':405 'interfac':52 'json':181 'keep':56,355 'kill':241 'kill-al':240 'latest':122 'live':199 'load':378 'localstorag':421 'locat':145 'long':198 'long-liv':197 'major':132 'map':312 'marker':441 'mock':402 'mode':388 'msedg':218 'name':190,415 'navig':131 'need':8,211,227,383 'network':278 'never':332 'npx':333 'open':17,92,202,254,331 'oper':153 'output':387,428 'page':62,291,364 'page.context':293 'page.png':269 'paus':363 'persist':203,208 'pipe':175 'playwright':2,10,31,36,41,44,54,74,90,95,99,104,110,115,144,160,165,252,259,265,271,276,285,297,303,315,320,329,334,349,371,398,408 'playwright-back':9 'playwright-c':1,40,43,89,94,98,103,109,114,159,164,251,258,264,270,275,284,296,302,348 'prefer':212,323 'press':112 'print':72,346 'process':358 'quick':171 'ran':77 'raw':173 're':127 're-run':126 'read':313 'record':438 'ref':27,67,119,138,148 'refer':377 'references/cli-reference.md':314,384 'references/element-attributes.md':442 'references/playwright-tests.md':394 'references/request-mocking.md':400 'references/running-code.md':406 'references/session-management.md':414 'references/storage-state.md':419 'references/test-generation.md':425 'references/tracing.md':431 'references/video-recording.md':436 'request':282,404 'request-head':281 'reserv':235 'rout':401 'rule':154 'run':35,128,288,359,395,412 'run-cod':287,411 'screenshot':267 'screenshots/traces/v':39 'selector':142 'sensit':392 'session':22,191,232,247,347,416 'sessionstorag':422 'shell':16,51 'shown':447 'skill' 'skill-playwright-cli' 'snapshot':24,63,97,123,129,261,366,449 'snippet':37,409 'source-appautomaton' 'stabl':65 'stale':246 'start':301 'state':58,424 'stop':307 'syntax':157 'task':7,226,249,382 'test':32,85,316,321,335,357,399,430 'token':49 'token-effici':48 'tool':179 'topic-agent-skills' 'topic-ai-agents' 'topic-browser-automation' 'topic-claude-code' 'topic-codex' 'topic-html-to-markdown' 'topic-playwright' 'topic-web-automation' 'topic-web-scraping' 'trace':300,306,432 'tracing-start':299 'tracing-stop':305 'turn':426 'tw':353 'tw-abcdef':352 'unavail':150 'unstabl':152 'use':4,118,140,172,180,189,201,365 'user@example.com':108 'valu':176 'version':391 'version-sensit':390 'wait':338 'warn':274 'webm':437 'work':200 'workflow':87,327","prices":[{"id":"15b9fa68-3733-485c-a018-163d7eabbaf6","listingId":"4bd1a5aa-5e0e-4660-ba2f-8420799d7586","amountUsd":"0","unit":"free","nativeCurrency":null,"nativeAmount":null,"chain":null,"payTo":null,"paymentMethod":"skill-free","isPrimary":true,"details":{"org":"appautomaton","category":"webmaton","install_from":"skills.sh"},"createdAt":"2026-05-06T01:03:38.647Z"}],"sources":[{"listingId":"4bd1a5aa-5e0e-4660-ba2f-8420799d7586","source":"github","sourceId":"appautomaton/webmaton/playwright-cli","sourceUrl":"https://github.com/appautomaton/webmaton/tree/main/skills/playwright-cli","isPrimary":false,"firstSeenAt":"2026-05-06T01:03:38.647Z","lastSeenAt":"2026-05-18T19:06:02.684Z"}],"details":{"listingId":"4bd1a5aa-5e0e-4660-ba2f-8420799d7586","quickStartSnippet":null,"exampleRequest":null,"exampleResponse":null,"schema":null,"openapiUrl":null,"agentsTxtUrl":null,"citations":[],"useCases":[],"bestFor":[],"notFor":[],"kindDetails":{"org":"appautomaton","slug":"playwright-cli","github":{"repo":"appautomaton/webmaton","stars":17,"topics":["agent-skills","ai-agents","browser-automation","claude-code","codex","html-to-markdown","playwright","web-automation","web-scraping"],"license":"mit","html_url":"https://github.com/appautomaton/webmaton","pushed_at":"2026-05-17T00:55:04Z","description":"Portable web-research and browser-automation SKILLs for Claude Code, Codex, and OpenCode — Playwright, Chrome DevTools, nodriver, and HTML-to-Markdown.","skill_md_sha":"b408436802d38a3780e0c97d9a26b2a0349a0235","skill_md_path":"skills/playwright-cli/SKILL.md","default_branch":"main","skill_tree_url":"https://github.com/appautomaton/webmaton/tree/main/skills/playwright-cli"},"layout":"multi","source":"github","category":"webmaton","frontmatter":{"name":"playwright-cli","description":"Use when a task needs Playwright-backed browser automation from the shell: open or attach to browser sessions, inspect snapshots and element refs, click/type/fill forms, debug Playwright tests, inspect console/network/storage, run Playwright snippets, capture screenshots/traces/videos, or generate reliable test code. Prefer for repeatable browser workflows and Playwright test work; not for static HTTP fetches, JSON APIs, or simple web search."},"skills_sh_url":"https://skills.sh/appautomaton/webmaton/playwright-cli"},"updatedAt":"2026-05-18T19:06:02.684Z"}}