The backend project is organized as follows:
backend/
│
├── app/
│ ├── api/
│ │ ├── controllers/
│ │ │ └── config/
│ │ └── ...
│ ├── client/
│ │ └── ...
│ ├── datagenerator/
│ │ └── ...
│ ├── harness/
│ │ └── ...
│ ├── middlewares/
│ │ └── ...
│ └── schemas/
│ └── ...
├── database/
│ └── ...
├── dependencies/
│ └── ...
├── logs/
│ └── ...
├── models/
│ └── ...
├── repository/
│ └── ...
├── routes/
│ └── ...
├── services/
│ └── ...
├── utils/
│ └── ...
├── .env
├── main.py
├── settings.py
├── .gitignore
├── README.md
└── requirements.txt
- app: The main application package.
- api: Contains API-related code and endpoints.
- controllers: Individual API Controllers (endpoints) are defined here.
- schemas: Contains data models or Pydantic models.
- services: Houses business logic or service layer components.
- utils: Contains utility functions or helper modules.
- api: Contains API-related code and endpoints.
- database: Handles database-related code, such as database connection and schemas.
- dependencies: Contains dependencies or dependency providers.
- main.py: Entry point of the application.
- routes: Base Routes Configuration.
- settings.py: Configuration settings for the application.
- logs: Directory for application logs.
- tests: Contains test modules and test cases.
- .env: Environment variables for the project.
- .gitignore: Specifies the files and directories to be ignored by Git.
- requirements.txt: List of project dependencies.
- FastAPI: A modern, fast (high-performance) web framework for building APIs with Python 3.7+ based on standard Python type hints.
- Pydantic: Used for data validation and settings management through Python type annotations.
- Uvicorn: A lightning-fast ASGI server implementation, using
uvloopandhttptools. - SQLAlchemy: The SQL toolkit and Object-Relational Mapping (ORM) system for Python.
- Alembic: A lightweight database migration tool for use with SQLAlchemy.
- Python Dotenv: For loading environment variables from a
.envfile. - Pydantic-Settings: For enhanced settings management with Pydantic.
- Logging: Python’s built-in logging module for tracking application behavior and errors.