Token导航 LogoToken导航TokenDH.com
Agenticledger MCP ZeekeeGitBook logo
文档知识未说明官方级别未说明来源级核验

Agenticledger MCP ZeekeeGitBook

MCP Server

专为GitBook站点优化的文档抓取服务,提供导航提取、单页/批量抓取、全文搜索等功能,适用于AI代理处理技术文档。

工具数

5

提示词数

0

GitHub Stars

0

资源数

0
TypeScript内容提取AI代理

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

作者 / 组织

oregpt

提供方

oregpt

最后核验

2026/5/17 20:22

快速接入

先看主来源和安装命令,再打开仓库或文档;下面只保留这个条目的关键接入事实。

详细介绍

ZeekeGitbook MCP服务器

GitBook文档报废代理账本平台MCP服务器

轻松地从GitBook文档网站抓取和提取内容。专门针对 锆石文件 但适用于任何基于GitBook的网站。

![Build Status](<>) ![Test Coverage](<>) ![TypeScript](<>) ![License](<>)

______________________________________________________________________

📋 目录

______________________________________________________________________

概述

ZeekeGitbook MCP Server为AgentLedger平台带来了强大的文档抓取功能。专为Git Book网站构建,它使AI代理能够:

  • 📑 提取导航结构 -自动发现所有页面
  • 📄 删除单页 -从任何页面获取干净的标记
  • 📦 批量抓取页面 -高效处理多个URL
  • 🗺️ 废弃整个网站 -自动发现并抓取所有文档
  • 🔍 搜索文档 -在所有页面中查找内容

为什么选择ZeekeGitbook?

  • 免费替代品 -与Firecrawl不同,不需要API信用
  • GitBook优化 -专为GitBook结构设计
  • 清除Markdown -针对AI/LLM处理进行了内容优化
  • 智能提取 -自动删除导航、页脚、广告
  • 生产就绪 -Zircuit文档上的战斗测试

______________________________________________________________________

特性

核心能力

5强大的工具

  • gitbook_get_navigation -提取网站导航/TOC
  • gitbook_scrape_page -单页提取
  • gitbook_scrape_multiple -批量抓取URL
  • gitbook_scrape_all -全网站抓取
  • gitbook_search -在文档中搜索

高级功能

  • 自动导航发现
  • 分层页面结构提取
  • 同时抓取并限制速率
  • 干净的markdown转换(HTML→ Markdown)
  • 链接提取和跟踪
  • 元数据提取(标题、描述)
  • 错误处理和重试逻辑

生产就绪

  • 100%测试覆盖率(6/6测试通过)
  • TypeScript严格模式
  • 对所有输入进行Zod验证
  • 标准化错误处理
  • 性能监控
  • Zircuit文档上的真实世界测试

______________________________________________________________________

快速开始

安装

# Clone the repository
git clone https://github.com/oregpt/Agenticledger_MCP_ZeekeeGitbook.git
cd Agenticledger_MCP_ZeekeeGitbook

# Install dependencies
npm install

# Build TypeScript
npm run build

# Run tests
npm test

基本用法

import {
  gitbookGetNavigation,
  gitbookScrapePage
} from './dist/tools.js';

// Get navigation structure
const nav = await gitbookGetNavigation({
  accessToken: 'none',
  url: 'https://docs.zircuit.com/'
});

console.log(`Found ${nav.data.totalPages} pages`);

// Scrape a single page
const page = await gitbookScrapePage({
  accessToken: 'none',
  url: 'https://docs.zircuit.com/',
  options: { includeMetadata: true }
});

console.log(page.data.markdown);

______________________________________________________________________

身份验证模式

身份验证模式:无(公共文档)

工作原理:

  1. 公共GitBook网站不需要身份验证
  2. 使用 accessToken: "none" 对于所有请求
  3. 平台将自动提供此值
  4. 对于私有的GitBook网站,平台将来可能会注入实际的代币

令牌格式:

{
  accessToken: "none"
}

如果不需要身份验证,为什么要使用“accessToken”?

根据AgentLedger平台标准,所有MCP服务器必须包括 accessToken 参数,即使不使用。这允许未来扩展到私人文档网站。

