MCP Browser Automation Server

local-only server

The server can only run on the client’s local machine because it depends on local resources.

MCP 浏览器自动化

这是一个演示项目,用于练习如何基于模型上下文协议 (MCP) 的服务器端实现,以便使用 Playwright 实现自动浏览。它与 Claude 桌面客户端交互,以接受用户提示并使用服务器控制浏览器。

先决条件

建筑

  1. 克隆存储库: git clone https://github.com/hrmeetsingh/mcp-browser-automation.git
  2. 安装依赖项: npm install
  3. 验证输出可执行文件是否存在于dist文件夹中

一体化

  1. ~/Application\ Support/Claude/claude_desktop_config.json中创建配置文件(适用于 macOS)
  2. 将以下内容复制到文件中:
{ "mcpServers": { "mcp-browser-automation": { "command": "node", "args": ["/path/to/mcp-browser-automation/dist/index.js"] } } }
  1. 启动 Claude Desktop

用法

  1. 打开 Claude 桌面
  2. 开始新的对话以打开浏览器并导航到 URL

例子

  • 添加了 MCP 服务器选项
  • 导航到 URL 并使用 playwright 执行操作

You must be authenticated.

A
security – no known vulnerabilities
A
license - permissive license
A
quality - confirmed to work

通过与 Claude Desktop 交互来执行用户定义的提示和操作,从而使用 Playwright 实现浏览器任务的自动化。

  1. Pre-requisites
    1. Building
      1. Integration
        1. Usage
          1. Example
            ID: hokppvk1dy