1. Help Center Home
  2. Buying on TravelgateX
  3. Hotel-X Development/Booking Flow: Search

How to limit and filter options through Business Rules

Business Rules for Efficient Option Filtering

What are the business rules that I can incorporate into my requests?💡

  1. CHEAPER_AMOUNT: The cheapest options is returned without exceeding the optionsQuota limit.
  2. ROOM_TYPE: It groups the option by room type without exceeding the optionsQuota limit.

The optionsQuota makes reference to the maximum number of options per mealplan returned in search response.

How can I set up business rules in my requests?🛠️

To configure business rules in your Search Query, simply include the BusinessRulesInput in your request settings:
 

Additional considerations on Business Rules✔️

Please note that we filter options by utilizing a limited combination of room types:

  1. Initially, we group options with the same room type/classification together. For instance, you may receive options like Standard-Standard-Standard-Standard or Junior-Junior-Junior-Junior.
  2. Subsequently, we combine the cheapest rooms with the remaining ones, ensuring that duplicates are checked and the options do not exceed the specified optionsQuota limit.

If a Buyer specifies a businessRules value, it will be implemented when the number of returned options surpasses the optionsQuota. However, if the Buyer does not provide any businessRules values, the default businessRules of CheaperAmount will be applied.

 

NOTE:

You can also configure your own Business Rules implementing our Aggregation plugin.  More information on Business Rules on our API Schema Documentation.

Have any doubts or questions? Don't hesitate to get in touch with our amazing Customer Care team via Tickets and they'll be happy to assist you⭐🚀