mcpField
@
@tiberriver256/docs-to-mcp-cli

@tiberriver256/docs-to-mcp-cli

Local
github.com/Tiberriver256Memory & Knowledge2Updated 80w ago

About @tiberriver256/docs-to-mcp-cli

@tiberriver256/docs-to-mcp-cli is a CLI that turns Markdown documentation into a runnable, self-contained MCP server. It gives AI assistants tools to list, search, and retrieve documents.

Key features

  1. 01Generate a bundled MCP server
  2. 02Select Markdown files with glob patterns
  3. 03List documents with previews
  4. 04Retrieve full document contents
  5. 05Fuzzy search across documents

Use cases

  1. 01Expose project documentation to AI assistants
  2. 02Create a searchable MCP endpoint from Markdown files

MCP support

The CLI generates a stdio MCP server exposing `list_docs`, `get_doc`, and `search_docs` tools for connected MCP clients.

Configuration

Local server config is the same for every client. Copy it into your client’s MCP config file.

mcp.json · Universal config
{
"mcpServers": {
"docs-to-mcp-cli": {
"command": "npx",
"args": [
"-y",
"@tiberriver256/docs-to-mcp-cli"
]
}
}
}
Run commandnpx -y @tiberriver256/docs-to-mcp-cli

Local servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.

Packages
npm@tiberriver256/docs-to-mcp-cli

Tools

No tool list yet

Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.

Details

From the project README

@tiberriver256/docs-to-mcp-cli

A CLI tool that generates a self-contained, runnable MCP (Model Context Protocol) server that exposes markdown documentation via specific tools.

What is MCP?

The Model Context Protocol (MCP) is an open standard that enables AI assistants to access external tools and data sources. By converting your documentation to an MCP server, you allow AI assistants to:

  • Browse through your documentation
  • Search for specific information
  • Access the full content of any document
  • Use your documentation to provide more accurate and contextual responses

Installation

You can install the tool globally:

npm install -g @tiberriver256/docs-to-mcp-cli

Or use it directly with npx:

npx @tiberriver256/docs-to-mcp-cli --docs "path/to/docs/**/*.md" --packageName MyDocsServer

Usage

docs-to-mcp-cli --docs <pattern> --packageName <n> [--outDir <dir>] [--toolName <name>]
Options
  • -d, --docs <pattern>: Glob pattern for markdown files (required)
  • -p, --packageName <n>: Name for the generated MCP server (required)
  • -o, --outDir <dir>: Output directory for the bundled server (default: "dist")
  • -t, --toolName <name>: Name of the tool/package/library being documented (used in tool descriptions)
  • -v, --version: Output the current version
Examples
# Generate a server from all markdown files in the docs directory
docs-to-mcp-cli --docs "docs/**/*.md" --packageName ProjectDocs

# Specify a custom tool name and output directory
docs-to-mcp-cli --docs "documentation/**/*.md" --packageName APIDocsServer --toolName "My API" --outDir build

# Run the generated server
node dist/index.js

Generated Server Tools

The generated MCP server provides the following tools to AI assistants:

  • list_docs: Lists all available documents with a preview of their content
  • get_doc: Gets the full content of a specific document by its path
  • search_docs: Searches across all documents using fuzzy matching

Integration with AI Assistants

Once your MCP server is running, AI assistants that support the Model Context Protocol can connect to it and access your documentation. This enables the AI to provide more accurate and contextual responses based on your specific documentation.

Development

To build the CLI tool locally:

# Clone the repository
git clone https://github.com/Tiberriver256/docs-to-mcp-cli.git
cd docs-to-mcp-cli

# Install dependencies
npm install

# Build the project
npm run build

# Link for local development
npm link

Current Version

The current version is 1.1.2. See the CHANGELOG.md for details on recent updates.

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.