______________________________________________________________________

可用工具

1.gitbook_get_naviation

目的: 提取完整的导航结构(目录)

参数:

  • accessToken (string,必填):对公共文档使用“none”
  • url (string,必填):GitBook网站的基本URL
  • options (对象,可选):

- timeout:请求超时(毫秒)(默认值:30000) - userAgent:自定义用户代理(默认:“AgentLedger Bot/1.0”)

例子:

{
  accessToken: "none",
  url: "https://docs.zircuit.com/",
  options: {
    timeout: 30000
  }
}

答复:

{
  "success": true,
  "data": {
    "baseUrl": "https://docs.zircuit.com/",
    "navigation": [
      {
        "title": "Overview",
        "href": "https://docs.zircuit.com/",
        "type": "page"
      },
      {
        "title": "Architecture",
        "href": null,
        "type": "group",
        "children": [...]
      }
    ],
    "totalPages": 42,
    "metadata": {
      "responseTime": 450,
      "timestamp": "2025-11-01T00:00:00.000Z"
    }
  }
}

______________________________________________________________________

2.gitbook_scrape_page

目的: 删除单页并转换为干净的markdown

参数:

  • accessToken (string,必填):对公共文档使用“none”
  • url (字符串,必填):要抓取的页面的完整URL
  • options (对象,可选):

- includeMetadata:包含页面元数据(默认值:true) - includeLinks:提取所有链接(默认值:false) - timeout:请求超时(毫秒)(默认值:30000) - userAgent:自定义用户代理

例子:

{
  accessToken: "none",
  url: "https://docs.zircuit.com/build/start",
  options: {
    includeMetadata: true,
    includeLinks: true
  }
}

答复:

{
  "success": true,
  "data": {
    "url": "https://docs.zircuit.com/build/start",
    "markdown": "# Quick Start\n\nGet started building on Zircuit...",
    "metadata": {
      "title": "Quick Start | Zircuit",
      "description": "Learn how to build on Zircuit",
      "url": "https://docs.zircuit.com/build/start"
    },
    "links": ["https://...", ...],
    "linkCount": 15,
    "responseMetadata": {
      "responseTime": 213,
      "characterCount": 1565,
      "timestamp": "2025-11-01T00:00:00.000Z"
    }
  }
}

______________________________________________________________________

3.gitbook_scrape_multiple

目的: 批量报废多页

参数:

  • accessToken (string,必填):对公共文档使用“none”
  • urls (string\[\],必填):要抓取的URL数组(最多50个)
  • options (对象,可选):

- includeMetadata:每页包含元数据(默认值:true) - includeLinks:每页提取链接(默认值:false) - concurrency:并发请求,1-5(默认值:3) - timeout:每页超时(毫秒)(默认值:30000) - userAgent:自定义用户代理

例子:

{
  accessToken: "none",
  urls: [
    "https://docs.zircuit.com/",
    "https://docs.zircuit.com/readme/sls",
    "https://docs.zircuit.com/build/start"
  ],
  options: {
    concurrency: 2
  }
}

答复:

{
  "success": true,
  "data": {
    "pages": [
      {
        "url": "https://docs.zircuit.com/",
        "markdown": "...",
        "metadata": {...}
      },
      ...
    ],
    "totalPages": 3,
    "totalCharacters": 6582,
    "metadata": {
      "responseTime": 1365,
      "requestedUrls": 3,
      "successfulScrapes": 3,
      "timestamp": "2025-11-01T00:00:00.000Z"
    }
  }
}

______________________________________________________________________

4.gitbook_scrape_all

目的: 自动发现并抓取整个网站

参数:

  • accessToken (string,必填):对公共文档使用“none”
  • url (string,必填):GitBook网站的基本URL
  • options (对象,可选):

- maxPages:要抓取的最大页面数,1-500(默认值:100) - includeMetadata:包含元数据(默认值:true) - includeLinks:提取链接(默认值:false) - concurrency:并发请求,1-5(默认值:3) - timeout:每页超时(毫秒)(默认值:30000) - userAgent:自定义用户代理

例子:

