getdr

io.github.index-pages由 GitHub 账号 index-pages 发布v0.2.0更新于 Oct 29, 2026

Ahrefs Domain Rating (0–100) for domains or URLs, via getdr by Index Pages

概览

AI 生成的概览

一个小型 stdio MCP 服务器,只提供一个 get_dr 工具,通过 getdr 返回域名或网址的 Ahrefs Domain Rating(0–100)。

可以做什么
  • 批量查询域名或网址的 Ahrefs Domain Rating
  • 选择 DR 公式版本(dr3 或 dr4),或忽略缓存重新抓取
  • 按输入顺序返回每个目标的 JSON 记录,Ahrefs 无数据时 DR 为 null,无效目标带错误标记
适用场景
适合需要快速获取一个或多个域名 Domain Rating 的场景,例如 SEO 或外链拓展工作,且你已有 getdr 环境或网络内的 getdr 服务器。
运行要求
通过 npx 以 stdio 在本地运行,需要 Node.js 18 或更高版本。需要设置 GETDR_API 指向 getdr 服务器(可选 GETDR_SERVE_TOKEN),或在 PATH 中有 0.2.0 或更新版本的 getdr 二进制文件,后者自身需要 Ahrefs API 密钥(AHREFS_KEY)。调用超时为 120 秒。
安装前请注意
Ahrefs API 密钥保存在 getdr 服务器或二进制文件中;GETDR_SERVE_TOKEN 是发送给该服务器的 Bearer 密钥。Domain Rating 数据受 Ahrefs 许可约束,发布数字时须注明“Domain Rating by Ahrefs”,但工具结果本身不含署名。HTTP 后端默认忽略 HTTP_PROXY/HTTPS_PROXY,除非设置 NODE_USE_ENV_PROXY。

安装

在 SourceWeft 中

  1. 打开 控制台中的 getdr,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

getdr-mcp

getdr-mcp is a small open-source MCP server by Index Pages that gives AI agents one tool, get_dr: Ahrefs Domain Rating (DR) for domains or URLs. It is a thin front for getdr – it asks a getdr server or the getdr binary and makes no Ahrefs requests of its own. Stdio transport, no runtime dependencies. Docs: index-pages.com/getdr.

Setup

Add it to your MCP client (Claude Desktop, Claude Code, Cursor and others use this shape):

json
{  "mcpServers": {    "getdr": {      "command": "npx",      "args": ["-y", "getdr-mcp"]    }  }}

That uses the getdr binary on your PATH. To use a getdr server on your network instead:

json
{  "mcpServers": {    "getdr": {      "command": "npx",      "args": ["-y", "getdr-mcp"],      "env": {        "GETDR_API": "http://lan-host:8080",        "GETDR_SERVE_TOKEN": "s3cret"      }    }  }}

Requires Node.js 18 or later.

Backends

