Package Documentation Fetcher MCP server

Integrates with multiple package registries and documentation sources to provide up-to-date library information for code assistance, dependency analysis, and learning about new libraries.
Back to servers
Provider
cdugo
Release date
Feb 27, 2025
Language
TypeScript
Package
Stats
103 downloads
13 stars

This MCP server fetches comprehensive package documentation from multiple language ecosystems, providing developers with easy access to information about libraries without requiring API keys. It works natively with Claude Desktop and Cursor IDE, offering specialized tools for analyzing and summarizing documentation.

Installation

Claude Desktop Setup

  1. Open Claude Desktop → Settings → Developer
  2. Click "Edit Config" and add:
{
  "mcpServers": {
    "docsFetcher": {
      "command": "npx",
      "args": [
        "-y",
        "@smithery/cli@latest",
        "run",
        "@cdugo/mcp-get-docs",
        "--config",
        "'{}'"
      ]
    }
  }
}

Cursor IDE Configuration

  1. Open Cursor IDE → Settings → MCP → Add New MCP Server
  2. Add:
Name: docsFetcher
Command: npx -y @smithery/cli@latest run @cdugo/mcp-get-docs --config "{}"

Prerequisites

  • Node.js 18 or later is required

Running Locally

To run the server locally, follow these steps:

git clone https://github.com/cdugo/package-documentation-mcp
cd package-documentation-mcp
npm install
npm run build

Once installed, start the server:

# From the project root directory
npm start

For development with auto-restart on file changes:

npm run dev

You should see output like:

🚀 DocsFetcher MCP Server running!
📋 Ready to fetch documentation

To use a custom port:

PORT=8080 npm start

Available Tools

The server provides several tools for fetching documentation:

  1. fetch-url-docs - Fetch documentation from a specific URL
  2. fetch-package-docs - Fetch documentation for a package with optional language specification
  3. fetch-library-docs - Smart tool that works with either package name or URL
  4. fetch-multilingual-docs - Fetch documentation for a package across multiple language ecosystems

Using the Tools

Example Queries

Basic Library Information

  • "What is Express.js and how do I use it?"
  • "Tell me about the React library"
  • "How do I use requests in Python?"

Multi-language Support

  • "Show me documentation for lodash in JavaScript"
  • "Compare pandas in Python and data.table in R"

Direct Tool Usage

@fetch-package-docs with packageName='express' and language='javascript'
@fetch-package-docs with packageName='requests' and language='python'
@fetch-multilingual-docs with packageName='http' and languages=['javascript', 'python', 'rust']

Using Prompts

The server also provides specialized prompts for documentation analysis:

@summarize-library-docs with libraryName='express'
@explain-dependency-error with packageName='dotenv'

Troubleshooting

If you encounter issues:

  • Server not showing up: Verify the absolute path in your configuration
  • Connection errors: Try restarting Claude Desktop or Cursor IDE
  • Fetch failures: Some packages may have non-standard documentation structures
  • Language support: If a specific language isn't working, try using the package's direct URL instead

How to add this MCP server to Cursor

There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json file so that it is available in all of your projects.

If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json file.

Adding an MCP server to Cursor globally

To add a global MCP server go to Cursor Settings > MCP and click "Add new global MCP server".

When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:

{
    "mcpServers": {
        "cursor-rules-mcp": {
            "command": "npx",
            "args": [
                "-y",
                "cursor-rules-mcp"
            ]
        }
    }
}

Adding an MCP server to a project

To add an MCP server to a project you can create a new .cursor/mcp.json file or add it to the existing one. This will look exactly the same as the global MCP server example above.

How to use the MCP server

Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.

The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.

You can also explictly ask the agent to use the tool by mentioning the tool name and describing what the function does.

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later