- Problem Statement
- Architecture
- Features
- Working
- Application Screenshot
- Installation
- Usage
- Contributing
- License
- Contact
In many situations, individuals witness crimes or incidents but hesitate to report them due to fear of retaliation or concerns about privacy. There is a need for a system that allows anonymous reporting while ensuring that precise location details are captured to aid in incident management and responses.
The Anonymous Reporter project comprises two main components:-
- Frontend: A simple web interface that allows users to report crimes by entering their phone number and providing their location access.
- Backend: A Flask application that receives the data, processes it, and sends the information through SMS to a designated police phone numbers using the 'Twilio API'.
- Browser
- Initiates requests to the web application.
- Sends phone number and location data.
- Displays confirmation messages and error alerts.
- HTML/CSS/JavaScript
- Hosts the user interface.
- Handles user input and geolocation.
- Sends POST requests to the backend server.
- Endpoints
/scan
: Handles incoming POST requests with phone number and location./
: Confirms the server is running.
- Middleware
- Flask-CORS: Handles cross-origin requests.
- Environment
- Uses environment variables for configuration (Twilio credentials, etc.).
- Twilio Client
- Sends SMS messages containing the phone number and location to the police phone numbers.
- API Endpoint
- Receives API requests from the Flask backend.
- Sends SMS messages to the specified police phone numbers.
- SMS
- Receives SMS notifications with crime report details and exact location coordinates.
- Precise Incident Reporting: Sends exact location details for precise incident reporting.
- Automatic Reporting: Automatically sends only the exact location coordinates after waiting 45 seconds if the user hesitates to enter their number and submit.
- Anonymous Reporting: Users can choose to be anonymous reporters or victims themselves.
- Widespread Accessibility: QR codes are pasted all across the city to ensure it is reachable in every corner.
- User accesses the web interface by scanning a QR code pasted in all corners of Hubballi-Dharwad and enters their phone number.
- User allows location access.
- The system waits 45 seconds; if the user doesn't submit, it sends the location automatically.
- Data is sent to the backend server.
- The backend processes the data and sends an SMS with the details using Twilio.
Details like user's exact location coordinates received within 2 seconds.
- Python 3.x
- Flask
- Twilio account
-
Clone the repository:
git clone https://github.com/yourusername/anonymous-reporter.git cd anonymous-reporter
-
Install dependencies:
pip install -r requirements.txt
-
Set up environment variables:
Create a
.env
file in the project root and add your Twilio credentials and phone numbers:TWILIO_ACCOUNT_SID=your_account_sid TWILIO_AUTH_TOKEN=your_auth_token TWILIO_PHONE_NUMBER=your_twilio_phone_number DEVELOPER_PHONE_NUMBER=your_developer_phone_number
-
Start the Flask server:
python app.py
-
Access the frontend:
Open
index.html
in your browser or deploy it to a static hosting service.
Contributions are welcome Please fork the repository and create a pull request with your changes.
This project is licensed under the MIT License - see the LICENSE file for details.
For any inquiries or support, please contact: