Updated script from https://github.com/xur17/southwest-alerts
This now uses chromium to pull the required headers and login to the southwest site to scan for price changes.
Note: I am not a python developer and this is fairly hacked together.
This is an application that can be used to monitor booked southwest flights for price changes. It logs into the accounts credentials are proided for, and checks to see if rebooking the flight would result in a lower price. If a lower price is available it will email you via the mailgun api. It will not automatically rebook the flight for you. You will need to create a free mailgun account to be able to receive the email notifications.
Setup a mailgun account, and create an api key. Use the default mailgun domain (username.mailgun.org), or create a new one for the next step.
- Run docker image (replacing everything on the right side of the equal sign with your values). You can add additional username#, password#, email# values as needed for additional southwest accounts.
docker run -e MAILGUN_DOMAIN=??? -e MAILGUN_API_KEY=??? -e USERNAME1=SOUTHWEST_USERNAME -e PASSWORD1=SOUTHWEST_PASSWORD -e EMAIL1=NOTIFICATION_EMAIL fffrank/southwest-alerts
- Pull repository
git clone fffrank/southwest-alerts
cd southwest-alerts
- Install dependencies
pip3 install -r requirements.txt
- Set environment variables (replacing value with the appropriate value)
export MAILGUN_DOMAIN=VALUE
export MAILGUN_API_KEY=VALUE
export USERNAME1=VALUE
export PASSWORD1=VALUE
export EMAIL1=VALUE
- Run
python southwestalerts/app.py