Flight Info Alerts - Creating an Alert

An alert can be created quickly using a simple HTTP request.

Flight Info Alerts allows you to configure which flights you want to see changes for. This can be at the global level i.e. for every single schedule change that OAG processes, or it can be all the way down to the individual flight level. Here we will show you the configurations available to you to create the alerts you need.

Prerequisites to create an Alert

  • An active subscription key for Flight Info Alerts.
  • An account ID, received when you completed your profile.

Creating an Alert

An alert can be created via a HTTP POST request with the following JSON body sample:

{
    "accountId": "ce29194a-8218-486b-a3b7-ade791d57423",
    "name": "John's Alert",
    "description": "Alert config for John",
    "iataCarrierCode": "AA",
    "icaoCarrierCode": "AAA",
    "flightNumber": 1231,
    "fromFlight": 1245,
    "toFlight": 6235,
    "departureAirport": "DUB",
    "arrivalAirport": "HTR",
    "departureDate": "2021-09-25",
    "arrivalDate": "2021-09-26",
    "alertType": "global",
    "content": "seats, changeindicator",
    "schedules": true,
    "status": true,
    "gaFlights": false,
    "unscheduledFlights": false,
    "statusChangeFilters": {
      "baggage": true,
      "aircraftRegistrationNumber": true,
      "gates": true,
      "terminal": true,
      "seats": true,
      "aircraftType": true
    }
}

Do note that not all parameters above are required to create an alert, and is dependent on the type of alert you would like to create. A detailed description of the type of alerts you can create, and the description of each of the above fields is listed below.

For other technical details such as authentication headers, sample code and the latest endpoint URL, please refer to this page on the developer portal.

Types of Alerts

Global Alerts

If you want to receive Alerts for every single change that OAG processes you will need to set up a Global Alert. Alerts will be generated on all schedule changes. No additional parameter is required to set this up.

Note: The global alert configuration supersedes all other alert types. It is not possible to create a global alert when you have other alerts active and our API will throw an error if you attempt to do so. Please delete all other existing alerts before you create a global alert.

Non-Global Alerts

For anything other than Global, Alerts can be configured using a number of data elements in combination. Some example of the types of Alerts that can be set up are:

Carrier Alert: Show me all changes for a specific carrier

Port Alert: Show me all changes for flights departing from a specific airport

Routing Alert: Show me all changes for flights on a specific route

Single Flight Alerts: A type of Carrier alert, this is used to show all changes for a specific flight number, on a specific route on a specific date

The parameters you can use to configure an alert are below:

Name

Example

Description

accountId aa12345a-1234-123c-d4e5-fgh791i57423

Alphanumeric characters. Generated on the creation of the customer profile

name My First Alert

Some text assigning a name to the alert

description My Alert for XX

Some text describing the purpose of the alert

alertType global

The type of alert being configured either Global, Port or Carrier. Please refer to this page to know what alert type to use for what purpose.

active TRUE

A true/false value to enable/disable the alert

content seats

If specified, additional data is included in the Alerts generated from this request

iataCarrierCode XX

A two-character code assigned by the IATA to international airlines

icaoCarrierCode XXX

A three-character code assigned by the ICAO to international airlines

flightNumber 1234

A numeric part (up to four digits) of a flight designator

fromFlight 0001

A numeric part (up to four digits) of a flight designator

toFlight 1000

A numeric part (up to four digits) of a flight designator

departureAirport LHR

A Three-letter code assigned by the IATA to an airport location representing departure airport

arrivalAirport JFK

A Three-letter code assigned by the IATA to an airport location representing arrival airport

departureDate 2022-01-01

A date in the format yyyy-MM-dd for flight departures

arrivalDate 2022-01-01

A date in the format yyyy-MM-dd for flight arrivals

schedules true

Indicates if you want to receive schedules updates. Do note that you need to have schedule subscription in order to do so.

status true

Indicates if you want to receive status updates. Do note that you need to have a status subscription in order to do so.

gaFlights true

Set to true if you want to receive general aviation flight status updates. Does not apply to schedules data.

unscheduledFlights false

Set to true if you would like to receive flight status updates for unscheduled flights. Does not apply to schedules data.

statusChangeFilters N/A

JSON container for status change filters

baggage true

Set to false if you do not want flight updates for baggage changes only

gates true

Set to false if you do not want flight updates for gate changes only

terminal true

Set to false if you do not want flight updates for terminal changes only

aircraftType true

Set to false if you do not want flight updates for aircraft type changes only

aircraftRegistrationNumber true

Set to false if you do not want flight updates for aircraft registration number changes only

Note: When a flight alert is created, no checks are performed to determine if the alert represents actual flight data and you will still receive a '201 Created' response.

Once your alert is set up you still start seeing related data changes flow through into your event hub as we process them.

If you need more information on the type of alerts to create and what information you will receive from them, please refer to this page: What type of alerts can I create?

Recommended next step: Connecting to your event hub to receive events.