npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@zero-ai-bits/doc-spider-mcp

v1.0.0

Published

MCP server for reading webpages and extracting technical docs.

Readme

Doc Spider MCP 🕷️

doc-spider-mcp 是一个支持 Model Context Protocol (MCP) 的网页阅读与抓取服务。它利用 Playwright 与 Readability,完美支持现代单页应用 (SPA) 与技术文档的内容抓取,自动提取网页的核心 Markdown 内容,并智能追踪“下一页”或侧边栏菜单,帮助大模型(LLM)实现批量、有序的技术文档学习。

🌟 特性

  • 精准内容提取:基于 @mozilla/readability,自动过滤广告、页脚等无关信息。
  • SPA/现代文档友好:底层使用 Playwright 无头浏览器,轻松应对 Docusaurus, VitePress, Next.js 等前端渲染文档。
  • Token 极简:利用 Turndown 将网页提取为干净的 Markdown 格式。
  • 智能链接分析:自动寻找文档的 [下一页] 按钮和侧边栏菜单结构。
  • 批量序列阅读:支持输入首个文档页面,自动顺藤摸瓜抓取整个教程序列。

📦 安装与配置

作为 MCP 服务使用时,推荐直接在支持 MCP 的 IDE(如 Cursor, Claude Desktop, Antigravity)中通过 npx 运行:

Cursor / Antigravity 配置示例

"mcpServers": {
  "doc-spider": {
    "command": "npx",
    "args": ["-y", "doc-spider-mcp"]
  }
}

Claude Desktop 配置示例 (claude_desktop_config.json)

{
  "mcpServers": {
    "doc-spider": {
      "command": "npx",
      "args": ["-y", "doc-spider-mcp"]
    }
  }
}

🛠️ MCP 工具列表 (Tools)

本服务提供以下核心 MCP Tools 供大模型调用:

  1. read_page

    • 描述:读取指定网页,提取核心内容为 Markdown,并获取该网页的下一页链接及同级菜单。
    • 参数url (string)
  2. read_docs_sequence

    • 描述:自动序列阅读文档。给定起始页,会自动点击“下一页”抓取指定页数,最后合并输出。适合一口气阅读长篇教程或完整的 API 说明。
    • 参数startUrl (string), maxPages (number, 默认 3)
  3. extract_page_menu

    • 描述:仅提取页面的导航链接和菜单(不抓取正文),帮助 AI 快速了解站点的文档架构。
    • 参数url (string)

💻 开发者本地调试

# 安装依赖
npm install

# 编译 TypeScript
npm run build

# 运行 MCP Server
npm start