Skip to content

AuthLoom

AuthLoom is a Python 3.12 or newer authentication library for FastAPI applications.

It provides email/password signup and signin, cookie-backed database sessions, current-user dependencies, password reset, password change, and email verification. AuthLoom is beta pre-release software; the beta series is for validating the public API, packaging, docs, and database integration before the first stable release.

Mental Model

AuthLoom owns authentication behavior and its database models: users, sessions, password-reset tokens, and email-verification tokens.

Your application owns the FastAPI app, database engine, async session factory, migrations, CSRF protection, email delivery, UI, deployment settings, and authorization rules for your own resources.

Prerequisites

You should already have, or be ready to add:

  • Python 3.12 or newer.
  • FastAPI.
  • SQLAlchemy 2 with async sessions.
  • One async database driver, such as aiosqlite or asyncpg.
  • Alembic or another migration workflow.

Choose A Starting Path

  1. Consumer Integration - install, configure, migrate, mount routes, and test first authentication.
  2. Database and Migrations - make AuthLoom tables part of your application-owned migration history.
  3. Configuration - required setting first, then optional cookies, password policy, and hooks.
  4. Account Security Flows - password reset, password change, email verification, hooks, and CSRF boundaries.
  5. Security Model - security guarantees and application responsibilities.