Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: fixed table width

...

GP Travel HUB offers several alternatives of searching hotels by location:

Search by

Description

Search example

1

City code from

"GEO" context

supplier context (one supplier)

Allows to specify city code of certain supplier and get hotel offers only from

all suppliers that are available in this city. The city code should be taken from internal list of GP Travel HUB (so-called GEO-tree). To be able to run this case from your application you need to import that GEO-tree and use location codes from it.

this supplier. You can use this case if you know exact location codes from suppliers and would like to get offers only from some supplier.

Code Block
languagexml
<Criterion>
   <HotelRef HotelCityCode="
12175
LON" HotelCodeContext="
GEO
supplierCode"/>
</Criterion>

2

City code from

supplier

customer context

(one supplier)Allows to specify city code of certain supplier and get hotel offers only from this supplier. You can use this case if you know exact location codes from suppliers and would like to get offers only from some

If it is agreed to support customer context, GP Travel HUB can do search by customer-specific city codes. In this case your application can provide your own city code, GP Travel HUB will resolve it via GEO-tree and send requests to supplier.

Code Block
languagexml
<Criterion>
   <HotelRef HotelCityCode="LON" HotelCodeContext="ABC.supplierCode"/>
</Criterion>

3

City code from customer context

If it is agreed to support customer context, GP Travel HUB can do search by customer-specific city codes. In this case your application can provide your own city code, GP Travel HUB will resolve it via GEO-tree and send requests to all suppliers matching to this location
  • In this example "ABC" is a customer identifier. Ask about your specific identifier during integration.

3

GEO Search context

Allows to use City Code from supplier context, and then send search request to all suppliers. HotelCodeContext value like "<supplier>.GEO" is used for this.

Code Block
languagexml
<Criterion>
   <HotelRef HotelCityCode="LON" HotelCodeContext="
ABC
supplierCode.GEO"/>
</Criterion>
  • In this example "ABC" is a customer identifier. Ask about your specific identifier during integration.

4

Compound Search context

Allows to use City Code from supplier context, and then send search request to all suppliers; and vice versa, you can use City Code from GEO, and then send search request to particular supplier. Compound HotelCodeContext values like "<supplier>.GEO" or "GEO.<supplier>" are used for this.

When the HotelCodeContext is "<supplier>.GEO" then the HotelCityCode must be specified in supplier’s context, and then search request goes to all suppliers.

Code Block
languagexml
<Criterion>
   <HotelRef HotelCityCode="LON" HotelCodeContext="supplierCode.GEO"/>
</Criterion>

When the HotelCodeContext is "GEO.<supplier>" then the HotelCityCode must be specified in GEO context, and then search request goes only to the supplier specified. So, you can send request to the particular supplier, even if you don’t know supplier-specific City Code (as described in p.2 above).

Code Block
languagexml
<Criterion>
   <HotelRef HotelCityCode="12175" HotelCodeContext="GEO.supplierCode"/>
</Criterion>

5

Pagination search

Allows to receive results in parts. To start a pagination search AllowPartialAvail attribute should be true in Availability request. HUB returns available offers until MoreIndicator is true on Availability response. Pagination search can be interrupted after each Availability request. If part of received offers is enough no need to send other Availability requests despite the fact that the MoreIndicator is true on Availability response. Check diagram below for case when you should receive all available offers:

You can see pagination search example after diagram below.

...

Diagram 2.1.1.1. Pagination search process.

Pagination search can be interrupted after each Availability request. If part of received offers is enough no need to send other Availability requests despite the fact that the MoreIndicator is true on Availability response.

...

titlePagination search example

First Availability request with AllowPartialAvail="true":

...

languagexml

...

4

Pagination search

Allows to receive results in parts. To start a pagination search AllowPartialAvail attribute should be true in Availability request. HUB returns available offers until MoreIndicator is true on Availability response. Pagination search can be interrupted after each Availability request. If part of received offers is enough no need to send other Availability requests despite the fact that the MoreIndicator is true on Availability response. Check diagram below for case when you should receive all available offers:

You can see pagination search example after diagram below.

...

Diagram 2.1.1.1. Pagination search process.

Pagination search can be interrupted after each Availability request. If part of received offers is enough no need to send other Availability requests despite the fact that the MoreIndicator is true on Availability response.

Expand
titlePagination search example

First Availability request with AllowPartialAvail="true":

