Don't see what you need? Submit a request

Itineraries endpoint

Jaivin Anzalota -

This endpoint returns a collection of itineraries.

Request

GET /itineraries

Parameters

Name Required Description
ids Yes Up to 75, comma-delimited itinerary keys. Extraneous keys are ignored.
include No Comma-delimited list of related resources to include. By default, this endpoint does not return any related resources.
  • score
  • amenity
  • speed
  • aircraft_summary
  • seat_summary
  • layout_summary
  • entertainment_summary
  • wifi_summary
  • power_summary
  • fresh_food_summary
  • legs.score
  • legs.amenity
  • legs.speed
  • legs.segments.seat
  • legs.segments.entertainment
  • legs.segments.power
  • legs.segments.wifi
  • legs.segments.aircraft
  • legs.segments.layout
  • legs.segments.fresh_food

Response

Resource Attributes

itinerary

Name Value set Description
id e.g. BOS-JFK-UA-123-20990224-ECON~JFK-ORD-UA-123-20990224-ECON Itinerary key

See below for related leg, segment and individual Flight Amenities for data elements:


Examples

#1 Itinerary scores

Request

curl \
  -H "Auth: YOUR_API_KEY" \
  -H "Accept: application/vnd.api.v3+json" \
  -G \
  -d ids=DEN-NRT-UA-139-20170206-ECON.NRT-DEN-UA-138-20170208-ECON \
  -d include=score \
  YOUR_HOST/itineraries

Response

{
  "data": [
    {
      "id": "DEN-NRT-UA-139-20170206-ECON.NRT-DEN-UA-138-20170208-ECON",
      "links": {
        "score": 8.8
      }
    }
  ],
  "linked": {
    "scores": [
      {
        "id": 8.8,
        "word_score": "Excellent"
      }
    ]
  }
}

#2 Fetching seat and wifi data and summaries

Request

curl \
  -H "Auth: YOUR_API_KEY" \
  -H "Accept: application/vnd.api.v3+json" \
  -G \
  -d ids=DEN-NRT-UA-139-20170206-ECON.NRT-DEN-UA-138-20170208-ECON \
  -d include=seat_summary,wifi_summary,legs.segments.seat,legs.segments.wifi \
  YOUR_HOST/itineraries

Response

{
  "data": [
    {
      "id": "DEN-NRT-UA-139-20170206-ECON.NRT-DEN-UA-138-20170208-ECON",
      "links": {
        "seat_summary": "2|2",
        "wifi_summary": "136|136",
        "legs": [
          "DEN-NRT-UA-139-20170206-ECON",
          "NRT-DEN-UA-138-20170208-ECON"
        ]
      }
    }
  ],
  "linked": {
    "seat_summaries": [
      {
        "id": "2|2",
        "display_text": "Above average legroom (32\")"
      }
    ],
    "wifi_summaries": [
      {
        "id": "136|136",
        "exists": "yes",
        "display_text": "Chance of better Wi-Fi (fee)"
      }
    ],
    "seats": [
      {
        "id": 2,
        "display_text": "Above average legroom (32\")",
        "quality": "better",
        "legroom": "more",
        "pitch": "32",
        "width": "standard",
        "flatness": "not flat",
        "type": "above average legroom",
        "updated_at": "2016-07-01T06:09:52Z"
      }
    ],
    "wifis": [
      {
        "id": 136,
        "display_text": "Chance of better Wi-Fi (fee)",
        "quality": "standard",
        "performance": "better",
        "cost": "paid",
        "exists": "yes",
        "chance": "very good",
        "coverage": "full",
        "connectivity_type": "wifi",
        "type": "chance",
        "updated_at": "2016-05-31T10:03:55Z"
      }
    ],
    "segments": [
      {
        "id": "DEN-NRT-UA-139-20170206-ECON",
        "links": {
          "seat": 2,
          "wifi": 136
        }
      },
      {
        "id": "NRT-DEN-UA-138-20170208-ECON",
        "links": {
          "seat": 2,
          "wifi": 136
        }
      }
    ],
    "legs": [
      {
        "id": "DEN-NRT-UA-139-20170206-ECON",
        "links": {
          "segments": [
            "DEN-NRT-UA-139-20170206-ECON"
          ]
        }
      },
      {
        "id": "NRT-DEN-UA-138-20170208-ECON",
        "links": {
          "segments": [
            "NRT-DEN-UA-138-20170208-ECON"
          ]
        }
      }
    ]
  }
}
Have more questions? Submit a request