Notes API (Django & React)
You can make notes using this API to store ideas from your lectures or reading. It will make revision easy and clarify your thinking.
Frontend is developed using ReactJS library. The UI is kept simple just to demonstrate the functionality of the app.
Backend is developed using DRF (Django Rest Framework) using both class based views (for tokenization) and function based views (for CRUD operation on Notes).
JWT Authentication Features
Access token valid for 5000ms
Generate a new access token using refresh token before expiry
Refresh token rotation lifespan 90 days
Previous refresh tokens are blacklisted after rotation so save the new refresh token each time after rotation
Encryption algorithm used HS256
For Authorization use 'Bearer {access token}' as value
Token claim has been customized to add additional field 'username'. You can retrieve 'username' by jwt decoding either refresh or access token
https://clean-orangutan-healthslash-3ca3ec8a.koyeb.app/
Signup to a create new user
Parameter
Type
Description
username
string
Required . username should be unique field
password
string
Required . password any format is acceptable
Parameter
Type
Description
username
string
Required . existing username
password
string
Required . existing password
Generate new tokens (tokens expire every 5000ms)
Parameter
Type
Description
refresh
string
Required . latest refresh token
Retrieve array of user notes
Parameter
Type
Description
access
string
Required . latest access token
Parameter
Type
Description
access
string
Required . latest access token to authenticate
body
string
Required . add content of note in 'body' key
DELETE /api/delete-notes/{id}/
Parameter
Type
Description
access
string
Required . latest access token to authenticate
id
string
Required . id of note to be deleted
PATCH /api/update-notes/{id}/
Parameter
Type
Description
access
string
Required . latest access token to authenticate
id
string
Required . id of note to be be updated
This project is running on @docker containers deployed on @DigitalOcean droplet and managed by @NGINX reverse proxy (depreciated).
Currently, running on https://www.koyeb.com/ free instance.
Zaeem Akhtar