Code Block
languagexml
<OTA_HotelAvailRQ AllowPartialAvail="true" AvailRatesOnly="false" BestOnly="false" EchoToken="54039685" PrimaryLangID="en" RateRangeOnly="false" Version="2" xmlns="http://www.opentravel.org/OTA/2003/05">
   <POS>
      <Source>
         <RequestorID ID="cla" MessagePassword="pwa" Type="22"/>
         <BookingChannel Type="7"/>
      </Source>
   </POS>
   <AvailRequestSegments>
      <AvailRequestSegment>
         <StayDateRange End="2020-09-17" Start="2020-09-12"/>
         <RoomStayCandidates>
            <RoomStayCandidate Quantity="1" RPH="1">
               <GuestCounts>
                 <RequestorID ID="cla" MessagePassword<GuestCount AgeQualifyingCode="pwa10" TypeCount="222"/>
          <BookingChannel Type="7"/>     </GuestCounts>
        </Source>    </POS>RoomStayCandidate>
      <AvailRequestSegments>   </RoomStayCandidates>
   <AvailRequestSegment>      <HotelSearchCriteria>
   <StayDateRange End="2020-09-17" Start="2020-09-12"/>       <Criterion>
  <RoomStayCandidates>             <RoomStayCandidate<HotelRef QuantityHotelCityCode="115744" RPHHotelCodeContext="1GEO.innstant"/>
               <Profiles>
<GuestCounts>                  <ProfileInfo>
<GuestCount AgeQualifyingCode="10" Count="2"/>                </GuestCounts>   <UniqueID ID="1" Type="1"/>
       </RoomStayCandidate>          </RoomStayCandidates>    <Profile>
     <HotelSearchCriteria>             <Criterion>      <Customer>
         <HotelRef HotelCityCode="15744" HotelCodeContext="GEO.innstant"/>                <Profiles><PersonName>
                  <ProfileInfo>            <NamePrefix>Mr</NamePrefix>
         <UniqueID ID="1" Type="1"/>                   <GivenName>TourLeadName</GivenName>
  <Profile>                         <Customer>   <Surname>TourLeadSurname</Surname>
                        <PersonName>   </PersonName>
                           <NamePrefix>Mr</NamePrefix><Address>
                              <GivenName>TourLeadName<<AddressLine>TourLeadAddress</GivenName>AddressLine>
                              <Surname>TourLeadSurname</Surname><CityName>TourLeadCity</CityName>
                              <<PostalCode>TourLeadPostal</PersonName>PostalCode>
                           <Address>   <CountryName/>
                           <AddressLine>TourLeadAddress<</AddressLine>Address>
                           <CitizenCountryName Code="GB"/>
 <CityName>TourLeadCity</CityName>                       </Customer>
       <PostalCode>TourLeadPostal</PostalCode>              </Profile>
                  <CountryName</>ProfileInfo>
                </Profiles>
            </Address>Criterion>
         </HotelSearchCriteria>
      </AvailRequestSegment>
   </AvailRequestSegments>
</OTA_HotelAvailRQ>

First Availability response with MoreDataEchoToken and MoreIndicator="true":

Code Block
languagexml
<OTA_HotelAvailRS EchoToken="54039685"     <CitizenCountryName Code="GB"/Version="2.0" xmlns="http://www.opentravel.org/OTA/2003/05">
   <Success/>
   <RoomStays MoreDataEchoToken="200331165120.019795" MoreIndicator="true">
      <RoomStay RoomStayCandidateRPH="1">
      </Customer>   <RoomTypes>
            <RoomType RoomTypeCode="2608f7ec">
    </Profile>           <RoomDescription Name="Highsuite Double">
     </ProfileInfo>             <Text>Highsuite Double (highsuite double)</Profiles>
     Text>
      </Criterion>          </HotelSearchCriteria>RoomDescription>
       </AvailRequestSegment>    </AvailRequestSegments> </OTA_HotelAvailRQ>

First Availability response with MoreDataEchoToken and MoreIndicator="true":

