fastapi-docs
A markdown documentation renderer for FastAPI applications.
Features
- 📁 Directory-based navigation from your markdown file structure
- 🔍 Full-text search across all documents
- 🎨 Syntax highlighting for Python, JavaScript, bash, C#, HTML
- 🌙 Automatic dark mode based on system preference
- 📱 Responsive design for mobile and desktop
- ⚡ Hot-reload during development
- 📑 Table of contents for each page
- 🔗 Previous/next navigation
Installation
pip install -e .
Quick Start
from fastapi import FastAPI
from fastapi_docs import create_docs_router, DocsConfig
app = FastAPI()
# Simple usage
app.include_router(create_docs_router("./userdocs"), prefix="/userdocs")
# Or with configuration
config = DocsConfig(
docs_dir="./userdocs",
title="My API Docs",
auto_refresh=True,
)
app.include_router(create_docs_router(config), prefix="/userdocs")
Markdown Frontmatter
Each markdown file can include YAML frontmatter:
---
title: Getting Started
order: 1
description: Learn how to get started
tags:
- quickstart
hidden: false
---
# Getting Started
Your content here...
Running the Example
pip install -e ".[dev]"
uvicorn example_app:app --reload
Then visit http://localhost:8000/userdocs
License
MIT
Metadata
Release files for fastapi-docs 0.1.6
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| fastapi_docs-0.1.6.tar.gz | 1.4 MB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| fastapi_docs-0.1.6-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 1.4 MB
Release files / fastapi_docs-0.1.6.tar.gz
| Download URL | fastapi_docs-0.1.6.tar.gz |
|---|---|
| Size | 1.4 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
438097a1ee7f607001d30c55f0859f0ae6c4f6b551034b3f43427d307757e867
|
|
BLAKE2b-256 checksum How to use checksums |
9572f22373218120f4dde9f88e44da3b6701412921fa7ba1b016cf3dbf37ac49
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.12
|
Release files / fastapi_docs-0.1.6-py3-none-any.whl
| Download URL | fastapi_docs-0.1.6-py3-none-any.whl |
|---|---|
| Size | 16.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d71d96cefa5eb12a23e7e5174663982730ac2e29dfd883744e43da5c1292a658
|
|
BLAKE2b-256 checksum How to use checksums |
ee9da1124ffd96aca814fb7da4a546d9a5612d29cfa596879ad65fb834a2f55a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.12
|