los_pricing (CSV)

This call is used for sending prices in URL-encoded CSV format when the Booking.com accommodation is configured to accept the LOS pricing model.

POST https://supply-xml.booking.com/hotels/csv/los_pricing

Concepts

Instead of giving us a price per day and having us calculate what the final price for a stay would be -- or whether it should even be available considering restrictions -- properties can give us the price for every possible length of stay (up to 30 nights) and occupancy (up to the max_persons value of the room), given a check-in date

Format

This call accept CSV data where 1 row has the following format:

{checkin},{occupancy},{room id},{rate id},{currency code},{1 night},{2 nights},{3 nights},...

For example:

2011-05-01,2,1444301,23543,EUR,100,210,270,390,550,580,650,82

If the check-in product is not available for a particular length of stay, the price should be set to 0:

2011-05-01,2,1444301,23543,EUR,100,210,0,390,550,580,0,82

The above means that customer will not be able to book the room for 3 or 7 nights if the check-in date is 2011-05-01. Any price beyond last price specified is assumed to be 0 and therefore lengths of stay more 8 is not available for reservation in the above example as well.

Rules

Each row must have the check-in date, occupancy, room id , rate id and currency code followed by a value set for every possible length of stay. There is no way to express a default per night price, due to determining the difference between an unavailable length of stay and a default price length of stay. All pricing is in the default currency for the hotel. A maximum of two decimal places is supported for each price value. The room and rate ids are Booking.com identifiers, and are setup prior to the use of the message. The room and rate ids must belong to a hotel for which the login account has permission to modify availability and pricing for. All room and rate ids must be active combinations for the hotel. Maximum number of nights is 32. If you provider more than 32 nights, the remaining nights will be ignored and only the first 32 nights will be considred. Only rooms belonging to one hotel are allowed in one call i.e separate requests for each hotel have to made.

€50000 maximum price

The maximum price you can set for a room is €50000 (or equivalent) per night. If you try to set a higher price, we set the price to zero, which automatically closes the room. The API will return a warning message like this:

method,status,ticket_id,warnings

los_pricing,ok,8dd66019d5720001,Line number 1 . Price 182000000 for room id 74115904 and rate id 8958505 is higher than Maximum System Rate. We have closed the room as a precaution.

Transmission details

This data is sent as an HTTP POST, where the CSV data is provided as a form value of the name "CSV". There should be no other form values included in the request. Each request header must contain a "Content-length" item that contains the number of character bytes of the POST data. The CSV commas and line feeds must be URL encoded, in that each comma and newline is an escape sequence. The content length must be the full character count including the extra bytes due to the escape sequences. The following escape sequences are implemented, but more can be added if required:

Character Encoding
, (comma) %2C
\n (line feed) %0A

Below is an example minimal HTTP request (without the required authorization header) containing three sample lines:

POST https://supply-xml.booking.com/hotels/csv/los_pricing
Content-Length: 721
Content-Type: application/x-www-form-urlencoded

CSV=2011-03-15%2C1000201%2C58848%2CEUR%2C100%2C200%2C300%2C400%2C500%2C600%2C700%2C800%2C900%2C1000%2C1100%2C1200%2C1300%2C1400%2C1500%2C1600%2C1700%2C1800%2C1900%2C2000%2C2100%2C2200%2C2300%2C2400%2C2500%2C2600%2C2700%2C2800%2C2900%2C3000%2C3100%0A2011-03-16%2C1000201%2C58848%2CEUR%2C100%2C200%2C300%2C400%2C500%2C600%2C700%2C800%2C900%2C1000%2C1100%2C1200%2C1300%2C1400%2C1500%2C1600%2C1700%2C1800%2C1900%2C2000%2C2100%2C2200%2C2300%2C2400%2C2500%2C2600%2C2700%2C2800%2C2900%2C3000%2C3100%0A2011-03-15%2C1000201%2C50587%2CEUR%2C100%2C200%2C300%2C400%2C500%2C600%2C700%2C800%2C900%2C1000%2C1100%2C1200%2C1300%2C1400%2C1500%2C1600%2C1700%2C1800%2C1900%2C2000%2C2100%2C2200%2C2300%2C2400%2C2500%2C2600%2C2700%2C2800%2C2900%2C3000%2C3100%0A

Successful response

Example of successful response:

method,status,ticket_id
los_pricing,ok,abcdef0123456789

Example of successful response where some nights are ignored in line 2 in the request:

method,status,ticket_id,warnings
los_pricing,ok,abcdef0123456789,The following lines has too many nights and only the first 32 nights were considered%2C2

Error handling

If there are any errors during request handling, request will look like the following:

method,fault_code,fault_message
los_pricing,<fault_code>,<error_message>

where fault_code has the same meaning as HTTP codes.

RUID

RUID is sent in 'X-RUID' header in response message