Auto-Suggestions
An AUTO_SUGGESTIONS request returns results—both suggested search terms and products—as the customer types each character in their search term. Therefore, a Personalized Search API call is made each time the customer types a new character. Personalized Search is both typo-tolerant and word order–toleratant, so it's able to return suggestions even when the customer misspells one or more words (for example, headlites instead of headlights) or puts the words of a search term in an unusual order (for example, chairs outdoor instead of outdoor chairs).
The recommended interval to wait between auto-suggestions request calls is 250 ms on key presses and 30 ms on focus.
In addition to suggesting search terms as the customer types, Personalized Search can suggest products within the auto-suggestions results. To use this function, add the recordQueries object to the request, with the value of its typeOfRequest parameter defined as "SEARCH".
Here's an example of an auto-suggestions request to include products in the results:
Refer to the recordQueries definition in Personalized Site Search Query Request for more information about its required and optional parameters.