A Python script that monitors flight prices from a specified origin city to multiple destinations and sends SMS notifications when prices drop below set thresholds.
- Tracks flight prices from a single origin to multiple destinations
- Checks prices for the next 6 months
- Sends SMS notifications for low-price alerts
- Integrates with Sheety for destination data management
- Handles rate limiting with request delays
- Python 3.x
- Required Python packages:
requests(implied for API calls)- Custom classes:
data_manager.py(Sheety_Manager)flight_search.py(FlightSearch)flight_data.py(find_cheapest_flight)notification_manager.py(NotificationManager)
- Clone the repository:
git clone https://github.com/yourusername/flight-price-tracker.git
cd flight-price-tracker- Install dependencies:
pip install -r requirements.txt- Set up required external services:
- Sheety account for destination data
- Flight search API (implementation dependent)
- SMS service (e.g., Twilio) for notifications
ORIGIN_CITY_IATA: Set to "ICN" (Incheon International Airport) by default- Destination data stored in Sheety spreadsheet with columns:
city: Destination city nameiataCode: Destination airport IATA codelowestPrice: Target price threshold
- Configure API keys/credentials in respective class files
- Ensure all class dependencies are properly configured
- Run the script:
python flight_tracker.py- Retrieves destination data from Sheety
- For each destination:
- Searches flights from origin (ICN) to destination
- Checks prices for next 6 months
- Finds cheapest available flight
- Compares with target price
- Sends SMS if price is lower than threshold
- Implements 2-second delay between requests to avoid rate limiting
flight_tracker.py: Main scriptdata_manager.py: Sheety data managementflight_search.py: Flight search API integrationflight_data.py: Flight data processingnotification_manager.py: SMS notification handling
- Searches flights from tomorrow to 6 months ahead
- Uses IATA codes for airports
- Price is displayed in GBP (£)
- Requires separate implementation of supporting classes
- Includes basic rate limiting with 2-second sleep
# Suggested requirements.txt
requests
# Add any additional dependencies required by the custom classes- Change
ORIGIN_CITY_IATAto your preferred departure airport - Modify date range by adjusting
timedeltavalues - Adjust sleep time based on API rate limits
- Update currency display in notification message
- Dependent on external API availability
- Requires separate implementation of supporting classes
- Basic error handling not shown in main script
Ensure compliance with:
- Flight search API terms of service
- SMS service provider regulations
- Sheety usage policies