Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/servetisikli/real-time-chat-app-socket-io-client
This is a real-time chat application built with Express, Socket.io, and MongoDB. It allows users to send and receive messages in real-time.
https://github.com/servetisikli/real-time-chat-app-socket-io-client
react socket-io
Last synced: 22 days ago
JSON representation
This is a real-time chat application built with Express, Socket.io, and MongoDB. It allows users to send and receive messages in real-time.
- Host: GitHub
- URL: https://github.com/servetisikli/real-time-chat-app-socket-io-client
- Owner: servetisikli
- Created: 2024-11-13T11:16:52.000Z (3 months ago)
- Default Branch: main
- Last Pushed: 2024-11-13T22:15:52.000Z (3 months ago)
- Last Synced: 2024-11-13T23:20:29.581Z (3 months ago)
- Topics: react, socket-io
- Language: JavaScript
- Homepage: https://real-time-chat-app-socket-io-client.onrender.com
- Size: 62.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Express Chat Application
This is a real-time chat application built with Express, Socket.io, and MongoDB. It allows users to send and receive messages in real-time.
## Web Page
You can access the web page for the chat application at the following URL:
[Chat Application Web Page](https://real-time-chat-app-socket-io-client.onrender.com)
## Table of Contents
- [Installation](#installation)
- [Usage](#usage)
- [API Endpoints](#api-endpoints)
- [Environment Variables](#environment-variables)## Installation
1. Clone the repository:
```sh
git clone https://github.com/servetisikli/real-time-chat-app-socket-io-client.git
cd real-time-chat-app-socket-io-client
```2. Install dependencies:
```sh
npm install
```3. Create a `.env` file in the root directory and add your environment variables:
```env
MONGODB_URI=your_mongodb_uri
PORT=5000
CLIENT_URL=http://localhost:5173
```4. Start the server:
```sh
npm start
```## Usage
1. Start the server as described in the [Installation](#installation) section.
2. Open your client application and connect to the server.## API Endpoints
- `GET /api/chat/messages` - Retrieve all chat messages.
- `POST /api/chat/message` - Send a new chat message.## Environment Variables
- `MONGODB_URI`: The URI of your MongoDB database.
- `PORT`: The port on which the server will run (default is 5000).
- `CLIENT_URL`: The URL of the client application.