- Djangosimplejwt : JWT library for django
- drf-yasg : Swagger/OpenAPI 2.0 specs from a Django Rest Framework API
- AmazonS3
- Flake8
- Postgresql
- Mailjet
- Install postgresql
- Create test database with the settings in settings.py
- Connect to posgresql
CREATE DATABASE test;
\c test;
CREATE USER test WITH PASSWORD 'test';
ALTER DATABASE test OWNER TO test
ALTER ROLE test SUPERUSER
virtualenv env
and start your virtualenvpip3 install -r requirements.txt
to install python dependenciesmake migrate
to install database
make reset_db
to start the drop your current database and set up a new onemake fake_db
to populate your database with fake datamake runserver
to start the servermake shell
to start the console
- Make sure your test file match
test*.py
- Make sure your methods start with
test_
- run
make tests
- run
make runserver
- Go to
http://localhost:8000/redoc/
orhttp://localhost:8000/swagger/
- Click on
authorize
and writeBearer *someusertoken*
to use protected routes
- Django Doc : https://docs.djangoproject.com/en/
- Django Rest Framework : http://www.django-rest-framework.org/
- GDPR : https://bohzo.developpez.com/rgpd-guide-pratique-developpeurs/
- Tips : https://www.vinaysahni.com/best-practices-for-a-pragmatic-restful-api
- Python3 : https://learnxinyminutes.com/docs/python3/
- Postico : https://eggerapps.at/postico/ (for Mac)