🛂
Track Flights between Airports
With this API you can track flights between any two airports. You can track flights for the next 365 days.
API endpoint for this API is:
https://api.flightapi.io/trackbyroute
Your API requests are authenticated using API keys. Any request that doesn't include an API key will return an error.
You can generate an API key from your Dashboard at any time.
Here is the list of default parameters you have to use with this API:
Parameters | Description | Type |
---|---|---|
api_key
required | This is your personal API key. You can find this on your Dashboard. | String |
date
required | This is the date of departure
Format - YYYYMMDD | String |
airport1
required | This is the IATA code of the departure airport.
required | String |
airport2
required | This is the IATA code of the arrival airport.
required | String |
You have to send a GET request to
https://api.flightapi.io/trackbyroute
along with all the parameters. Take a look at how you might call this API using various different coding languages.
curl
Node
Python
curl "https://api.flightapi.io/trackbyroute/api_key?date=20230724&airport1=AMS&airport2=LIS"
// require the Unirest or any other module to make an HTTP GET request
const unirest = require('unirest')
unirest.get('https://api.flightapi.io/trackbyroute/api_key?date=20230724&airport1=AMS&airport2=LIS')
.then(response => {
console.log(response.body);
})
.catch(error => {
console.log(error);
});
// Set your API key before making the request
import requests
resp = requests.get('https://api.flightapi.io/trackbyroute/api_key?date=20230724&airport1=AMS&airport2=LIS')
print (resp.json())
The sample response of the API will look somewhat like this.
// Sample Response
[
{
"Airline": "AeroMexico",
"FlightNumber": "6552",
"Status": "In Air",
"Operated By": "KLM Royal Dutch Airlines1697",
"DepartureTime": "9:08 PM, Apr 24",
"ArrivalTime": "10:54 PM, Apr 24"
},
{
"Airline": "Air Baltic Corp",
"FlightNumber": "5296",
"Status": "Arrived",
"Operated By": "TAP Portugal673",
"DepartureTime": "3:09 PM, Apr 24",
"ArrivalTime": "4:59 PM, Apr 24"
},
{
...
}
]
It is just a sample API response. Some objects will have more attributes. A new array might also be there.
Last modified 4mo ago