Skip to main content
Glama

AutoDocs MCP Server

PyPI Python 3.11+ License: MIT

Intelligent documentation context provider for AI assistants

AutoDocs MCP Server automatically provides AI assistants with contextual, version-specific documentation for Python project dependencies. It uses intelligent dependency resolution to include both the requested package and its most relevant dependencies, giving AI assistants comprehensive context for accurate code assistance.

Key Features

  • Smart dependency context - Automatically includes 3-8 most relevant dependencies

  • AI-optimized documentation - Token-aware formatting with performance metrics

  • Production-ready - 8 MCP tools with health monitoring and caching

  • Framework-aware - Special handling for FastAPI, Django, Flask ecosystems

  • High performance - Concurrent fetching with circuit breakers and connection pooling

Related MCP server: Context7 MCP

Quick Start

Installation

# Using uv (recommended)
uv tool install autodoc-mcp

# Using pip
pip install autodoc-mcp

Basic Usage

# Start the MCP server
autodoc-mcp

# Test with your AI assistant
# Ask: "What packages are available in this project?"
# Ask: "Tell me about FastAPI with its dependencies"

MCP Client Configuration

Add to your MCP client configuration:

{
  "mcpServers": {
    "autodoc-mcp": {
      "command": "autodoc-mcp",
      "env": {
        "CACHE_DIR": "~/.cache/autodoc-mcp"
      }
    }
  }
}

Documentation

πŸ“š Complete Documentation: https://bradleyfay.github.io/autodoc-mcp/

Our documentation is organized into three focused paths:

MCP Tools Overview

AutoDocs provides 8 production-ready MCP tools:

Core Tools

  • get_package_docs_with_context - Primary tool for comprehensive documentation with dependencies

  • scan_dependencies - Parse project dependencies from pyproject.toml

  • get_package_docs - Legacy single-package documentation tool

Cache Management

  • refresh_cache - Clear documentation cache

  • get_cache_stats - View cache statistics

System Health

  • health_check - Comprehensive system health status

  • ready_check - Kubernetes-style readiness check

  • get_metrics - Performance metrics and monitoring data

Development & Contributing

This project welcomes contributions! Please see our Contributing Guide for detailed information.

Quick Development Setup

git clone https://github.com/bradleyfay/autodoc-mcp.git
cd autodoc-mcp
uv sync --all-extras
uv run pytest  # Run 400+ tests

Development Standards

  • Conventional Commits - All commits must follow conventional commit format

  • Pre-commit Hooks - Automated linting, formatting, and type checking

  • Comprehensive Testing - pytest ecosystem with 400+ tests

  • GitFlow Workflow - Feature branches, release branches, and semantic versioning

Project Information

  • Version: 0.5.1 (Production Ready)

  • Python: 3.11+ required

  • License: MIT

  • Architecture: Layered design with 10 specialized core service modules

  • Dependencies: Minimal production footprint with FastMCP, httpx, Pydantic

Transparency & Learning

This project demonstrates transparent AI-assisted development. Explore these directories to see the complete development process:

  • .claude/agents/ - Claude Code agent configurations

  • .specstory/history/ - Complete session history

  • planning/ - Planning documents and technical decisions

License

MIT License - see LICENSE for details.


Built with FastMCP | Documentation Site | GitHub

Available Tools

4 tools
get_cache_statsB

Get statistics about the documentation cache.

Returns: Cache statistics and information

Inputs: no named parameters. Returns: object

get_package_docsA

Retrieve formatted documentation for a package with version-based caching.

Args: package_name: Name of the package to fetch documentation for version_constraint: Version constraint from dependency scanning query: Optional query to filter documentation sections

Returns: Formatted documentation with package metadata

Inputs: package_name (required), query, version_constraint. Returns: object

refresh_cacheB

Refresh the local documentation cache.

Returns: Statistics about cache refresh operation

Inputs: no named parameters. Returns: object

scan_dependenciesC

Scan project dependencies from pyproject.toml

Args: project_path: Path to project directory (defaults to current directory)

Returns: JSON with dependency specifications and project metadata

Inputs: project_path. Returns: object

Tool Schema Changelog

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

Loading tool schema changelog…

    TDQS

    A3.5/5.0

    Scored across 4 tools

    Disambiguation5/5

    Each tool has a clearly distinct purpose with no overlap: get_cache_stats retrieves cache statistics, get_package_docs fetches documentation for a specific package, refresh_cache updates the cache, and scan_dependencies analyzes project dependencies. The descriptions clearly differentiate their functions, making tool selection unambiguous.

    Naming Consistency5/5

    All tool names follow a consistent verb_noun pattern (get_cache_stats, get_package_docs, refresh_cache, scan_dependencies) using snake_case throughout. This predictability aids in understanding and usage without any deviations or mixed conventions.

    Tool Count4/5

    With 4 tools, the count is reasonable for a documentation-focused server, covering key operations like fetching docs, scanning dependencies, and managing cache. It feels slightly thin but well-scoped, as each tool serves a distinct and necessary function without bloat.

    Completeness4/5

    The tool set covers core workflows for documentation retrieval and management: scanning dependencies, fetching package docs with caching, and cache operations. A minor gap exists in not having tools for updating or deleting cached docs, but agents can work around this with the provided refresh and get operations.

    Maintenance

    ActivityInactive
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers