Channel Managers · API docs

Update rates

URL: /v1/hotels/rate-plans/update

Goals

To update in the extranet and in the website the rates for the room/rate plan requested of a specific property in a set period of time.

Notes

The API is deliberately pedantic in making the distinctions detailed below to make sure both the hotel and channel manager know what values they are updating.

Charge Type Code

This is a known source of confusion between the hotel and the channel manager. The charge type code and the pricing structure are tied to the hotel configuration. Specifically, the charge type code selects one of the two pricing models supported by Despegar.com: Per person, per night and per room, per night. The pricing structure matches the pricing model.

Taxes

Another source of confusion. The hotel selects whether they'd like to indicate rates including taxes or not. You can obtain this setting from Get Hotel Information (look for the TaxPolicy element).

Depending on this value, you need to use either @AmountAfterTax or @AmountBeforeTax.

Message Detail

Input: OTA_HotelRatePlanNotifRQ

ElementNumberDescription
OTA_HotelRatePlanNotifRQ1Root element
OTA_HotelRatePlanNotifRQ / RatePlans1Rate plan collection
@HotelCode1The unique hotel code
RatePlans / RatePlanAll the information of an specific rate plan.
@RatePlanCode1Identifier code of the rate plan
@ChargeTypeCode1Indicates how the rate is applied. Refer to OpenTravel Charge Type (CHG) code table. Despegar.com supports only the following values: "19": Per room per night "21": Per person per night
@CurrencyCode1ISO 4217 currency code. Example: USD, ARG, EUR.
RatePlan / Rates
Rates / Rate
@InvCode1Room identifier code.
@Start1Data request start date (inclusive).
@End1Data request end date (exclusive).
Rate / BaseByGuestAmts1
BaseByGuestAmts / BaseByGuestAmt1Base charge for the indicated number of guests for an age code classification.
@NumberOfGuests1The number of guests linked to the rate.
@AgeQualifyingCode1Define the age range of the rate. Refer to OpenTravel Age Qualifying Code (AQC) code table. Possible values: "10": Adult "8": Child "7": Infant "3": Baby
@AmountBeforeTax1The new rate without taxes.
@AmountAfterTax1The new rate with taxes.
Rate / AdditionalGuestAmounts0..1
AdditionalGuestAmounts / AdditionalGuestAmount1The amount charged by the extra guest is related to the age group of the base guest.
@MaxAdditionalGuests1Maximum additional guests.
@AgeQualifyingCode1Define the age range of the rate. Refer to OpenTravel Age Qualifying Code (AQC) code table. Possible values: "10": Adult (Only for per room per night) "8": Child "7": Infant "3": Baby
@Amount1Additional amount

Output: OTA_HotelRatePlanNotifRS

ElementNumberDescription
OTA_HotelRatePlanNotifRS1Root element
@Version1Service version
OTA_HotelRatePlanNotifRS / Success0..1It is present if the request has been processed successfully. The error node is not present if this node appears.
OTA_HotelRatePlanNotifRS / Errors0..1Contains an error list in case the request was not processed correctly.
Errors / Error1..nIf there is an error node then there has to exist at least one error node. The element will contain the error text.
@Type1Error type
@Code0..1Error code
OTA_HotelRatePlanNotifRS / Warnings0..1Contains a warning list in case the request was processed partially.
Warnings / Warning1..nIf there is a warnings node then there has to exist at least one warning node. The element will contain the warning text.
@Type1Warning type
@Code0..1Warning code