Skip to content
A simple script that searches all of the cities in europe to find the cheapest flight from a given airport code
Ruby JavaScript
Find file
Latest commit 8a29d82 Douglas Sellers Now there is a script for africa
Failed to load latest commit information.
.gitignore Made it so that xml files are ignored
cheapest_flight_to_asia.rb Updated the list for asia
cheapest_flight_to_australia_new_zealand.rb Added some of more of the south pacific to australia/new zealand
cheapest_flight_to_south_and_central_america.rb Initial add of flights to south and central america
google_api.js Made it so that the basics of a phantomjs flight search
google_flight_multi_destination_flight_search.rb Made the google flight search api stuff work a bit better
google_flights_search.rb Made the google flight search api stuff work a bit better
multi_destination_flight_search.rb Made it so that there is a little better handling of errors
phantomjs_multi_destination_flight_search.rb Made it so that now phantomjs correctly sorts things


This is a simple program that is used to find the cheapest flights to europe (and other places) from a given airport code.  It is useful if you are interested in traveling to a certain portion of the world but aren't really concerned about exactly where.

In order to use this, you will need to have bundler installed and (eventually) phantomjs.  After doing a git clone you should bundle install.  This should install phantomjs.  After bundle finishes running verify that phantomjs is in your path.  

Once it is the usage is as follows:
bundle exec ruby cheapest_flight_to_europe.rb DEPARTURE_AIRPORT_CODE DEPART_DATE RETURN_DATE

For example:
bundle exec ruby cheapest_flight_to_europe.rb LAX,LGB,SNA,BUR,ONT 2012-12-18 2013-01-02

This will return CSV separated list of values of the format:

Price in USD, City - Country, URL

Here are some example results:
$1,278 , Osaka - Japan ,;f=LAX,LGB,SNA,BUR,ONT;t=KIX;d=2012-12-18;r=2013-01-02
$1,429 , Seoul - Korea ,;f=LAX,LGB,SNA,BUR,ONT;t=GMP;d=2012-12-18;r=2013-01-02
$1,459 , Tokyo - Japan ,;f=LAX,LGB,SNA,BUR,ONT;t=NRT;d=2012-12-18;r=2013-01-02

There are three scripts currently, one for europe, one for asia and one for australia/newzealand.  Enjoy!

Something went wrong with that request. Please try again.