OTA 酒店通知计数

请求数

语法

OTA_HotelInvCountNotifRQ 消息使用以下语法:

<?xml version="1.0" encoding="UTF-8"?>
<OTA_HotelInvCountNotifRQ xmlns="http://www.opentravel.org/OTA/2003/05"
                          EchoToken="message_ID"
                          TimeStamp="timestamp"
                          Version="3.0">
  <POS>
    <Source>
      <RequestorID ID="partner_key"/>
    </Source>
  </POS>
  <Inventories HotelCode="HotelID">
    <Inventory>
      <StatusApplicationControl Start="YYYY-MM-DD"
                                End="YYYY-MM-DD"
                                Mon="boolean_value"
                                Tue="boolean_value"
                                Weds="boolean_value"
                                Thur="boolean_value"
                                Fri="boolean_value"
                                Sat="boolean_value"
                                Sun="boolean_value"
                                InvTypeCode="RoomID"/>
      <InvCounts>
        <InvCount Count="integer" CountType="2"/>
      </InvCounts>
    </Inventory>
  </Inventories>
</OTA_HotelInvCountNotifRQ>

元素和属性

OTA_HotelInvCountNotifRQ 消息包含以下元素和属性:

Element / @Attribute 出现次数 类型 说明
OTA_HotelInvCountNotifRQ 1 Complex element 用于定义房价供应情况的消息的根元素。
OTA_HotelInvCountNotifRQ / @xmlns 0..1 string (URI) XML 命名空间。
OTA_HotelInvCountNotifRQ / @EchoToken 1 string 此请求消息的唯一标识符。此值在响应消息中返回。允许使用的字符包括 a-z、A-Z、0-9、_(下划线)和 -(短划线)。
OTA_HotelInvCountNotifRQ / @TimeStamp 1 DateTime 此消息的创建日期和时间。
OTA_HotelInvCountNotifRQ / @Version 1 decimal OpenTravel 消息版本。
OTA_HotelInvCountNotifRQ / POS 0..1 POS 用于指定此消息的合作伙伴帐号的容器(通常在后端为多个合作伙伴帐号提供价格 Feed 时使用)。
OTA_HotelInvCountNotifRQ / POS/ Source 1 Source 必需(如果存在 <POS>)。<RequestorID> 的容器。
OTA_HotelInvCountNotifRQ / POS / RequestorID 1 RequestorID 必需(如果存在 <POS>)。定义合作伙伴帐号。
OTA_HotelInvCountNotifRQ / POS / RequestorID / @ID 1 string 此消息的合作伙伴帐号。此字符串值是 Hotel Center “帐号设置”页面上列出的合作伙伴键值。

注意:如果您有为多个帐号提供 Feed 的后端,则此值需要与交易(房源数据)消息的 partner 属性值和同一帐号的 <OTA_HotelRateAmountNotifRQ> 消息的 <RequestorID> 元素中的 ID 属性值相匹配。

OTA_HotelInvCountNotifRQ / Inventories 1 Inventories 包含一个或多个 <Inventory> 元素的容器。
OTA_HotelInvCountNotifRQ / Inventories / @HotelCode 1 string 属性的唯一标识符。此值必须与使用 <id>(在酒店列表 Feed 的 <listing> 元素中)指定的酒店 ID 一致。酒店 ID 也会在 Hotel Center 中列出。
OTA_HotelInvCountNotifRQ / Inventories / Inventory 1..n Inventory 定义单个媒体资源在不同时间范围内的空房数。
OTA_HotelInvCountNotifRQ / Inventories / Inventory / StatusApplicationControl 1 StatusApplicationControl 定义日期范围以及客房类型的标识符 (InvTypeCode)。
OTA_HotelInvCountNotifRQ / Inventories / Inventory / StatusApplicationControl / @Start 1 Date 日期范围的开始日期(基于媒体资源的时区)。
OTA_HotelInvCountNotifRQ / Inventories / Inventory / StatusApplicationControl / @End 1 Date 日期范围的结束日期(基于媒体资源的时区)。必须等于或大于 start 值。 如果 startend 相等,则更新应用于该日期。
OTA_HotelInvCountNotifRQ / Inventories / Inventory / StatusApplicationControl / @Mon 0..1 boolean 设置为 true1 可明确包含星期一。

