To ensure that the Advanced Personalization feature can understand each user’s journey and continuously improve their personalization experience, attach a user token to each query.
The user tokens attached to the queries must match the user tokens sent with events.
This feature isn’t available on every plan. Refer to your pricing plan to see if it’s included.
Attach user tokens with InstantSearch
To include the userToken in your search queries using InstantSearch, use the configure widget to set the userToken search parameter.
response,err:=client.SearchSingleIndex(client.NewApiSearchSingleIndexRequest("ALGOLIA_INDEX_NAME").WithSearchParams(search.SearchParamsObjectAsSearchParams(search.NewEmptySearchParamsObject().SetQuery("query").SetUserToken("user-1234"))))iferr!=nil{// handle the eventual errorpanic(err)}
Now that you’ve prepared your index structure, event implementation and search implementation, Advanced Personalization can build a holistic view of each user’s journey and personalize search results accordingly.