Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

playwright-agents

БесплатноБез исполняемых скриптовНе проверен

Use when a coding agent works with Playwright through playwright-cli, Playwright MCP or the planner, generator and healer Test Agents: setting them up…

testlandот testland★ 18 звёзд на GitHub

Об этом скилле

playwright-agents

Overview

Playwright ships three things built for coding agents, and they solve different problems:

Tool What it is Use it for
playwright-cli A command-line browser driver: open, click e15, snapshot, screenshot An agent checking a page, reproducing a bug or poking a flow while it also works in a large codebase
Playwright MCP An MCP server that exposes the browser as tools and returns accessibility snapshots Long agent loops that keep browser state and reason over page structure
Playwright Test Agents Three agent definitions (planner, generator, healer) generated into your repo by npx playwright init-agents Turning an app into a Markdown test plan, then into @playwright/test files, then keeping them green

The official guidance on the first two (getting-started-cli): "playwright-cli is best for coding agents (Claude Code, GitHub Copilot, etc.) that favor token-efficient, skill-based workflows", while "MCP is best for specialized agentic loops that benefit from persistent state and iterative reasoning over page structure".

This skill covers choosing between them, setting them up, and the review a human still owes their output. Writing Playwright tests by hand (locators, web-first assertions, config, sharding) is playwright-testing; scaffolding a whole harness for a repo with no suite is the automation-harness-bootstrapper agent; cleaning up a recorded codegen spec is playwright-codegen-reviewer.

Facts below are checked against Playwright 1.65 docs and a local npx playwright init-agents --loop=claude run on @playwright/test 1.65.0. Agent definitions change between releases, so re-check after an upgrade.

When to use

  • "Have Claude open the app and check X" or "reproduce this UI bug in a browser".
  • "Set up Playwright MCP / playwright-cli for Claude Code."
  • "Generate Playwright tests for this app with the planner / generator / healer agents", or "the healer changed my tests, is that OK?"
  • A Playwright test fails only on CI and the agent has to debug it from a trace in the terminal.
  • A reviewer wants proof the agent actually ran the flow (video receipt).

Not a fit: hand-writing or refactoring specs (playwright-testing), cross-browser matrix planning (browser-matrix-strategy-reference).

Step 1 - Pick the tool

Situation Pick Why
Claude Code works in a repo and needs to check a page now and then playwright-cli Commands avoid "loading large tool schemas and verbose accessibility trees into the model context" (pw-cli); each snapshot is written to a file the agent reads only when needed
An MCP-only client (Claude Desktop, Cursor, VS Code chat) or a long exploration loop Playwright MCP Tools and snapshots stay in the conversation; persistent profile by default (pw-mcp)
You want a test suite, not a one-off check Test Agents They write specs/*.md plans and tests/*.spec.ts files you keep and run in CI (pw-agents)
You need the agent to see your own signed-in browser tabs Either, with the Playwright Extension: playwright-cli attach --extension or MCP --extension Connects to existing tabs instead of a fresh browser

Do not install all three "just in case": each MCP server adds its tool schemas to every conversation.

Step 2 - Set up playwright-cli

Per pw-cli (Node.js 20+ for the CLI itself):

npm install -g @playwright/cli@latest
playwright-cli --help
playwright-cli install --skills        # skill files for the agent, this project
# or: playwright-cli install --skills -g   (into ~/.claude/skills)

Since 1.62, a project that already has @playwright/test can run the bundled copy as npx playwright cli (pw-notes).

First run, headless by default:

playwright-cli open http://localhost:3000/login
playwright-cli snapshot                 # element refs like e15
playwright-cli fill e15 "[email protected]"
playwright-cli click "role=button[name=Sign in]"
playwright-cli screenshot --filename=after-login.png
playwright-cli console                  # browser console messages
playwright-cli requests                 # network since page load
playwright-cli close

Sessions: -s=<name> runs several browsers side by side; list, close-all, kill-all manage them; playwright-cli show opens a live dashboard of every session. The profile lives in memory unless you pass --persistent. A headless session closes itself after an hour without commands; change that with open --idle-timeout=<ms>. Project defaults go in .playwright/cli.config.json, loaded automatically.

Step 3 - Set up Playwri

Полный SKILL.md на GitHub

Установить playwright-agents в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

.tessl-plugin/plugin.jsonevals/agent-browser-for-a-monorepo/criteria.jsonevals/agent-browser-for-a-monorepo/task.mdevals/ci-trace-without-a-display/criteria.jsonevals/ci-trace-without-a-display/task.mdevals/healer-made-suite-green/criteria.jsonevals/healer-made-suite-green/task.md

FAQ

Что делает скилл playwright-agents?

Use when a coding agent works with Playwright through playwright-cli, Playwright MCP or the planner, generator and healer Test Agents: setting them up, reviewing healer diffs before merging, debugging a failing test from its trace in a terminal with no display, and leaving a video receipt.

Как установить скилл playwright-agents?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл playwright-agents запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить playwright-agents с