Metadata-Version: 2.5
Name: moosey-cms
Version: 0.9.9
Summary: A lightweight, drop-in Markdown CMS for FastAPI with hot reloading
Project-URL: Homepage, https://github.com/mugendi/moosey-cms
Project-URL: Repository, https://github.com/mugendi/moosey-cms
Project-URL: Bug Tracker, https://github.com/mugendi/moosey-cms/issues
Project-URL: Documentation, https://github.com/mugendi/moosey-cms/blob/master/docs
Project-URL: Changelog, https://github.com/mugendi/moosey-cms/commits/master/
Author: Anthony Mugendi
License: MIT
License-File: LICENSE
Keywords: cms,fastapi,hot-reload,jinja2,markdown,seo
Classifier: Development Status :: 4 - Beta
Classifier: Framework :: FastAPI
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content :: Content Management System
Classifier: Topic :: Software Development :: Libraries :: Application Frameworks
Requires-Python: >=3.10
Requires-Dist: beautifulsoup4>=4.15.0
Requires-Dist: bleach<7,>=6.0
Requires-Dist: cachetools>=6.2.4
Requires-Dist: cryptography>=49.0.0
Requires-Dist: fastapi>=0.128.0
Requires-Dist: filelock>=3.29.7
Requires-Dist: gitpython>=3.1.0
Requires-Dist: httpx>=0.28.1
Requires-Dist: inflection>=0.5.1
Requires-Dist: jinja2>=3.1.6
Requires-Dist: markdown>=3.10
Requires-Dist: minify-html>=0.18.1
Requires-Dist: pycountry>=26.2.16
Requires-Dist: pymdown-extensions>=10.20
Requires-Dist: pynacl>=1.6.2
Requires-Dist: pytest>=9.1.1
Requires-Dist: python-frontmatter>=1.1.0
Requires-Dist: python-multipart>=0.0.32
Requires-Dist: python-slugify>=8.0.4
Requires-Dist: questionary>=2.1.1
Requires-Dist: redis>=8.0.1
Requires-Dist: ruamel-yaml>=0.18.0
Requires-Dist: uvicorn[standard]>=0.40.0
Requires-Dist: watchdog>=6.0.0
Provides-Extra: all
Requires-Dist: opencv-python-headless<5,>=4.9; extra == 'all'
Requires-Dist: pillow>=10.0; extra == 'all'
Provides-Extra: cdn
Provides-Extra: dev
Requires-Dist: httpx>=0.27; extra == 'dev'
Requires-Dist: pytest-asyncio>=0.24; extra == 'dev'
Requires-Dist: pytest>=8.0; extra == 'dev'
Provides-Extra: faces
Requires-Dist: opencv-python-headless<5,>=4.9; extra == 'faces'
Requires-Dist: pillow>=10.0; extra == 'faces'
Provides-Extra: images
Requires-Dist: pillow>=10.0; extra == 'images'
Description-Content-Type: text/markdown

<!--
 Copyright (c) 2026 Anthony Mugendi

 This software is released under the MIT License.
 https://opensource.org/licenses/MIT
-->

# Moosey CMS 🫎
<p align="center">
  <a href="https://pypi.org/project/moosey-cms/">
    <img src="https://img.shields.io/pypi/v/moosey-cms" alt="PyPI version">
  </a>
  <a href="https://pypi.org/project/moosey-cms/">
    <img src="https://img.shields.io/pypi/pyversions/moosey-cms" alt="Python versions">
  </a>
  <a href="https://opensource.org/licenses/MIT">
    <img src="https://img.shields.io/pypi/l/moosey-cms" alt="MIT License">
  </a>
  <a href="https://pypi.org/project/moosey-cms/">
    <img src="https://img.shields.io/pypi/dm/moosey-cms" alt="Downloads">
  </a>
  <a href="https://github.com/mugendi/moosey-cms">
    <img src="https://img.shields.io/github/last-commit/mugendi/moosey-cms" alt="Last commit">
  </a>
