For start demo:
- Create virtual environment and make
pip install -r requirements.txt - Change DNS in
config.pyas you needs. Or simply create in local Postgres db with nametest_db, usertest_userand passwordtest_pass - Run command in terminal:
python server.py - Visit http://127.0.0.1:8000 (start page) or http://127.0.0.1:8000/docs (for the documentation)
In this demo you can find following:
- CRUD examples
- Filtering with validation of input and output fields in API
- Offset and limits available for entities list
- Connection to Postgres DB using sessions and ORM
- Password hashing
- Requests for handy usage in Pycharm Pro or VSCode
- Example of one-to-many relations between Visitor and Log entities
- Separate routers for different entities
- JWT authentication and defence API methods from unauthorized access