Zippy is a small Chatroom project written using Fast API, uses HTTP and WebSocket protocols, and its authentication is in the form of JWT tokens. It uses Postegras as a database, but it is possible that MongoDB will be added to it soon
- HTTP and WebSocket protocols : It uses the HTTP protocol to manage users and rooms and the Websocket protocol to communicate between clients.
- Database Integration : It uses SqlAlchemy for database management, which allows you to use other databases such as MySQL without the need for major changes in the code.
- JWT Authentication : It uses JWT tokens to authenticate users, which works on platforms other than the web
- Clear structure : The code is written in a way that is easy to understand and modify
- Python 3.8 and above
- Postegras or any other database supported by SqlAlchemy
- Clone the repository
git clone https://github.com/mahdiashtian/zippy.git
- Navigate to the project directory
cd zippy
- Create and activate a virtual environment
sudo apt install python3.10-venv
(Linux)python -m venv venv
source venv/bin/activate
(Linux)venv\Scripts\activate
(Windows)
- Install the requirements
pip install -r requirements.txt
- Fixed imports
pip install -e .
To launch the project, you need to replace your project settings in the .env file with the default settings. Required values:
SECRET_KEY=''
PSQL_DATABASE_USER=''
PSQL_DATABASE_PASSWORD=''
PSQL_DATABASE_NAME=''
PSQL_DATABASE_HOST=''
Start the server
python src/main.py
launch up this project is very easy and does not require any other settings
For any questions or suggestions, please contact me