Hotels offer specific discounts based on time range from booking to arrival, based on booked length of stay or other criteria.
This function returns required data to determine discounts.
Parameters
Sample request
<request>
<login>user_login</login>
<password>password</password>
<hotId>hotId</hotId>
</request>
Output
<priceActions> [1] |
|
|
<actionPrices> [1] |
|
|
<actionPrice> [0..*] |
|
|
<id> [1] |
Discount ID |
<discountRateType> [1] |
Discount rate type (percent - discount is set in "discountRate", absolute amount in currency - discount is set in "discountRateAbs")
'per' | 'abs'
|
<discountRate> [1] |
Discount in % (negative number - surcharge) |
<discountRateAbs> [1] |
Discount as absolute amount |
|
|
<actionFrom> |
Valid from |
<actionTo> |
Valid until |
<objectKinds> |
Valid for these object kinds (if empty, discount is valid for all object kinds) |
|
|
<weekDays> |
Valid for these week days (if empty, discount is valid for all week days) |
|
<weekDay> [0..7] |
Week day
'sun' | 'mon' | 'tue' | 'wed' | 'thu' | 'fri' | 'sat'
|
|
<combineActionPrice> [1] |
Combine action price with other discount / surcharge
true / false
|
<combineActionPriceOnlyWithSurcharge> [1] |
Combine action price only with other surcharge (do not combine action price with discounts)
true / false
|
|
|
|
|
<firstMinutes> [1] |
|
|
<firstMinute> [0..*] |
|
|
<id> [1] |
Discount ID |
<minNumOfDaysBeforeArrival> [1] |
Minimum number of days booked before arrival to receive the discount |
<discountRateType> [1] |
Discount rate type (percent - discount is set in "discountRate", absolute amount in currency - discount is set in "discountRateAbs")
'per' | 'abs'
|
<discountRate> [1] |
Discount in % (negative number - surcharge) |
<discountRateAbs> [1] |
Discount as absolute amount |
|
|
<actionFrom> |
Valid from |
<actionTo> |
Valid until |
<objectKinds> |
Valid for these object kinds (if empty, discount is valid for all object kinds) |
|
|
<weekDays> |
Valid for these week days (if empty, discount is valid for all week days) |
|
<weekDay> [0..7] |
Week day
'sun' | 'mon' | 'tue' | 'wed' | 'thu' | 'fri' | 'sat'
|
|
|
|
|
|
<lastMinutes> [1] |
|
|
<lastMinute> [0..*] |
|
|
<id> [1] |
Discount ID |
<maxNumOfHoursBeforeArrival> [1] |
Maximum number of hours booked before arrival to receive the discount |
<discountRateType> [1] |
Discount rate type (percent - discount is set in "discountRate", absolute amount in currency - discount is set in "discountRateAbs")
'per' | 'abs'
|
<discountRate> [1] |
Discount in % (negative number - surcharge) |
<discountRateAbs> [1] |
Discount as absolute amount |
|
|
<actionFrom> |
Valid from |
<actionTo> |
Valid until |
<objectKinds> |
Valid for these object kinds (if empty, discount is valid for all object kinds) |
|
|
<weekDays> |
Valid for these week days (if empty, discount is valid for all week days) |
|
<weekDay> [0..7] |
Week day
'sun' | 'mon' | 'tue' | 'wed' | 'thu' | 'fri' | 'sat'
|
|
|
|
|
|
<longTerms> [1] |
|
|
<longTerm> [0..*] |
|
|
<id> [1] |
Discount ID |
<minNumOfNights> [1] |
Minimum number of nights booked to receive the discount |
<discountRateType> [1] |
Discount rate type (percent - discount is set in "discountRate", absolute amount in currency - discount is set in "discountRateAbs")
'per' | 'abs'
|
<discountRate> [1] |
Discount in % (negative number - surcharge) |
<discountRateAbs> [1] |
Discount as absolute amount |
|
|
<actionFrom> |
Valid from |
<actionTo> |
Valid until |
<objectKinds> |
Valid for these object kinds (if empty, discount is valid for all object kinds) |
|
|
<weekDays> |
Valid for these week days (if empty, discount is valid for all week days) |
|
<weekDay> [0..7] |
Week day
'sun' | 'mon' | 'tue' | 'wed' | 'thu' | 'fri' | 'sat'
|
|
|
|
|
Samlpe output
<priceActions>
<actionPrices>
<actionPrice>
<id>1550</id>
<discountRateType>per</discountRateType>
<discountRate>20</discountRate>
<actionFrom>2017-10-12</actionFrom>
<actionTo>2017-10-22</actionFrom>
<objectKinds>
<objectKind>
<obkId>1234567</obkId>
</objectKind>
</objectKinds>
<weekDays>
<weekDay>mon</weekDay>
<weekDay>tue</weekDay>
<weekDay>wed</weekDay>
</weekDays>
<combineActionPrice>true</combineActionPrice>
<combineActionPriceOnlyWithSurcharge>false</combineActionPriceOnlyWithSurcharge>
</actionPrice>
</actionPrices>
<firstMinutes>
<firstMinute>
<id>1991</id>
<minNumOfDaysBeforeArrival>10</minNumOfDaysBeforeArrival>
<discountRateType>per</discountRateType>
<discountRate>20</discountRate>
<actionFrom>2017-10-12</actionFrom>
<actionTo>2017-10-22</actionFrom>
<objectKinds>
<objectKind>
<obkId>1234567</obkId>
</objectKind>
</objectKinds>
<weekDays>
<weekDay>mon</weekDay>
<weekDay>tue</weekDay>
<weekDay>wed</weekDay>
</weekDays>
</firstMinute>
</firstMinutes>
<lastMinutes>
<lastMinute>
<id>5111</id>
<maxNumOfHoursBeforeArrival>24</maxNumOfHoursBeforeArrival>
<discountRateType>per</discountRateType>
<discountRate>15</discountRate>
<actionFrom/>
<actionTo>2017-10-22</actionFrom>
<objectKinds>
<objectKind>
<obkId>3434343</obkId>
</objectKind>
<objectKind>
<obkId>4444444</obkId>
</objectKind>
</objectKinds>
<weekDays/>
</lastMinute>
</lastMinutes>
<longTerms>
<longTerm>
<id>13096</id>
<minNumOfNights>1</minNumOfNights>
<discountRateType>abs</discountRateType>
<discountRate>0</discountRate>
<discountRateAbs>
<discountRate>
<curId>1</curId>
<rate>600</rate>
</discountRate>
<discountRate>
<curId>2</curId>
<rate>25</rate>
</discountRate>
</discountRateAbs>
<actionFrom>2017-10-12</actionFrom>
<actionTo/>
<objectKinds/>
<weekDays/>
</longTerm>
</longTerms>
</priceActions>