Examples
Below are some common uses of modifying the query request. You can find guides for more elaborate customizations within the How-To section of the Template JS documentation.
Please review : The Modify Request Overview for complete details on the syntax used for modifying the outgoing query.
Increase the default maximum number of filter options (10) to "20" for every query.
API Parameter | Description |
---|---|
options.limit | Specify the maximum number of options to be included per filter. |
See : Klevu API documentation on Retrieving Filters for more details and options
Influence the relevancy algorithm by assigning weight to different aspects at the time of query.
API Parameter | Description |
---|---|
boost | Query-level aspects to influence the relevancy rankings |
See : Klevu API Personalisation for more details and more options
You can add a groupCondition to restrict the result set to specific attributes and values. This constraint is typically applied "behind the scenes" to create specialized result set experiences.
Some examples include:
- Brand specific listings
- Curated landing pages
- Automotive fitment
API Parameter | Description |
---|---|
groupOperator | Defines the condition of filtering (ALL_OF, ANY_OF, NONE_OF) |
conditions | The array of attributes (key) to apply to the condition |
See : Klevu API Advance Filtering for more details and more options