MCP server
Playwright tests your editor’s AI has proven on the live page
Connect GitHub Copilot, Cursor or Claude Code to PlaywrightGen. Your assistant writes the test from the real page, runs it and fixes what fails until it passes, and proposes it with that evidence — and your team decides what counts.
Write it from the real page
generate_playwright_test opens the page in a remote browser and builds locators from its real buttons, fields and test attributes, so the first draft is not a guess.
Run it, fix it, run it again
run_playwright_test replays the test step by step on the live page and returns the failing step with the page as it was, so your assistant fixes the locator and runs again. prove_playwright_test does that whole loop in one call.
Propose it for review
propose_test_case sends the test case and code with a signed receipt of the passing run. A person on your team approves it; then it becomes reviewed automation.
Tools
Sixteen tools over the Model Context Protocol (Streamable HTTP), speaking the 2026-07-28 revision and every earlier one back to 2024-11-05, so an editor connects whichever it implements. Running and generating use your workspace’s daily AI allowance.
| Tool | Kind | What it does |
|---|---|---|
| prove_playwright_test | Runs | The whole loop in one call: write it, run it, fix the failing step, run again until it passes or the fixes run out. |
| plan_page_coverage | Proposes | Plans the tests a whole page needs; a person approves the plan in PlaywrightGen. |
| prove_page_coverage | Runs | Proves each approved test on the live page and returns the passing suite. |
| generate_playwright_test | Runs | Writes a draft from a described flow and the real page. |
| run_playwright_test | Runs | Replays a test on the live page; reports each step and the page at a failure. |
| propose_requirement | Proposes | Starts the chain: a draft requirement for what the product should do and how somebody would know it works. A person approves it before anything is measured against it. |
| propose_test_case | Proposes | Creates a draft test case, optionally with code and a passing run, for review. |
| submit_playwright_code | Proposes | Sends code for an existing test case, waiting for a person to use it. |
| list_requirements | Reads | What the product is meant to do, each with its review status and a verdict from stored records: verified, failing, or nothing verifies it yet. Ask for the unverified ones to find the gaps worth writing. |
| get_requirement | Reads | One requirement with every approved test that verifies it, how each last ran, and who proposed it. |
| list_test_cases | Reads | Test cases with their review status and version. |
| get_test_case | Reads | Approved steps, expected results and the version marker for the test title. |
| list_approved_automation | Reads | Reviewed Playwright automation in the project. |
| get_approved_automation | Reads | The approved code, ready to save into the repository. |
| list_recent_failures | Reads | What failed in CI recently, with the failure output. |
| project_overview | Reads | Release readiness: coverage, regressions and blockers. |
What happens after your team approves
An assistant can propose; approval is what makes a test count. From then on the workspace keeps it working and keeps the record.
- Daily checks, once you switch them on, run it on your live site and say the day it breaks.
- Approved code opens as a pull request in your repository.
- The evidence can be shared as a read-only link, downloaded as a file, or shown as a README badge.
Connect in three steps
- 1. Create a free workspace and a project.
- 2. Open the project’s Automation page and copy your personal editor token.
- 3. Add PlaywrightGen to your editor, replacing YOUR_TOKEN (the Automation page gives you this with your token filled in):
VS Code (Copilot agent mode)
.vscode/mcp.json
{
"inputs": [
{
"type": "promptString",
"id": "playwrightgen-token",
"description": "PlaywrightGen editor token",
"password": true
}
],
"servers": {
"playwrightgen": {
"type": "http",
"url": "https://playwrightgen.com/api/mcp",
"headers": {
"Authorization": "Bearer ${input:playwrightgen-token}"
}
}
}
}Cursor
~/.cursor/mcp.json
{
"mcpServers": {
"playwrightgen": {
"url": "https://playwrightgen.com/api/mcp",
"headers": {
"Authorization": "Bearer YOUR_TOKEN"
}
}
}
}Claude Code
Terminal
claude mcp add --transport http playwrightgen https://playwrightgen.com/api/mcp --header "Authorization: Bearer YOUR_TOKEN"
What it can never do
- Approve anything. Proposals wait for a person on your team; nothing counts as coverage until they approve it.
- Go beyond your role. The token is yours, for one project, and checked against your access on every request. A viewer’s assistant cannot write.
- Execute test code. Runs read the test into safe Playwright steps and replay them in a remote browser, only on public pages.
- Keep your test account. Values for a sign-in are used for one run, never stored, and blanked out of what the run reports.