Command Palette

Search for a command to run...

UnylyUnyly
Весь каталог

Infy Mcp Playwright

БесплатноПоддерживается

MCP Playwright server for web app testing automation via HTTP API

GitHubEmbed

Описание

MCP Playwright server for web app testing automation via HTTP API

README

MCP Playwright server for web app testing automation. Exposes an HTTP API to run Playwright tests (navigation, clicks, link checks, screenshots). This tool can be used for quick website validation, smoke testing, link validation, accessibility testing, performance checks, and basic SEO testing. It reduces the need to manually create a separate Playwright framework for every small testing requirement.

Install

npm install infy-mcp-playwright

Or install globally:

npm install -g infy-mcp-playwright

Start the server

Local project:

npm start

Global CLI:

infy-mcp-playwright

The server prints:

MCP Server Running on Port 3000

Set PORT to change the listen port (default: 3000). Set HEADLESS=false to open a visible browser window.

Health check

Verify the server is running without starting a browser test:

curl http://localhost:3000/health

Expected response:

{
  "status": "ok",
  "service": "infy-mcp-playwright"
}

Run a test request

curl -X POST http://localhost:3000/run-test \
  -H "Content-Type: application/json" \
  -d '{
    "url": "https://perfectqaservices.com",
    "checkLinks": {
      "selector": "a"
    }
  }'

Request body options

Field Description
url Page URL to open (required)
steps Array of user actions to run after the page loads (see below)
type { selector, value } — fill an input (legacy single-step shortcut)
press Keyboard key (e.g. "Enter")
click { selector } — click an element
checkLinks { selector } — visit each matching link and report status

Multi-step actions

After the page loads, steps runs a real user flow. Each step is recorded in stepResults. If a step fails, the test stops and returns status: "failed" with the failed step.

action Fields What it does
click selector, optional timeout Click an element
type / fill selector, value, optional timeout Clear and type into an input
press key (or value), optional selector Press a keyboard key
wait selector and/or timeout Wait for an element, or wait a number of ms
assertText selector, text Fail if the element does not contain text
screenshot optional name Save a full-page screenshot under artifacts/
curl -X POST http://localhost:3000/run-test \
  -H "Content-Type: application/json" \
  -d '{
    "url": "https://example.com/login",
    "steps": [
      { "action": "type", "selector": "#email", "value": "[email protected]" },
      { "action": "type", "selector": "#password", "value": "secret" },
      { "action": "click", "selector": "button[type=submit]" },
      { "action": "wait", "selector": ".dashboard", "timeout": 10000 },
      { "action": "assertText", "selector": "h1", "text": "Welcome" },
      { "action": "screenshot", "name": "after-login" }
    ]
  }'

Programmatic API

const { runTest } = require('infy-mcp-playwright');

const result = await runTest({
  url: 'https://example.com',
  checkLinks: { selector: 'a' }
});

Enhanced checks and outputs

worker.js performs additional runtime checks and produces reports and artifacts automatically. Notable request options and outputs:

  • Request body options:

    • browser: chromium|firefox|webkit — choose the engine (default: chromium).
    • headless: boolean — run with a visible browser when false (default: true).
    • mobile: boolean — emulate iPhone 13 when true.
    • darkMode: boolean — set page color scheme to dark when true.
    • slowMo: number — slow motion in ms for Playwright (default: 200).
  • Runtime checks performed: performance metrics (dns, tcp, ttfb, dom/load times), memory usage, empty-page detection, infinite-loader detection (common loader selectors), basic SEO extraction (title, meta description, h1, canonical), broken images, console errors, page JS errors, failed requests and network failures (status >= 400), slow API detection (>5s), and accessibility scans via axe-core.

  • Link checking: visits links matched by checkLinks.selector (default a) with up to 3 retries, captures a screenshot per visited page, and marks each as PASSED or FAILED.

  • Artifacts & reports: saved under artifacts/, videos/, json-reports/ and reports/. The worker writes a JSON report (json-reports/report-<ts>.json) and an HTML report (reports/report-<ts>.html) and stores screenshots in artifacts/.

  • Response object: the API returns a structured object containing status, browser, loadTime, performanceMetrics, memoryUsage, seo, totalPages, passed, failed, brokenImages, consoleErrors, jsErrors, failedRequests, networkFailures, slowApis, accessibilityIssues, stepResults, checkedPages, aiSummary, htmlReport, jsonReport, and screenshot (final screenshot path).

