Historical Airport Schedules API – Returns Just What It Promises!
Tags: api, airportapi, aviation, historicalflights
Published: 2023-08-14 07:36:00

Stumbling upon this article, a [historical airport schedules API](https://aviyair.com/discover-historical-airport-schedules-api/) is probably the data tool you’ve been looking for to get started with your project. Aviyair’s API promises this exact data for airports all around the world with just the necessary objects with each request. Let’s break down what you can expect with the API. If you don’t have time to go through this article, you can find a **link to the full documentation and how to get your API key at the bottom**.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9777ybvfbeus1qgzvtst.jpeg)

----

### Table of Contents 

<ol>
  <li><a href="#api-structure-and-integration-environment">API Structure and Integration Environment</a></li>
  <li><a href="#example-200-ok-output-and-full-documentation">Example 200 OK Output and Full Documentation</a></li>
  <li><a href="#url-examples-with-api-methods-and-filters">URL Examples with API Methods and Filters</a></li>
  <li><a href="#summary-and-api-key-link">Summary and API Key Link</a></li>
</ol>

----

## API Structure and Integration Environment

The structure of the Historical Airport Schedules API is **REST** which means your preferred programming language will be supported when integrating. REST’s highly adapted style is a developer-friendly feature that will ease the integration phase. In Aviyair, our team members include developers who are experienced in the aviation industry, so we understand the pain of endless nights with coding and coffee to meet deadlines. This is why we aimed to keep the Past Airport Schedules API as plain but effective as possible. Its easing optimization and ability to cache responses effectively are good reasons to choose this structure.

> Code your project using Javascript, JQuery, VueJS, Angular, JAVA, PHP, NodeJS, Python, Go, Ruby, C#, R, Strest, Rust, Swift, Scala and more.

----

## Example 200 OK Output and Full Documentation

When only the obligatory parameters of airport IATA code, schedule type and date, the Historical Airport Schedules API is programmed to return the complete schedule in a single call. It is possible to filter the flights in it by airline, flight number and more. As the example output, we will show you a single flight from the output to give you an idea.

The API returns past airport schedules data in **JSON** format. You can easily convert this to other formats should you need it. The response times are fast, completely within the industry standards. 

### API Output

```
{
  "status": {
    "message": "Success"
  },
  "results": {
    "status": {
      "message": "Success"
    },
    "results": {
      "airline": {
        "iataCode": "AF",
        "icaoCode": "AFR",
        "name": "Air France"
      },
      "arrival": {
        "actualRunway": "2022-08-11T11:48:00.000",
        "actualTime": "2022-08-11T11:48:00.000",
        "baggage": "05",
        "delay": null,
        "estimatedRunway": "2022-08-11T11:48:00.000",
        "estimatedTime": "2022-08-11T11:43:00.000",
        "gate": "2",
        "iataCode": "ORY",
        "icaoCode": "LFPO",
        "scheduledTime": "2022-08-11T12:00:00.000",
        "terminal": "2"
      },
      "departure": {
        "actualRunway": "2022-08-11T10:35:00.000",
        "actualTime": "2022-08-11T10:35:00.000",
        "baggage": "4",
        "delay": "6",
        "estimatedRunway": "2022-08-11T10:35:00.000",
        "estimatedTime": "2022-08-11T10:30:00.000",
        "gate": "2C",
        "iataCode": "NCE",
        "icaoCode": "LFMN",
        "scheduledTime": "2022-08-11T10:30:00.000",
        "terminal": "2"
      },
      "flight": {
        "iataNumber": "AF6209",
        "icaoNumber": "AFR6209",
        "number": "6209"
      },
      "status": "landed",
      "type": "arrival"
    }
  }
}
```


<table>
  <thead>
    <tr>
      <th>Object</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td>status</td>
      <td>Status of the API request</td>
    </tr>
    <tr>
      <td>airline.iataCode</td>
      <td>The airline IATA code</td>
    </tr>
    <tr>
      <td>airline.icaoCode</td>
      <td>The airline ICAO code</td>
    </tr>
    <tr>
      <td>airline.name</td>
      <td>The name of the airline</td>
    </tr>
    <tr>
      <td>arrival.actualRunway</td>
      <td>Actual runway time at arrival</td>
    </tr>
    <tr>
      <td>arrival.actualTime</td>
      <td>Actual arrival time</td>
    </tr>
    <tr>
      <td>arrival.baggage</td>
      <td>Baggage belt number</td>
    </tr>
    <tr>
      <td>delay</td>
      <td>Flight delay measured in minutes</td>
    </tr>
    <tr>
      <td>arrival.estimatedRunway</td>
      <td>Estimated runway arrival time</td>
    </tr>
    <tr>
      <td>arrival.estimatedTime</td>
      <td>Estimated arrival time</td>
    </tr>
    <tr>
      <td>arrival.gate</td>
      <td>Arrival gate</td>
    </tr>
    <tr>
      <td>arrival.iataCode</td>
      <td>The IATA code of the arrival airport</td>
    </tr>
    <tr>
      <td>arrival.icaoCode</td>
      <td>The ICAO code of the arrival airport</td>
    </tr>
    <tr>
      <td>arrival.scheduledTime</td>
      <td>Scheduled arrival time</td>
    </tr>
    <tr>
      <td>arrival.terminal</td>
      <td>Arrival terminal number</td>
    </tr>
    <tr>
      <td>departure.actualRunway</td>
      <td>Actual runway departure time</td>
    </tr>
    <tr>
      <td>departure.actualTime</td>
      <td>Actual departure time</td>
    </tr>
    <tr>
      <td>departure.baggage</td>
      <td>Baggage claim number at departure airport</td>
    </tr>
    <tr>
      <td>departure.delay</td>
      <td>Departure delay in minutes</td>
    </tr>
    <tr>
      <td>departure.estimatedRunway</td>
      <td>Estimated runway departure time</td>
    </tr>
    <tr>
      <td>departure.estimatedTime</td>
      <td>Estimated departure time</td>
    </tr>
    <tr>
      <td>departure.gate</td>
      <td>Departure gate number</td>
    </tr>
    <tr>
      <td>departure.iataCode</td>
      <td>Departure airport IATA code</td>
    </tr>
    <tr>
      <td>departure.icaoCode</td>
      <td>Departure airport ICAO code</td>
    </tr>
    <tr>
      <td>departure.scheduledTime</td>
      <td>Scheduled departure time</td>
    </tr>
    <tr>
      <td>departure.terminal</td>
      <td>Departure terminal</td>
    </tr>
    <tr>
      <td>flight.iataNumber</td>
      <td>The IATA flight number</td>
    </tr>
    <tr>
      <td>flight.icaoNumber</td>
      <td>The ICAO flight number</td>
    </tr>
    <tr>
      <td>flight.number</td>
      <td>The flight number</td>
    </tr>
    <tr>
      <td>status</td>
      <td>Latest recorded flight status</td>
    </tr>
    <tr>
      <td>type</td>
      <td>The type of flight data (arrival or departure)</td>
    </tr>
  </tbody>
</table>

----

Visit the full documentation for everything.

{% embed https://aviyair.com/documentation/ %}

----

> **Note:** In case you are looking for other flight details in the historical airport schedules data such as the aircraft details or real-time flight location, keep in mind that we have several other aviation APIs. These will cover anything else that is not in the Historical Airport Schedules API. If you have such a requirement, send us an email explaining it and let us guide you on how you can get this data at no additional costs. This is because the unique API key you get on our website will grant you access to all our APIs. 


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/gj524acrvqi3etae2nuf.jpeg)


----

## URL Examples with API Methods and Filters

The Past Airport Schedules API requests are all GET. The server is `https://data.aviyair.com/data/v1/` and the endpoint is "/historicalschedule?" with many parameters available to use as filters.

<table>
  <thead>
    <tr>
      <th>Route</th>
      <th>Method</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td>https://data.aviyair.com/data/v1/historicalschedule?key=APIKEY&amp;airport_iata=CGK&amp;type=departure&amp;date_from=2023-01-01</td>
      <td>GET</td>
      <td>Departure schedule of CGK on 2023-01-01</td>
    </tr>
    <tr>
      <td> https://data.aviyair.com/data/v1/historicalschedule?key=APIKEY&amp;airport_iata=CGK&amp;type=departure&amp;date_from=2023-01-01&amp;date_to=2023-01-03&amo</td>
      <td>GET</td>
      <td>The complete departure schedule of CGK between 2023-01-01 and 2023-01-03 (3 days included)</td>
    </tr>
      <td> https://data.aviyair.com/data/v1/historicalschedule?key=APIKEY&amp;airport_iata=CGK&amp;type=departure&amp;date_from=2023-01-01&amp;airline_iata=QZ</td>
      <td>GET</td>
      <td>Departure schedule of CGK on 2023-01-01 with every flight of Indonesia AirAsia</td>
    </tr>
    <tr>
      <td> https://data.aviyair.com/data/v1/historicalschedule?key=APIKEY&amp;airport_iata=CGK&amp;type=departure&amp;date_from=2023-01-01&amp;airline_iata=QZ&amp;flight_number=265</td>
      <td>GET</td>
      <td>Delay data and other details for flight QZ265 on 2023-01-01</td>
    </tr>
  </tbody>
</table>

----- 

###USEFUL TIPS CORNER

✅ **Coverage:** Aviyair’s historical airport schedules data have GLOBAL coverage. No matter which markets you want your business to focus, the API’s got you covered!

✅ **Expert Support:** If you are not sure how to draw a path for your use case or looking for ways to enhance it, feel free to send us an email and exchange ideas with one of our experts in the industry.

✅ **Marketing Opportunity:** Online visibility matters. If you are looking for ways to increase the organic online visibility of your product powered by Aviyair’s past airport schedules data, we can talk about several affordable opportunities. Give us a holler if you are interested!

----

## Summary and API Key Link

**TL;DR**, the past airport schedules API of Aviyair is a very convenient data tool to **fetch historical airport timetable data**. With all the useful details in the output such as airline details, airport details, scheduled/estimated/actual departure and arrival + runway times, flight number, flight and cancellation status, total delay, gate, terminal, baggage belt and more, for each flight in the response this **JSON REST **API is definitely a developer-friendly option. You can request one or multiple consecutive dates at once.

Accessing this API is very easy and **takes 1 minute of your time.** Simply go with a subscription plan below and receive your API key to your email. Great discounts apply for the first weeks so you can fully test and start integrating the API for basically nothing. 

📌 **Cancel anytime.** You have full control over your access to the Historical Airport Timetables API.
Custom plans available. If you need fewer or more API calls than our fixed plans, we can get you a custom offer.

📌 **No hidden fees.** When you reach your limit, you will simply receive a message in the output and will not get charged unexpectedly. When you need more calls, simply upgrade your plan on your dashboard for immediate higher limits.

📌 **Get support.** With their background in aviation, Aviyair is here to help if you have any questions or for your support requests. [**Contact Aviyair here.**](https://aviyair.com/contact-aviyair/)

-----

Get your API key and get ready to take-off! 🛫🛫🛫

{% embed https://aviyair.com/pricing-subscription-plans/ %}🛫