</p>

**A lightweight, drop-in Markdown CMS for FastAPI.**



Moosey CMS turns a FastAPI application into a content-driven website using Markdown files, YAML frontmatter, and Jinja templates - no database required.

![Moosey CMS admin editor with side-by-side Markdown editing and live preview](example/assets/screenshots/admin-editor-split-preview.png)

## Features

- File-based Markdown content with automatic URL routing
- Jinja template resolution and sandboxed expressions
- Hot reloading and content-aware caching
- Visual admin for content, frontmatter, and static assets
- Git-backed file history, diff previews, and rollback
- SEO metadata, sitemaps, robots.txt, and RSS feeds
- Responsive image processing and CDN support
- JSON API for content management

## Features that replace paid services

| Moosey CMS feature | Can replace |
|---|---|
| Responsive image generation, `srcset`, local transforms, and CDN URL support | Cloudinary, Imgix, and ImageKit |
| Open Graph, Twitter Cards, JSON-LD, canonical URLs, sitemaps, robots.txt, and RSS feeds | Yoast SEO Premium, Rank Math Pro, and managed SEO tooling |
| Markdown content management, a visual admin, structured metadata, file uploads, and a CRUD API | Contentful, Sanity, Ghost(Pro), and hosted headless CMS platforms |
| Automatic Git history, version tracking, diff previews, and one-click rollback | Contentful revisions, headless CMS version history, and Git-based CMS platforms |

## Installation

Install every optional feature, including image processing and face-aware cropping:

```bash
uv add 'moosey-cms[all]'
# or
pip install 'moosey-cms[all]'
```

Choose a smaller installation when you do not need every feature:

| Package | Included features |
|---|---|
| `moosey-cms` | Core CMS |
| `moosey-cms[images]` | Core CMS and Pillow image processing |
| `moosey-cms[faces]` | Image processing and OpenCV face-aware cropping |
| `moosey-cms[all]` | All optional features |

Use the same package specifier with `uv add` or `pip install`.

## Quick start

Scaffold and run a complete site:

```bash
moosey-cms init ./my-site
cd my-site
moosey-cms dev
```

Open `http://localhost:8000`. To add the admin UI to an existing project:

```bash
moosey-cms admin --templates ./templates --static ./static
```

See [Getting Started](docs/getting-started.md) for manual FastAPI setup, optional dependencies, and production commands.

## Documentation

| Guide | Covers |
|---|---|
| [Getting Started](docs/getting-started.md) | Installation, setup, configuration, and the example app |
| [CLI](docs/cli.md) | Project scaffolding, admin installation, and server commands |
| [Admin Dashboard & API](docs/admin.md) | Admin UI, Git history, authentication, and JSON endpoints |
| [Templates](docs/templates.md) | Template resolution, layouts, collections, and pagination |
| [Frontmatter](docs/frontmatter.md) | Supported metadata and project overrides |
| [Markdown](docs/markdown.md) | Rendering and enabled Markdown extensions |
| [Filters](docs/filters.md) | Complete Jinja filter reference |
| [Images](docs/images.md) | Responsive images, transforms, face detection, and CDNs |
| [SEO](docs/seo.md) | Metadata, structured data, sitemaps, robots.txt, and feeds |
| [Security](docs/security.md) | Sanitization, CSP, template sandboxing, and deployment guidance |
| [Patterns](docs/patterns.md) | Practical project structures and conventions |

The [`example/`](example/) project is a working reference implementation.

## Development

```bash
uv sync
uv run pytest
```

Please report bugs and security issues through the [GitHub issue tracker](https://github.com/mugendi/moosey-cms/issues).

## License

MIT License. Copyright © 2026 Anthony Mugendi.

Inspired by [fastapi-blog](https://github.com/pydanny/fastapi-blog) by Daniel Roy Greenfeld.
