Create reservation – OTA_HotelResRQ

434 views July 22, 2016 October 20, 2017 korzhkov 0

This request could be used in case if you need to create a new reservation.

Request sample

<OTA_HotelResRQ xmlns="http://www.opentravel.org/OTA/2003/05">
    <HotelReservations>
        <HotelReservation>
            <RoomStays>
                <RoomStay>
                    <RoomTypes>
                        <RoomType RoomTypeCode="C_633" />
                    </RoomTypes>
                    <RatePlans>
                        <RatePlan RatePlanCode="331" />
                    </RatePlans>
                    <RoomRates>
                        <RoomRate RoomTypeCode="C_633" NumberOfUnits="1" RatePlanCode="331">
                            <Rates>
                                <Rate UnitMultiplier="5">
                                    <Total AmountAfterTax="138.50" CurrencyCode="EUR" />
                                </Rate>
                            </Rates>
                        </RoomRate>
                    </RoomRates>
                    <GuestCounts>
                        <GuestCount AgeQualifyingCode="1" Count="2" />
                    </GuestCounts>
                    <TimeSpan Start="2012-03-15" End="2012-03-16" />
                    <Guarantee>
                        <GuaranteesAccepted>
                            <GuaranteeAccepted>
                                <PaymentCard CardType="2" CardNumber="4111111111111111" SeriesCode="555" ExpireDate="05/2012">
                                    <CardHolderName>Bulanova Darya</CardHolderName>
                                </PaymentCard>
                            </GuaranteeAccepted>
                        </GuaranteesAccepted>
                    </Guarantee>
                    <BasicPropertyInfo HotelCode="604" />
                    <ResGuestRPHs>
                        <ResGuestRPH RPH="11" />
                        <ResGuestRPH RPH="12" />
                    </ResGuestRPHs>
                </RoomStay>
            </RoomStays>
            <ResGuests>
                <ResGuest ResGuestRPH="11">
                    <Profiles>
                        <ProfileInfo>
                            <Profile>
                                <Customer>
                                    <PersonName>
                                        <GivenName>Darya</GivenName>
                                        <Surname>Bulanova</Surname>
                                    </PersonName>
                                    <Telephone PhoneNumber="+79267076653" />
                                    <Email>darya.bulanova@gmail.com</Email>
                                    <Address>
                                        <CityName>MOW</CityName>
                                        <CountryName>Ru</CountryName>
                                    </Address>
                                </Customer>
                            </Profile>
                        </ProfileInfo>
                    </Profiles>
                </ResGuest>
                <ResGuest ResGuestRPH="12">
                    <Profiles>
                        <ProfileInfo>
                            <Profile>
                                <Customer>
                                    <PersonName>
                                        <GivenName>Sokolov</GivenName>
                                        <Surname>Sergey</Surname>
                                    </PersonName>
                                </Customer>
                            </Profile>
                        </ProfileInfo>
                    </Profiles>
                </ResGuest>
            </ResGuests>
        </HotelReservation>
    </HotelReservations>
</OTA_HotelResRQ>

Required fields:
RoomTypeCode – Room Category Code. Note it starts from C for hotel rooms and from P for apartments and virtual units
RatePlanCode – Rate plan code
AmountAfterTax – Amount
CurrencyCode – Currency code based on ISO 4217
TimeSpan – Period of reservation
Start — Check-In date
End — Check-Out date
CardType — Credit card type. Use 1 for Visa, 2 for Master Card, 3 for Maestro, 4 for American Express and 5 for Dinners Club
CardNumber — Credit Card number
SeriesCode — CVV2
ExpireDate — CC expiration date
CardHolderName — Cardholder’s name
HotelCode — Hotel ID
PrimaryLangID – Use ISO 639-3 language codes
Version – This is strange, but OTA requires it to be a required field

Optional fields:
AltLangID – Use ISO 639-3 language codes
StayDateRange – Desired period of hotel reservation
HotelCityCode – Desired location
HotelAmenity – OTA Hotel Amenity Code (HAC)

Response sample

<OTA_HotelSearchRS version="1">
    <Success/>
    <Properties>
        <Property HotelCode="532" HotelName="Name of the hotel goes here">
            <Position Latitude="65.326526" Longitude="32.659827"/>
            <Policy CheckInTime="14:00:00" CheckOutTime="12:00:00"/>
            <Address>
                <County>FR</County>
                <StateProv/>
                <CityName>27490</CityName>
                <PostalCode>321654</PostalCode>
                <AddressLine>Sample street address will be here</AddressLine>
            </Address>
            <Award Rating="3"/>
            <VendorMessages>
                <VendorMessage Title="Descriptions">
                    <SubSection SubTitle="Description">
                        <Paragraph>
                            <Text>Description text will come here</Text>
                        </Paragraph>
                    </SubSection>
                    <SubSection SubTitle="Amenities">
                        <Paragraph>
                            <Text>Amenities will come here</Text>
                        </Paragraph>
                    </SubSection>
                    <SubSection SubTitle="Services">
                        <Paragraph>
                            <Text>Services will come here</Text>
                        </Paragraph>
                    </SubSection>
                </VendorMessage>
                <VendorMessage Title="Images">
                    <SubSection SubTitle="Image[0]">
                        <Paragraph Name="Thumbnail">
                            <Image>
                                http://sampledomain.com/upload/image/100x50/1422.jpg
                            </Image>
                        </Paragraph>
                        <Paragraph Name="Original">
                            <Image>
                                http://sampledomain.com/upload/image/original/1422.jpg
                            </Image>
                        </Paragraph>
                    </SubSection>
                </VendorMessage>
            </VendorMessages>
            <RateRange MinRate="100" MaxRate="150" RateTimeUnit="FullDuration" CurrencyCode="EUR"/>
        </Property>
    </Properties>
</OTA_HotelSearchRS>

Response fields explained:
HotelCode – Hotel ID
CheckInTime – Time of check-in
CheckOutTime – Time of check-out
HotelName – Name of the hotel
Latitude – Latitude
Longitude – Longitude
County — Country code based on ISO 3166-1 alpha-2
CityName — City code
PostalCode — Postal code
AddressLine – Address line
Rating – Hotel star rating
VendorMessage Title=”Descriptions” – Hotel descriptive content
SubSection SubTitle=”Description” – Hotel description
SubSection SubTitle=”Amenities” – Hotel amenities
SubSection SubTitle=”Services” – Hotel services
VendorMessage Title=”Images” – Collection of hotel photos
SubSection SubTitle=”Image[х]” – х — Number of the photo in collection
Paragraph Name=”Thumbnail” – Thumbnail
Paragraph Name=”Original” – Original photo
MinRate – Min price for selected dates
MaxRate — Max price for selected dates
CurrencyCode – Currency code based on ISO 4217

Was this helpful?