低价端点返回缺少缺少operation.carrierCode的JSON

时间:2019-08-05 17:00:43

标签: amadeus

低票价端点最近开始返回JSON,并且某些航班段缺少用于operation.carrierCode的键值对,例如:

"operating": {
                  "number": “5898"

这是昨天我搜索的第一个结果(数据[0] .offerItems [0] .services [0] .segments [1] .flightSegment)的第二个航班段。

https://test.api.amadeus.com/v1/shopping/flight-offers?origin=LON&destination=PAE&departureDate=2019-10-29&returnDate=2019-11-13&adults=1&nonStop=false&max=50

在上下文中:

{ "data": [ { "type": "flight-offer", "id": "1564934270644-1482530186", "offerItems": [ { "services": [ { "segments": [ { "flightSegment": { "departure": { "iataCode": "LHR", "terminal": "2", "at": "2019-10-29T09:20:00Z" }, "arrival": { "iataCode": "SFO", "terminal": "I", "at": "2019-10-29T13:30:00-07:00" }, "carrierCode": "SN", "number": "9101", "aircraft": { "code": "777" }, "operating": { "carrierCode": "UA", "number": "9101" }, "duration": "0DT11H10M" }, "pricingDetailPerAdult": { "travelClass": "ECONOMY", "fareClass": "K", "availability": 4, "fareBasis": "KLP5ULGT" } }, { "flightSegment": { "departure": { "iataCode": "SFO", "terminal": "3", "at": "2019-10-29T16:15:00-07:00" }, "arrival": { "iataCode": "PAE", "at": "2019-10-29T18:32:00-07:00" }, "carrierCode": "UA", "number": "5898", "aircraft": { "code": "E7W" }, "operating": { "number": “5898” }, "duration": "0DT2H17M" }, "pricingDetailPerAdult": { "travelClass": "ECONOMY", "fareClass": "K", "availability": 9, "fareBasis": "KLP5ULGT" } } ] …

这是一个已知的错误吗?编写解决方法非常容易,但是令我惊讶的是,由于该数据已经正常运行了几个月,因此缺少这些数据。

1 个答案:

答案 0 :(得分:0)

即使在加密模式下,这也是运营商的常见问题 FLT / DATE RTNG CKIN TM DEP ARR TM EQP ML DURA DIST

UA5898 Y 29OCT SFOPAE 3 415P 632P E7W G 2:17 711
                 由SKYWEST DBA UNITED EXPRESS运营的SFOPAE

>

在使用企业API进行购物时,您可以使用相同的文字描述按航班号恢复的时间表数据。 也不知道要在api响应中获取任何参数。