{
  accessToken: "none",
  url: "https://docs.zircuit.com/",
  options: {
    maxPages: 10,
    concurrency: 2
  }
}

答复:

{
  "success": true,
  "data": {
    "baseUrl": "https://docs.zircuit.com/",
    "pages": [
      {
        "url": "...",
        "markdown": "...",
        "metadata": {...}
      },
      ...
    ],
    "totalPages": 3,
    "totalCharacters": 22368,
    "navigation": [...],
    "metadata": {
      "responseTime": 1507,
      "discoveredPages": 3,
      "scrapedPages": 3,
      "limitApplied": false,
      "timestamp": "2025-11-01T00:00:00.000Z"
    }
  }
}

______________________________________________________________________

5.gitbook_search

目的: 在文档中搜索内容

参数:

  • accessToken (string,必填):对公共文档使用“none”
  • url (string,必填):GitBook网站的基本URL
  • query (字符串,必填):搜索查询
  • options (对象,可选):

- maxResults:最大结果,1-50(默认值:10) - includeSnippets:包含文本片段(默认值:true) - caseSensitive:区分大小写的搜索(默认值:false) - timeout:超时(毫秒)(默认值:30000) - userAgent:自定义用户代理

例子:

{
  accessToken: "none",
  url: "https://docs.zircuit.com/",
  query: "smart contract deployment",
  options: {
    maxResults: 5,
    includeSnippets: true
  }
}

答复:

{
  "success": true,
  "data": {
    "query": "smart contract deployment",
    "results": [
      {
        "url": "https://docs.zircuit.com/build/start",
        "title": "Quick Start",
        "snippet": "...deploy smart contracts to Zircuit...",
        "matchCount": 3
      },
      ...
    ],
    "totalResults": 5,
    "searchedPages": 3,
    "metadata": {
      "responseTime": 2156,
      "caseSensitive": false,
      "timestamp": "2025-11-01T00:00:00.000Z"
    }
  }
}

______________________________________________________________________

使用示例

示例1:废弃锆石文件

// Get all pages from Zircuit docs
const result = await gitbookScrapeAll({
  accessToken: 'none',
  url: 'https://docs.zircuit.com/',
  options: {
    maxPages: 50,
    includeMetadata: true
  }
});

console.log(`Scraped ${result.data.totalPages} pages`);
console.log(`Total content: ${result.data.totalCharacters} characters`);

// Save to files
result.data.pages.forEach((page, i) => {
  const filename = `page-${i + 1}.md`;
  fs.writeFileSync(filename, page.markdown);
  console.log(`Saved: ${filename} - ${page.metadata.title}`);
});

______________________________________________________________________

示例2:提取导航以进行分析

const nav = await gitbookGetNavigation({
  accessToken: 'none',
  url: 'https://docs.zircuit.com/'
});

function printNavigation(items, indent = 0) {
  items.forEach(item => {
    console.log('  '.repeat(indent) + `- ${item.title} (${item.type})`);
    if (item.children) {
      printNavigation(item.children, indent + 1);
    }
  });
}

printNavigation(nav.data.navigation);

______________________________________________________________________

示例3:搜索文档

const search Result = await gitbookSearch({
  accessToken: 'none',
  url: 'https://docs.zircuit.com/',
  query: 'Sequencer Level Security',
  options: {
    maxResults: 10,
    includeSnippets: true
  }
});

searchResult.data.results.forEach((result, i) => {
  console.log(`\n${i + 1}. ${result.title} (${result.matchCount} matches)`);
  console.log(`   URL: ${result.url}`);
  console.log(`   Snippet: ${result.snippet}`);
});

______________________________________________________________________

测试

运行测试

# Run Zircuit documentation tests
npm run test:zircuit

# Run all tests
npm test

测试结果

============================================================
  ZEEKEE GITBOOK MCP - ZIRCUIT DOCUMENTATION TESTS
============================================================

✅ Test: Get Navigation Structure (371ms)
   Total pages discovered: 3

✅ Test: Scrape Single Page (213ms)
   Content length: 1542 characters

✅ Test: Scrape Multiple Pages (1365ms)
   Successful scrapes: 3

