This template includes battle-tested features for building secure, scalable, and maintainable APIs
- 🚀 Latest Django (5+) with full feature set
- 🛠️ Django Rest Framework for API development
- 📖 API documentation with drf-spectacular and Swagger
- 💿 Pre-configured PostgreSQL database
- 📦 Redis caching system
- 🗄️ BaseModel with
created_at
andupdated_at
fields - 🗑️ Optional SoftDeleteBaseModel for soft deletions
- 🔒 Complete auth system using Knox
- 🙋 Extended user model with email-based authentication
- ⏳ Celery for async tasks with BaseTaskWithRetry
- 🗃️ Task results storage with django_celery_results
- 📅 Task scheduling through django_celery_beat
- 🧪 Testing with Pytest
- ⚡ Interactive development using Jupyter Notebooks
- 🐞 Debugging with Django Debug Toolbar
- 🔧 Code quality tools: Black, Flake8
- 👨💻 VS Code with Dev Containers
- 🔽 Advanced filtering with django-filter
- 🧩 Extended functionality with Django Extensions
- 💻 VS Code
- 🐋 Docker
- 🐳 Docker Compose
- Use GitHub's template feature (recommended) or clone repository and delete the
.git
folder. - Open the project in VS Code.
- If you installed the recommended extensions, open
Todo Tree
in the sidebar. It will guide you trough the first steps setting up your project, like changing the name of the container, adjusting your URLS, etc. - Hit
CTL/CMD + Shift + p
and selectReopen in container
. This will:- Create a dev container.
- Setup a Redis server.
- Setup your PostgreSQL database.
- Add a development
.env
file. - Install the dependencies.
- Migrate the database.
- Create your super user with
python manage.py createsuperuser
. - Run the project with
python manage.py reserver
. - Work as usual.
This template comes with some shortcuts so you don't have to memorize how to start the workers:
poetry run worker
: to start a new Celery worker.poetry run beat
: to start your periodic tasks.
You can also use:
poetry run server
instead ofpython manage.py runserver
poetry run makemigrations
instead ofpython manage.py makemigrations
poetry run migrate
instead ofpython manage.py migrate
poetry run create_dev_env
to create a development.env
file
- Index Page with a link to the Django admin
- OpenAPI 3 schema generation and Swagger.
- CI with Github Actions
- Add method to restore soft deleted data
- Email sending with celery
- Data seeding
- API Versioning
- Production Docker file
- Production Docker compose file
- CD with Github Actions