Home
Developer Guide
Introduction
About the API
Integrating with the API
FAQ
Get Hotel Information
Information
Examples
List RoomRates (Room + RatePlan)
Information
Examples
Get Availability and Restrictions
Information
Examples
Get Inventory
Information
Examples
Update Availability and Restrictions
Information
Examples
List Rate Plans
Information
Examples
Get Rates
Information
Examples
Update Rates
Information
Examples
Booking Handling (Pull)
Information
Examples
Booking Handling (Push)
Information
Examples
Reference Tables
Warning Validation Codes
Error Validation Codes
Booking Data Structures
## Get rates **URL**: ```/v1/hotels/rate-plans/get``` ### Goals To return rates for a date range, for all or selected room-rates. ### Notes When you want to update rates, you need to, basically, send back the same structure you get from this message with the new values. You need to take note of three very important things: 1. The charge type code. 1. The pricing structure. 1. Rates including taxes or not. See the [notes for updating rates][Update Rates Notes] for more details. Don't forget to see the [examples]. Hotel 638049 uses *per person, per night*, while hotel 282445 uses *per room, per night* pricing models. #### Pricing Models These sample `Rate` elements show how each pricing model manifests itself in the response of this message. For each model, the hotel can also configure extra charges. ##### Per room, per night — Standard ```xml
``` ##### Per room, per night — With Extra Charges ```xml
``` ##### Per person, per night — Standard ```xml
``` ##### Per person, per night — With Extra Charges ```xml
``` ### Message Detail #### Input: OTA_HotelRatePlanRQ | Element | Number | Description | |:----------------------------------------------|:-------|:-----------------| | OTA_HotelRatePlanRQ | 1 | Root element | | OTA_HotelRatePlanRQ / RatePlans | 1 | Rate plan collection | | RatePlans / RatePlan | 1 | Defines the criteria to identify the rate plan to be returned. | | RatePlan / DateRange | 0..1 | A date or date range for the search criteria. | | @Start | 1 | Data request start date (inclusive).| | @End | 1 | Data request end date (exclusive).| | RatePlan / RatePlanCandidates | 1 | **Caveat**. This element cannot be repeated in this context, a separate `RatePlan` element must be issued per each rate plan to get rates for. | | RatePlanCandidates / RatePlanCandidate | 1 | | | @RatePlanCode | 1 | Identifier code of the rate plan | #### Output: OTA_HotelRatePlanRS | Element | Number | Description | |:----------------------------------------------|:-------|:-----------------| | OTA_HotelRatePlanRS | 1 | Root element | | OTA_HotelRatePlanRQ / RatePlans | 1 | Rate plan collection | | @HotelCode | 1 | The code of the hotel to be queried. | | RatePlans / RatePlan | | All the information of a specific rate plan.| | @RatePlanCode | 1 | Identifier code of the rate plan. | | @ChargeTypeCode | 1 | Indicates how the rate is applied. Refer to OpenTravel [Charge Type (CHG)](http://adriatic.pilotfish-net.com/ota-modelviewer/model/codelists/ota?term=CHG) code table. Despegar.com supports only the following values:
"19": Per room per night
"21": Per person per night
| | @CurrencyCode | 1 | ISO 4217 currency code. Example: USD, ARG, EUR.| | RatePlan / Rates | | | | Rates / Rate | | | | @InvCode | 1 | The unique room code. | | @Start | 1 | Start date (inclusive).| | @End | 1 | End date (exclusive).| | Rate / BaseByGuestAmts | 1 | | | BaseByGuestAmts / BaseByGuestAmt | 1 | Base charge for the indicated number of guests for an age code classification.| | @NumberOfGuests | 0..1 | The number of guests linked to the rate.| | @AgeQualifyingCode | 0..1 | Defines the age range of the rate. Refer to OpenTravel [Age Qualifying Code (AQC)](http://adriatic.pilotfish-net.com/ota-modelviewer/model/codelists/ota?term=AQC) code table. For this instance, Despegar.com supports only the following value:
"10": Adult
| | @AmountBeforeTax | 1 | The rate. This field is used if the hotel doesn't upload its prices with taxes included | | @AmountAfterTax | 1 | The rate. This field is used if the hotel uploads its prices with taxes included| | Rate / AdditionalGuestAmounts | 0..1 | | | AdditionalGuestAmounts / AdditionalGuestAmount| 1 | Additional charges collection according to the age classification of additional guests. The amount charged by the extra guest is related to the age group of the base guest.| | @AgeQualifyingCode | 1 | Define the age range of the rate. Refer to OpenTravel [Age Qualifying Code (AQC)](http://adriatic.pilotfish-net.com/ota-modelviewer/model/codelists/ota?term=AQC) code table. Possible values:
"10": Adult (Only for per room per night)
"8": Child
"7": Infant
"3": Baby
| | @Amount | 1 | Additional amount | | RatePlan / Description | | | | Description / Text | | Rate plan name | [Update Rates Notes]: [examples]: