Quick Help When You Need It Most
A comprehensive emergency response and civic issue reporting platform with real-time tracking, AI-powered analysis, and multi-agency coordination.
Demo โข Features โข Installation โข Usage โข Architecture
RapidAssist is a modern emergency services platform designed to provide instant access to emergency services (Police, Ambulance, Fire), enable community issue reporting, and provide real-time status tracking. The platform connects citizens with emergency responders and local authorities seamlessly.
- One-tap SOS activation with 7-second countdown
- Automatic location sharing using GPS
- Multimedia evidence capture - automatically captures 5 images + 7-second audio recording
- Shake-to-activate emergency alerts
- Real-time Firebase sync for instant responder notification
- Emergency contact notification system
- Gemini AI Integration for civic issue analysis
- Automatic issue categorization from photos
- AI-generated user health summaries for emergency responders
- Smart priority assessment for reported issues
- Interactive Leaflet maps for precise location marking
- Reverse geocoding for address resolution
- Real-time location tracking during emergencies
- Accuracy indicators for GPS positioning
- Police Control Center (
/police-admin) - Ambulance Control Center (
/ambulance-admin) - Fire Control Center (
/fire-admin) - Central Admin Dashboard (
/admin) - Real-time SOS monitoring with live updates
- Quick-view health summary popups
- **One-click case assignment and status updates
- Civic issue reporting with photo evidence
- AI-powered issue analysis and categorization
- Upvote/downvote system for community prioritization
- Status tracking from submission to resolution
- Multiple categories: Roads, Street Lights, Water, Drainage, Garbage, Safety, Noise
- Mobile number registration with OTP verification
- Medical profile storage (blood group, conditions, allergies)
- Emergency contacts management
- User dashboard for tracking submitted reports
| Category | Technology |
|---|---|
| โ๏ธ Frontend | React 18, React Router DOM 6 |
| โก Build Tool | Vite 5 |
| ๐ฅ Backend | Firebase Realtime Database |
| ๐๏ธ Storage | Supabase Storage, ImgBB |
| ๐บ๏ธ Maps | Leaflet, React-Leaflet |
| ๐ค AI | Google Gemini API |
| ๐จ Styling | Custom CSS with CSS Variables |
rapidassist/
โโโ ๐ index.html # Entry HTML file
โโโ ๐ฆ package.json # Dependencies & scripts
โโโ โ๏ธ vite.config.js # Vite configuration
โโโ ๐ vercel.json # Vercel deployment config
โโโ ๐ public/
โ โโโ manifest.json # PWA manifest
โ โโโ sw.js # Service worker
โโโ ๐ src/
โโโ ๐ main.jsx # React entry point
โโโ ๐ฑ App.jsx # Main app with routing
โโโ ๐ฅ firebase.js # Firebase configuration
โโโ ๐๏ธ supabase.js # Supabase configuration
โโโ ๐ components/
โ โโโ ๐ต AudioEvidencePlayer/ # Audio playback for evidence
โ โโโ ๐จ EmergencyCard/ # Emergency service cards
โ โโโ ๐ Header/ # Navigation header
โ โโโ ๐บ๏ธ LocationMap/ # Leaflet map component
โ โโโ ๐ LoginForm/ # Authentication form
โ โโโ ๐ RegistrationForm/ # User registration
โ โโโ ๐ ReportCard/ # Issue report display
โ โโโ ๐ SOSButton/ # SOS activation button
โ โโโ ๐ StatusTracker/ # Status timeline
โโโ ๐ context/
โ โโโ ๐ AuthContext.jsx # Authentication state
โ โโโ ๐ ReportsContext.jsx # Reports & SOS state
โ โโโ ๐ ToastContext.jsx # Notification system
โโโ ๐ pages/
โ โโโ ๐ Home.jsx # Landing page
โ โโโ ๐ Login.jsx # Login page
โ โโโ ๐ Register.jsx # Registration page
โ โโโ ๐ Dashboard.jsx # User dashboard
โ โโโ ๐ SOS.jsx # Emergency SOS page
โ โโโ ๐ ReportIssue.jsx # Issue reporting
โ โโโ ๐๏ธ Community.jsx # Community issues feed
โ โโโ ๐ค UserProfile.jsx # User profile management
โ โโโ ๐ก๏ธ AdminDashboard.jsx # Central admin panel
โ โโโ ๐ฎ PoliceAdmin.jsx # Police control center
โ โโโ ๐ AmbulanceAdmin.jsx # Ambulance control center
โ โโโ ๐ FireAdmin.jsx # Fire control center
โโโ ๐ styles/
โ โโโ ๐จ index.css # Base styles
โ โโโ โจ enhanced.css # Component styles
โโโ ๐ utils/
โโโ ๐ค civicAnalyzer.js # Gemini AI integration
โโโ ๐ก sendingSOS.js # SOS evidence capture
โโโ โ๏ธ constants.js # App constants
- Node.js 18+
- npm or yarn
- Firebase project
- Supabase project (for audio storage)
- Gemini API key (for AI features)
-
Clone the repository
git clone https://github.com/yourusername/rapidassist.git cd rapidassist -
Install dependencies
npm install
-
Configure environment variables
Create a
.envfile in the root directory:# Firebase Configuration VITE_FIREBASE_API_KEY=your_firebase_api_key VITE_FIREBASE_AUTH_DOMAIN=your_project.firebaseapp.com VITE_FIREBASE_PROJECT_ID=your_project_id VITE_FIREBASE_STORAGE_BUCKET=your_project.appspot.com VITE_FIREBASE_MESSAGING_SENDER_ID=your_sender_id VITE_FIREBASE_APP_ID=your_app_id # Supabase Configuration VITE_SUPABASE_URL=https://your-project.supabase.co VITE_SUPABASE_ANON_KEY=your_supabase_anon_key # AI Configuration VITE_GEMINI_API_KEY=your_gemini_api_key
-
Start development server
npm run dev
-
Build for production
npm run build
| Action | Description |
|---|---|
| ๐ Emergency SOS | Press the SOS button, select service type, and wait 7 seconds for automatic alert |
| ๐ธ Report Issue | Take a photo, AI analyzes and categorizes it, then submit |
| ๐๏ธ Community | Browse issues, upvote important ones, add your own posts |
| ๐ค Profile | Manage medical info and emergency contacts |
| Login | Credentials |
|---|---|
| ๐ฎ Police | police / police123 |
| ๐ Ambulance | ambulance / ambulance123 |
| ๐ Fire | fire / fire123 |
| ๐ก๏ธ General Admin | admin / admin123 |
โโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโ
โ ๐ค Citizen โโโโโโถโ ๐ฑ RapidAssist โโโโโโถโ ๐ฅ Firebase โ
โ โ โ Frontend โ โ Realtime DB โ
โโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโโ โโโโโโโโโโฌโโโโโโโโโ
โ โ
โผ โผ
โโโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโ
โ ๐ค Gemini AI โ โ ๐ฎ Admin โ
โ Analysis โ โ Dashboards โ
โโโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโ
- User presses SOS button
- 7-second countdown begins (cancelable)
- Camera/microphone permissions requested
- Parallel capture: 5 images + 7s audio recording
- Media uploaded to ImgBB (images) + Supabase (audio)
- Emergency data pushed to Firebase with:
- Location (GPS coordinates + address)
- User profile & medical info
- AI-generated health summary
- Emergency contacts
- Evidence URLs
- Real-time notification to admin dashboards
- Admin can view, assign, and manage cases
- Civic Issue Analysis: Upload a photo โ Gemini analyzes โ Returns structured JSON with category, priority, description
- User Health Summary: Generates concise emergency summary from user's medical profile during registration
{
"rules": {
"emergencies": {
".read": true,
".write": true
},
"reports": {
".read": true,
".write": true
},
"users": {
"$uid": {
".read": true,
".write": true
}
}
}
}Create a bucket named sos-recordings with public access for audio evidence storage.
npm run build
vercel --prodThe vercel.json is pre-configured for SPA routing.
| Service | Number | Color | Use Case |
|---|---|---|---|
| ๐ฎ Police | 100 | ๐ต Blue | Crime, accidents, security |
| ๐ Ambulance | 108 | ๐ด Red | Medical emergencies |
| ๐ Fire | 101 | ๐ Orange | Fire, rescue operations |
- Fork the repository
- Create a feature branch (
git checkout -b feature/AmazingFeature) - Commit changes (
git commit -m 'Add AmazingFeature') - Push to branch (
git push origin feature/AmazingFeature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- React - UI Library
- Firebase - Backend & Realtime Database
- Leaflet - Interactive Maps
- Google Gemini - AI Analysis
- Supabase - Storage Solution
Made with โค๏ธ for INVENTO 2026
๐ Your Safety, Our Priority ๐