Description
The Algolia dashboard's Analytics tab shows "No tracked searches" for Click-through Rate, Conversion Rate, and No Clicks Rate. No click tracking implementation (search-insights, clickAnalytics, queryID) exists anywhere in this codebase currently.
Without click events, there's no way to measure whether search results are actually useful to users (CTR, conversion, no-clicks rate), which makes it impossible to data-drive any future Algolia ranking/Rules tuning.
Changes needed (frontend)
- Add Algolia's official
search-insights library.
- When a user clicks a search result, send a click event including:
queryID (returned by the backend search API — see backend follow-up below), the result's Algolia objectID, and its position in the result list.
- Initialize
search-insights with the same Algolia App ID / Search API key used for search.
Dependency
Backend needs to surface queryID and each hit's objectID in the /api/v1/heritages/search response first — tracked in zigzagdev/world-heritage-api#486.
Acceptance Criteria
Description
The Algolia dashboard's Analytics tab shows "No tracked searches" for Click-through Rate, Conversion Rate, and No Clicks Rate. No click tracking implementation (
search-insights,clickAnalytics,queryID) exists anywhere in this codebase currently.Without click events, there's no way to measure whether search results are actually useful to users (CTR, conversion, no-clicks rate), which makes it impossible to data-drive any future Algolia ranking/Rules tuning.
Changes needed (frontend)
search-insightslibrary.queryID(returned by the backend search API — see backend follow-up below), the result's AlgoliaobjectID, and its position in the result list.search-insightswith the same Algolia App ID / Search API key used for search.Dependency
Backend needs to surface
queryIDand each hit'sobjectIDin the/api/v1/heritages/searchresponse first — tracked in zigzagdev/world-heritage-api#486.Acceptance Criteria