A production-oriented MERN + WebSocket application inspired by the supplied customer-support chat dashboard. It includes authenticated real-time conversation rooms, message delivery/read states, typing indicators, contact context, queue management, assignment, tags, notes, uploads, quick replies, and a responsive three-panel interface.
- React + TypeScript + Vite
- Node.js + Express
- MongoDB + Mongoose
- Socket.IO WebSockets
- JWT authentication
- Multer file uploads
- Docker Compose and Nginx
- Login with seeded administrator, manager, and support-agent accounts
- Open, pending, and closed conversation queues
- Search by customer, phone, email, company, or conversation subject
- Live inbound and outbound messages
- Typing indicators and agent presence
- Delivered/read receipts and unread counters
- Text, image, audio, and file messages
- Reply-to message structure
- Agent assignment and priority management
- Customer profile and channel details
- Tags and internal notes
- Quick-response library
- Responsive desktop, tablet, and mobile layout
- Tenant-aware data model and API filtering
- Audit-friendly message metadata
cp .env.example .env
docker compose up --buildOpen http://localhost:8080.
The server seeds demo data automatically when the database is empty.
Run MongoDB locally on port 27017, or use Docker:
docker compose up -d mongocd server
cp .env.example .env
npm install
npm run seed
npm run devBackend: http://localhost:5000
cd client
cp .env.example .env
npm install
npm run devFrontend: http://localhost:5173
| Role | Password | |
|---|---|---|
| Administrator | [email protected] | Admin@123 |
| Manager | [email protected] | Manager@123 |
| Support Agent | [email protected] | Agent@123 |
Client to server:
conversation:joinconversation:leavemessage:sendtyping:starttyping:stopconversation:read
Server to client:
message:newmessage:deliveredmessage:readtyping:updatepresence:updateconversation:updated
omnichat-mern/
├── client/ React application
├── server/ Express, MongoDB, Socket.IO API
├── docker-compose.yml
├── nginx.conf
└── .github/workflows/ci.yml
- Replace demo JWT and tenant secrets.
- Store uploads in S3-compatible object storage rather than local disk.
- Add Redis adapter for horizontally scaled Socket.IO nodes.
- Put the API behind TLS and a managed reverse proxy.
- Configure MongoDB backups, indexes, observability, and secret management.
docs/ARCHITECTURE.md— runtime topology, tenant boundary, event flow, collections, and scaling pathdocs/API.md— REST endpoints and mock inbound webhook example

