This is an auto-generated translation

选购测试请求

为帮助测试您的集成能否处理潜在的选购错误状态,针对所有 Rapid 选购 API 方法提供了多个测试请求。

测试选购重要说明

  • 要针对 Rapid 选购 API 方法发送测试请求,请在预订申请中包含名为 Test 的其他 HTTP 标头,并使用下表中的相应值。
  • 发送测试标头失败或发送无效的测试标头将导致实时处理选购。
  • 使用测试标头将使静态“预设”消息作为响应返回。因此,返回的房价、内容等可能与正在测试的住宿无关。

选购

测试标头值HTTP 代码和响应状态
standard200 - Standard responseavailable
no_availability200 - Standard responsesold_out
unknown_internal_error500 - Internal error不适用
service_unavailable503 - Service unavailable error不适用

价格检查

测试标头值HTTP 代码和响应状态
available200 - Standard responseavailable
price_changed200 - Standard responseprice_changed
sold_out200 - Standard responsesold_out
unknown_internal_error500 - Internal errorNA
service_unavailable503 - Service unavailable errorNA

押金政策

测试标头值HTTP 代码和响应
all200 - Standard response with all options
night200 - Standard night-based deposit response
amount200 - Standard amount-based deposit response
percent200 - Standard percentage-based deposit response
remainder200 - Standard remainder-based deposit response
unknown_internal_error500 - Internal error
service_unavailable503 - Service unavailable error

关于 HTTP 错误代码的更多信息,请参见常见错误响应

您觉得这个页面有用吗?
我们该如何改进这些内容?
感谢您帮助我们改进!