Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/lexler/skill-factory/playwright-clinpx skills add lexler/skill-factory --skill playwright-cligit clone --depth 1 https://github.com/lexler/skill-factoryWhat it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00051 | $0.00768 |
| Opus 5 | $0.00026 | $0.00384 |
| Sonnet 5 | $0.00010 | $0.00154 |
| Haiku 4.5 | $0.00005 | $0.00077 |
Grade A, and why
playwright-cli scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 79 lines — stays where its author put it; the contents beside it link to each section on GitHub.
STARTER_CHARACTER = 🎭
playwright-cli
Driving a browser from the shell. Each command prints the executed Playwright code, the page state, and a fresh snapshot.
The loop
Snapshot to see the page, act on an element by its ref, snapshot again.
playwright-cli snapshot # accessibility tree with [ref=e8] handles
playwright-cli click e8 # act on a ref
playwright-cli snapshot # confirm the result
Refs are not stable. Any DOM change renumbers them — re-snapshot before acting on a page that just changed. Acting on a stale ref hits the wrong element or none.
For a large page, snapshot a region instead of the whole tree: snapshot e34 or snapshot --depth=4.
Targeting elements
A target is one of three things — a ref, a CSS selector, or a Playwright locator:
playwright-cli click e8
playwright-cli click ".todo-list .toggle"
playwright-cli click "getByRole('button', { name: 'Submit' })"
playwright-cli click "getByText('buy milk')"
A bare descriptive phrase is not a target. click "the submit button" is parsed as a CSS selector and fails with "does not match any elements". Prefer refs; reach for getByRole/getByText when a ref won't survive a re-render.
Key commands
playwright-cli goto https://example.com
playwright-cli fill e5 "[email protected]" --submit # clear, type, then Enter — one step
playwright-cli type "free text into the focused element"
playwright-cli press Enter # also: Tab, Escape, ArrowDown
playwright-cli select e9 "option-value"
playwright-cli check e12 # uncheck / hover / dblclick likewise
playwright-cli screenshot # saves to .playwright-cli/
fill works on React/controlled inputs where raw DOM events don't. After filling, the field must blur before dependent values (totals, validation) update — --submit or a following press Tab does that.
Inspecting and verifying
playwright-cli eval "el => el.getAttribute('data-testid')" e5 # attributes the snapshot hides
playwright-cli console # page console messages
playwright-cli requests # network log, then `request <n>`
What ships with it
2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 3d ago First seen · 79 lines · 51 tokens per session scan A 85e7a440f611
playwright-cli is a skill published in the GitHub repository lexler/skill-factory (231 stars, last pushed 7d ago), licensed Apache-2.0. It adds 51 tokens to every session and 768 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
electron
Automate Electron desktop apps (VS Code, Slack, Discord, Figma, Notion, Spotify, etc.) using agent-browser via Chrome DevTools Protocol. Use when the user needs to interact with an Electron app, automate a desktop app, connect to a running app, control a native app, or test an Electron application. Triggers include…
use-agent-browser-for-airi
Test AIRI display-model imports with agent-browser across stage-tamagotchi Electron, stage-web, and stage-pocket mobile web layouts. Use when uploading and verifying contributor-supplied Live2D ZIP, VRM, or MMD ZIP/PMX/PMD files through AIRI's model selector, including onboarding bypass, format-specific import…
opencli-sitemap-author
Use when creating or maintaining OpenCLI site sitemaps: agent-facing navigation, page-state, action, workflow, API-reference, pitfall, and fallback knowledge for a website. Use after browser exploration discovers durable site context, when a sitemap is stale, or when promoting local site knowledge into the repo.
playwright
Use when the task requires automating a real browser from the terminal (navigation, form filling, snapshots, screenshots, data extraction, UI-flow debugging) via playwright-cli or the bundled wrapper script.
pinchtab-mcp
Use this skill when a task requires browser automation through PinchTab's MCP server connected to a remote browser instance. Covers navigation, element interaction, data extraction, form filling, multi-step flows, and session management via MCP tools.
peekaboo
Capture and automate macOS UI with the Peekaboo CLI.