如果设置为 true,系统会排除一周中未明确设置为 true 的其他日子(实际上,系统会从 StartEnd 中的日期中滤除这些日子)。

OTA_HotelInvCountNotifRQ / Inventories / Inventory / StatusApplicationControl / @Tue 0..1 boolean 设置为 true1 可明确包含星期二。

如果设置为 true,系统会排除一周中未明确设置为 true 的其他日子(实际上,系统会从 StartEnd 中的日期中滤除这些日子)。

OTA_HotelInvCountNotifRQ / Inventories / Inventory / StatusApplicationControl / @Weds 0..1 boolean 设置为 true1 可明确包含星期三。

如果设置为 true,系统会排除一周中未明确设置为 true 的其他日子(实际上,系统会从 StartEnd 中的日期中滤除这些日子)。

OTA_HotelInvCountNotifRQ / Inventories / Inventory / StatusApplicationControl / @Thur 0..1 boolean 设置为 true1 可明确包含星期四。

如果设置为 true,系统会排除一周中未明确设置为 true 的其他日子(实际上,系统会从 StartEnd 中的日期中滤除这些日子)。

OTA_HotelInvCountNotifRQ / Inventories / Inventory / StatusApplicationControl / @Fri 0..1 boolean 设置为 true1 可明确包含星期五。

如果设置为 true,系统会排除一周中未明确设置为 true 的其他日子(实际上,系统会从 StartEnd 中的日期中滤除这些日子)。

OTA_HotelInvCountNotifRQ / Inventories / Inventory / StatusApplicationControl / @Sat 0..1 boolean 设置为 true1 可明确包含星期六。

如果设置为 true,系统会排除一周中未明确设置为 true 的其他日子(实际上,系统会从 StartEnd 中的日期中滤除这些日子)。

OTA_HotelInvCountNotifRQ / Inventories / Inventory / StatusApplicationControl / @Sun 0..1 boolean 设置为 true1 可明确包含星期日。

如果设置为 true,系统会排除一周中未明确设置为 true 的其他日子(实际上,系统会从 StartEnd 中的日期中滤除这些日子)。

OTA_HotelInvCountNotifRQ / Inventories / Inventory / StatusApplicationControl / @InvTypeCode 1 string 广告资源(房间类型)的唯一标识符。此值映射到交易(房源数据)消息中的 <RoomID>
OTA_HotelInvCountNotifRQ / Inventories / Inventory / InvCounts 1 InvCounts 用于定义单个商品目录数量的容器。
OTA_HotelInvCountNotifRQ / Inventories / Inventory / InvCounts / InvCount 1 InvCount 定义可预订的空房数量。
OTA_HotelInvCountNotifRQ / Inventories / Inventory / InvCounts / InvCount / @Count 1 integer 可按相应客房类型预订的空房数量。 值为零表示客房类型已售罄。负值被视为零。
OTA_HotelInvCountNotifRQ / Inventories / Inventory / InvCounts / InvCount / @CountType 1 enum

指定的商品目录数量的类型。有效值为:

  • 2:确定可用性。

示例

剩余库存

