Flight Links API
Guidance and examples for accessing the Flight Links API
The Flight Links API allows you to submit flight data and matches with Expedia inventory and returns links to XAP Details API and/or Expedia website details page.
Endpoint
Method | Endpoint |
---|---|
POST | https://apim.expedia.com/flights/links |
Required Headers
Key: | Expedia API key |
Authorization: | Expedia API Authorization String |
Content-Type: | application/json |
Accept: | application/vnd.exp-flight.v3+json |
Partner-Transaction-Id: | Partner TransactionID String |
Next Steps
- Deeplink to Expedia website details page and access to booking page.
- Query the Flight Details API for more info on flight and booking API query.
Example of Flight Links Request
Flight Links URL
https://apim.expedia.com/flights/links
Flight Links Body
{
"Flights": [{
"FlightId": "abc",
"SplitTicket": false,
"Segments": [{
"FareType": "PUBLISHED",
"Provider": "Amadeus",
"LowCost": false,
"Legs": [{
"DepartureAirport": {
"Code": "COK"
},
"ArrivalAirport": {
"Code": "DOH"
},
"DepartureDateTime": "2021-06-06T03:35:00+05:30",
"ArrivalDateTime": "2021-06-06T05:35:00+03:00",
"FlightNumber": "517",
"MarketingAirlineCode": "QR",
"BookingCode": "W",
"CabinClass": "ECONOMY"
},
{
"DepartureAirport": {
"Code": "DOH"
},
"ArrivalAirport": {
"Code": "ORD"
},
"DepartureDateTime": "2021-06-06T08:50:00+03:00",
"ArrivalDateTime": "2021-06-06T14:55:00-05:00",
"FlightNumber": "725",
"MarketingAirlineCode": "QR",
"BookingCode": "W",
"CabinClass": "ECONOMY"
}
]
}],
"TotalPrice": {
"Value": "2576.68",
"Currency": "USD"
}
},
{
"FlightId": "def",
"SplitTicket": false,
"Segments": [{
"FareType": "PUBLISHED",
"Provider": "Sabre",
"LowCost": false,
"Legs": [{
"DepartureAirport": {
"Code": "COK"
},
"ArrivalAirport": {
"Code": "AUH"
},
"DepartureDateTime": "2021-06-06T21:25:00+05:30",
"ArrivalDateTime": "2021-06-06T23:55:00+04:00",
"FlightNumber": "6528",
"MarketingAirlineCode": "9W",
"BookingCode": "H",
"CabinClass": "ECONOMY"
},
{
"DepartureAirport": {
"Code": "AUH"
},
"ArrivalAirport": {
"Code": "ORD"
},
"DepartureDateTime": "2021-06-07T03:20:00+04:00",
"ArrivalDateTime": "2021-06-07T08:55:00-05:00",
"FlightNumber": "6405",
"MarketingAirlineCode": "9W",
"BookingCode": "H",
"CabinClass": "ECONOMY"
}
]
}],
"TotalPrice": {
"Value": "3266.52",
"Currency": "USD"
}
}
],
"Passengers": {
"Adult": "1",
"Senior": "1",
"ChildrenAges": "2,14"
},
"Links": [
"WD",
"AD"
]
}
Flight Links Response
{
"Links": [{
"FlightId": "abc",
"WebDetails": {
"Method": "GET",
"Href": "https://www.expedia.com/go/udp?CCheck=1&piid=~null.S~AQoCCAASCAjUBBABGI8KIAEgDCAHIA0oAg~AQpCCh8I0aQBEgM1MTcYwlMgwzsozbGLATDbs4sBOFdAAFgBCh8I0aQBEgM3MjUYwzsgrhwonrWLATDru4sBOFdAAFgBEgYIARABGAEYBCIECAEQASIECAMQASIECAIQAigCMAI&DepartureTLA=L1:COK&ArrivalTLA=L1:ORD&DepartureDate=L1:2021-06-06&ArrivalDate=L1:2021-06-06&NumAdult=1&NumSenior=1&NumChild=2&ChildrenAges=2|14&Sort=10&TripType=OneWay&ProductType=air&eapid=0-1&ServiceVersion=V5&MessageGuid=a79898d0-3bc2-11e8-a98c-4ccc6a3c3f78&langid=1033"
},
"ApiDetails": {
"Accept": "application/vnd.exp-flight.v3+json",
"Method": "GET",
"Href": "http://apim.expedia.com/flights/details/~null.S~AQoCCAASCAjUBBABGI8KIAEgDCAHIA0oAg~AQpCCh8I0aQBEgM1MTcYwlMgwzsozbGLATDbs4sBOFdAAFgBCh8I0aQBEgM3MjUYwzsgrhwonrWLATDru4sBOFdAAFgBEgYIARABGAEYBCIECAEQASIECAMQASIECAIQAigCMAI?price=2576.68&childrenAges=2%2C14"
}
},
{
"FlightId": "def",
"WebDetails": {
"Method": "GET",
"Href": "https://www.expedia.com/go/udp?CCheck=1&piid=~null.S~AQoCCAASCAjUBBABGI8KIAEgDCAHIA0oAg~AQpECiAIua4BEgQ2NTI4GMJTIIA9KPu5iwEw67uLAThIQABYAQogCLmuARIENjQwNRiAPSCuHCi4vYsBMKPEiwE4SEAAWAESBggBEAEYARgEIgQIARABIgQIAxABIgQIAhACKAIwAg&DepartureTLA=L1:COK&ArrivalTLA=L1:ORD&DepartureDate=L1:2021-06-06&ArrivalDate=L1:2021-06-07&NumAdult=1&NumSenior=1&NumChild=2&ChildrenAges=2|14&Sort=10&TripType=OneWay&ProductType=air&eapid=0-1&ServiceVersion=V5&MessageGuid=a79898d0-3bc2-11e8-a98c-4ccc6a3c3f78&langid=1033"
},
"ApiDetails": {
"Accept": "application/vnd.exp-flight.v3+json",
"Method": "GET",
"Href": "http://apim.expedia.com/flights/details/~null.S~AQoCCAASCAjUBBABGI8KIAEgDCAHIA0oAg~AQpECiAIua4BEgQ2NTI4GMJTIIA9KPu5iwEw67uLAThIQABYAQogCLmuARIENjQwNRiAPSCuHCi4vYsBMKPEiwE4SEAAWAESBggBEAEYARgEIgQIARABIgQIAxABIgQIAhACKAIwAg?price=3266.52&childrenAges=2%2C14"
}
}
]
}
Error Codes
API details
Here, you can explore the endpoint definitions for this API, then go to the API Explorer to try out all the XAP endpoints, download OpenAPI specs, or download our Postman collections. Testing with one or all of these options will give you an understanding of how the examples and schema definitions compare to the actual output.