MCP cover image
See in Github
2025-04-14

0

Github Watches

0

Github Forks

0

Github Stars

MCP Playwright Server

A custom Playwright MCP (Multi-Client Protocol) server implementation that enables distributed test execution and browser automation across multiple clients.

Features

  • Distributed test execution across multiple clients
  • Browser automation using Playwright
  • Custom tool implementations for various browser operations
  • Request/Response handling for MCP protocol
  • Support for multiple browser contexts and pages

Project Structure

├── mcp-playwright/
│   ├── src/
│   │   ├── tools/            # Tool implementations
│   │   │   ├── api/          # API-related tools
│   │   │   ├── browser/      # Browser automation tools
│   │   │   └── codegen/      # Code generation tools
│   │   ├── index.ts          # Main entry point
│   │   ├── requestHandler.ts  # MCP request handling
│   │   ├── toolHandler.ts     # Tool management
│   │   └── types.ts          # Type definitions
│   └── __tests__/            # Test files
├── package.json
└── tsconfig.json

Installation

  1. Clone the repository:
git clone https://github.com/DreViz/Playwrite_MCP.git
cd Playwrite_MCP
  1. Install dependencies:
npm install

Usage

To start the MCP server:

npm run mcp

This will start the Playwright MCP server that can handle requests from multiple clients.

Tools

The server implements various tools for browser automation:

  • Browser Tools:

    • Navigation
    • Screenshots
    • Console logging
    • User agent management
    • Page interactions
  • API Tools:

    • Request handling
    • Response processing
  • CodeGen Tools:

    • Test recording
    • Code generation

Development

Prerequisites

  • Node.js (v14 or higher)
  • npm (v6 or higher)

Setup Development Environment

  1. Install development dependencies:
npm install
  1. Run tests:
npm test

Docker Support

The project includes Docker support for containerized execution:

  1. Build the image:
docker build -t mcp-playwright .
  1. Run the container:
docker run -p 3000:3000 mcp-playwright

Contributing

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

License

This project is licensed under the MIT License - see the LICENSE file for details.

相关推荐

  • WangRongsheng
  • 🧑‍🚀 全世界最好的 LLM 资料总结 (数据处理、模型训练、模型部署、 O1 模型、 MCP 、小语言模型、视觉语言模型) | Résumé des meilleures ressources LLM du monde.

  • av
  • Exécutez sans effort LLM Backends, API, Frontends et Services avec une seule commande.

  • langgenius
  • alibaba
  • 1Panel-dev
  • 🔥 1Panel fournit une interface Web intuitive et un serveur MCP pour gérer des sites Web, des fichiers, des conteneurs, des bases de données et des LLM sur un serveur Linux.

  • rulego
  • ⛓️RULEGO est un cadre de moteur de règle d'orchestration des composants de nouvelle génération légère, intégrée, intégrée et de nouvelle génération pour GO.

  • Byaidu
  • PDF Traduction de papier scientifique avec formats conservés - 基于 AI 完整保留排版的 PDF 文档全文双语翻译 , 支持 Google / Deepl / Olllama / Openai 等服务 , 提供 CLI / GUI / MCP / DOCKER / ZOTERO

  • nbonamy
  • Witsy: Assistant AI de bureau

  • hkr04
  • SDK C ++ MCP (Protocole de contexte modèle léger)

  • AstrBotDevs
  • ✨ 易上手的多平台 llm 聊天机器人及开发框架 ✨ 平台支持 QQ 、 QQ 频道、 Télégramme 、微信、企微、飞书 | MCP 服务器、 Openai 、 Deepseek 、 Gemini 、硅基流动、月之暗面、 Olllama 、 Oneapi 、 Dify 等。附带 webui。

  • microsoft
  • Python tool for converting files and office documents to Markdown.

    Reviews

    2 (1)
    Avatar
    user_WqoXqPoU
    2025-04-24

    As a dedicated user of Playwrite_MCP by DreViz, I must say this application is superb for content creation. The intuitive interface and seamless functionality make writing a pleasure. Highly recommend it to anyone needing a reliable tool for their writing projects!