playwright

playwright is a skill for Claude Code, Codex from melodic-software/claude-code-plugins. It costs 114 tokens per session (2,062 once invoked), scanned A, original, MIT.

A command-line toolkit for controlling a live web browser through Playwright, including page inspection, interaction, screenshots, and diagnostic capture.

In plain words
What is it for?
It helps test websites end to end, fill forms, click controls, inspect accessibility structure, capture console and network details, and record traces or video.
Why use it?
It removes the need to perform browser checks manually and keeps large snapshots and artifacts out of the conversation.

Skill for Claude CodeCodex

Installs and runs on its own, but its text points at files inside its plugin — anything it tells you to read at a ${CLAUDE_PLUGIN_ROOT} path is only there once the plugin is installed. Installing the plugin gets both.

Part of the playwright plugin — 1 skill shipped together

Install

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.

agentmods
npx agentmods add skills/melodic-software/claude-code-plugins/playwright
Any agent
npx skills add melodic-software/claude-code-plugins --skill playwright
Clone the repo
git clone --depth 1 https://github.com/melodic-software/claude-code-plugins

Made for: Claude Code, Codex.

Or install playwright, the plugin that ships this one along with the rest of its 1 skill.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for playwright

README.md
[![agentmods](https://agentmods.dev/badge/skills/melodic-software/claude-code-plugins/playwright.svg)](https://agentmods.dev/skills/melodic-software/claude-code-plugins/playwright)
Your own site
<a href="https://agentmods.dev/skills/melodic-software/claude-code-plugins/playwright"><img src="https://agentmods.dev/badge/skills/melodic-software/claude-code-plugins/playwright.svg" alt="Measured on agentmods" height="20"></a>
Per session 114 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,062 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What 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.

ModelPer sessionOnce invoked
Fable 5 $0.00114 $0.02062
Opus 5 $0.00057 $0.01031
Sonnet 5 $0.00023 $0.00412
Haiku 4.5 $0.00011 $0.00206

Measured today against content hash b91ebd18822d, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

playwright 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 today.

The scan reads SKILL.md. This mod also ships 3 executable files (scripts/force-chrome-foreground.ps1, scripts/update.sh, scripts/update.test.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

plugins/playwright/skills/playwright/SKILL.md · 102 lines

How it starts

The opening of the file, as written. The whole thing — 102 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Playwright CLI, live browser automation

Wraps Microsoft's @playwright/cli for token-efficient browser automation. Snapshots and screenshots write to disk; only paths come back into context, a substantial token reduction versus Playwright MCP's in-context payloads.

Requires playwright-cli on PATH (npm install -g @playwright/cli). If it is missing, tell the user to install it rather than substituting a different automation surface.

Quick start (90% of use)

playwright-cli kill-all                              # start clean (no stale sessions)
playwright-cli -s=<flow> open <url>                  # named session, headless by default
playwright-cli -s=<flow> snapshot                    # writes YAML with element refs (e1, e2, ...)
playwright-cli -s=<flow> click e42                   # interact by ref
playwright-cli -s=<flow> fill e37 "input" --submit   # fill + press Enter
playwright-cli -s=<flow> screenshot --filename=meaningful-name.png
playwright-cli -s=<flow> console                     # summarize console messages
playwright-cli -s=<flow> close                       # tear down

Read the YAML snapshot file directly to locate element refs. Do not dump it into context.

Conventions

  • Always use named sessions (-s=<flow>) for multi-step work. Default (unnamed) sessions are hard to isolate when things go sideways
  • kill-all at the start of a fresh E2E run guards against stale daemon state from prior sessions
  • close at the end. Don't leave zombie browsers
  • --headed only when the user explicitly wants to observe. On Windows, headed browsers spawn in the background and don't auto-focus. See reference/windows-quirks.md
  • Artifacts land in .playwright-cli/ relative to CWD at command time. Add .playwright-cli/ to the project's .gitignore if it isn't already. For meaningful artifacts (evidence for PRs, regression baselines), pass --filename=<descriptive>.png; let timestamp-named snapshots pile up as throwaway intermediate state
  • Use element refs from snapshots (e15, e37), not CSS selectors. Snapshots use accessibility roles, which survive cosmetic UI changes

Read the full file on GitHub · 102 lines

Changes

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.

  1. today First seen · 102 lines · 114 tokens per session scan A b91ebd18822d

Subscribe to this mod's changes

playwright is a skill published in the GitHub repository melodic-software/claude-code-plugins (14 stars, last pushed today), licensed MIT. It adds 114 tokens to every session and 2,062 once invoked, about $0.0006 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-09-03.