Skip to main content
Glama
xenodocs-mcp-server

xenodocs-mcp-server

Official
by Xenodocs

XenoDocs MCP - Up-to-date Documentation For Any Library

Website PyPI Version MIT licensed

❌ Without XenoDocs

LLMs rely on outdated or generic information about the libraries you use. You get:

  • ❌ Code examples are outdated and based on year-old training data

  • ❌ Hallucinated APIs that don't even exist

  • ❌ Generic answers for old package versions

Related MCP server: Context7 MCP

✅ With XenoDocs

XenoDocs MCP pulls up-to-date, version-specific documentation and code examples straight from the source — and places them directly into your prompt.

Tell your AI assistant to search for library documentation:

Search for "authentication middleware" in the FastAPI library documentation
Find examples of async functions in the httpx library

XenoDocs fetches up-to-date code examples and documentation right into your LLM's context.

  • 1️⃣ Write your prompt naturally

  • 2️⃣ Ask for specific library documentation

  • 3️⃣ Get working code answers

No tab-switching, no hallucinated APIs that don't exist, no outdated code generation.

�️ Installation

Requirements

  • Python >= 3.10

  • VS Code, Cursor, Claude Desktop, or another MCP Client

  • XenoDocs API Key (Get yours by creating an account at xenodocs.com/account/api-keys

uv add xenodocs-mcp-server

Method 2: Using pip

pip install xenodocs-mcp-server

Add this to your VS Code MCP config file (.vscode/mcp.json). See VS Code MCP docs for more info.

VS Code Local Server Connection

{
  "servers": {
    "xenodocs-mcp-server": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "xenodocs-mcp-server"
      ],
      "env": {
        "XENODOCS_API_KEY": "YOUR_API_KEY"
      }
    }
  },
  "inputs": []
}

Alternative configurations:

Using uv project:

{
  "servers": {
    "xenodocs-mcp-server": {
      "type": "stdio",
      "command": "uv",
      "args": ["run", "xenodocs-mcp-server"],
      "env": {
        "XENODOCS_API_KEY": "YOUR_API_KEY"
      }
    }
  },
  "inputs": []
}

Using Python module:

{
  "servers": {
    "xenodocs-mcp-server": {
      "type": "stdio",
      "command": "python",
      "args": ["-m", "xenodocs_mcp_server.server"],
      "env": {
        "XENODOCS_API_KEY": "YOUR_API_KEY"
      }
    }
  },
  "inputs": []
}

Add to your Cursor MCP configuration (~/.cursor/mcp.json):

{
  "mcpServers": {
    "xenodocs": {
      "command": "uvx",
      "args": ["xenodocs-mcp-server"],
      "env": {
        "XENODOCS_API_KEY": "YOUR_API_KEY"
      }
    }
  }
}

Add to your Claude Desktop configuration:

{
  "mcpServers": {
    "xenodocs": {
      "command": "uvx",
      "args": ["xenodocs-mcp-server"],
      "env": {
        "XENODOCS_API_KEY": "YOUR_API_KEY"
      }
    }
  }
}

Add to your Windsurf MCP configuration:

{
  "mcpServers": {
    "xenodocs": {
      "command": "uvx",
      "args": ["xenodocs-mcp-server"],
      "env": {
        "XENODOCS_API_KEY": "YOUR_API_KEY"
      }
    }
  }
}

Add to your Zed settings.json:

{
  "context_servers": {
    "xenodocs": {
      "source": "custom",
      "command": "uvx",
      "args": ["xenodocs-mcp-server"],
      "env": {
        "XENODOCS_API_KEY": "YOUR_API_KEY"
      }
    }
  }
}

🔨 Available Tools

XenoDocs MCP provides the following tools that LLMs can use:

  • search_library_name: Search for matching library names in the XenoDocs documentation database.

    • library_name (required): The name or partial name of the library to search for

    • top_k (optional): Maximum number of matching libraries to return (default: 3, max: 20)

  • search_library: Search for specific information within a library's documentation.

    • library_name (required): The exact name of the library to search in

    • query (required): The search query describing what you're looking for

💻 Development

Clone the project and install dependencies:

git clone https://github.com/Xenodocs/xenodocs-mcp-server.git
cd xenodocs-mcp-server
uv sync

Set your API key:

export XENODOCS_API_KEY="your-api-key"

Run the server:

uv run xenodocs-mcp-server

Testing with MCP Inspector

npx @modelcontextprotocol/inspector uv run xenodocs-mcp-server

🚨 Troubleshooting

If you get "command not found" errors:

  1. For uv projects: Make sure you're in a directory with a pyproject.toml file

  2. For pip installation: Use the Python module method:

    {
      "command": "python",
      "args": ["-m", "xenodocs_mcp_server.server"]
    }

If you see WARNING: XENODOCS_API_KEY not set!, make sure you've configured the API key in your MCP client configuration or as a system environment variable.

  1. Restart your MCP client completely

  2. Check that your installation method is working by running the command manually

  3. Check client output/logs for MCP connection errors

  4. Verify you have the correct Python version (>=3.10)

Available Tools

2 tools
search_latest_documentationA

Retrieve official, up-to-date code examples and API references for a library.

Use this tool to find the exact syntax, function signatures, and usage patterns. Do not rely on your internal training data as it may be outdated; always verify with this tool.

Inputs: query (required), library_name (required). Returns: result

search_library_nameA

CRITICAL: Always use this tool FIRST before generating code for any third-party library.

This tool identifies the correct library version and official documentation source. Using this prevents hallucinations and ensures you use the most up-to-date APIs.

Usage Strategy:

  1. Call this tool to find the exact library name (e.g., mapping "langchain" to the specific package).

  2. Use the result from this tool to call 'search_latest_documentation'.

Inputs: query (required), library_name (required). Returns: result

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.4/5.0

    Scored across 2 tools

    Disambiguation5/5

    Each tool has a clearly distinct role: one identifies the canonical library name and version, the other retrieves the matching documentation. There is no functional overlap; they are designed to be used sequentially.

    Naming Consistency5/5

    Both tool names follow a consistent 'search_target' verb_noun pattern: 'search_library_name' and 'search_latest_documentation'. The style is uniform and readable.

    Tool Count4/5

    With only two tools, the server feels minimal but appropriately scoped for a narrow purpose: resolving library names and retrieving docs. It is slightly thin but not unreasonable for a focused utility.

    Completeness4/5

    The two tools cover the core workflow of finding a library and getting its documentation. A minor gap is the lack of version-specific documentation retrieval, as the second tool only targets the latest docs.

    Maintenance

    ActivityInactive
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers