Python backends, with real architecture

Austial is the batteries-included framework that gives FastAPI modules, dependency injection and a real request lifecycle, so your codebase stays easy to change as it grows.

Python
3.11+
Latest release
v0.1.5
License
MIT

( Built on proven foundations )

  • FastAPI
  • Pydantic
  • Starlette
  • SQLAlchemy
  • Alembic
  • Uvicorn
  • Python 3.11+
  • uv
  • pytest

( What is Austial )

Austial is a modern framework designed to build efficient, structured web applications in Python.

Built on FastAPI and inspired by NestJS, Austial blends proven architecture with Python's type hints, keeping projects organised and easy to maintain.

  • Modules

    Organise apps into self-contained modules that own their controllers and providers.

  • Dependency Injection

    Constructor injection resolved by type hints. No tokens or glue code.

  • Decorators

    Declare routes, guards and pipes right where they apply.

  • Type Safety

    Type hints and Pydantic keep inputs and outputs honest end to end.

  • Request Lifecycle

    Guards, pipes, interceptors and filters in a predictable order.

  • Database

    Entities, repositories and migrations built on SQLAlchemy and Alembic.

  • Testing

    A testing module with provider overrides and an in-process client.

WhenyourFastAPIappoutgrowsonefilewegiveitanarchitecture

FastAPI is a fantastic toolkit, but it doesn't prescribe how to organise an application. Austial adds modules, dependency injection and a request lifecycle on top, so large codebases stay readable and testable.

Request Pipeline

Guards, pipes, interceptors and exception filters wrap every handler in a predictable order.

  1. Guard
  2. Pipe
  3. Interceptor
  4. Handler
  5. Filter
api_key_guard.py
class ApiKeyGuard(CanActivate):
    async def can_activate(self, context: ExecutionContext) -> bool:
        request = context.switch_to_http().get_request()
        return request.headers.get("x-api-key") == "expected-value"

A falsy result short-circuits the pipeline with a 403 Forbidden.

CLI

Scaffold a project and generate modules, controllers and services without leaving the terminal.

~/projects
$ uv tool install austial
$ austial new my-app
$ cd my-app && uv sync
my-app/
├── AGENTS.md
├── pyproject.toml
└── src/
├── main.py
├── app_module.py
└── modules/health/

AI Agents

Every project ships rules for AI coding tools, so assistants follow your architecture instead of guessing.

my-app
  • AGENTS.md
  • CLAUDE.md -> AGENTS.md
  • GEMINI.md -> AGENTS.md
  • CONVENTIONS.md -> AGENTS.md
  • .windsurfrules -> AGENTS.md
  • .clinerules -> AGENTS.md
  • .rules -> AGENTS.md
  • .github/copilot-instructions.md -> AGENTS.md

AGENTS.md

# AGENTS.md

This is an **Austial** application: a NestJS-style,
batteries-included web framework for Python, built on FastAPI.

## Commands

uv run austial serve         # dev server on :8000 with reload
uv run austial g resource <name>   # scaffold a full CRUD feature module

( Production ready )

Everything a real backend needs, already wired

14 documented techniques across 17 packages. Pick what you need, ignore the rest.

Build your app with the most elegant and intuitive syntax.

from austial import AustialFactory

from .app_module import AppModule


app = AustialFactory.create(AppModule, title="my-app")


async def bootstrap() -> None:
    await app.listen(8000)

( Learn )

From zero to a running app in minutes

Follow the guides in order, or jump straight to the part of the framework you need.

Batteries included. Nothing to glue.

17

Packages in the box

14
Techniques
5
Lifecycle stages
MIT
License

( Click. Copy. Build. )