Skip to content

Instantly share code, notes, and snippets.

@daz
Created October 23, 2020 07:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save daz/0faa37a421570981f4327167a34d3759 to your computer and use it in GitHub Desktop.
Save daz/0faa37a421570981f4327167a34d3759 to your computer and use it in GitHub Desktop.
Download all Airdata flights
// Get a list of all Airdata flight download URLs in KML, GPX, CSV, original format.
// Go to https://app.airdata.com/flight/last and paste this into the console
let urlList = $("#item_list_dt")
.DataTable()
.tables()
.context[0].aoData.map(a => {
return a._aData.h;
})
.slice(1, -1)
.map(h => {
return {
kml: `https://app.airdata.com/kml?flight=${h}&default_color=ff00ffff&default_width=2&color_width=3`,
gpx: `https://app.airdata.com/gpx?flight=${h}&default_color=ff00ffff&default_width=2&color_width=3`,
csv: `https://app.airdata.com/csv?flight=${h}`,
original: `https://app.airdata.com/original?flight=${h}`
};
});
// Copy to clipboard
copy(
urlList
.map(u => {
return u.original;
})
.join("\n")
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment