首页 > 解决方案 > Amadeus Flight 提供不同的价格

问题描述

我们正在使用航班优惠搜索 api 并准备转移到 prod。但是,当我们使用经济舱搜索航班时,价格甚至与“amadeus.net”搜索引擎结果或 TK(土耳其航空公司)网站价格相差甚远。如果我们使用 BUSINESS 类作为参数,则 api 结果更接近实际价格。我们如何解决这个问题?

示例查询为:(IST - CGN 5 月 25 日 ECONOMY 和 TK Opearated 航班起飞时间 16:05)

/v2/shopping/flight-offers?originLocationCode=IST&destinationLocationCode=CGN&departureDate=2021-05-25&adults=1&travelClass=ECONOMY&includedAirlineCodes=TK&nonStop=true&max=250

api 结果为:206.55 欧元

TK 网站:121 欧元

Amadeus.net €103

详细的 API 结果:

{
  "meta": {
    "count": 2,
    "links": {
      "self": "https://test.api.amadeus.com/v2/shopping/flight-offers?originLocationCode=IST&destinationLocationCode=CGN&departureDate=2021-05-25&adults=1&travelClass=ECONOMY&includedAirlineCodes=TK&nonStop=true&max=250"
    }
  },
  "data": [
    {
      "type": "flight-offer",
      "id": "2",
      "source": "GDS",
      "instantTicketingRequired": false,
      "nonHomogeneous": false,
      "oneWay": false,
      "lastTicketingDate": "2021-05-25",
      "numberOfBookableSeats": 9,
      "itineraries": [
        {
          "duration": "PT3H20M",
          "segments": [
            {
              "departure": {
                "iataCode": "IST",
                "at": "2021-05-25T16:05:00"
              },
              "arrival": {
                "iataCode": "CGN",
                "terminal": "2",
                "at": "2021-05-25T18:25:00"
              },
              "carrierCode": "TK",
              "number": "1675",
              "aircraft": {
                "code": "321"
              },
              "operating": {
                "carrierCode": "TK"
              },
              "duration": "PT3H20M",
              "id": "2",
              "numberOfStops": 0,
              "blacklistedInEU": false
            }
          ]
        }
      ],
      "price": {
        "currency": "EUR",
        "total": "206.55",
        "base": "134.00",
        "fees": [
          {
            "amount": "0.00",
            "type": "SUPPLIER"
          },
          {
            "amount": "0.00",
            "type": "TICKETING"
          }
        ],
        "grandTotal": "206.55"
      },
      "pricingOptions": {
        "fareType": [
          "PUBLISHED"
        ],
        "includedCheckedBagsOnly": true
      },
      "validatingAirlineCodes": [
        "TK"
      ],
      "travelerPricings": [
        {
          "travelerId": "1",
          "fareOption": "STANDARD",
          "travelerType": "ADULT",
          "price": {
            "currency": "EUR",
            "total": "206.55",
            "base": "134.00"
          },
          "fareDetailsBySegment": [
            {
              "segmentId": "2",
              "cabin": "ECONOMY",
              "fareBasis": "QT2PXOW",
              "class": "Q",
              "includedCheckedBags": {
                "weight": 30,
                "weightUnit": "KG"
              }
            }
          ]
        }
      ]
    }
  ],
  "dictionaries": {
    "locations": {
      "SAW": {
        "cityCode": "IST",
        "countryCode": "TR"
      },
      "CGN": {
        "cityCode": "CGN",
        "countryCode": "DE"
      },
      "IST": {
        "cityCode": "IST",
        "countryCode": "TR"
      }
    },
    "aircraft": {
      "321": "AIRBUS A321",
      "738": "BOEING 737-800"
    },
    "currencies": {
      "EUR": "EURO"
    },
    "carriers": {
      "TK": "TURKISH AIRLINES"
    }
  }
}

提前致谢

标签: amadeus

解决方案


您看到不同价格的原因有两个:

  • 自助服务 API 返回来自 GDS 的已发布机票,而不是任何协商的机票。这意味着 API 返回的航班可能比您在 OTA 或航空公司网站上找到的更贵。
  • 在您使用的测试环境中,您可以访问可能与实时价格不同的缓存航班数据。

推荐阅读