在指定日期设置 5rooms left forRoomID_1`。

<OTA_HotelInvCountNotifRQ xmlns="http://www.opentravel.org/OTA/2003/05"
                          EchoToken="12345678"
                          TimeStamp="2023-07-13T20:50:37-05:00"
                          Version="3.0">
  <Inventories HotelCode="Property_1">
    <Inventory>
      <StatusApplicationControl Start="2023-07-18"
                                End="2023-07-23"
                                InvTypeCode="RoomID_1"/>
      <InvCounts>
        <InvCount Count="5" CountType="2"/>
      </InvCounts>
    </Inventory>
  </Inventories>
</OTA_HotelInvCountNotifRQ>

广告资源已售罄

RoomID_1 在指定日期售罄。

<OTA_HotelInvCountNotifRQ xmlns="http://www.opentravel.org/OTA/2003/05"
                          EchoToken="12345678"
                          TimeStamp="2023-07-13T20:50:37-05:00"
                          Version="3.0">
  <Inventories HotelCode="Property_1">
    <Inventory>
      <StatusApplicationControl Start="2023-07-18"
                                End="2023-07-23"
                                InvTypeCode="RoomID_1"/>
      <InvCounts>
        <InvCount Count="0" CountType="2"/>
      </InvCounts>
    </Inventory>
  </Inventories>
</OTA_HotelInvCountNotifRQ>

响应

语法

OTA_HotelInvCountNotifRS 消息使用以下语法:

<?xml version="1.0" encoding="UTF-8"?>
<OTA_HotelInvCountNotifRS xmlns="http://www.opentravel.org/OTA/2003/05"
                          TimeStamp="timestamp"
                          EchoToken="echo_token"
                          Version="3.0">
  <!-- Either Success or Errors will be populated. -->
  <Success/>
  <Errors>
    <Error Type="12" Status="NotProcessed" ShortText="issue_code">issue_description</Error>
  </Errors>
</OTA_HotelInvCountNotifRS>

元素和属性

OTA_HotelInvCountNotifRS 消息包含以下元素和属性:

Element / @Attribute 出现次数 类型 说明
1 Complex element 对可用性消息的响应的根元素。
OTA_HotelInvCountNotifRS / @TimeStamp 1 DateTime 此消息的创建日期和时间。
OTA_HotelInvCountNotifRS / @EchoToken 1 string 关联的 OTA_HotelInvCountNotifRQ 消息中的唯一标识符。
OTA_HotelInvCountNotifRS / Success 0..1 Success 表示 OTA_HotelInvCountNotifRQ 消息已成功处理。

每条消息都有 <Success><Errors>

OTA_HotelInvCountNotifRS / Errors 0..1 Errors 处理 OTA_HotelInvCountNotifRQ 消息时遇到的一个或多个问题的容器。

每条消息都有 <Success><Errors>

OTA_HotelInvCountNotifRS / Errors / Error 1..n Error 处理 OTA_HotelInvCountNotifRQ 消息时遇到的错误说明。如需详细了解这些错误,请参阅 Feed 状态错误消息
OTA_HotelInvCountNotifRS / Errors / Error / @Type 1 integer 与错误关联的 OpenTravel Alliance EWT(错误警告类型)。仅使用 12 (Processing exception) 值。
OTA_HotelInvCountNotifRS / Errors / Error / @Code 1 integer 与错误关联的 OpenTravel Alliance ERR(错误代码)。 仅使用 450 (Unable to process) 值。
OTA_HotelInvCountNotifRS / Errors / Error / @Code 1 enum 原始请求的状态。仅使用 NotProcessed 值。
OTA_HotelInvCountNotifRS / Errors / Error / @ShortText 1 string 问题的 Google 标识符。如需详细了解这些错误,请参阅 Feed 状态错误消息

示例

成功

以下是对成功处理的 OTA_HotelInvCountNotifRQ 消息的响应。

<?xml version="1.0" encoding="UTF-8"?>
<OTA_HotelInvCountNotifRS xmlns="http://www.opentravel.org/OTA/2003/05"
                          TimeStamp="2023-07-23T20:50:37-05:00"
                          Version="3.0">
  <Success/>
</OTA_HotelInvCountNotifRS>

错误数

以下是对因错误而未处理的 OTA_HotelInvCountNotifRQ 消息的响应。

<?xml version="1.0" encoding="UTF-8"?>
<OTA_HotelInvCountNotifRS xmlns="http://www.opentravel.org/OTA/2003/05"
                          TimeStamp="2023-07-23T20:50:37-05:00"
                          Version="3.0">
  <Errors>
    <Error Type="12" Code="450" Status="NotProcessed" ShortText="8001">Example</Error>
  </Errors>
</OTA_HotelInvCountNotifRS>