# Airport Schedule API V2

API endpoint for this API is: **`https://api.flightapi.io/schedule/v2`**

## Guide

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     |
| --------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------- |
| <p>api\_key<br><br><mark style="color:red;">required</mark></p> | This is your personal API key. You can find this on your Dashboard.                                                                                                          | `String` |
| <p>mode<br><br><mark style="color:red;">required</mark></p>     | <p>The value of mode could be either <strong><code>arrivals</code></strong> or <strong><code>departures</code></strong>.<br><br><mark style="color:red;">required</mark></p> | `String` |
| <p>year<br><br><mark style="color:red;">required</mark></p>     | <p>This represents the year.<br><br>Example values - <code>2025</code> or <code>2026</code></p>                                                                              | `String` |
| <p>month<br><br><mark style="color:red;">required</mark></p>    | <p>This could be any month of the year.<br><br>Example values - <code>01</code>, <code>06</code> or <code>12</code>.</p>                                                     | `String` |
| <p>day<br><br><mark style="color:red;">required</mark></p>      | This is the day of a month                                                                                                                                                   | `String` |
| <p>page<br><br><mark style="color:red;">required</mark></p>     | <p>For each day there are maximum 4 pages. <br><br>Possible values - 1,2,3 or 4.</p>                                                                                         | `String` |

{% hint style="info" %}
If you don't pass the day parameter then our API will respond with the complete schedule of the airport from the last 5 days to the next 5 days. Credit cost also depends on the number of days you receive.
{% endhint %}

## Usage

You have to send a GET request to  `https://api.flightapi.io/schedule` along with all the parameters.&#x20;

Check out sample API calls written in multiple programming languages.

{% tabs %}
{% tab title="curl" %}

```bash
curl "https://api.flightapi.io/schedule/v2/api_key?mode=dep&iata=JAI&year=2025&month=11&day=25&page=1
```

{% endtab %}

{% tab title="Node" %}

```javascript
// require the Unirest or any other module to make an HTTP GET request
const unirest = require('unirest')

unirest.get('https://api.flightapi.io/schedule/v2/api_key?mode=departures&iata=DOH&day=1')
  .then(response => {
    console.log(response.body);
  })
  .catch(error => {
    console.log(error);
  });


```

{% endtab %}

{% tab title="Python" %}

```python
import axios from "axios";

const url = "https://api.flightapi.io/schedule/v2/api_key";

const params = {
  mode: "dep",
  iata: "JAI",
  year: 2025,
  month: 11,
  day: 25,
  page: 1
};

async function fetchSchedule() {
  try {
    const response = await axios.get(url, { params });
    console.log(response.data);
  } catch (error) {
    console.error("Error fetching flight schedule:", error.message);
  }
}

fetchSchedule();


```

{% endtab %}
{% endtabs %}

### Response

The sample response of the API will look somewhat like this.

{% code overflow="wrap" fullWidth="false" %}

