Used Technology:
- Python
- Django
- Django Rest Framework
- Django Channels
- Redis
- Heroku
- Postgresql
- VueJS
Live server link
https://django-chat-api.herokuapp.com/
Features
- Send message to a particular user
- Updates Inbox when someone sends a new message
- Updates status to online when a user logs in and updates status to offline when logs out
- Can delete message
- Paginated messages
- Custom User Model
Commands
python manage.py createsuperuser
- To create superuser
python manage.py collectstatic
- Collects Static
python manage.py runserver
How to run on heroku
- Login to your heroku dashboard and create a Heroku App
- Payment verify your account in order to use addons
- Download and install heroku cli
- Open terminal in the working directory and run the following commands in your terminal
- Run
heroku login
, this will open a tab in your browser, click login - Run
heroku git:remote -a {your-app-name}
- Run
heroku addons:create heroku-postgresql:<PLAN_NAME>
-> if you want to buy any other plan - Run
heroku addons:create heroku-redis
- Run
heroku config:set SECRET_KEY="YOUR_SECRET_KEY"
- Run
heroku config:set FIELD_ENCRYPTION_KEYS="FIELD_ENCRYPTION_KEYS"
- Set database url in django settings
- Run
git add .
- Run
git commit -m"Application setup"
- Run
git push heroku master
- Run
heroku run python manage.py migrate
Database Design