OTA_HotelInvCountRQ / OTA_HotelInvCountRS

The OTA_HotelInvCountRQ messages are used to read availaiblities in the Hotel-Spider system.

Endpoints

Example request and response

Requesting availaiblities for a specific room :

OTA_HotelAvailNotifRQ request
<OTA_HotelInvCountRQ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.opentravel.org/OTA/2003/05" xsi:schemaLocation="http://www.opentravel.org/OTA/2003/05 OTA_HotelInvCountRQ.xsd" TimeStamp="2012-10-05T14:20:50" Target="Test" Version="1.005">
  <POS>
    <Source>
      <RequestorID Type="5" ID="USERNAME" MessagePassword="PASSWORD"></RequestorID>
    </Source>
  </POS>
  <HotelInvCountRequests>
     <HotelInvCountRequest>
		<HotelRef HotelCode="HOTELCODE" />
		<DateRange Start="2017-04-01" End="2017-04-12" />
		<RoomTypeCandidates>
			<RoomTypeCandidate RoomID="ROOMID" />
		</RoomTypeCandidates>
	 </HotelInvCountRequest>
  </HotelInvCountRequests>
</OTA_HotelInvCountRQ>

Requesting availaiblities for all rooms configured in Hotel-Spider :

OTA_HotelAvailNotifRQ request
<OTA_HotelInvCountRQ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.opentravel.org/OTA/2003/05" xsi:schemaLocation="http://www.opentravel.org/OTA/2003/05 OTA_HotelInvCountRQ.xsd" TimeStamp="2012-10-05T14:20:50" Target="Test" Version="1.005">
  <POS>
    <Source>
      <RequestorID Type="5" ID="USERNAME" MessagePassword="PASSWORD"></RequestorID>
    </Source>
  </POS>
  <HotelInvCountRequests>
     <HotelInvCountRequest>
		<HotelRef HotelCode="HOTELCODE" />
		<DateRange Start="2017-04-01" End="2017-04-12" />
		<RoomTypeCandidates>
			<RoomTypeCandidate RoomID="ROOMID" />
		</RoomTypeCandidates>
	 </HotelInvCountRequest>
  </HotelInvCountRequests>
</OTA_HotelInvCountRQ>

Request structure

OTA_HotelInvCountRQ

Parent: None (Root element)

Mandatory: yes

Attributes:

NameMandatoryDescription
TimeStampYesThe format should respect the ISO 8601 2015-11-16T22:23:48+00:00
TargetYes

When sending updates to the staging environment "Test" must be used.

When sending updates to the production environment "Production" must be used.

VersionYesThe default value should be "1.000"

Child elements: POS (when using POS authentication. See Authentication methods for more information), AvailStatusMessages


HotelInvCountRequests

Parent: OTA_HotelInvCountRQ

Multiple : no

Mandatory: yes

Children: HotelInvCountRequest


HotelInvCountRequest

Parent: HotelInvCountRequests

Multiple : no

Mandatory: yes

Children : HotelRef, DateRange, RoomTypeCandidates


HotelRef

Parent: HotelInvCountRequest

Multiple : no

Mandatory: yes

Attributes:

NameMandatoryDescription
HotelCodeYes

Children : none


DateRange

Parent: HotelInvCountRequest

Multiple : no

Mandatory: yes

Attributes:

NameMandatoryDescription
StartYesThe format should respect the ISO 8601 2015-11-16
EndYes

The format should respect the ISO 8601 2015-11-17

The End date is inclusive meaning that it will also be updated.

Children : none


RoomTypeCandidates

Parent: HotelInvCountRequest

Multiple : no

Mandatory: no

Children: RoomTypeCandidate


RoomTypeCandidate

Parent: RoomTypeCandidate

Multiple : yes

Mandatory: yes

Attributes:

NameMandatoryDescription
RoomIDYesHotel-Spider room identifier

Children: none



Response structure


