The logo includes the abstract combination of the three letters FBA, forming a lightning bolt that seems to spread out from the ground # FastAPI Best Architecture Enterprise-level backend architecture solution English | [简体中文](./README.zh-CN.md) [![GitHub](https://img.shields.io/github/license/fastapi-practices/fastapi_best_architecture)](https://github.com/fastapi-practices/fastapi_best_architecture/blob/master/LICENSE) [![Python](https://img.shields.io/badge/python-3.10%2B-blue)](https://www.python.org/downloads/) ![MySQL](https://img.shields.io/badge/MySQL-8.0%2B-%2300758f) ![PostgreSQL](https://img.shields.io/badge/PostgreSQL-16.0%2B-%23336791) ![SQLAlchemy](https://img.shields.io/badge/SQLAlchemy-2.0-%23778877) [![Pydantic v2](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/pydantic/pydantic/main/docs/badge/v2.json)](https://pydantic.dev) [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff) [![uv](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/uv/main/assets/badge/v0.json)](https://github.com/astral-sh/uv) ![Docker](https://img.shields.io/badge/Docker-%232496ED?logo=docker&logoColor=white) [![Discord](https://img.shields.io/badge/Discord-%235865F2.svg?logo=discord&logoColor=white)](https://discord.com/invite/yNN3wTbVAC) ![Discord](https://img.shields.io/discord/1185035164577972344) [![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/fastapi-practices/fastapi_best_architecture)
## Three-tier architecture The MVC architecture is common in Python Web as a general design pattern, but the three-tier architecture is more fascinating However, please note that we do not have a traditional multi-app (microservices) directory structure (django, springBoot...). ), but a self-righteous directory structure that you can give it any twist if you don't like this model! | workflow | java | fastapi_best_architecture | |----------------|----------------|---------------------------| | view | controller | api | | data transmit | dto | schema | | business logic | service + impl | service | | data access | dao / mapper | crud | | model | model / entity | model | ## Help For more details, please check the [official documentation](https://fastapi-practices.github.io/fastapi_best_architecture_docs/) ## Contributors ## Special thanks - [FastAPI](https://fastapi.tiangolo.com/) - [Pydantic](https://docs.pydantic.dev/latest/) - [SQLAlchemy](https://docs.sqlalchemy.org/en/20/) - [Casbin](https://casbin.org/zh/) - [Ruff](https://beta.ruff.rs/docs/) - ... ## Interactivity [Discord](https://wu-clan.github.io/homepage/) ## License This project is licensed by the terms of the [MIT](https://github.com/fastapi-practices/fastapi_best_architecture/blob/master/LICENSE) license [![Stargazers over time](https://starchart.cc/fastapi-practices/fastapi_best_architecture.svg?variant=adaptive)](https://starchart.cc/fastapi-practices/fastapi_best_architecture)