π€ RainAlert is a smart weather alert system that sends you a daily email notification at 7 AM, keeping you informed about the rain forecast for the day. Whether you're heading to work, running errands, or planning outdoor activities, RainAlert ensures you're never caught off guard by the weather! βπ§
β° Daily Email Alerts: Get notified at 7 AM every morning, so you can plan your day knowing whether to carry an umbrella or not. π¦
π Location-Based Alerts: Tailored weather updates for your specific location β never miss out on the forecast! π
π§ Real-Time Rain Forecast: Get real-time weather data from the OpenWeather API to stay ahead of the rain.
π Automated Email Notifications: Seamlessly integrated with Twilio to send alerts straight to your inbox.
β‘ Python Powered: Built in Python for efficiency and flexibility, with a clean, easy-to-understand codebase.
Twilio API: For sending email notifications with real-time weather updates. π§
OpenWeather API: For fetching live weather data. π€
Python: The backbone of this system, providing smooth automation and reliability. π
SMTP: For sending the emails directly to your inbox! β
Getting up and running is easy with just a few steps:
-
Clone the Repository: git clone https://github.com/SrinjoyeeDey/Twilio-Rain-Alert.git
-
Install Required Dependencies: pip install -r requirements.txt
-
Setup Your Credentials:
Twilio: Get your SID, Auth Token, and Twilio Phone Number.
OpenWeather: Sign up to get your API Key.
- Configure the .env File: Create a .env file in the root directory and add the following keys:
TWILIO_SID=your_twilio_sid
TWILIO_AUTH_TOKEN=your_twilio_auth_token
TWILIO_PHONE_NUMBER=your_twilio_phone_number
OPENWEATHER_API_KEY=your_openweather_api_key
ALERT_TIME=07:00 (Set your preferred alert time, default is 7 AM)
- Run the System: Start the application and let it do the work! python rain_alert.py π§
-
Weather Data Fetching: Every morning, the system connects to the OpenWeather API to retrieve the weather data for your location. π€
-
Rain Prediction: If rain is forecasted, it prepares a personalized alert email that details the rain forecast for the day. π§
-
Email Notification: At 7 AM, Twilio sends the email directly to your inbox, so you can get ready before you step out! π§ Now, you can plan your day and make decisions accordingly!
Change Alert Time: Want to get alerts at a different time? No problem! Simply change the ALERT_TIME variable to any time you prefer. β°
Location Settings: Customize the system to send weather updates for any city or region you like. Just update the location settings in the .env file! π
We welcome all contributions to enhance RainAlert! π If you have ideas for new features, enhancements, or even bug fixes, feel free to fork the repo and create a pull request. Together, letβs make this weather alert system even better! π
GitHub Repo: https://github.com/SrinjoyeeDey/Twilio-Rain-Alert/tree/main
Twilio API Documentation: https://www.twilio.com/login?iss=https%3A%2F%2Flogin.twilio.com%2F
OpenWeather API Documentation: https://openweathermap.org/current