SyncChatRoom is a real-time chat application developed using Django and Django Channels, leveraging WebSocket technology to provide users with an interactive and instant messaging experience. This project aims to demonstrate the implementation of real-time features in a Django web application.
- Real-time Messaging: Utilizes WebSocket and Django Channels for real-time communication between users.
- User Authentication and Authorization: Implements user authentication and authorization features for secure access to the chat application.
- Message Broadcasting: Supports message broadcasting, allowing users to send and receive messages instantly.
- User Online Status: Provides an online status feature to indicate whether users are currently active in the chat.
- Django: A high-level web framework for Python.
- Django Channels: Extends Django to handle WebSockets for real-time functionality.
- WebSocket: A communication protocol for full-duplex communication channels.
- HTML, CSS, JavaScript: Front-end technologies for a user-friendly and responsive interface.
syncchatroom
: Django project directory containing settings, configuration, and top-level application routing.syncchat
: Django app responsible for handling chat-related functionalities, including models, views, and templates.templates
: Directory containing HTML templates for rendering pages.static
: Directory for storing static files like CSS and JavaScript.consumers.py
: Defines WebSocket consumers for handling connections, disconnections, and message reception.routing.py
: Configures URL routing for WebSocket connections using Django Channels.
-
Clone the Repository:
git clone https://github.com/davitacols/SyncChatRoom.git cd SyncChatRoom
-
Install Dependencies:
python -m venv venv source venv/bin/activate # On Windows, use `venv\Scripts\activate` pip install -r requirements.txt
-
Run Migrations:
python manage.py migrate
-
Start the Development Server:
python manage.py runserver
-
Open the Application: Visit
http://127.0.0.1:8000/
in your web browser.
- User Registration:
- Navigate to
/register/
and sign up for an account.
- Navigate to
- User Login:
- Go to
/login/
and log in with your credentials.
- Go to
- Real-time Chat:
- Access the main chat interface at
/
. - Send and receive real-time messages using the WebSocket-based chat.
- Access the main chat interface at
Contributions to improve and expand the features of SyncChatRoom are welcome. Follow the guidelines mentioned in the README.md file to contribute to the project.
This project is licensed under the MIT License. See the LICENSE file for details.