Skip to main content

MCP server for RootBrowse browser automation

Project description

RootBrowse MCP

MCP Server for RootBrowse browser automation framework. 为 AI Agent 提供结构化的浏览器操控能力。

安装

pip install rootbrowse-mcp

Claude Code 配置

settings.json 中添加:

{
  "mcpServers": {
    "rootbrowse": {
      "command": "rootbrowse-mcp"
    }
  }
}

或指定路径:

{
  "mcpServers": {
    "rootbrowse": {
      "command": "D:\\path\\to\\.venv\\Scripts\\python.exe",
      "args": ["-m", "rootbrowse_mcp.server"]
    }
  }
}

Tools

页面扫描

  • get_page_regions() — 获取页面所有语义区域
  • get_region_summary(region_id) — 获取区域统计摘要
  • match_element(region_id, tag, role, text_contains, query, limit) — 按条件筛选元素
  • get_element(ref) — 获取元素完整信息

元素操作

  • click_element(ref) — 点击元素
  • input_text(ref, text, clear) — 向输入框输入文字
  • send_enter() — 发送回车键

浏览器

  • init_browser(headless) — 初始化浏览器(必选,headless 默认 True)
  • get_page(url, timeout) — 打开 URL
  • take_screenshot(path) — 页面截图
  • close_browser() — 关闭浏览器

注意: 使用其他工具前必须先调用 init_browser() 初始化浏览器。

标签页

  • new_tab(url) — 打开新标签页
  • close_tab() — 关闭当前标签页
  • switch_tab(index) — 切换标签页
  • get_tabs_count() — 获取标签页数量

状态

  • save_state(path) — 保存浏览器状态
  • load_state(path) — 恢复浏览器状态

依赖

  • Python >= 3.10
  • rootbrowse >= 0.2.0
  • mcp >= 1.0.0

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

rootbrowse_mcp-0.1.4.tar.gz (4.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

rootbrowse_mcp-0.1.4-py3-none-any.whl (5.8 kB view details)

Uploaded Python 3

File details

Details for the file rootbrowse_mcp-0.1.4.tar.gz.

File metadata

  • Download URL: rootbrowse_mcp-0.1.4.tar.gz
  • Upload date:
  • Size: 4.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.7

File hashes

Hashes for rootbrowse_mcp-0.1.4.tar.gz
Algorithm Hash digest
SHA256 b3acff4ddeeac766e7cf38f833097bae2306faa0295b4ed3e7c22191baa3c000
MD5 8cfbb7626d20b1f3488b0fa48df339ed
BLAKE2b-256 75ac70e052fc9c4e42fd52ebdc72c6696c5b3b1188d2735c1ffeff1cc736b6ae

See more details on using hashes here.

File details

Details for the file rootbrowse_mcp-0.1.4-py3-none-any.whl.

File metadata

  • Download URL: rootbrowse_mcp-0.1.4-py3-none-any.whl
  • Upload date:
  • Size: 5.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.7

File hashes

Hashes for rootbrowse_mcp-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 6671daa6e8234ebf82e4d628090eaa678354d41e774e838e2dff4f57aa0551b5
MD5 6bfe6abe0b693c9b9841b313eb7d9ccd
BLAKE2b-256 c0132d244539c6e15fd69fdd370c890e8e2503fa6883a5b7531fd63d94ae7727

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page