Popular Searches

The selection made in the KMC for whether to display popular searches will no longer have any effect on the frontend with Klevu JS Library. It is up to you to determine whether to include popular searches and how to display them.

There is currently no method via our API to retrieve popular searches for your search instance. However, a static JS file is refreshed at regular intervals containing this information should you wish to consume it, via the following URL: https://js.klevu.com/klevu-js-v1/klevu-js-api/{JS_API_KEY}.js, for example:

The inclusions and exclusions specified within the KMC will also be respected within this generated JS file.

Should you wish to include popular searches in your quick search, you can follow the same example included in our Hello World tutorial which includes auto-suggestions, page and category suggestions.