JM.
New Template

FastAPI Async SQLAlchemy Template

Template Author / Backend LeadFastAPI · Async SQLAlchemy · Alembic · Docker · Postgres · Redis · OpenTelemetryActive
fastapisqlalchemydddtemplatealembicdocker
GitHub ↗

Production-ready FastAPI starter with Docker, async SQLAlchemy and observability wired in.


Reusable foundation for backend teams that want the first sprint done before writing business code. The template spins up with Docker Compose and delivers a FastAPI stack wired through async SQLAlchemy, Alembic migrations, Redis, and Postgres. Logging, metrics, and tracing are turned on by default with Loguru + OpenTelemetry so incidents surface quickly. Architecture follows Domain-Driven Design: each domain packages models, schemas, repositories, services, and routers. The router loader discovers new domains automatically, so adding features is just scaffolding a folder. Settings auto-detect the environment, inject versioning via Hatch-VCS, and expose app health metadata at /api/health. Why it matters: teams bootstrap faster, enforce clean boundaries, and get CI-ready workflows (lint, format, coverage) without reinventing the wheel. It is my go-to accelerator when spinning new services or coaching teams on modern Python backends.

Goal

Let backend teams ship scalable APIs fast with DDD boundaries, migrations and monitoring out of the box.

Back to projects