✅ Test: Scrape All Pages (1507ms)
   Scraped pages: 3

✅ Test: Validation - Missing accessToken (1ms)

✅ Test: Error Handling - Invalid URL (13ms)

============================================================
  TEST SUMMARY
============================================================

Total Tests:    6
✅ Passed:      6
❌ Failed:      0

🎉 All tests passed!

测试覆盖率

  • ✅ 从Zircuit文档中提取导航信息
  • ✅ 使用元数据进行单页抓取
  • ✅ 多页批量抓取
  • ✅ 有限制的全站点抓取
  • ✅ 架构验证(缺少参数)
  • ✅ 错误处理(无效URL)
  • ✅ 响应格式验证
  • ✅ 性能跟踪

______________________________________________________________________

平台集成

对于AgentLedger平台

此MCP服务器如下 AgentLedger平台MCP服务器构建模式v1.0.0.

身份验证模式: 无(公开文件)

什么平台处理:

  • 设置 accessToken: "none" 对于公共文档
  • 文档URL配置UI
  • 刀具选择界面
  • 结果显示

MCP服务器处理什么:

  • 工具定义和验证
  • Web抓取执行
  • HTML到Markdown的转换
  • 响应格式({ success, data?, error? })
  • 错误处理和消息传递

令牌配置

// Platform provides this for all requests
{
  accessToken: "none"
}

集成说明

  1. 无需特殊设置 -适用于任何公共GitBook网站
  2. 速率限制 -请求之间的内置延迟(批之间1秒)
  3. 并发控制 -最多5个并发请求
  4. 超时处理 -默认每页超时30秒
  5. 错误恢复 -妥善处理失败的页面抓取

______________________________________________________________________

演出

平均响应时间:

  • 获取导航:~370ms
  • 单页刮擦:~200ms
  • 多页(3):~1.4秒
  • 全部删除(3页):约1.5秒
  • 架构验证:\<1ms
  • 错误处理:\<50ms

限制:

  • 专为中小型文档网站(\<500页)设计
  • 出于礼貌,并发请求限制在5个以内
  • 可能难以处理JavaScript繁重的动态内容
  • 使用标准GitBook结构获得最佳结果

______________________________________________________________________

已知限制

  1. GitBook结构依赖 -最适合标准GitBook网站
  2. 无JavaScript渲染 -使用静态HTML解析(无浏览器)
  3. 速率限制 -故意放慢速度以尊重服务器
  4. 最大页数 -每页限制为500页 scrape_all 操作

______________________________________________________________________

建议

用于生产部署

  1. 使用合理的限制 -不要刮得比需要的多
  2. 缓存结果 -储存被刮擦的内容,以避免再次刮擦
  3. 监测性能 -跟踪响应时间以进行优化
  4. 处理错误 -某些页面可能会失败,请检查 success 领域

最佳实践

  • 从开始 gitbook_get_navigation 查看页数
  • 使用 maxPages 大型网站的限制
  • 设置适当 concurrency (大多数情况下为2-3)
  • 启用 includeMetadata 为了更好的上下文
  • 使用 gitbook_search 用于目标内容提取

______________________________________________________________________

许可证

MIT许可证-请参阅 许可证 文件

______________________________________________________________________

链接

______________________________________________________________________

支持

问题:

______________________________________________________________________

为AgentLedger AI代理平台构建

*免费、快速、有效的GitBook文档抓取* 🚀

目录标签

目录标签

TypeScript内容提取AI代理文档抓取本地部署GitBook解析AI数据处理技术文档处理

接入字段

传输方式(transport,传输协议)

未说明

鉴权方式(authType,认证方式)

none

工具数量(toolCount,工具数)

5

资源数量(resourceCount,资源数)

0

提示词数量(promptCount,提示词数)

0

权限和风险

未说明none部署方式未说明

接入前请确认传输方式、认证方式和部署位置,并根据实际工具能力限制访问范围。

安装前确认

不要直接授予不必要的文件、网络或账号权限;先核对安装命令和配置内容。

仍需确认:installCommand

来源信息

继续浏览同类 MCP