Amadeus API 不显示可用的直飞航班

问题描述 投票:0回答:1

我正在使用 Postman(以及 python)测试 Amadeus API。当我设置特定日期 (2024-03-02) 时,仅从 BUD(布达佩斯)飞往 LHR(伦敦希思罗机场)的直飞航班显示 0 个结果。 我查了一下天巡,当然那天有 3 个英国航空直飞航班。

有人可以解释一下我做错了什么吗?

api postman amadeus skyscanner
1个回答
0
投票

您的问题似乎是 nonStop=true 查询参数由于某种原因限制了您的结果。

如果我使用 nonStop=false 执行相同的搜索,那么我会得到结果:

GET https://test.api.amadeus.com/v2/shopping/flight-offers?originLocationCode=BUD&destinationLocationCode=LHR&departureDate=2024-03-02&adults=1&nonStop=false&max=5 HTTP/1.1

{
  "meta": {
    "count": 5,
    "links": {
      "self": "https://test.api.amadeus.com/v2/shopping/flight-offers?originLocationCode=BUD&destinationLocationCode=LHR&departureDate=2024-03-02&adults=1&nonStop=false&max=5"
    }
  },
  "data": [
     ...
  ]
}
© www.soinside.com 2019 - 2024. All rights reserved.