A full-stack, real-time logistics and dispatch platform modeling real-world workflows (Client, Driver, Dispatcher) using WebSockets, state machine logic, and interactive spatial mapping.
- Client Interface: Request rides, set pickup/drop-off coordinates, specify accessibility requirements, and track driver arrival.
- Driver View (Mobile Web/PWA): Receive ride requests, accept/reject assignments, and push real-time status updates using a strict state machine (
Assigned->En Route->Arrived->Completed). - Dispatcher Dashboard: Monitor all active drivers, current ride statuses, and system metrics on a live Mapbox interface via persistent WebSockets.
- Frontend: React, TailwindCSS, Mapbox GL JS
- Backend: Node.js (Express), Socket.io
- Database: PostgreSQL / Supabase (PostGIS for spatial queries)
- Testing: Jest, Cypress / Playwright
- Node.js (v18+)
- npm or yarn
- PostgreSQL / Supabase account
- Mapbox API Token
- Clone the repository:
git clone https://github.com/BYULabs/realtime-dispatch-system.git)
cd realtime-dispatch-system- Install dependencies for server and client:
cd server && npm install
cd ../client && npm install- Set up environment variables (
.env):
PORT=5000
DATABASE_URL=your_postgres_url
MAPBOX_ACCESS_TOKEN=your_mapbox_token
- Run the development server:
# In /server
npm run dev
# In /client
npm run dev
We welcome contributions! Check out the Issues tab to find open tasks categorized by layer (frontend, backend, database, good first issue). Comment on an issue to get assigned.