OTA_HotelAvailRQ
Methode zum Abrufen von Zimmern und Angeboten von Kurzurlaub.de.
OTA_HotelAvailRQ - Anfrage per GET - REST-API
jede Methode kann per REST-API mittels GET aufgerufen werden.
Verwendete Parameter:
AgentDutyCode(optional, sofern IP WhiteList oder HTTP Basic Auth verwendet wird)HotelCode(mandatory)
Beispiel:
GET /ota/api/HotelAvail?AgentDutyCode=1&HotelCode=4
OTA_HotelAvailRQ - Anfrage per POST
HotelAvail Request (RQ) und Response (RS) am Beispiel des Testhotels
Verwendete Parameter:
@AgentDutyCode(Agent-ID): 1@HotelCode(Hotel-ID): 4
Beispiel OTA_HotelAvailRQ (Request)
<?xml version="1.0" encoding="UTF-8"?>
<OTA_HotelAvailRQ xmlns="http://www.opentravel.org/OTA/2003/05" AvailRatesOnly="true"
EchoToken="938a6a32-c526-485b-b641-f69d635cda41"
TimeStamp="2020-06-18T15:04:39+01:00"
Version="1.0">
<POS>
<Source AgentDutyCode="1">
<RequestorID ID="4" Type="4"/>
</Source>
</POS>
<AvailRequestSegments>
<AvailRequestSegment AvailReqType="Room">
<HotelSearchCriteria>
<Criterion>
<HotelRef HotelCode="4"/>
</Criterion>
</HotelSearchCriteria>
</AvailRequestSegment>
</AvailRequestSegments>
</OTA_HotelAvailRQ>
OTA_HotelAvailRS - Versionen der Response
OTA-V1
Alte Version der OTA_HotelAvailRS nur mit Zimmerdaten ohne Angebotsdaten
Beispiel OTA_HotelAvailRS (Response)
<?xml version="1.0" encoding="UTF-8"?>
<OTA_HotelAvailRS xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.opentravel.org/OTA/2003/05"
xsi:schemaLocation="http://opentravel.org/2010A/OTA_HotelAvailRS.xsd" Version="1.0"
TimeStamp="2021-11-04T12:59:20" EchoToken="43e234b7cede64ea341c6417ab3cd9dd">
<Success/>
<RoomStays>
<RoomStay>
<RoomTypes>
<RoomType RoomTypeCode="2625">
<RoomDescription Name="Appartement/s (28 m²)"/>
</RoomType>
</RoomTypes>
</RoomStay>
<RoomStay>
<RoomTypes>
<RoomType RoomTypeCode="9147">
<RoomDescription Name="Doppelzimmer (24 m²)"/>
</RoomType>
</RoomTypes>
</RoomStay>
<RoomStay>
<RoomTypes>
<RoomType RoomTypeCode="25871">
<RoomDescription Name="Doppelzimmer (20 m²)"/>
</RoomType>
</RoomTypes>
</RoomStay>
<RoomStay>
<RoomTypes>
<RoomType RoomTypeCode="9143">
<RoomDescription Name="Doppelzimmer Seeseite (29 m²)"/>
</RoomType>
</RoomTypes>
</RoomStay>
<RoomStay>
<RoomTypes>
<RoomType RoomTypeCode="11668">
<RoomDescription Name="Dreibettzimmer (29 m²)"/>
</RoomType>
</RoomTypes>
</RoomStay>
<RoomStay>
<RoomTypes>
<RoomType RoomTypeCode="5307">
<RoomDescription Name="Einzelzimmer (15 m²)"/>
</RoomType>
</RoomTypes>
</RoomStay>
<RoomStay>
<RoomTypes>
<RoomType RoomTypeCode="9148">
<RoomDescription Name="Einzelzimmer Deluxe (18 m²)"/>
</RoomType>
</RoomTypes>
</RoomStay>
</RoomStays>
</OTA_HotelAvailRS>
OTA-V2 (neue Version ab 10.2021)
Neue Version der OTA_HotelAvailRS mit Zimmerdaten und Angebotsdaten
Hier wird eine RoomType / RatePlan Kombination geliefert d.h. alle Zimmer und die dazugehörigen verfügbaren Angebote (RatePlan) mit Attributen.
Für die Zimmer (<RoomType>) werden folgende Attribute verwendet
@RoomID@RoomTypeCode(wie RoomID)@RoomType- (Zimmertyp bspw. Einzelzimmer, Doppelzimmer, Appartement ...)@NumberOfUnits(Zimmeranzahl 1-n)RoomDescription@Name(Zimmername und Größe)Occupancy@MaxOccupancy(max. Belegung mit erwachsenen Personen)
Beispiel RoomType:
<RoomType RoomID="2625" RoomTypeCode="2625" RoomType="Appartement" NumberOfUnits="10">
<RoomDescription Name="Appartement/s (28m², ID:2625, 4E/2K)"/>
<Occupancy MaxOccupancy="4"/>
</RoomType>
Für die Angebote (RatePlan) werden folgende Attribute verwendet
@RatePlanID@RatePlanCode@RatePlanName@RatePlanType- Angebotszeitraum (
@EffectiveDate-@ExpireDate)
Die RatePlanID und RatePlanCode (bspw. BEST-RATE oder BAR - Best Available Rate) sind in der Regel unterschiedlich. Sofern kein RatePlanCode angegeben ist, wird hier auch die RatePlanID gesendet.
Der RatePlanType ist immer gleich (11), da es sich um ein Package handelt - siehe OTA Standard in der Rate Plan Type Code Table (RPT)
Beispiel RatePlan:
<RatePlan RatePlanID="190772" RatePlanCode="BAR-190772" RatePlanType="11"
RatePlanName="Testarrangement schönes Schwerin"
EffectiveDate="2020-01-01" ExpireDate="2022-12-31">
Beispiel OTA_HotelAvailRS (Response)
<?xml version="1.0" encoding="UTF-8"?>
<OTA_HotelAvailRS xmlns="http://www.opentravel.org/OTA/2003/05" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
EchoToken="fb67da72b95941c8dc28aeb276790cc0" PrimaryLangID="de" TimeStamp="2021-11-04T12:46:34+01:00"
Target="Production" Version="2.0">
<Success/>
<RoomStays>
<RoomStay>
<RoomTypes>
<RoomType RoomID="2625" RoomTypeCode="2625" RoomType="Appartement" NumberOfUnits="10">
<RoomDescription Name="Appartement/s (28m², ID:2625, 4E/2K)"/>
<Occupancy MaxOccupancy="4"/>
</RoomType>
</RoomTypes>
<RatePlans>
<RatePlan RatePlanID="20540" RatePlanCode="20540"
RatePlanName="Testarrangement schönes Schwerin - bitte nicht buchen" RatePlanType="11"
EffectiveDate="2017-03-01" ExpireDate="2021-12-31">
<RatePlanDescription Name="Testarrangement schönes Schwerin - bitte nicht buchen">
<text>Kurzurlaub Angebot 2 ÜN gültig bis 31.12.2021</text>
</RatePlanDescription>
</RatePlan>
</RatePlans>
</RoomStay>
<RoomStay>
<RoomTypes>
<RoomType RoomID="2625" RoomTypeCode="2625" RoomType="Appartement" NumberOfUnits="10">
<RoomDescription Name="Appartement/s (28m², ID:2625, 4E/2K)"/>
<Occupancy MaxOccupancy="4"/>
</RoomType>
</RoomTypes>
<RatePlans>
<RatePlan RatePlanID="190772" RatePlanCode="BAR-190772"
RatePlanName="Testarrangement schönes Schwerin - bitte nicht buchen 2" RatePlanType="11"
EffectiveDate="2017-03-01" ExpireDate="2021-12-31">
<RatePlanDescription Name="Testarrangement schönes Schwerin - bitte nicht buchen 2">
<text>Kurzurlaub Angebot 3 ÜN gültig bis 31.12.2021</text>
</RatePlanDescription>
</RatePlan>
</RatePlans>
</RoomStay>
<RoomStay>
<RoomTypes>
<RoomType RoomID="5306" RoomTypeCode="5306" RoomType="Doppelzimmer" NumberOfUnits="43">
<RoomDescription Name="Doppelzimmer (20m², ID:5306, 2E/1K)"/>
<Occupancy MaxOccupancy="2"/>
</RoomType>
</RoomTypes>
<RatePlans>
<RatePlan RatePlanID="20540" RatePlanCode="20540"
RatePlanName="Testarrangement schönes Schwerin - bitte nicht buchen" RatePlanType="11"
EffectiveDate="2017-03-01" ExpireDate="2021-12-31">
<RatePlanDescription Name="Testarrangement schönes Schwerin - bitte nicht buchen">
<text>Kurzurlaub Angebot 2 ÜN gültig bis 31.12.2021</text>
</RatePlanDescription>
</RatePlan>
</RatePlans>
</RoomStay>
<RoomStay>
<RoomTypes>
<RoomType RoomID="5306" RoomTypeCode="5306" RoomType="Doppelzimmer" NumberOfUnits="43">
<RoomDescription Name="Doppelzimmer (20m², ID:5306, 2E/1K)"/>
<Occupancy MaxOccupancy="2"/>
</RoomType>
</RoomTypes>
<RatePlans>
<RatePlan RatePlanID="190772" RatePlanCode="BAR-190772"
RatePlanName="Testarrangement schönes Schwerin - bitte nicht buchen 2" RatePlanType="11"
EffectiveDate="2017-03-01" ExpireDate="2021-12-31">
<RatePlanDescription Name="Testarrangement schönes Schwerin - bitte nicht buchen 2">
<text>Kurzurlaub Angebot 3 ÜN gültig bis 31.12.2021</text>
</RatePlanDescription>
</RatePlan>
</RatePlans>
</RoomStay>
<RoomStay>
<RoomTypes>
<RoomType RoomID="9143" RoomTypeCode="9143" RoomType="Doppelzimmer" NumberOfUnits="2">
<RoomDescription Name="Doppelzimmer Seeseite (29m², ID:9143, 2E/2K)"/>
<Occupancy MaxOccupancy="2"/>
</RoomType>
</RoomTypes>
<RatePlans>
<RatePlan RatePlanID="20540" RatePlanCode="20540"
RatePlanName="Testarrangement schönes Schwerin - bitte nicht buchen" RatePlanType="11"
EffectiveDate="2017-03-01" ExpireDate="2021-12-31">
<RatePlanDescription Name="Testarrangement schönes Schwerin - bitte nicht buchen">
<text>Kurzurlaub Angebot 2 ÜN gültig bis 31.12.2021</text>
</RatePlanDescription>
</RatePlan>
</RatePlans>
</RoomStay>
<RoomStay>
<RoomTypes>
<RoomType RoomID="9147" RoomTypeCode="9147" RoomType="Doppelzimmer" NumberOfUnits="3">
<RoomDescription Name="Doppelzimmer (24m², ID:9147, 2E/2K)"/>
<Occupancy MaxOccupancy="2"/>
</RoomType>
</RoomTypes>
<RatePlans>
<RatePlan RatePlanID="20540" RatePlanCode="20540"
RatePlanName="Testarrangement schönes Schwerin - bitte nicht buchen" RatePlanType="11"
EffectiveDate="2017-03-01" ExpireDate="2021-12-31">
<RatePlanDescription Name="Testarrangement schönes Schwerin - bitte nicht buchen">
<text>Kurzurlaub Angebot 2 ÜN gültig bis 31.12.2021</text>
</RatePlanDescription>
</RatePlan>
</RatePlans>
</RoomStay>
<RoomStay>
<RoomTypes>
<RoomType RoomID="9148" RoomTypeCode="9148" RoomType="Einzelzimmer" NumberOfUnits="1">
<RoomDescription Name="Einzelzimmer Deluxe (18m², ID:9148, 1E/1K)"/>
<Occupancy MaxOccupancy="1"/>
</RoomType>
</RoomTypes>
<RatePlans>
<RatePlan RatePlanID="20540" RatePlanCode="20540"
RatePlanName="Testarrangement schönes Schwerin - bitte nicht buchen" RatePlanType="11"
EffectiveDate="2017-03-01" ExpireDate="2021-12-31">
<RatePlanDescription Name="Testarrangement schönes Schwerin - bitte nicht buchen">
<text>Kurzurlaub Angebot 2 ÜN gültig bis 31.12.2021</text>
</RatePlanDescription>
</RatePlan>
</RatePlans>
</RoomStay>
<RoomStay>
<RoomTypes>
<RoomType RoomID="45741" RoomTypeCode="45741" RoomType="Einzelzimmer" NumberOfUnits="1">
<RoomDescription Name="Einzelzimmer Meerblick (28m², ID:45741, 1E/1K)"/>
<Occupancy MaxOccupancy="1"/>
</RoomType>
</RoomTypes>
<RatePlans>
<RatePlan RatePlanID="20540" RatePlanCode="20540"
RatePlanName="Testarrangement schönes Schwerin - bitte nicht buchen" RatePlanType="11"
EffectiveDate="2017-03-01" ExpireDate="2021-12-31">
<RatePlanDescription Name="Testarrangement schönes Schwerin - bitte nicht buchen">
<text>Kurzurlaub Angebot 2 ÜN gültig bis 31.12.2021</text>
</RatePlanDescription>
</RatePlan>
</RatePlans>
</RoomStay>
</RoomStays>
</OTA_HotelAvailRS>