<?xml version="1.0" encoding="UTF-8"?>
<OTA_HotelInvCountRS xmlns="http://www.opentravel.org/OTA/2003/05" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.opentravel.org/OTA/2003/05 OTA_HotelInvCountRS.xsd" TimeStamp="2017-03-24T17:40:57+01:00" Target="Test" Version="1.0" CorrelationID="00Q58d54c191746e">
  <Inventories HotelCode="HOTELCODE">
    <Inventory>
      <StatusApplicationControl InvCodeApplication="InvCode" InvCode="ROOMID" Start="2017-04-01" End="2017-04-01">
      <InvCounts>
        <InvCount Count="0" CountType="14">
        <InvCount Count="5" CountType="13">
        <InvCount Count="0" CountType="1">
      </InvCounts>
    </Inventory>
    <Inventory>
      <StatusApplicationControl InvCodeApplication="InvCode" InvCode="ROOMID" Start="2017-04-02" End="2017-04-02">
      <InvCounts>
        <InvCount Count="8" CountType="14">
        <InvCount Count="0" CountType="13">
        <InvCount Count="10" CountType="1">
      </InvCounts>
    </Inventory>
    <Inventory>
      <StatusApplicationControl InvCodeApplication="InvCode" InvCode="ROOMID" Start="2017-04-03" End="2017-04-03">
      <InvCounts>
        <InvCount Count="5" CountType="14">
        <InvCount Count="1" CountType="13">
        <InvCount Count="6" CountType="1">
      </InvCounts>
    </Inventory>
    <Inventory>
      <StatusApplicationControl InvCodeApplication="InvCode" InvCode="ROOMID" Start="2017-04-04" End="2017-04-08">
      <InvCounts>
        <InvCount Count="45" CountType="14">
        <InvCount Count="0" CountType="13">
        <InvCount Count="60" CountType="1">
      </InvCounts>
    </Inventory>
    <Inventory>
      <StatusApplicationControl InvCodeApplication="InvCode" InvCode="00P55192452c758a" Start="2017-04-09" End="2017-04-10">
      <InvCounts>
        <InvCount Count="45" CountType="14">
        <InvCount Count="1" CountType="13">
        <InvCount Count="59" CountType="1">
      </InvCounts>
    </Inventory>
    <Inventory>
      <StatusApplicationControl InvCodeApplication="InvCode" InvCode="ROOMID" Start="2017-04-11" End="2017-04-11">
      <InvCounts>
        <InvCount Count="45" CountType="14">
        <InvCount Count="0" CountType="13">
        <InvCount Count="60" CountType="1">
      </InvCounts>
    </Inventory>
    <Inventory>
      <StatusApplicationControl InvCodeApplication="InvCode" InvCode="ROOMID" Start="2017-04-12" End="2017-04-12">
      <InvCounts>
        <InvCount Count="44" CountType="14">
        <InvCount Count="2" CountType="13">
        <InvCount Count="58" CountType="1">
      </InvCounts>
    </Inventory>
  </Inventories>
</OTA_HotelInvCountRS>


OTA_HotelInvCountRS

Parent: None (Root element)

Mandatory: yes

Attributes:

NameMandatoryDescription
TimeStampYesThe format will respect the ISO 8601 2015-11-16T22:23:48+00:00
TargetYesThe same value, used in the request, will be returned.
VersionYesThe value wil be "1.000"

Child elements: SuccessWarnings and Errors

Success

Parent: OTA Response root element

Mandatory: No

Attributes: None

Child elements: None


Warnings

Parent: OTA Response root element

Mandatory: No

Attributes: None

Child elements: None


Warning

Parent: Warnings

Mandatory: yes (If Warnings is provided)

Attributes:

NameMandatoryDescription
TypeYesOTA EWT type code

Code

YesOTA ERR error code
StatusYesPossible values: NotProcessed | Incomplete | Complete | Unknown
ShortTextYesTextual explanation of the error.

Child elements: None


Errors

Parent: OTA Response root element

Mandatory: No

Attributes: None

Child elements: Error


Error

Parent: Error

Mandatory: yes (If Errors is provided)

Attributes:

NameMandatoryDescription
TypeYesOTA EWT type code

Code

YesOTA ERR error code
StatusYesPossible values: NotProcessed | Incomplete | Complete | Unknown
ShortTextYesTextual explanation of the error.

Child elements: None


Inventories

Parent: OTA_HotelInvCountRS

Mandatory: yes

Multiple : no

Attributes:

NameMandatoryDescription
HotelCodeYes

Children: Inventory


Inventory

Parent: Inventories

Mandatory: yes

Multiple : yes

Attributes:

NameMandatoryDescription
StartYesThe format should respect the ISO 8601 2015-11-16
EndYes

The format should respect the ISO 8601 2015-11-17

The End date is inclusive meaning that it will also be updated.

InvCodeYes

The Hotel-Spider room ID

InvCodeApplicationyes

Always same value : InvCode

Children: InvCounts


InvCounts

Parent: Inventory

Mandatory: yes

Children: InvCount


InvCount

Parent: InvCounts

Mandatory: yes

Attributes:

NameMandatoryDescription
CountYesAvailability value
CountTypeYes

14 = VirtualAvailable, meaning availability with an applied derivation

13 = sold rooms

1 = stock

Children: NONE