Loading repository dataβ¦
Loading repository dataβ¦
douglaschalegre / repository
π¨ This is a template that serves as a kickstarter for a back-end API application. Implemented with FastAPI, Pydantic, SQLAlchemy and Alembic with a layered architecture structure.
A transparent discovery signal based on current public GitHub metadata.
This score does not audit code, security, maintainers, documentation quality, or suitability. Verify the repository and its current documentation before adoption.
This repository contains a simple API that serves as a kickstart for new projects using FastAPI, SQLAlchemy and PostgreSQL. It's built with a simple layered architecture, containing domain, service, repository and controller layers. With this layered architecture approach, it's possible to separate concerns and make the codebase more maintainable and scalable.
It's also possible to add more layers if responsibilities grow within a specific layer. That being said, it's important to keep in mind that layers should be as independent as possible, and the dependencies should always point inwards, otherwise, could lead to ciclic dependencies mainly because of Pydantic schemas.
Install Python (version 3.10).
In project folder, execute the following commands:
pip install uv
uv venv .venv
source .venv/bin/activate
Create a .env file with the required environment variables see [.env.example]
Run the following installation command:
uv pip install -r requirements.txt
On virtual environment, execute
python main.py
While running the server, one can access the API documentation.