Example curl request using the new options:

curl -X POST http://localhost:3000/run-test \
  -H "Content-Type: application/json" \
  -d '{
    "url": "https://example.com",
    "browser": "firefox",
    "headless": false,
    "mobile": false,
    "darkMode": true,
    "slowMo": 100,
    "checkLinks": { "selector": "a" }
  }'

Publish to npm

  1. Log in: npm login
  2. Dry-run: npm pack --dry-run
  3. Publish: npm publish

License

ISC

from github.com/sujeet0414/Infy_mcp_playwright

Установить Infy Mcp Playwright в Claude Desktop, Claude Code, Cursor

Рекомендуется · одна команда, все IDE
unyly install infy-mcp-playwright

Ставит в Claude Desktop, Claude Code, Cursor и VS Code — сам разбирается с npx, uvx и сборкой из исходников.

Впервые? Поставь CLI: curl -fsSL https://unyly.org/install | sh

Или настроить вручную

Выполни в терминале:

claude mcp add infy-mcp-playwright -- npx -y infy-mcp-playwright

Пошаговые гайды: как установить Infy Mcp Playwright

FAQ

Infy Mcp Playwright MCP бесплатный?

Да, Infy Mcp Playwright MCP бесплатный — установка в пару кликов через Unyly без оплаты.

Нужен ли API-ключ для Infy Mcp Playwright?

Нет, Infy Mcp Playwright работает без API-ключей и переменных окружения.

Infy Mcp Playwright — hosted или self-hosted?

Self-hosted: сервер запускается локально на твоей машине командой из раздела установки.

Как установить Infy Mcp Playwright в Claude Desktop, Claude Code или Cursor?

Открой Infy Mcp Playwright на unyly.org, выбери вкладку своего клиента (Claude Desktop, Claude Code, Cursor) и нажми Install — конфиг сгенерируется автоматически, без правки JSON.

Изменения

Версии и запрашиваемые доступы со временем.

  • Новая версия опубликована
  • Новая версия опубликована
  • Новая версия опубликована

Похожие MCP

Playwright

Browser automation, scraping, screenshots

Microsoftавтор: Microsoft

Puppeteer

Browser automation and web scraping.

modelcontextprotocolавтор: modelcontextprotocol

Garmin Connect

An MCP server for Garmin Connect that provides access to fitness activities, health statistics, and sleep data by routing requests through a headless browser to

etweisbergавтор: etweisberg

Higgsfield Unlimited

MCP server for Higgsfield AI that enables unlimited-mode image, video, audio generation, uploads, and job management via multiple parallel accounts, using brows

nukIeerавтор: nukIeer

opentabs-dev/opentabs

Plugin-based MCP server + Chrome extension that gives AI agents access to web applications through the user's authenticated browser session. 100+ plugins with a

opentabs-devавтор: opentabs-dev

robhunter/agentdeals

1,500+ developer infrastructure deals, free tiers, and startup programs across 54 categories. Search deals, compare vendors, plan stacks, and track pricing chan

robhunterавтор: robhunter

hlydecker/ucsc-genome-mcp

MCP server to interact with the UCSC Genome Browser API, letting you find genomes, chromosomes, and more.

hlydeckerавтор: hlydecker

34892002/bilibili-mcp-js

A MCP server that supports searching for Bilibili content. Provides LangChain integration examples and test scripts.

34892002автор: 34892002

achiya-automation/safari-mcp

Native Safari browser automation for AI agents with 80+ tools. No Chrome dependency, optimized for Apple Silicon with 60% less CPU overhead.

achiya-automationавтор: achiya-automation

agent-infra/mcp-server-browser

Browser automation capabilities using Puppeteer, both support local and remote browser connection.

bytedanceавтор: bytedance

Compare Infy Mcp Playwright with

Не уверен что выбрать?

Найди свой стек за 60 секунд

Автор?

Embed-бейдж для README

Похожее

Все в категории browse