Code Block
languagexml
<OTA_HotelAvailRS EchoToken="54039685" Version="2.0" xmlns="http://www.opentravel.org/OTA/2003/05">/RoomType>
         <Success/></RoomTypes>
         <RatePlans>
   <RoomStays MoreDataEchoToken="200331165120.019795" MoreIndicator="true">       <RoomStay<RatePlan RoomStayCandidateRPHRatePlanCode="1RO">
         <RoomTypes>      <RatePlanDescription>
           <RoomType RoomTypeCode="2608f7ec">      <Text>Room Only</Text>
        <RoomDescription Name="Highsuite Double">     </RatePlanDescription>
             <Text>Highsuite Double (highsuite double)</Text>
  <MealsIncluded Breakfast="false" Dinner="false" Lunch="false" MealPlanCodes="14"/>
            </RoomDescription>RatePlan>
         </RatePlans>
  </RoomType>       <RoomRates>
   </RoomTypes>         <RoomRate <RatePlans>
            <RatePlan AvailabilityStatus="AvailableForSale" BookingCode="12c7e2a9" FreeCancellationDeadline="2020-06-23T00:00:00+00:00" NonRefundable="false" NumberOfUnits="1" RoomTypeCode="2608f7ec" RatePlanCode="RO">
               <RatePlanDescription><Rates>...</Rates>
               <VendorInfo>
  <Text>Room Only</Text>                <<VendorCode>5683</RatePlanDescription>VendorCode>
               <MealsIncluded Breakfast="false" Dinner="false" Lunch="false" MealPlanCodes="14"/> <VendorName>hotelsdemo</VendorName>
               </RatePlan>VendorInfo>
         </RatePlans>      <CancelPenalties>...</CancelPenalties>
   <RoomRates>            <Total <RoomRate AvailabilityStatusAmountAfterTax="AvailableForSale910.00" BookingCodeCurrencyCode="12c7e2a9USD" FreeCancellationDeadline="2020-06-23T00:00:00+00:00" NonRefundable="false" NumberOfUnits="1" RoomTypeCode="2608f7ec" RatePlanCode="RO">/>
            </RoomRate>
        <Rates>... </Rates>RoomRates>
         <TimeSpan End="2020-09-17" Start="2020-09-12"/>
   <VendorInfo>      <BasicPropertyInfo HotelCityCode="260526" HotelCode="716668" HotelCodeContext="innstant" HotelName="1000Nights Guest House - Near the    <VendorCode>5683</VendorCode>beach" AreaID="IL">
            <Position Latitude="32.06891" Longitude="34.76621"/>
   <VendorName>hotelsdemo</VendorName>         <Address>...</Address>
      </VendorInfo>      ...
         <CancelPenalties>...</CancelPenalties>BasicPropertyInfo>
      </RoomStay>
   </RoomStays>
</OTA_HotelAvailRS>

Second Availability request with AllowPartialAvail=true and MoreDataEchoToken from previous Availability response:

Code Block
languagexml
<OTA_HotelAvailRQ AllowPartialAvail="true" AvailRatesOnly="false" BestOnly="false" EchoToken="54039685" PrimaryLangID="en"  <Total AmountAfterTax="910.00" CurrencyCode="USD"/>
        RateRangeOnly="false" Version="2" xmlns="http://www.opentravel.org/OTA/2003/05">

  </RoomRate> <POS>
      <Source>
 </RoomRates>        <RequestorID  <TimeSpan End="2020-09-17" Start="2020-09-12ID="cla" MessagePassword="pwa" Type="22"/>
         <BasicPropertyInfo HotelCityCode="260526" HotelCode="716668" HotelCodeContext="innstant" HotelName="1000Nights Guest House - Near the beach"<BookingChannel AreaIDType="IL7"/>
      </Source>
     <Position Latitude="32.06891" Longitude="34.76621"/></POS>
   <AvailRequestSegments>
        <Address>...</Address><AvailRequestSegment MoreDataEchoToken="200331165120.019795">
         <StayDateRange   ...End="2020-09-17" Start="2020-09-12"/>
         <RoomStayCandidates>...</BasicPropertyInfo>RoomStayCandidates>
      </RoomStay>    </RoomStays>
</OTA_HotelAvailRS>

Second Availability request with AllowPartialAvail=true and MoreDataEchoToken from previous Availability response:

Code Block
languagexml
<OTA_HotelAvailRQ AllowPartialAvail="true" AvailRatesOnly="false" BestOnly="false" EchoToken="54039685" PrimaryLangID="en" RateRangeOnly="false" Version="2" xmlns="http://www.opentravel.org/OTA/2003/05"> <HotelSearchCriteria>
          <POS>  <Criterion>
    <Source>          <RequestorID ID="cla" MessagePassword<HotelRef HotelCityCode="pwa15744" TypeHotelCodeContext="22GEO.innstant"/>
         <BookingChannel Type="7"/>      <Profiles>
    </Source>    </POS>    <AvailRequestSegments>      <ProfileInfo>
<AvailRequestSegment MoreDataEchoToken="200331165120.019795">          <StayDateRange End="2020-09-17" Start="2020-09-12"/>        <UniqueID  <RoomStayCandidates>...</RoomStayCandidates>ID="1" Type="1"/>
         <HotelSearchCriteria>            <Profile>