```json
{
    "data": {
        "header": {
            "date": "21-Nov-2025",
            "dateMDY": "Nov-21-2025",
            "title": "(JAI) Jaipur International Airport Departures",
            "mobileTitle": "JAI Departures",
            "departureAirport": {
                "fs": "JAI",
                "iata": "JAI",
                "icao": "VIJP",
                "name": "Jaipur International Airport",
                "city": "Jaipur",
                "state": "",
                "country": "IN",
                "active": true,
                "classification": 3,
                "timeZoneRegionName": "Asia/Kolkata"
            }
        },
        "destOriginTitle": "Destination",
        "flights": [
            {
                "sortTime": "2025-11-20T17:45:00.000Z",
                "departureTime": {
                    "timeAMPM": "11:15PM",
                    "time24": "23:15"
                },
                "arrivalTime": {
                    "timeAMPM": "1:10AM",
                    "time24": "01:10"
                },
                "carrier": {
                    "fs": "SG",
                    "name": "SpiceJet",
                    "flightNumber": "251"
                },
                "operatedBy": null,
                "url": "/flight-tracker/SG/251?year=2025&month=11&date=20&flightId=1352424334",
                "airport": {
                    "fs": "BOM",
                    "city": "Mumbai"
                }
            },
            {
                "sortTime": "2025-11-20T18:20:00.000Z",
                "departureTime": {
                    "timeAMPM": "11:50PM",
                    "time24": "23:50"
                },
                "arrivalTime": {
                    "timeAMPM": "1:00AM",
                    "time24": "01:00"
                },
                "carrier": {
                    "fs": "6E",
                    "name": "IndiGo",
                    "flightNumber": "5136"
                },
                "operatedBy": null,
                "url": "/flight-tracker/6E/5136?year=2025&month=11&date=20&flightId=1352341884",
                "airport": {
                    "fs": "DEL",
                    "city": "Delhi"
                }
            },
            {
                "sortTime": "2025-11-20T18:20:00.000Z",
                "departureTime": {
                    "timeAMPM": "11:50PM",
                    "time24": "23:50"
                },
                "arrivalTime": {
                    "timeAMPM": "1:00AM",
                    "time24": "01:00"
                },
                "carrier": {
                    "fs": "QF",
                    "name": "Qantas",
                    "flightNumber": "5398"
                },
                "operatedBy": "Operated by IndiGo 5136",
                "url": "/flight-tracker/QF/5398?year=2025&month=11&date=20&flightId=1352341884",
                "airport": {
                    "fs": "DEL",
                    "city": "Delhi"
                },
                "isCodeshare": true
            },
            {
                "sortTime": "2025-11-20T18:20:00.000Z",
                "departureTime": {
                    "timeAMPM": "11:50PM",
                    "time24": "23:50"
                },
                "arrivalTime": {
                    "timeAMPM": "1:00AM",
                    "time24": "01:00"
                },
                "carrier": {
                    "fs": "VS",
                    "name": "Virgin Atlantic",
                    "flightNumber": "8599"
                },
                "operatedBy": "Operated by IndiGo 5136",
                "url": "/flight-tracker/VS/8599?year=2025&month=11&date=20&flightId=1352341884",
                "airport": {
                    "fs": "DEL",
                    "city": "Delhi"
                },
                "isCodeshare": true
            },
            {
                "sortTime": "2025-11-20T18:25:00.000Z",
                "departureTime": {
                    "timeAMPM": "11:55PM",
                    "time24": "23:55"
                },
                "arrivalTime": {
                    "timeAMPM": "1:45AM",
                    "time24": "01:45"
                },
                "carrier": {
                    "fs": "6E",
                    "name": "IndiGo",
                    "flightNumber": "5166"
                },
                "operatedBy": null,
                "url": "/flight-tracker/6E/5166?year=2025&month=11&date=20&flightId=1352341935",
                "airport": {
                    "fs": "BOM",
                    "city": "Mumbai"
                }
            },
            {
                "sortTime": "2025-11-20T18:25:00.000Z",
                "departureTime": {
                    "timeAMPM": "11:55PM",
                    "time24": "23:55"
                },
                "arrivalTime": {
                    "timeAMPM": "1:45AM",
                    "time24": "01:45"
                },
                "carrier": {
                    "fs": "VS",
                    "name": "Virgin Atlantic",
                    "flightNumber": "8758"
                },
                "operatedBy": "Operated by IndiGo 5166",
                "url": "/flight-tracker/VS/8758?year=2025&month=11&date=20&flightId=1352341935",
                "airport": {
                    "fs": "BOM",
                    "city": "Mumbai"
                },
                "isCodeshare": true
            },
            {
                "sortTime": "2025-11-20T19:40:00.000Z",
                "departureTime": {
                    "timeAMPM": "1:10AM",
                    "time24": "01:10"
                },
                "arrivalTime": {
                    "timeAMPM": "3:55AM",
                    "time24": "03:55"
                },
                "carrier": {
                    "fs": "IX",
                    "name": "Air India Express",
                    "flightNumber": "195"
                },
                "operatedBy": null,
                "url": "/flight-tracker/IX/195?year=2025&month=11&date=21&flightId=1352577756",
                "airport": {
                    "fs": "DXB",
                    "city": "Dubai"
                }
            },
            {
                "sortTime": "2025-11-20T19:40:00.000Z",
                "departureTime": {
                    "timeAMPM": "1:10AM",
                    "time24": "01:10"
                },
                "arrivalTime": {
                    "timeAMPM": "3:55AM",
                    "time24": "03:55"
                },
                "carrier": {
                    "fs": "AI",
                    "name": "Air India",
                    "flightNumber": "9123"
                },
                "operatedBy": "Operated by Air India Express 195",
                "url": "/flight-tracker/AI/9123?year=2025&month=11&date=21&flightId=1352577756",
                "airport": {
                    "fs": "DXB",
                    "city": "Dubai"
                },
                "isCodeshare": true
            },
            {
                "sortTime": "2025-11-20T21:45:00.000Z",
                "departureTime": {
                    "timeAMPM": "3:15AM",
                    "time24": "03:15"
                },
                "arrivalTime": {
                    "timeAMPM": "5:50AM",
                    "time24": "05:50"
                },
                "carrier": {
                    "fs": "EY",
                    "name": "Etihad Airways",
                    "flightNumber": "329"
                },
                "operatedBy": null,
                "url": "/flight-tracker/EY/329?year=2025&month=11&date=21&flightId=1352563158",
                "airport": {
                    "fs": "AUH",
                    "city": "Abu Dhabi"
                }
            },
            {
                "sortTime": "2025-11-20T22:40:00.000Z",
                "departureTime": {
                    "timeAMPM": "4:10AM",
                    "time24": "04:10"
                },
                "arrivalTime": {
                    "timeAMPM": "6:20AM",
                    "time24": "06:20"
                },
                "carrier": {
                    "fs": "G9",
                    "name": "Air Arabia",
                    "flightNumber": "436"
                },
                "operatedBy": null,
                "url": "/flight-tracker/G9/436?year=2025&month=11&date=21&flightId=1352571091",
                "airport": {
                    "fs": "SHJ",
                    "city": "Sharjah"
                }
            },
            {
                "sortTime": "2025-11-20T23:45:00.000Z",
                "departureTime": {
                    "timeAMPM": "5:15AM",
                    "time24": "05:15"
                },
                "arrivalTime": {
                    "timeAMPM": "6:15AM",
                    "time24": "06:15"
                },
                "carrier": {
                    "fs": "SG",
                    "name": "SpiceJet",
                    "flightNumber": "9944"
                },
                "operatedBy": null,
                "url": "/flight-tracker/SG/9944?year=2025&month=11&date=21&flightId=1352952928",
                "airport": {
                    "fs": "DEL",
                    "city": "Delhi"
                }
            },
            {
                "sortTime": "2025-11-20T23:50:00.000Z",
                "departureTime": {
                    "timeAMPM": "5:20AM",
                    "time24": "05:20"
                },
                "arrivalTime": {
                    "timeAMPM": "7:30AM",
                    "time24": "07:30"
                },
                "carrier": {
                    "fs": "SG",
                    "name": "SpiceJet",
                    "flightNumber": "1077"
                },
                "operatedBy": null,
                "url": "/flight-tracker/SG/1077?year=2025&month=11&date=21&flightId=1352606014",
                "airport": {
                    "fs": "PNQ",
                    "city": "Pune"
                }
            },
            {
                "sortTime": "2025-11-21T00:05:00.000Z",
                "departureTime": {
                    "timeAMPM": "5:35AM",
                    "time24": "05:35"
                },
                "arrivalTime": {
                    "timeAMPM": "8:10AM",
                    "time24": "08:10"
                },
                "carrier": {
                    "fs": "6E",
                    "name": "IndiGo",
                    "flightNumber": "839"
                },
                "operatedBy": null,
                "url": "/flight-tracker/6E/839?year=2025&month=11&date=21&flightId=1352521518",
                "airport": {
                    "fs": "BLR",
                    "city": "Bengaluru"
                }
            },
            {
                "sortTime": "2025-11-21T00:05:00.000Z",
                "departureTime": {
                    "timeAMPM": "5:35AM",
                    "time24": "05:35"
                },
                "arrivalTime": {
                    "timeAMPM": "8:10AM",
                    "time24": "08:10"
                },
                "carrier": {
                    "fs": "QF",
                    "name": "Qantas",
                    "flightNumber": "8889"
                },
                "operatedBy": "Operated by IndiGo 839",
                "url": "/flight-tracker/QF/8889?year=2025&month=11&date=21&flightId=1352521518",
                "airport": {
                    "fs": "BLR",
                    "city": "Bengaluru"
                },
                "isCodeshare": true
            },
            {
                "sortTime": "2025-11-21T00:15:00.000Z",
                "departureTime": {
                    "timeAMPM": "5:45AM",
                    "time24": "05:45"
                },
                "arrivalTime": {
                    "timeAMPM": "7:50AM",
                    "time24": "07:50"
                },
                "carrier": {
                    "fs": "6E",
                    "name": "IndiGo",
                    "flightNumber": "6977"
                },
                "operatedBy": null,
                "url": "/flight-tracker/6E/6977?year=2025&month=11&date=21&flightId=1352520935",
                "airport": {
                    "fs": "GOX",
                    "city": "Goa"
                }
            },
            {
                "sortTime": "2025-11-21T00:20:00.000Z",
                "departureTime": {
                    "timeAMPM": "5:50AM",
                    "time24": "05:50"
                },
                "arrivalTime": {
                    "timeAMPM": "7:15AM",
                    "time24": "07:15"
                },
                "carrier": {
                    "fs": "6E",
                    "name": "IndiGo",
                    "flightNumber": "7742"
                },
                "operatedBy": null,
                "url": "/flight-tracker/6E/7742?year=2025&month=11&date=21&flightId=1352521448",
                "airport": {
                    "fs": "IXC",
                    "city": "Chandigarh"
                }
            },
            {
                "sortTime": "2025-11-21T00:30:00.000Z",
                "departureTime": {
                    "timeAMPM": "6:00AM",
                    "time24": "06:00"
                },
                "arrivalTime": {
                    "timeAMPM": "8:05AM",
                    "time24": "08:05"
                },
                "carrier": {
                    "fs": "AI",
                    "name": "Air India",
                    "flightNumber": "414"
                },
                "operatedBy": null,
                "url": "/flight-tracker/AI/414?year=2025&month=11&date=21&flightId=1352537438",
                "airport": {
                    "fs": "BOM",
                    "city": "Mumbai"
                }
            }
        ]
    }
}
```

{% endcode %}

{% hint style="info" %}
It is just a sample API response. Some objects will have more attributes. A new array might also be there.
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.flightapi.io/airport-schedule-api-v2.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
