Skip to content

feat: add @mcp-framework/docs package#144

Merged
QuantGeekDev merged 2 commits intomainfrom
feat/mcp-framework-docs
Apr 1, 2026
Merged

feat: add @mcp-framework/docs package#144
QuantGeekDev merged 2 commits intomainfrom
feat/mcp-framework-docs

Conversation

@QuantGeekDev
Copy link
Copy Markdown
Owner

Summary

  • Adds @mcp-framework/docs — a new package in packages/docs/ that lets API providers spin up an MCP documentation server from their Fumadocs site or any site with llms.txt
  • AI agents in Claude Code, Cursor, or any MCP client get search_docs, get_page, and list_sections tools to search, browse, and retrieve documentation
  • Ships with two source adapters (LlmsTxtSource, FumadocsRemoteSource), in-memory LRU cache, token budget utilities, custom error classes, CLI scaffolder (npx create-docs-server), and a SKILL.md companion template
  • 76 tests across 9 suites (unit + integration), all passing

Package structure

packages/docs/
├── src/
│   ├── sources/       # DocSource interface, llms.txt parser, adapters
│   ├── tools/         # SearchDocsTool, GetPageTool, ListSectionsTool
│   ├── cache/         # MemoryCache (LRU + TTL)
│   ├── utils/         # Token estimation & truncation
│   ├── cli/           # create-docs-server scaffolder
│   ├── errors.ts      # Typed error hierarchy
│   ├── server.ts      # DocsServer wrapper
│   └── index.ts       # Public API
├── tests/             # 76 tests (unit + integration)
├── templates/         # Project scaffold templates
└── README.md          # Full documentation

Test plan

  • npm run build compiles cleanly (strict TS, Node16 modules)
  • 76 tests pass across 9 suites (npm test in packages/docs/)
  • Integration tests boot a real HTTP server with fixture data
  • npm pack --dry-run produces clean tarball (59 files, 25.5 KB)
  • All 4 export subpaths verified (root, /sources, /tools, /cache)
  • Verify no regressions in parent mcp-framework tests

🤖 Generated with Claude Code

QuantGeekDev and others added 2 commits April 1, 2026 17:24
New package that lets API providers spin up an MCP documentation server
from their Fumadocs site or any site with llms.txt. AI agents in Claude
Code, Cursor, or any MCP client get tools to search, browse, and retrieve
documentation — enabling correct integration code on the first try.

Includes:
- DocSource interface and core types
- LlmsTxtSource and FumadocsRemoteSource adapters
- SearchDocsTool, GetPageTool, ListSectionsTool (extending MCPTool)
- DocsServer convenience wrapper with auto-registration
- MemoryCache with LRU eviction and TTL
- CLI scaffolder (npx create-docs-server)
- 76 tests across 9 suites (unit + integration)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Covers overview, sources, tools, server config, caching, CLI scaffolding,
custom adapters, and Fumadocs setup guide.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@QuantGeekDev QuantGeekDev merged commit 6bfa4f4 into main Apr 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant