# PlaywrightGen [Health: Active]

**Category:** 📂 Browser Automation  
**Repository:** https://github.com/hmamut39/playwrightgen  
**GitHub Stars:** 0  
**Views:** 0  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/playwrightgen

## Description
Approved test intent, reviewed Playwright automation and run evidence, inside your editor.

## Claude Desktop Quick Installation
No generated config for this server: it installs through its own setup steps.

The project's own setup steps (from https://github.com/hmamut39/playwrightgen), copied verbatim. Follow them in order; they are not an mcpServers config.

1. Install:

```sh
npm install
```

## Documentation

## What PlaywrightGen does

PlaywrightGen connects AI coding clients with a testing workflow built around requirements, test cases, Playwright automation, and run evidence. The MCP interface exposes sixteen tools for reading approved intent, inspecting recent failures, generating browser tests, proving them on live pages, and preparing drafts for human review.

The system separates suggestion from approval. A person reviews and approves requirements, test cases, and automation; the generator and the MCP agent cannot approve, accept, share, or delete these records. Approved versions provide a stable reference for later automation and evidence.

A generated test is based on the target page's accessibility tree and is exercised in a remote browser. When a step fails, the workflow can attempt a repair, but it rejects fixes that weaken the original checks. Validators also reject focused tests, fixed sleeps, credentials embedded in test files, requests outside the application under test, and unsuitable Node capabilities.

## How it works

The free generation path accepts a testing request and a public URL. PlaywrightGen reads the page, produces Playwright code, runs it remotely, and iterates on failing steps until it reaches a result. The output includes working code and a signed run record that can later be brought into a workspace.

Within a workspace, requirements are reviewed first, followed by test cases containing objectives, steps, and expected results. Automation is generated from an approved test-case version, checked against deterministic rules, proven on the live page, and then sent for human approval.

CI execution happens on the user's runners and in the user's environment. Only a bounded result summary is submitted. A marker in the test title associates that result with the approved version it covers. Skipped runs are not treated as proof, and sign-in credentials used for a run are removed from its reports rather than retained.

## Setup and configuration

For local development, install dependencies with `npm install` and start the application with `npm run dev`. The project uses Next.js, TypeScript, PostgreSQL through Prisma, Clerk, Playwright, OpenAI, and Stripe. Database integration tests require `TEST_DATABASE_URL` to point to a separate non-production database.

Runtime configuration includes a PostgreSQL `DATABASE_URL`, Clerk credentials, an `OPENAI_API_KEY`, and a `BROWSERLESS_API_KEY` for remote browser execution. Redis settings control per-minute and per-day AI allowances. GitHub integration uses a separate group of app and webhook secrets, and can open pull requests containing approved test code and add evidence notes.

## Tools and capabilities

- Read requirements, test cases, approved automation, and recent failures.
- Draft requirements and test cases for review.
- Generate Playwright tests from a live page.
- Run and prove tests in a remote browser.
- Return code and signed run evidence.
- Associate CI summaries with approved test versions.
- Support signed proof links with downloadable evidence files.

Agents receive the permissions associated with the token they use. The server can propose and send code, but approval remains a human action. Deterministic evaluation commands, including type checking, linting, builds, and the test suite, are available for the local project.

_Full upstream README: https://allmcps.com/mcp/playwrightgen/readme_