<Criterion>                <HotelRef HotelCityCode="15744" HotelCodeContext="GEO.innstant"/>        <Customer>
            <Profiles>               <PersonName>...</PersonName>
   <ProfileInfo>                      <UniqueID ID="1" Type="1"/> <Address>...</Address>
                      <Profile>     <CitizenCountryName Code="RU"/>
                  <Customer>      </Customer>
                     <PersonName>...</PersonName>Profile>
                  </ProfileInfo>
        <Address>...</Address>       </Profiles>
            </Criterion>
         <CitizenCountryName Code="RU"/></HotelSearchCriteria>
      </AvailRequestSegment>
   </AvailRequestSegments>
</OTA_HotelAvailRQ>

Second Availability response with MoreDataEchoToken and MoreIndicator="false":

Code Block
languagexml
<OTA_HotelAvailRS EchoToken="54039685"     Version="2.0" xmlns="http://www.opentravel.org/OTA/2003/05">
      </Customer><Success/>
   <RoomStays MoreDataEchoToken="200331165120.019795" MoreIndicator="false">
      <RoomStay RoomStayCandidateRPH="1">
       </Profile>  <RoomTypes>
            <RoomType RoomTypeCode="4cffc724">
  </ProfileInfo>             <RoomDescription   </Profiles>
      Name="Apartment Double">
     </Criterion>          </HotelSearchCriteria>   <Text>Apartment Double (apartment  double)</AvailRequestSegment>Text>
     </AvailRequestSegments> </OTA_HotelAvailRQ>

Second Availability response with MoreDataEchoToken and MoreIndicator="false":

Code Block
languagexml
<OTA_HotelAvailRS EchoToken="54039685" Version="2.0" xmlns="http://www.opentravel.org/OTA/2003/05">       </RoomDescription>
        <Success/>    <RoomStays MoreDataEchoToken="200331165120.019795" MoreIndicator="false"></RoomType>
        <RoomStay RoomStayCandidateRPH="1"> </RoomTypes>
         <RoomTypes><RatePlans>
            <RoomType<RatePlan RoomTypeCodeRatePlanCode="4cffc724BB">
               <RatePlanDescription>
          <RoomDescription Name="Apartment Double">      <Text>Breakfast</Text>
            <Text>Apartment Double (apartment double)</Text>RatePlanDescription>
               <MealsIncluded Breakfast="true"  </RoomDescription>Dinner="false" Lunch="false" MealPlanCodes="3"/>
            </RoomType>RatePlan>
         </RoomTypes>RatePlans>
         <RoomRates>
  <RatePlans>          <RoomRate AvailabilityStatus="OnRequest" BookingCode="12c7eb0a" NonRefundable="true"   <RatePlanNumberOfUnits="1" RoomTypeCode="4cffc724" RatePlanCode="BBRO">
               <RatePlanDescription><Rates>...</Rates>
                  <Text>Breakfast</Text><VendorInfo>...</VendorInfo>
               <CancelPenalties>...</RatePlanDescription>CancelPenalties>
               <MealsIncluded<Total BreakfastAmountAfterTax="true204.00" DinnerCurrencyCode="false" Lunch="false" MealPlanCodes="3"USD"/>
            </RatePlan>RoomRate>
         </RatePlans>RoomRates>
         <RoomRates>
 <TimeSpan End="2020-09-17" Start="2020-09-12"/>
         <BasicPropertyInfo <RoomRate AvailabilityStatusHotelCityCode="260526" HotelCode="OnRequest514348" BookingCodeHotelCodeContext="12c7eb0ainnstant" NonRefundableHotelName="truespat holon" NumberOfUnitsAreaID="1IL" RoomTypeCode="4cffc724" RatePlanCode="RO">
            <Position Latitude="31.99902" Longitude="34.76588"/>
               <Rates><Address>...</Rates>Address>
            <CategoryCodes>
  <VendorInfo>...</VendorInfo>             <HotelCategory Code="20"  <CancelPenalties>...</CancelPenalties>GroupCode="Type" CodeDetail="Hotel"/>
               <Total AmountAfterTax="204.00" CurrencyCode="USD"/></CategoryCodes>
            </RoomRate>...
         </RoomRates>BasicPropertyInfo>
      </RoomStay>
  <TimeSpan End="2020-09-17" Start="2020-09-12"/>
         <BasicPropertyInfo HotelCityCode="260526 </RoomStays>
</OTA_HotelAvailRS>

2.1.2. SEARCH BY HOTEL

Search by

Description

Search example

Hotel code from supplier context

If you already did search, you can check just availability of certain hotel. In this case you need to provide supplier city code and hotel code as a search criteria.

