Back to search

Documentation platform

GitPageDocs

An open-source toolkit to scaffold, generate and ship multilingual, versioned documentation to GitHub Pages — with a built-in AI assistant, an MCP server, and a themeable docs shell.

npx gitpagedocs
View on GitHub

Overview

What GitPageDocs is and the problem it solves.

GitPageDocs turns a single config file into a complete, static documentation site: multilingual (en/pt/es), version-aware (/v/:version), themeable and deployable to GitHub Pages with no server. It ships as three npm packages that share one core.

PackageRole
@gitpagedocs/cliScaffolds config, generates docs, AI generation, configures GitHub Pages.
@gitpagedocs/mcpModel Context Protocol server exposing tools & resources to AI agents.
@gitpagedocs/toolsShared core: crypto, encrypted vault, cache, logging, doc utilities.

Quickstart

Generate your first docs in seconds.

Run the CLI in your repository. It writes a gitpagedocs/ folder with config.json and multilingual markdown you can edit right away.

# one-off, no install
npx gitpagedocs

# include local theme layouts
npx gitpagedocs --layoutconfig

# configure GitHub Pages + commit + push
npx gitpagedocs deploy --owner <you> --repo <repo>

CLI

Commands and options of the gitpagedocs command.

CommandDescription
gitpagedocsGenerate config and docs in gitpagedocs/.
gitpagedocs --layoutconfigAlso generate local layouts/templates.
gitpagedocs --homeStandalone distribution (gitpagedocshome/).
gitpagedocs aiInteractive AI documentation generator.
gitpagedocs document[:repo|:file|:folder]Generate documentation with AI for a scope.
gitpagedocs deploy / pagesConfigure GitHub Pages via Actions and push.
gitpagedocs mcp startStart the MCP server over stdio.
OptionDescription
--owner / --repoTarget GitHub owner and repository.
--path <subpath>Docs subpath; sets the base path for correct CSS/JS on project sites.
--output <dir>Output directory (default: gitpagedocs).
--search true|falseEnable/disable repository search (with --home).
--pushCreate workflow, commit artifacts, push.
--interactive / -iInteractive mode with prompts.

Configuration

Everything in config.json: site, translations and versions.

config.json has three top-level sections. site holds the chrome (name, languages, theme defaults, header icons, langmenu, AiChatEnabled, docsAccess). translations holds navigation/footer/not-found labels per language. VersionControl lists the documentation versions.

Content typeConfig key
Markdownroutes-md
HTML / source-viewer or external urlroutes-html
Videoroutes-video
Audioroutes-audio

Layouts & themes

60+ light and dark themes, switchable at runtime.

Each theme is a JSON template (colors, typography, component tokens) turned into CSS variables at runtime. Pick a default with site.ThemeDefault and site.ThemeModeDefault; visitors can switch theme and light/dark mode from the header.

The catalog includes editor-inspired themes (VSCode Light/Dark) plus 25 modern palettes such as Midnight, Neon Noir, Ember, Cobalt, Lagoon, Orchid, Velvet and more.

AI assistant

14 providers, streaming, keys encrypted at rest.

The docs ship an AI assistant in two surfaces: an in-docs chat drawer (enabled by site.AiChatEnabled) and a dedicated /ai console. Both share one core across 14 providers: OpenAI, Anthropic, Gemini, OpenRouter, Ollama, Azure OpenAI, Mistral, DeepSeek, Cohere, Groq, xAI, Together, Fireworks and Perplexity.

MCP server

Expose tools and resources to editors and AI agents.

gitpagedocs mcp start runs a Model Context Protocol server over stdio exposing 20 tools (filesystem, AI, doc generation/analysis) and 7 resources for editors and AI agents.

  • project://structure
  • project://docs
  • project://config
  • project://repository
  • project://readme
  • project://ai/providers
  • project://ai/models

Tools core

The shared, runtime-agnostic foundation.

@gitpagedocs/tools is the core both the CLI and the MCP server build on. It provides the crypto service (AES-256-GCM), the encrypted credential vault, a memory cache with TTL, a redaction-aware logger, and the shared doc-access key scheme.

Protected docs

Gate documentation by access key, roles or external auth.

Set a top-level auth block in a version config (accessKeys, rolesStorageKey, providers) and per-route authorization (accessKeyId, requiredRoles, requireExternalAuth, allowedProviders). A whole documentation can also sit behind a password gate via site.docsAccess.

Deploy & environment

Ship to GitHub Pages and the environment flags.

gitpagedocs deploy generates a GitHub Actions workflow that statically exports the site and publishes it to GitHub Pages on every push to the default branch.

VariableEffect
GITPAGEDOCS_REPOSITORY_SEARCHEnables repository search, the multi-repo home and this guide.
GITHUB_ACTIONSSwitches the build into GitHub Pages static-export mode.