Scrappey MCP Server

by pim97
Verified

remote-capable server

The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.

Integrations

  • Allows selection of HTML elements using CSS selectors for browser automation actions like clicking, hovering, typing, and scrolling.

  • Enables creation and management of persistent browser sessions that maintain cookies and state across multiple requests and actions.

Scrappey MCP 服务器

一个模型上下文协议 (MCP) 服务器,用于与 Scrappey.com 的 Web 自动化和数据抓取功能进行交互。您可以直接访问smithery.ai/server/@pim97/mcp-server-scrappey进行试用。

概述

该 MCP 服务器在 AI 模型和 Scrappey 的 Web 自动化平台之间架起了一座桥梁,使您能够:

  • 创建和管理浏览器会话
  • 通过 Scrappey 的基础设施发送 HTTP 请求
  • 执行浏览器操作(单击、键入、滚动等)
  • 自动处理各种反机器人保护

设置

  1. Scrappey.com获取您的 Scrappey API 密钥
  2. 设置环境变量:
SCRAPPEY_API_KEY=your_api_key_here

可用工具

1. 创建会话( scrappey_create_session

创建一个新的浏览器会话,以保留 cookie 和其他状态。

{ "proxy": "http://user:pass@ip:port" // Optional: Custom proxy, leave empty for default }

2. 销毁会话( scrappey_destroy_session

正确关闭浏览器会话。

{ "session": "session_id_here" // Required: The session ID to destroy }

3.发送请求( scrappey_request

通过 Scrappey 基础设施发送 HTTP 请求。

{ "cmd": "request.get", // Required: request.get, request.post, etc. "url": "https://example.com", // Required: Target URL "session": "session_id_here", // Required: Session ID to use "postData": "key=value", // Optional: POST data "customHeaders": { // Optional: Custom headers "User-Agent": "custom-agent" } }

4. 浏览器操作( scrappey_browser_action

执行浏览器自动化操作。

{ "session": "session_id_here", // Required: Session ID to use "browserActions": [ // Required: Array of actions to perform { "type": "click", // Action type: click, hover, type, scroll, wait "cssSelector": ".button", // CSS selector for element "text": "Hello", // Text to type (for type action) "wait": 1000 // Wait time in ms } ] }

典型工作流程

  1. 创建会话:
{ "name": "scrappey_create_session" }
  1. 将返回的会话 ID 用于后续请求:
{ "name": "scrappey_request", "cmd": "request.get", "url": "https://example.com", "session": "returned_session_id" }
  1. 如果需要,执行浏览器操作:
{ "name": "scrappey_browser_action", "session": "returned_session_id", "browserActions": [ { "type": "click", "cssSelector": "#login-button" }, { "type": "type", "cssSelector": "#username", "text": "myuser" } ] }
  1. 完成后通过销毁会话进行清理:
{ "name": "scrappey_destroy_session", "session": "returned_session_id" }

特征

  • 会话持久化以维护状态
  • 自动反机器人保护处理
  • 支持自定义代理
  • 浏览器自动化功能
  • HTTP 请求方法(GET、POST、PUT、DELETE、PATCH)
  • 自定义标头和 Cookie 支持

最佳实践

  1. 每次使用完会话后都要销毁它们
  2. 向同一站点发出多个请求时重复使用会话
  3. 在动作之间使用适当的等待时间以实现更像人类的行为
  4. 使用会话前检查其是否存在

错误处理

出现错误时,服务器会返回包含详细信息的错误消息。常见错误包括:

  • 无效的会话 ID
  • 网络超时
  • 浏览器操作的选择器无效
  • 反机器人保护失败

资源

执照

MIT 许可证

-
security - not tested
F
license - not found
-
quality - not tested

连接 AI 模型与 Scrappey 的网络自动化平台的服务器,允许创建浏览器会话、执行 HTTP 请求以及自动化浏览器操作,同时处理反机器人保护。

  1. Overview
    1. Setup
      1. Available Tools
        1. 1. Create Session (scrappey_create_session)
        2. 2. Destroy Session (scrappey_destroy_session)
        3. 3. Send Request (scrappey_request)
        4. 4. Browser Actions (scrappey_browser_action)
      2. Typical Workflow
        1. Features
          1. Best Practices
            1. Error Handling
              1. Resources
                1. License
                  ID: wlt8ef3tcu