docsfy
AI-powered documentation generator that creates polished static HTML sites from GitHub repositories
Get StartedGetting Started
-
Introduction
Overview of docsfy, what it does, how it uses AI CLI tools to generate Mintlify-quality documentation from GitHub repositories, and the core value proposition
-
Quickstart
Step-by-step guide to get docsfy running locally with Docker Compose, generate documentation for your first repository, and view the results
-
Installation
Detailed installation options including Docker-based deployment, local development setup with uv and Python 3.12+, and system prerequisites like git, Node.js, and AI CLI tools
Configuration
-
Environment Variables
Complete reference of all environment variables including AI_PROVIDER, AI_MODEL, AI_CLI_TIMEOUT, authentication keys (ANTHROPIC_API_KEY, GEMINI_API_KEY, CURSOR_API_KEY), Vertex AI settings, and LOG_LEVEL
-
AI Providers
How to configure and switch between supported AI providers: Claude Code, Gemini CLI, and Cursor Agent, including binary requirements, authentication methods, and model selection
-
Storage & Data
How docsfy stores data using SQLite for metadata and the filesystem for generated documentation, including the directory structure under /data/projects/ and database schema
Usage
-
Generating Documentation
How to submit a repository for documentation generation via the POST /api/generate endpoint, monitor generation status, and understand the four-stage pipeline (clone, plan, content, render)
-
Serving Documentation
How to access generated documentation through the built-in static file server at /docs/{project}/, including navigation, dark/light theme toggle, and client-side search
-
Downloading & Self-Hosting
How to download generated documentation as a .tar.gz archive via the API and host it on your own infrastructure, CDN, or static hosting service
-
Incremental Updates
How docsfy detects repository changes via commit SHA tracking, re-evaluates documentation plans, and regenerates only affected pages for efficient updates
Architecture
-
Generation Pipeline
Deep dive into the four-stage generation pipeline: repository cloning, AI-driven documentation planning (plan.json), concurrent page content generation with semaphore-limited concurrency, and HTML rendering with Jinja2
-
HTML Renderer & Theming
How the HTML renderer converts markdown and plan.json into static sites with sidebar navigation, syntax highlighting via highlight.js, callout boxes, card layouts, responsive design, and search indexing
-
AI CLI Integration
Technical details of the provider pattern for AI CLI tools, subprocess invocation, async execution via asyncio.to_thread, multi-strategy JSON response parsing, and availability checking
API Reference
-
POST /api/generate
Start documentation generation for a GitHub repository URL, including request format, response structure, and supported repository types (public/private, SSH/HTTPS)
-
GET /api/status & Project Details
List all projects and their generation status, get detailed project information including last generated timestamp, commit SHA, and page list, and delete projects
-
GET /api/projects/{name}/download
Download a project's generated documentation site as a .tar.gz archive for self-hosting
-
GET /health
Health check endpoint for monitoring and container orchestration
Deployment
-
Docker Deployment
Production deployment using the multi-stage Dockerfile with python:3.12-slim, non-root user configuration for OpenShift compatibility, volume mounts for data persistence and cloud credentials, and health check configuration
-
Docker Compose Setup
Running docsfy with docker-compose.yaml including port mapping, environment file configuration, volume mounts for data and gcloud credentials, and health check settings
Development
-
Development Setup
Setting up a local development environment with uv, Python 3.12+, pre-commit hooks (ruff, mypy, flake8, gitleaks, detect-secrets), and tox for testing
-
Contributing
Guidelines for contributing to docsfy including code style enforcement via pre-commit, running tests, build system (hatchling), and project conventions