Events always occur on a page view, so you must pass the associated page view pixel information together with the event pixel.

If you have an auto-suggest feature in your search form, when a user clicks on a search suggestion, BloomReach expects a Search Suggest Event to fire.  The information captured in a suggest event persists until the next page load happens (deferred) and the next Page View pixel is fired. E.g. if the search leads to a Search Results Page, the [Search Page View Pixel](🔗) will send the Suggest Event information to Bloomreach. 

To get started, follow the steps given below:

1\. Copy and paste the **Suggest Event Tracking Snippet** and install on all of your search suggestions.  2\. Map the search and suggest event variables in the tracking snippet. 3\. Make sure to review the implementation scenarios to ensure that the search event data are sent to Bloomreach

**Suggest Event Tracking Snippet**

Scenario: User types "wo" in the Search Box and then clicks on the auto-suggested term "woven scarf"



**Suggest Event Variables**

Column Title
Column Title
Column Title
Column Title
**Variable****Type****Example****Description**
aqStringVariable Example: woThe display query (the one or more letters) that the user has actually typed.  <br>This is NOT the suggested word or phrase.
qStringVariable Example: woven scarfUser's typed search query submitted to search box
catalogsArray of ObjectsVariable Example: woven scarf<br><br>"name" : "example_products"Specific catalog for which the suggestion was chosen. <br><br>Example: If you have text suggestions for Product and text suggestions for Content, then you will send the name of the catalog that those text suggestions belongs to (e.g. if a suggestion is picked from product text suggest then you'd send "example\_products", otherwise "example\_content")

**Implementation Scenarios**

Please review each of the following scenarios and implement as it applies to your site.

ScenarioExample
User types "wo " in Search Box and clicks on the auto-suggested term "woven scarf".  <br> <br>The search result is displayed on a Search Results Page.Implement the Suggest Event Code on the Suggest click. <br> <br>The [Search Page View Pixel](🔗) that fires on the Search Results Page will automatically send the information captured in the Suggest Event to Bloomreach. <br>Make sure that the Suggest Event Pixel fires before the Search Page View Pixel.
User enters an exact product name (or product ID)  in the Search Bar. A product suggestions comes up and the user clicks on the Product Suggestions. <br> <br>The search redirects to a Product Page.The system appends the attribute **\_br_psugg_q={search term}** to the URL of the Product Page of the clicked suggestion. The [Product Page View Pixel](🔗) that fires on the Product Page will capture this information to tag and track product suggestion sessions. More information about this process can be found in the [Autosuggest API reference](🔗).
User enters an exact category name (or cat ID)  in the Search Bar. A category suggestion comes up and the user clicks on the Category Suggestion. <br> <br>The search redirects to a Category Page.Implement the Suggest Event Code on the Suggest click. <br> <br>The [Category Page View Pixel](🔗) that fires on the Category Page will automatically send the information captured in the Search Event to Bloomreach.  <br>Make sure that the Search Event Pixel fires before the Category Page View Pixel.

### Native App Implementation

Discovery SDKs

For details on using the Discovery [Android](🔗) and [iOS](🔗) SDKs for specific Native App Implementation, refer to their respective linked guides.

You can include the [Global View variables](🔗) and the following variables.

  • type

  • aq (see above)

  • q (see above)

  • group

  • etype

NameVariableExampleDescription
Tracking Typetype
The type of tracking fire. For events, type=event
Group Typegroup
Specifies the event grouping. Must not be empty.<br><br>For suggest events, group=suggest
Event Action Typeetype
Specifies the event's action type. Must not be empty.<br><br>For suggest events, etype=click

Example requests: