跳转到主要内容
POST
Create Flight Search

请求规范

  • 方法与路径: POST /apis/v1/duffel/flights/offer-requests/create
  • 可用状态: enabled
  • 请求 URL 模板: https://api.aisa.one/apis/v1/duffel/flights/offer-requests/create
  • return_offers: query; 可选
  • supplier_timeout: query; 可选
  • view: query; 可选
完整 OpenAPI 定义 有效请求声明(包括认证和引用的 schema):

费用与请求规则

公开参考价格:每次成功请求 $0.02 USD。 账户适用价格可能不同;支持报价的接口可按实际请求获取报价。

授权

Authorization
string
header
必填

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

查询参数

return_offers
boolean
默认值:true

When set to true, the offer request resource returned will include all the offers returned by the airlines. If set to false, the offer request resource won't include any offers. To retrieve the associated offers later, use the List Offers endpoint, specifying the offer_request_id. You should use this option if you want to take advantage of the pagination, sorting and filtering that the List Offers endpoint provides.

示例:

false

supplier_timeout
integer
默认值:20000

The maximum amount of time in milliseconds to wait for each airline search to complete. This timeout applies to the response time of the call to the airline and includes some additional overhead added by Duffel. Value should be between 2 seconds and 60 seconds. Any values outside the range will be ignored and the default supplier_timeout will be used. If a value is set, the response will only include offers from airline searches that completed within the given time. If a value is not set, the response will only include offers from airline searches that completed within the default supplier_timeout value of 20 seconds. We recommend setting supplier_timeout lower than the timeout on the HTTP request you send to Duffel API as that will allow us to respond with the offers we received before your request times out with an empty response.

示例:

10000

view
enum<string>
默认值:offers

The format of the response. When set to offers (the default), the response includes a flat list of offers. When set to itineraries, offers are grouped into a hierarchical structure of slices, itineraries, and brands, with shared data (airlines, places, aircraft) in top-level reference maps.

可用选项:
offers,
itineraries

请求体

application/json
data
Body parameters · object
必填

响应

Successful response. The payload schema has not been reviewed yet.