Checked on every call, in this order:

  1. GETDR_API is set – one POST $GETDR_API/dr to that getdr server (getdr serve), with Authorization: Bearer $GETDR_SERVE_TOKEN when the token is set. The server holds the Ahrefs key and the shared cache, so this machine needs neither.
  2. getdr (0.2.0 or newer) is on PATH – runs getdr --format json -q [--version V] [--fresh] -f - with the targets on stdin, no shell (as arguments after -- when a target starts with #, which -f would skip as a comment). The binary uses its own config, cache and key (AHREFS_KEY), or its own api setting.
  3. Neither – the tool returns an error with setup instructions.

Install the binary with go install github.com/index-pages/getdr@latest or from Releases, then get a free Ahrefs API key: index-pages.com/getdr#key.

Both backends return the same records. Calls time out after 120 seconds.

Proxies: the HTTP backend uses Node's built-in fetch, which ignores HTTP_PROXY/HTTPS_PROXY unless NODE_USE_ENV_PROXY=1 is set (Node 22.21 or later, or 24 and later; older versions have no built-in proxy support). The binary backend honours HTTP_PROXY, HTTPS_PROXY and NO_PROXY as usual.

Tool

get_dr – "Ahrefs Domain Rating (0–100) for domains or URLs, via getdr by Index Pages".

argumenttype
targetsstring[]required, non-empty; domains or URLs
version"dr3" or "dr4"DR formula; when left out, the backend's config decides: the getdr server's with GETDR_API, otherwise the binary's (also when that binary uses a server), dr3 unless set; values are not comparable between versions
freshbooleanignore the cache and fetch again

Targets are normalized by getdr: a URL becomes its host, www. is dropped, everything is lower-cased and duplicates are removed. Results follow the input order.

Output

The text result is a JSON array with one record per target, and nothing else:

[{"target":"ahrefs.com","dr":91,"version":"dr3","checked_at":"2026-10-28T12:00:00Z","cached":true},{"target":"nodata.example","dr":null,"version":"dr3","checked_at":"2026-10-28T12:00:00Z","cached":false}]

The record is the getdr JSON contract, the same as getdr --format json and getdr serve. dr is null when Ahrefs has no data; checked_at is null too when there was no response or the target is invalid. An invalid target (not a domain or URL, or refused by Ahrefs, such as localhost) also has "error":"invalid target"; no other record has an error key. Clients on MCP protocol 2025-06-18 or later also get structuredContent – {"results": […]} – and an outputSchema for it.

Invalid targets and targets without a response are part of a normal result. Failures come back as a tool error (isError: true) with getdr's message:

  • no target got a response at all;
  • getdr server answered 401 – the token is missing or wrong, set GETDR_SERVE_TOKEN;
  • getdr server answered 503, or the binary exited with code 3 – the Ahrefs key is missing or rejected;
  • the server is unreachable, the binary failed, or a call timed out.

Supported MCP protocol versions: 2026-07-28 (stateless: server/discover and per-request _meta, no handshake) and the initialize-based 2025-11-25, 2025-06-18, 2025-03-26 and 2024-11-05, served side by side.

Attribution

Domain Rating data comes from Ahrefs and is subject to the Domain Rating License, which requires the attribution "Domain Rating by Ahrefs" wherever you publish the numbers. The tool result carries only the data, with no attribution in it.

getdr is not affiliated with Ahrefs.

No telemetry

getdr-mcp connects to exactly one place: the getdr server in GETDR_API, when you set it. Otherwise it only starts the getdr binary. No telemetry, no update checks, no analytics, no pings. Requests carry the User-Agent getdr-mcp/<version> (+https://index-pages.com/getdr). You can verify this in the source: the only outgoing request and the only child process are in src/backends.ts.

Development

sh
npm cinpm run buildnpm test

The backend tests build getdr and its mock-backed server from the getdr source tree (../bin, or GETDR_SRC) and need Go; without it they are skipped. The live check runs only when AHREFS_KEY is set.

Releasing

Bump the version in package.json, server.json (twice) and src/version.ts, update CHANGELOG.md, then push a tag vX.Y.Z. .github/workflows/release.yml builds, runs the tests against the getdr source at the same tag, checks that every version matches the tag and that the packed tarball holds dist/index.js with its shebang, and publishes with npm trusted publishing (OIDC, no token, provenance included).

Trusted publishing can only be configured for a package that already exists on npm, so the first release is published by hand once: npm login, then npm run release. Right after that, add the trusted publisher on npmjs.com (package Settings → Trusted publishing: GitHub Actions, index-pages / getdr-mcp, workflow release.yml); the workflow has to complete its first publish within 2 days or the configuration expires.

For any manual publish use npm run release (build, tests, check-release, npm publish), never a bare npm publish: with install scripts disabled (ignore-scripts) prepack does not run and the package would ship without dist/. prepack stays as a fallback for setups that run scripts.

The same workflow then publishes server.json to the MCP Registry as io.github.index-pages/getdr-mcp: it waits until npm shows the new version (the registry checks mcpName in the npm package), proves the index-pages namespace with the workflow's OIDC token (mcp-publisher login github-oidc, no secret) and runs mcp-publisher publish with a pinned, checksummed mcp-publisher. A version already in the registry is skipped.

License

MIT, see LICENSE. Made by Index Pages.

来源:README.md,提交 01c586b

工具

0
SourceWeft 尚未在沙箱中启动过该软件包,因此其工具未知。

版本历史

1
  1. v0.2.0最新Oct 29, 2026

评分

已满足适用检查项的 50%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分

    请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。

  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具15 分

    请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。

  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分