← Step 4 – Create rate plan | Step 6 – Push availability →¶
Step 5 – Create product¶
Now it's time to create a product. A product is a combination of room, rate, and policy details. This combined information is effectively what guests buy when they book a stay through the Booking.com website. This is why you had to create a room type and rate plan earlier.
This seems complicated – why not just put everything in a product?
The reason we treat rooms, rates, and products as separate entities is that it enables reuse. You can combine the same rooms and rates into different products. For example, a lone traveller might pay less than a couple for the same double room. Or, a property could offer discounts to groups greater than 4. Or to guests who stay more than a week. You only need one room type to sell all these different products.
Use this method and URL to create a new product:
POST https://supply-xml.booking.com/hotels/ota/OTA_HotelProductNotif
In the sample request below, make sure you replace these {PlaceHolders}
:
Placeholder | Description |
---|---|
{PropertyID} |
Your property's ID. |
{RoomTypeID} |
Use the value of InventoryCrossRef[@ResponseInvCode] from the response to your room type request. |
{RatePlanID} |
Use the value of RatePlanCrossRef[@ResponseRatePlanCode] from the response to your rate plan request. |
Sample request¶
<?xml version="1.0" encoding="UTF-8"?>
<OTA_HotelProductNotifRQ
xmlns="http://www.opentravel.org/OTA/2003/05"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
PrimaryLangID="en-US"
EchoToken="GUID"
Version="1.0"
Target="Test">
<HotelProducts HotelCode="{PropertyID}">
<HotelProduct ProductNotifType="New">
<RoomTypes>
<RoomType RoomTypeCode="{RoomTypeID}" MaxOccupancy="{MaxOccupancy}"/>
</RoomTypes>
<RatePlans>
<RatePlan RatePlanCode="{RatePlanID}" />
</RatePlans>
<PolicyInfo>
<BookingRules>
<BookingRule MinAdvancedBookingOffset="P1D" />
</BookingRules>
<CancelPolicy>
<CancelPenalty PolicyCode="12" />
</CancelPolicy>
</PolicyInfo>
</HotelProduct>
</HotelProducts>
</OTA_HotelProductNotifRQ>
Sample response¶
<?xml version="1.0" encoding="UTF-8"?>
<OTA_HotelProductNotifRS 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_HotelProductNotifRS.xsd" TimeStamp="2018-02-12T10:12:41+00:00" Target="Test" Version="3.000">
<Success />
</OTA_HotelProductNotifRS>
<!-- RUID: [UmFuZG9...] -->
Learn more about the last call here: OTA_HotelProductNotif