Skip to main content
Glama

@copperline/rendex-mcp

npm version npm downloads License: MIT

用于 Rendex 的 MCP 服务器 —— 通过使用模型上下文协议 (Model Context Protocol) 的 AI 代理,截取任何网页的屏幕截图和 PDF。

快速开始

Claude Desktop / Cursor / Windsurf (npx)

添加到您的 MCP 客户端配置中:

{
  "mcpServers": {
    "rendex": {
      "command": "npx",
      "args": ["-y", "@copperline/rendex-mcp"],
      "env": {
        "RENDEX_API_KEY": "your-api-key"
      }
    }
  }
}

添加位置:

客户端

配置位置

Claude Desktop

~/Library/Application Support/Claude/claude_desktop_config.json (macOS)

Cursor

项目根目录下的 .cursor/mcp.json,或 Settings > MCP

Windsurf

Settings > MCP Servers

Claude Code (CLI)

在项目根目录添加一个 .mcp.json,内容与上述配置相同。然后重启 Claude Code。

重要提示:将 .mcp.json 添加到您的 .gitignore 中 —— 它包含您的 API 密钥。

远程 (无需安装)

直接连接 —— 无需安装(仅限 Claude Desktop):

{
  "mcpServers": {
    "rendex": {
      "url": "https://mcp.rendex.dev/mcp",
      "headers": {
        "Authorization": "Bearer your-api-key"
      }
    }
  }
}

工具

rendex_screenshot

截取任何网页或原始 HTML 的屏幕截图或 PDF。

"Take a screenshot of https://example.com"
"Capture the full page of https://news.ycombinator.com in dark mode"
"Generate a PDF of https://github.com with A4 page size"
"Capture https://amazon.de as seen from Germany"
"Render this HTML invoice as a PDF"

参数:

参数

类型

默认值

描述

url

string

必填*

要截取的网页 URL。与 html 互斥。

html

string

要渲染的原始 HTML。与 url 互斥。

format

"png"

"jpeg"

"webp"

"pdf"

"png"

输出格式

fullPage

boolean

false

截取整个可滚动页面

darkMode

boolean

false

模拟深色配色方案

width

number

1280

视口宽度 (320-3840)

height

number

800

视口高度 (240-2160)

quality

number

80

图像质量 1-100 (仅限 JPEG/WebP,默认 80)

delay

number

0

截取前等待的毫秒数

blockAds

boolean

true

屏蔽广告和追踪器

blockResourceTypes

string[]

屏蔽资源类型:font, image, media, stylesheet

deviceScaleFactor

number

2

设备像素比 (1-3)。默认 2× Retina

timeout

number

30

等待页面加载的最长秒数 (5-60)

waitUntil

string

"networkidle2"

页面就绪状态:load, domcontentloaded, networkidle0, networkidle2

waitForSelector

string

截取前等待的 CSS 选择器

bestAttempt

boolean

true

超时时返回部分渲染结果而不是失败

selector

string

要截取的元素的 CSS 选择器(代替全页截取)

css

string

截取前注入的自定义 CSS (最大 50KB)

js

string

截取前执行的自定义 JavaScript (最大 50KB)

cookies

array

用于身份验证截取的 Cookie (最大 50)

headers

object

页面请求的自定义 HTTP 标头

userAgent

string

覆盖浏览器用户代理字符串

pdfFormat

string

PDF 页面尺寸:A4, Letter, Legal, Tabloid, A3

pdfLandscape

boolean

PDF 横向模式

pdfPrintBackground

boolean

true

在 PDF 中打印背景

pdfScale

number

1

PDF 缩放比例 (0.1-2)

pdfMargin

object

PDF 页边距:以 CSS 值表示的 {top, right, bottom, left}

geo

string

用于地理位置定位截取的 ISO 国家代码 (Pro/Enterprise)

geoCity

string

地理位置定位的城市 (需要 geo)

geoState

string

地理位置定位的州/省 (需要 geo)

async

boolean

异步处理 (返回任务 ID)

webhookUrl

string

异步截取完成时接收回调的 URL

cacheTtl

number

缓存结果的秒数 (3600-2592000)

身份验证

rendex.dev 获取您的 API 密钥。

在您的 MCP 客户端配置中设置 RENDEX_API_KEY 环境变量。

定价

计划

每月调用次数

速率

免费版

500

10/分钟

入门版

10,000

60/分钟

专业版

100,000

300/分钟

企业版

自定义

1,000/分钟

许可证

MIT — Copperline Labs LLC

Install Server
A
security – no known vulnerabilities
A
license - permissive license
A
quality - A tier

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/copperline-labs/rendex-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server