Derived Rates
Query Overview
A derived rate is a rate whose configuration is inherited from another rate (its base rate). Instead of defining every value from scratch, a derived rate reuses the base rate configuration and only overrides the specific fields you need. Each inheritable field is returned wrapped in an object that exposes both its resolved value and an isInherit flag indicating whether the value comes from the base rate.
The derivedRatesSetup query returns the derived rates added to a hotel for a specific client-seller relation in Inventory. The returned fields include:
codenameactivebaseCodemealPlanIncludedvalueisInherit
inheritedAgePoliciesmaxAgeChildrenmaxAgeInfantsfreeInfantsfreeChildren
paymentPoliciesinheritedCurrencyinheritedCommissioninheritedPriceIsBindingacceptedPayments
bookingRulesbookingWindowmarketsrateRuleseniorRule
cancelPoliciesvalueisInherit
inheritedSurchargesinheritAllRoomsBaseRateroomsinformBaseRateinheritMealPlanSupplements
1. Criteria
When building your query, you need to provide the following input fields:
Mandatory Input
clientCodesupplierCodehotelCode
Optional Input
contextCodebaseRateCodes
2. Settings
Ensure that all required fields are properly set and match existing hotel derived rate configurations.
Response Considerations
The query returns a collection of derived rates along with success status and possible advise messages.
DerivedRatesRs (OBJECT)
rates(DerivedRateSetup) - A collection of retrieved derived rates.code(String) - The derived rate code.name(String) - The name of the derived rate.active(Boolean) - Indicates if the derived rate is active.baseCode(String) - The base rate code the derived rate inherits from.mealPlanIncluded(Object) - Meal plan included, with its resolved value and inheritance flag.inheritedAgePolicies(Object) - Age policies inherited from the base rate.paymentPolicies(Object) - Payment policies with inheritance metadata.bookingRules(Object) - Booking window, markets and special rate rules with inheritance metadata.cancelPolicies(Object) - Cancel policies with inheritance metadata.inheritedSurcharges(Object) - Surcharges inherited from the base rate.inheritAllRoomsBaseRate(Boolean) - Indicates whether all rooms are inherited from the base rate.rooms(Object) - Rooms associated with the derived rate when they are not inherited.informBaseRate(Boolean) - Indicates if the base rate code is sent to the supplier instead of the derived rate code.inheritMealPlanSupplements(Boolean) - Indicates whether meal plan supplements are inherited from the base rate.
success(Boolean) - Indicates if the operation was successful.adviseMessages(AdviseMessage) - Messages related to the operation.
Query Inputs
InventoryDerivedRatesSetupFilterInput (INPUT_OBJECT)
Derived rates setup filter input.
Derived rates setup filter input.
hotelCode * (String)
Hotel code of the derived rates to retrieve.
clientCode * (String)
Client code.
supplierCode * (String)
Travelgate Supplier/Channel code.
contextCode(String)
Travelgate Supplier/Channel context code.
baseRateCodes(String)
Base rate codes used to filter derived rates.
Returned Fields
DerivedRatesRs (OBJECT)
Represents the response object for derived rates setup operations.
Represents the response object for derived rates setup operations.
adviseMessages(AdviseMessage)
Collection of advise messages. code * (ID) AM code: The following codes can be returned: description * (String) Error description level * (AdviseMessageLevel) Indicates the level of importance of the message.
Possible values: ERROR, WARN, INFO.
Possible values: Specify the external message. External code. message * (String) External message. correlationID * (ID) Identifier to investigate the cause of the error.WARN: Warning message.ERROR: Error message.INFO: Info message.external(ExternalMessage)
code(String)
rates(DerivedRateSetup)
Collection of derived rate setup objects. Code associated with the derived rate. Name of the derived rate. active * (Boolean) Indicates whether the derived rate is active. Indicates the meal plan included in the derived rate. The derived value. isInherit * (Boolean) Indicates whether the value is inherited from the base rate. Base rate code associated with the derived rate. Age policies inherited from the base rate. Age policies are always inherited from the base rate. maxAgeInfants * (Int) Max age baby not inclusive freeInfants * (Boolean) If true the babies are free of charge maxAgeChildren * (Int) Max age child not inclusive freeChildren * (Boolean) If true children are free of charge Payment policies associated with the derived rate. inheritedCurrency * (Currency) Currency inherited from the base rate. inheritedCommission * (Float) Commission inherited from the base rate. inheritedPriceIsBinding * (Boolean) Indicates whether the inherited prices are binding. Accepted payment methods with inheritance metadata. The derived value. type * (PaymentType) isInherit * (Boolean) Indicates whether the value is inherited from the base rate. Booking rules associated with the derived rate. Booking Dates for which the rate will be available. Do not send it if you want the rate available for all dates. The derived value. start * (DateTime) Start date of the booking window. end * (DateTime) End date of the booking window. isInherit * (Boolean) Indicates whether the value is inherited from the base rate. Markets included or excluded. Do not send if the rate is available for all markets. Only informative. The derived value. Included markets. Excluded markets. isInherit * (Boolean) Indicates whether the value is inherited from the base rate. Rate rule for the derived rate. The derived value.
Possible values: isInherit * (Boolean) Indicates whether the value is inherited from the base rate. Senior rule for the derived rate. The derived value.
Possible values: isInherit * (Boolean) Indicates whether the value is inherited from the base rate. Cancel policies associated with the derived rate. The derived value. Defines the base cancel policies. Only Informative. refundable * (Boolean) Indicates if the rate is refundable. List of penalties applicable for the rate. See CancelPenalty. daysBeforeArrival * (Int) Number of days prior to arrival day in which this Cancellation policy applies. penaltyType * (PenaltyType) Penalty type. See PenaltyType.
Possible values: value * (Float) Penalty value. This defines a calendar of cancel policies, serving as informational data. If base cancel policies exist for a particular day, the CancelPoliciesByDate take precedence. start * (DateTime) Start date where the cancel policy must apply. end * (DateTime) End date where the cancel policy must apply. cancelPolicy * (InventoryCancelPolicy) Cancel policy. See CancelPolicy. refundable * (Boolean) Indicates if the rate is refundable. List of penalties applicable for the rate. See CancelPenalty. daysBeforeArrival * (Int) Number of days prior to arrival day in which this Cancellation policy applies. penaltyType * (PenaltyType) Penalty type. See PenaltyType.
Possible values: value * (Float) Penalty value. isInherit * (Boolean) Indicates whether the value is inherited from the base rate. Surcharges inherited from the base rate. chargeType * (InventoryChargeType) Indicates if the surcharge is included or not in the price.
Possible values: taxType * (InventoryTaxType) The type of tax applied to the surcharge.
Possible values: value * (Float) The value of the surcharge. applyType * (InventoryApplyType) The type of application for the surcharge.
Possible values: perNight * (Boolean) Indicates whether the surcharge is applied per night. perPax * (Boolean) Indicates whether the surcharge is applied per person. inheritAllRoomsBaseRate * (Boolean) Indicates whether all rooms are inherited from the base rate for the derived rate.
If true, all rooms from the base rate are inherited. If false, only specific rooms are associated with the derived rate. Rooms associated with the derived rate. Code associated with the room. Master of the room. id * (Int) Id associated with the room master. Code associated with the room. Name associated with the room. active * (Boolean) Indicates whether the room is active. External code associated with the room. standard * (Int) Standard of the room. Typically the number of guests. uses * (InventoryRoomUse) List of uses associated with the room. numberOfGuests * (Int) Gets or sets the number of guests allowed in the room. minAge * (Int) Gets or sets the minimum age allowed for guests in the room. maxAge * (Int) Gets or sets the maximum age allowed for guests in the room. paxType * (InventoryPaxType) Gets or sets the type of guests allowed in the room.
PaxType
Possible values: informBaseRate * (Boolean) Indicates if the base rate code has to be sent to the supplier instead of the derived rate code. inheritMealPlanSupplements * (Boolean) Indicates whether to inherit meal plan supplements from the base rate.code(String)
name(String)
mealPlanIncluded(InventoryDerivedInt)
value(Int)
baseCode(String)
inheritedAgePolicies(InventoryAgePolicies)
paymentPolicies(InventoryDerivedPaymentPolicies)
acceptedPayments(InventoryDerivedAcceptedPayments)
value(AcceptedPayment)
MERCHANT: Payment is managed by the supplier.DIRECT: Payment is made directly to the actual payee (e.g., the hotel), without involving an intermediary or third party. The payment will be completed at check-in.CARD_BOOKING: Payment is managed by the supplier. The payment is effectuated at the time of booking.CARD_CHECK_IN: Payment is managed by the supplier and is made at the hotel during check-in.cardTypes(PaymentCardType)
VI: VisaAX: American ExpressBC: BC CardCA: MasterCardCB: Carte BlancheCU: China Union PayDS: DiscoverDC: Diners ClubT: Carta SiR: Carte BleueN: DankortL: DeltaE: ElectronJC: Japan Credit BureauTO: MaestroS: SwitchEC: Electronic CashEU: EuroCardTP: universal air travel cardOP: optimaER: Air Canada/RnRouteXS: accessO: othersbookingRules(InventoryDerivedBookingRules)
bookingWindow(InventoryDerivedBookingWindow)
value(InventoryBookingWindow)
markets(InventoryDerivedMarkets)
value(InventoryMarkets)
included(String)
excluded(String)
rateRule(InventoryDerivedRateRule)
value(RatePlanType)
NO_RATE_PLAN_TYPELARGE_FAMILYPUBLIC_SERVANTNEGOTIATEDPACKAGECANARY_RESIDENTBALEARIC_RESIDENTHONEY_MOONseniorRule(InventoryDerivedSeniorRule)
value(SeniorRate)
NO_SENIOR_RATESENIOR_RATE_55SENIOR_RATE_60SENIOR_RATE_65cancelPolicies(InventoryDerivedCancelPoliciesRate)
value(InventoryCancelPoliciesRate)
baseCancelPolicy(InventoryCancelPolicy)
cancelPenalties(InventoryCancelPenalty)
AMOUNTNIGHTSPERCENTAGEcancelPoliciesByDate(InventoryCancelPolicyByDate)
cancelPenalties(InventoryCancelPenalty)
AMOUNTNIGHTSPERCENTAGEinheritedSurcharges(InventorySurcharge)
INCLUDEDEXCLUDEDCITY: The tax is a city tax.LOCAL: The tax is a local tax.RESORT_FEE: The tax is a resort fee.SUPPLEMENT_TO_BE_PAID_ON_SPOT: The tax is a supplement to be paid on spot.PERCENTAGE: The rate is applied as a percentage.AMOUNT: The rate is applied as an amount.rooms(InventoryRoomSetUp)
code(String)
master(InventoryMasterRoom)
code(String)
name(String)
externalCode(String)
INFANT: Represents an infant guest.CHILD: Represents a child guest.ADULT: Represents an adult guest.
success * (Boolean)
Indicates whether the operation was successful based on the absence of advise messages.