Code Block
languagexml
<Criterion>
   <HotelRef HotelCityCode="LON" HotelCode="

...

157292" HotelCodeContext="

...

supplierCode"

...

/>
</Criterion>

Hotel name

Allows to perform search by hotel name. Full hotel name or part of it can be specified.

Code Block
languagexml
<Criterion>
          <HotelRef 

...

2.1.2. SEARCH BY HOTEL

Search by

Description

Search example

1

Hotel code from supplier context

If you already did search, you can check just availability of certain hotel. In this case you need to provide supplier city code and hotel code
HotelCityCode="29603" HotelName="Boutique Hotel" HotelCodeContext="GEO.supplierCode"/>
</Criterion>

List of hotels

Allows to perform search by list of hotel codes.

Info

Note: This functionality supported for limited suppliers. Please check with GP Travel HUB development if you are interested in specific supplier.

In case of search by list of hotels from one city you need to provide supplier city code and codes of each hotel as a search criteria.

Code Block
languagexml
<Criterion>
   <HotelRef HotelCityCode="3687" HotelCodeContext="supplierCode" HotelCode="e50deacb596"/>
</Criterion>
<Criterion>
   <HotelRef HotelCityCode="3687" HotelCodeContext="supplierCode" HotelCode="dd0d3e162e9"/>
</Criterion>
<Criterion>
   <HotelRef HotelCityCode="3687" HotelCodeContext="supplierCode" HotelCode="ad0d3e162e9"/>
</Criterion>

In case of search by list of hotels from different cities you need to provide supplier city codes and codes of each hotel of appropriate city as a search criteria.

Code Block
languagexml
<Criterion>
   <HotelRef HotelCityCode="1089" HotelCodeContext="supplierCode" HotelCode="e50f345345h"/>
</Criterion>
<Criterion>
   <HotelRef HotelCityCode="
LON
3687" 
HotelCode
HotelCodeContext="
157292
supplierCode" 
HotelCodeContext="supplierCode"/> </Criterion>2

 Hotel Chain

Allows to perform search on chain criterion. To define the chain, there is a ChainCode attribute added to HotelRef element.

Info

Note: This functionality supported for limited suppliers. Please check with GP Travel HUB development if you are interested in specific supplier.

Code Block
languagexml
HotelCode="dd0d3e162e9"/>
</Criterion>
<Criterion>
   <HotelRef 
ChainCode
HotelCityCode="
HILTO
9695" 
HotelCityCode
HotelCodeContext="
25995
supplierCode" 
HotelCodeContext
HotelCode="
GEO.supplierCode
ad04234f34v"/>
</Criterion>

2.1.3. SEARCH BY COORDINATES

Search by

Description

Search example

Coordinates

Allows to perform search, specifying latitude and longitude of a point as well as radius of search. Refers to OTA Unit of Measure Code.

Info

Note: HUB uses internal logic listed below for search by coordinates only if supplier does not support this kind of search. If it is supported by supplier then HUB just passes coordinates to supplier.

In case of request with GEO code, search is performed by HUB in following way:

  • all locations are extract from database from GEO tree. Then by mappings we extract supplier's locations and make search.

  • results are filtered to compute distance and the closest location considering Radius/@Distance to reseive only suitable locations.

by Geo context

Code Block
languagexml
<Criterion>
   <Position Latitude="41.69411" Longitude="44.83368"/>
   <HotelRef HotelCodeContext="GEO.supplierCode"/>
   <Radius Distance="50" UnitOfMeasureCode="2"/>
</Criterion>

In case of request with supplier code, search is performed by HUB in following way:

  • all locations are extract from database from Supplier tree. This means search can be made if we have latitude and longitude in supplier's static data only.

  • results are filtered to compute distance and the closest location considering Radius/@Distance to reseive only suitable locations.

by supplier context

Code Block
languagexml
<Criterion>
   <Position Latitude="41.69411" Longitude="44.83368"/>
   <HotelRef HotelCodeContext="supplierCode"/>
   <Radius Distance="50" UnitOfMeasureCode="2"/>
</Criterion>

Quadrangle

Allows to specify the quadrangular area of search by defining its south-west and east-north coordinates. In response HUB returns all hotels that are located into specified area.

Code Block
languagexml
<Criterion>
   <HotelRef HotelCodeContext="supplierCode"/>
   <MapArea EastLongitude="-0.1" NorthLatitude="51.53" SouthLatitude="51.52" WestLongitude="-0.92"/>
</Criterion>

2.1.4. SEARCH FOR MULTIPLE ROOMS REQUESTED

...