What is read-docs-mcp?
read-docs-mcp is a Model Context Protocol (MCP) server that enables AI agents to access and understand package documentation through a structured interface. It supports two modes: Read Documentation Mode, which reads docs from a given git repository, and Create Documentation Mode, which guides users in setting up documentation files. It is intended for developers who want AI assistants to explore or create documentation for their libraries.
How to use read-docs-mcp?
read-docs-mcp is invoked via npx -y read-docs-mcp with optional command-line arguments such as --name, --git-repo-path, --branch, --docs-path, and --clone-location. It can be configured in Cursor by adding a JSON block to the Cursor settings under mcpServers. For Read Documentation Mode, provide both --name and --git-repo-path; omit them to use Create Documentation Mode.
Key features of read-docs-mcp
- Dual usage modes: read existing documentation or create documentation structure
- Automatically generates MCP tools from documentation structure
- Supports multiple documentation modules (hooks, components, utilities, etc.)
- Configurable naming patterns for documentation files and module folders
- Provides listing, overview, and detailed documentation access per module
- Falls back to package.json for version information when not specified in config
Use cases of read-docs-mcp
- Explore available modules and hooks of a library through an AI agent
- Retrieve detailed documentation for a specific component or utility
- Guide the creation of a documentation folder structure and configuration files
- Learn how to use individual features (e.g., authentication, form validation) from documentation
- Set up documentation for a library being developed, with step-by-step instructions
评论