在预订前重新校验所选酒店房型报价,以确认可订性、价格变化和预订资格。
接口
| 方法 | 路径 | 认证 |
|---|---|---|
POST | /v1/hotels/check/:gdsprovider | 需要 API key |
| Header | 说明 |
|---|---|
Authorization | Bearer <secret_key>. The secret is shown only once when the credential is created. |
X-Travelandz-Id | <public_key>:<profile_code>. The profile_code is the dp_-prefixed Developer Profile code shown in your dashboard. This binds the request to a profile and credential. |
Content-Type | Use application/json for requests with a body. |
请求参数结构
gdsprovider请求体
Send the provider offer/rate payload returned by hotel offers.
请求体结构
offersoffers[]gdsprovideroffers[]hotelCodeoffers[]rateKeyoffers[]adultsoffers[]childrenoffers[]nameoffers[]boardoffers[]totalPriceoffers[]originalPriceoffers[]currencyoffers[]originalCurrencyoffers[]supplementsoffers[]supplements[]descriptionoffers[]supplements[]priceoffers[]supplements[]currencyoffers[]cancellationPoliciesoffers[]cancellationPolicies[]amountoffers[]cancellationPolicies[]fromDateoffers[]isRefundablecheckIncheckOut成功响应
返回 the revalidated rate, price and booking eligibility.
响应体结构
availableratesConditionsratesConditions[]rateKeyratesConditions[]conditionsratesConditions[]conditions[]pricesChangedpricesChanged[]rateKeypricesChanged[]newPricepricesChanged[]newPrice[]ratesUnavailableratesUnavailable[]rateKeyliveModeTrue when the request is served by the live Travelandz environment. This value comes from Travelandz, not the provider payload.
示例
bash
curl -X POST https://api.sandbox.travelandz.com/v1/hotels/check/:gdsprovider \
-H "Authorization: Bearer $TRAVELANDZ_SECRET_KEY" \
-H "X-Travelandz-Id: $TRAVELANDZ_PUBLIC_KEY:$TRAVELANDZ_PROFILE_CODE" \
-H "Content-Type: application/json" \
-d '<request_body_json>'