The Emergency Communication System is a web-based application that allows users to send emergency alerts via SMS using Twilio. Users can capture their geolocation using HTML5's Geolocation API to provide additional context about their emergency. This system is designed to be simple, intuitive, and efficient, enabling users to send alerts with just a few clicks.
- Develop a user-friendly web-based application to send emergency alerts via SMS using Twilio.
- Integrate HTML5's Geolocation API to capture and transmit the user's location for precise emergency reporting.
- Ensure the system is efficient, accessible, and responsive to facilitate quick emergency communication during wildfires.
Background Information: Wildfires are unpredictable and can spread rapidly, leaving limited time for individuals to react. Effective communication during such crises is vital to ensuring safety. However, traditional systems often lack speed and precise location data.
Significance: This project addresses the need for a lightweight, fast, and reliable communication tool that provides real-time location data, significantly enhancing emergency response efficiency.
Novelty: Unlike many existing emergency communication systems, this application combines SMS alerts with geolocation capabilities, ensuring accurate contextual information is shared. Its simplicity and accessibility set it apart, as users can quickly send alerts without requiring specialized equipment or extensive technical knowledge.
Before you can run the project locally, ensure you have:
- Python 3.x installed
- A Twilio account with credentials
- Twilio's credentials (
Account SID,Auth Token, and a Twilio phone number)
- Clone the repository:
git clone <https://github.com/chazdj/Emergency-Communication-System> cd Emergency-Communication-System
- Install dependencies:
pip install flask twilio
- Set Twilio credentials in the server: Replace placeholders with your Twilio
Account SID,Auth Token, and Twilio phone number:client = Client("YOUR_TWILIO_ACCOUNT_SID", "YOUR_TWILIO_AUTH_TOKEN")
- Run the server:
python server.py
- Open the frontend: Navigate to http://127.0.0.1:5000 in your browser.
- Open the application in a web browser.
- Grant location permissions when prompted.
- Enter the recipient’s phone number and optional additional details about the emergency.
- Click Send Alert to transmit the SMS along with your geolocation.
The project leverages the following tools and libraries:
- Frontend: HTML5, CSS, JavaScript
- Handles user interactions and geolocation capture.
- Backend: Flask (Python), Twilio, Geolocation API
- Processes SMS sending via Twilio and manages API endpoints.
| User Interface |
|---|
| ↓ |
| Frontend (HTML/JavaScript) |
| ↓ |
| API Request (Geolocation & Message) |
| ↓ |
| Backend |
| ↓ |
| Twilio API (Send SMS) |
Explanation: The frontend captures user input and location data, sends it to the backend API, which then communicates with Twilio to dispatch the alert.
Functionalities:
- SMS Alert System using Twilio API.
- Geolocation capture with HTML5 API.
- Minimalistic UI for quick usage.
- Logging of sent messages for verification.
Testing Results:
- Functionality: Successful SMS transmission with accurate geolocation.
- Error Handling: Identified and resolved invalid phone number and location access denial issues.
- Successfully integrated Twilio for real-time SMS communication.
- Demonstrated geolocation capture on desktop browsers.
- Achieved seamless interaction between frontend and backend, ensuring reliability.
- Geolocation Accuracy: Limited by device/browser capabilities.
- Twilio Constraints: SMS functionality depends on Twilio's pricing and plan.
This project reinforced course concepts in:
- Web development (frontend and backend integration)
- API usage (Twilio and Geolocation APIs)
- Testing and debugging
Created by Chastidy Joanem
GitHub: @chazdj



