all templates
Blog Engines

Blog Engine — Python · Postgres

FastAPI + asyncpg: the blog engine with the shortest path from zero to endpoint.

The Python + Postgres take on the series: FastAPI for the surface, asyncpg with raw SQL underneath — no ORM, no session juggling. Argon2 local auth issuing JWTs, uv with a committed lockfile, and the same Clerk/Auth0 swap examples as every sibling.

What's inside

  • Full CRUD + publish flow for markdown posts
  • Local auth: users table, argon2, HS256 JWT
  • Drop-in Clerk & Auth0 JWT verifier examples
  • Raw SQL via asyncpg — no ORM
  • schema.sql applied on startup
  • compose stack — Postgres state in ./data, healthchecked

Quickstart

$ git clone https://github.com/devai-io/devai_boilerplates.git$ cd devai_boilerplates/blog-python-postgres$ docker compose up --build   # API on http://localhost:8080

Browse the code

The full source, exactly as it ships in the repo.

loading…
Download .zip
loading tree…

about this series

Part of the devai.io blog engine series: one contract, eight backends — compare languages on identical ground.