Skip to content
This repository has been archived by the owner on Jun 15, 2023. It is now read-only.

✈️ An API for flight information from the Syracuse Hancock International Airport

Notifications You must be signed in to change notification settings

code-for-syracuse/syracuse-airport-api

Repository files navigation

Syracuse Airport Flight Info API

An API for flight information data from the Syracuse Hancock International Airport.

Rationale

The Syracuse Hancock International Airport currently publishes an XML file with flight data that is used on the organization's public website.

In a way, this is awesome and the data is far easier to use than the data from many other public public organizations. However, this XML file is not as flexible as a full REST API, which would allow for searches by flight number, by gate assignment, etc.

To create a lightweight REST interface on top of the existing airport flight information XML file, this project uses Node.js and XPath to parse the XML file and expose search paths that make this data more easily consumed by civic apps.

Example usage

Get flights by flight number

~$ curl https://{host}/number/2815
[
  {
    "$": {
      "type": "A",
      "indicator": "D",
      "airlinecode": "DL",
      "date": "03/05/16",
      "claim": "B2",
      "remarks": "ARRIVED",
      "gate": "24",
      "actualtime": "1653",
      "scheduletime": "1707",
      "city": "ATLANTA",
      "flightnumber": "2815"
    }
  }
]

Get flights by gate number

~$ curl https://{host}/gate/20

Get flights by city

~$ curl https://{host}/city/toronto

Get flights by direction

~$ curl https://{host}/direction/arrival

Get all flights

~$ curl https://{host}/

Note: JSONP is supported by using a callback parameter with requests.

About

✈️ An API for flight information from the Syracuse Hancock International Airport

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published