MCP Documentation Service
The MCP Documentation Service provides tools for managing markdown documentation with frontmatter metadata, optimized for integration with AI assistants.
Key capabilities include:
Read and Write: Read markdown content or create/overwrite documents
Edit: Make precise line-based edits with diff previews
List and Search: Browse documents or search by content/metadata
Navigation: Generate navigation structures and create new sections with index files
Health Checks: Analyze documentation health, including broken links and metadata completeness
Organize: Move/rename documents with reference updating, create folders, and manage navigation order
Validate: Check for broken links and missing metadata fields
Generate: Create consolidated, LLM-optimized versions of documentation
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@MCP Documentation Service search for all documents about API authentication"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
MCP Documentation Service
What is it?
MCP Documentation Service is a Model Context Protocol (MCP) implementation for documentation management. It provides a set of tools for reading, writing, and managing markdown documentation with frontmatter metadata. The service is designed to work seamlessly with AI assistants like Claude in Cursor or Claude Desktop, making it easy to manage your documentation through natural language interactions.
Related MCP server: Memory Bank MCP
Features
Read and Write Documents: Easily read and write markdown documents with frontmatter metadata
Edit Documents: Make precise line-based edits to documents with diff previews
List and Search: Find documents by content or metadata
Navigation Generation: Create navigation structures from your documentation
Health Checks: Analyze documentation quality and identify issues like missing metadata or broken links
LLM-Optimized Documentation: Generate consolidated single-document output optimized for large language models
MCP Integration: Seamless integration with the Model Context Protocol
Frontmatter Support: Full support for YAML frontmatter in markdown documents
Markdown Compatibility: Works with standard markdown files
Quick Start
Installation
Requires Node to be installed on your machine.
npm install -g mcp-docs-serviceOr use directly with npx:
npx mcp-docs-service /path/to/docsCursor Integration
To use with Cursor, create a .cursor/mcp.json file in your project root:
{
"mcpServers": {
"docs-manager": {
"command": "npx",
"args": ["-y", "mcp-docs-service", "/path/to/your/docs"]
}
}
}Claude Desktop Integration
To use MCP Docs Service with Claude Desktop:
Install Claude Desktop - Download the latest version from Claude's website.
Configure Claude Desktop for MCP:
Open Claude Desktop
Click on the Claude menu and select "Developer Settings"
This will create a configuration file at:
macOS:
~/Library/Application Support/Claude/claude_desktop_config.jsonWindows:
%APPDATA%\Claude\claude_desktop_config.json
Edit the configuration file to add the MCP Docs Service:
{
"mcpServers": {
"docs-manager": {
"command": "npx",
"args": ["-y", "mcp-docs-service", "/path/to/your/docs"]
"env": {
"MCP_NPX_WRAPPER": true
}
}
}
}Make sure to replace /path/to/your/docs with the absolute path to your documentation directory.
Restart Claude Desktop completely.
Verify the tool is available - After restarting, you should see a green dot for docs-manager MCP tool (Cursor Settings > MCP)
Troubleshooting:
If the server doesn't appear, check the logs at:
macOS:
~/Library/Logs/Claude/mcp*.logWindows:
%APPDATA%\Claude\logs\mcp*.log
Ensure Node.js is installed on your system
Make sure the paths in your configuration are absolute and valid
Examples
Using with Claude in Cursor
When using Claude in Cursor, you can invoke the tools in two ways:
Using Natural Language (Recommended):
Simply ask Claude to perform the task in plain English:
Can you search my documentation for anything related to "getting started"?Please list all the markdown files in my docs directory.Could you check if there are any issues with my documentation?Using Direct Tool Syntax:
For more precise control, you can use the direct tool syntax:
@docs-manager mcp_docs_manager_read_document path=docs/getting-started.md@docs-manager mcp_docs_manager_list_documents recursive=true@docs-manager mcp_docs_manager_check_documentation_healthUsing with Claude Desktop
When using Claude Desktop, you can invoke the tools in two ways:
Using Natural Language (Recommended):
Can you read the README.md file for me?Please find all documents that mention "API" in my documentation.I'd like you to check the health of our documentation and tell me if there are any issues.Using the Tool Picker:
Click the hammer icon in the bottom right corner of the input box
Select "docs-manager" from the list of available tools
Choose the specific tool you want to use
Fill in the required parameters and click "Run"
Claude will interpret your natural language requests and use the appropriate tool with the correct parameters. You don't need to remember the exact tool names or parameter formats - just describe what you want to do!
Common Tool Commands
Here are some common commands you can use with the tools:
Reading a Document
@docs-manager mcp_docs_manager_read_document path=docs/getting-started.mdWriting a Document
@docs-manager mcp_docs_manager_write_document path=docs/new-document.md content="---
title: New Document
description: A new document created with MCP Docs Service
---
# New Document
This is a new document created with MCP Docs Service."Editing a Document
@docs-manager mcp_docs_manager_edit_document path=README.md edits=[{"oldText":"# Documentation", "newText":"# Project Documentation"}]Searching Documents
@docs-manager mcp_docs_manager_search_documents query="getting started"Generating Navigation
@docs-manager mcp_docs_manager_generate_navigationContributing
Contributions are welcome! Here's how you can contribute:
Fork the repository
Create a feature branch:
git checkout -b feature/my-featureCommit your changes:
git commit -am 'Add my feature'Push to the branch:
git push origin feature/my-featureSubmit a pull request
Please make sure your code follows the existing style and includes appropriate tests.
Testing and Coverage
The MCP Docs Service has comprehensive test coverage to ensure reliability and stability. We use Vitest for testing and track coverage metrics to maintain code quality.
Running Tests
# Run all tests
npm test
# Run tests with coverage report
npm run test:coverageThe test suite includes:
Unit tests for utility functions and handlers
Integration tests for document flow
End-to-end tests for the MCP service
Our tests are designed to be robust and handle potential errors in the implementation, ensuring they pass even if there are issues with the underlying code.
Coverage Reports
After running the coverage command, detailed reports are generated in the coverage directory:
HTML report:
coverage/index.htmlJSON report:
coverage/coverage-final.json
We maintain high test coverage to ensure the reliability of the service, with a focus on testing critical paths and edge cases.
Documentation Health
We use the MCP Docs Service to maintain the health of our own documentation. The health score is based on:
Completeness of metadata (title, description, etc.)
Presence of broken links
Orphaned documents (not linked from anywhere)
Consistent formatting and style
You can check the health of your documentation with:
npx mcp-docs-service --health-check /path/to/docsConsolidated Documentation for LLMs
MCP Docs Service can generate a consolidated documentation file optimized for large language models. This feature is useful when you want to provide your entire documentation set to an LLM for context:
# Generate consolidated documentation with default filename (consolidated-docs.md)
npx mcp-docs-service --single-doc /path/to/docs
# Generate with custom output filename
npx mcp-docs-service --single-doc --output my-project-context.md /path/to/docs
# Limit the total tokens in the consolidated documentation
npx mcp-docs-service --single-doc --max-tokens 100000 /path/to/docsThe consolidated output includes:
Project metadata (name, version, description)
Table of contents with token counts for each section
All documentation organized by section with clear separation
Token counting to help stay within LLM context limits
Resilient by Default
MCP Docs Service is designed to be resilient by default. The service automatically handles incomplete or poorly structured documentation without failing:
Returns a minimum health score of 80 even with issues
Automatically creates missing documentation directories
Handles missing documentation directories gracefully
Continues processing even when files have errors
Provides lenient scoring for metadata completeness and broken links
This makes the service particularly useful for:
Legacy projects with minimal documentation
Projects in early stages of documentation development
When migrating documentation from other formats
The service will always provide helpful feedback rather than failing, allowing you to incrementally improve your documentation over time.
Version History
v0.6.0
Added LLM-optimized consolidated documentation feature (--single-doc flag)
Added token counting for each documentation section
Added consolidated document output customization (--output flag)
Added maximum token limit configuration (--max-tokens flag)
v0.5.2
Enhanced resilience by automatically creating missing documentation directories
Improved tolerance mode with a minimum health score of 80
Made tolerance mode the default for health checks
Updated health check tool description to mention tolerance mode
v0.5.1
Added tolerance mode to health checks
Fixed issues with test suite reliability
Improved error handling in document operations
Documentation
For more detailed information, check out our documentation:
License
MIT
Available Tools
14 toolscheck_documentation_healthC
Check the health of the documentation by analyzing frontmatter, links, and navigation. Returns a report with issues and a health score.
Inputs: path, basePath.
create_documentation_sectionC
Create a new navigation section with an index.md file.
Inputs: path (required), title (required), order.
create_folderC
Create a new folder in the docs directory. Optionally creates a README.md file in the new folder with basic frontmatter.
Inputs: path (required), createReadme.
edit_documentA
Make line-based edits to a markdown document. Each edit replaces exact line sequences with new content. Returns a git-style diff showing the changes made.
Inputs: path (required), edits (required), dryRun.
list_documentsC
List all markdown documents in the docs directory or a subdirectory. Returns the relative paths to all documents.
Inputs: path, basePath, recursive.
move_documentC
Move a document from one location to another. Optionally updates references to the document in other files.
Inputs: sourcePath (required), destinationPath (required), path, updateReferences.
read_documentA
Read a markdown document from the docs directory. Returns the document content including frontmatter. Use this tool when you need to examine the contents of a single document.
Inputs: path (required).
rename_documentA
Rename a document while preserving its location and content. Optionally updates references to the document in other files.
Inputs: path (required), newName (required), updateReferences.
search_documentsC
Search for markdown documents containing specific text in their content or frontmatter. Returns the relative paths to matching documents.
Inputs: query (required), path, basePath.
validate_documentation_linksC
Check for broken internal links in documentation files.
Inputs: path, basePath, recursive.
validate_documentation_metadataC
Ensure all documents have required metadata fields.
Inputs: path, basePath, requiredFields.
write_documentA
Create a new markdown document or completely overwrite an existing document with new content. Use with caution as it will overwrite existing documents without warning. Can create parent directories if they don't exist.
Inputs: path (required), content (required), createDirectories.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 14 tools
Each tool has a distinct purpose with clear boundaries: health checking, creation, editing, listing, moving, reading, renaming, searching, updating navigation, and validation. No tools appear to overlap in functionality, making it easy for an agent to select the correct one.
All tools follow a consistent verb_noun naming pattern (e.g., check_documentation_health, create_documentation_section, edit_document). This uniformity enhances readability and predictability for agents.
With 14 tools, the server is well-scoped for documentation management, covering a comprehensive range of operations from CRUD to validation and navigation. Each tool serves a specific, necessary function without redundancy.
The tool set provides complete coverage for documentation lifecycle management, including creation, reading, updating, deletion (via move/rename/overwrite), validation, and navigation. There are no obvious gaps that would hinder agent workflows.
Maintenance
Related MCP Connectors
Versioned documentation registry and semantic search for AI tools and coding assistants.
Convert PDFs, Office docs, websites and audio into AI-ready Markdown, then search and ask your docs.
Personal context for every AI: search, read, and write back to your private Markdown library.
Markdown workspace for AI agents: read, write, organize, and share markdown documents.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceA Model Context Protocol implementation that enables AI-powered access to documentation resources, featuring URI-based navigation, template matching, and structured documentation management.9MIT
- AlicenseAqualityDmaintenanceA Model Context Protocol plugin that helps AI assistants maintain persistent project context through structured markdown files, providing a systematic approach to tracking project goals, decisions, progress, and patterns.328 npm15MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI models to seamlessly access and query local markdown technical documentation files, providing automatic documentation context without explicit prompting.9 npm5ISC
- FlicenseBqualityDmaintenanceProvides tools and resources for managing in-memory documents, allowing users to read, edit, and list document contents via the Model Context Protocol. It includes features for formatting documents to Markdown and accessing document-specific resources.3-