FastAPI task manager with JWT cookie auth, Redis refresh tokens, and PostgreSQL.
- Python 3.12+
- uv
- PostgreSQL 16+
- Redis 7+
- Copy environment file:
cp example.env .env- Generate JWT keys:
mkdir -p certs
openssl genrsa -out certs/jwt-private.pem 2048
openssl rsa -in certs/jwt-private.pem -pubout -out certs/jwt-public.pem- Install dependencies:
uv sync --group dev- Run migrations:
uv run alembic upgrade head- Start the API:
uv run python -m appAPI docs: http://localhost:9000/docs
docker compose up --builduv run coverage run -m pytest tests -v
uv run coverage report -m --fail-under=80app/
api/v1/endpoints/ # HTTP routes
core/ # config, DI, security, database
models/ # SQLAlchemy models
repository/ # data access layer
services/ # business logic
schemas/ # Pydantic DTOs
migrations/ # Alembic migrations
tests/
unit_tests/
integration_tests/
POST /api/v1/users/auth/registerPOST /api/v1/users/auth/loginPOST /api/v1/users/refreshPOST /api/v1/users/logoutGET /api/v1/tasks/POST /api/v1/tasks/DELETE /api/v1/tasks/delete_taskPATCH /api/v1/tasks/update_task_status