This Python script checks the latest announcement on the websites listed in the URLS dictionary and sends an email notification to the email addresses listed in the EMAIL_INFO dictionary.
- Python 3.x
requests
modulebeautifulsoup4
modulesmtplib
moduleemail-to
moduledotenv
module- A Gmail account with "App password" turned on
- Clone this repository to your local machine.
- Install the required modules:
pip3 install -r requirements.txt
- Create a
.env
file in the same directory as theannouncement.py
file, and add the following lines:
sender_password=your_gmail_app_password
The EMAIL_INFO dictionary contains the email information for sending the notifications. You can customize the sender email, sender password, and receiver emails by modifying this dictionary.
Example:
EMAIL_INFO = {
"sender_email": "[email protected]",
"sender_password": "your_gmail_app_password",
"receiver_emails": ["[email protected]", "[email protected]"]
}
This project is licensed under the MIT License - see the LICENSE file for details