WebSocket server created for a chat application.
This project must be used in conjunction with at least two others, one that is an authentication microservice that manage the users, and another microservice that manages chat functions.
It is necessary to develop a WebSocket client, or you can use the one found in the next repository.
When connecting to the server, a token must be sent, which is obtained from the authentication microservice.
All logs are sent to a MongoDB database.
- Python 3.12+
- MongoDB (local server or remote server)
- Create a virtual environment
python -m venv .venv- Activate it (Linux, macOS)
source .venv/bin/activateActivate it (Windows PowerShell)
.venv\Scripts\Activate.ps1- Install dependencies
pip install -r requirements.txt- Set configuration file (.env)
The address and port of the websocket server, the connection string of the database and other configurations must be included
- Run it locally
python main.py- Open the next url in a browser to see the Swagger UI
h