coveo.analytics 2.30.56 → 2.32.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (84) hide show
  1. package/README.md +37 -43
  2. package/dist/browser.mjs +513 -357
  3. package/dist/coveoua.browser.js +1 -1
  4. package/dist/coveoua.browser.js.map +1 -1
  5. package/dist/coveoua.debug.js +542 -359
  6. package/dist/coveoua.debug.js.map +1 -1
  7. package/dist/coveoua.js +1 -1
  8. package/dist/coveoua.js.map +1 -1
  9. package/dist/definitions/client/analytics.d.ts +3 -2
  10. package/dist/definitions/client/runtimeEnvironment.d.ts +1 -1
  11. package/dist/definitions/donottrack.d.ts +1 -0
  12. package/dist/definitions/react-native/index.d.ts +1 -2
  13. package/dist/definitions/version.d.ts +1 -1
  14. package/dist/library.cjs +15350 -3699
  15. package/dist/library.es.js +513 -357
  16. package/dist/library.js +15350 -3699
  17. package/dist/library.mjs +15350 -3699
  18. package/dist/react-native.es.js +634 -460
  19. package/modules/package.json +9 -9
  20. package/package.json +60 -91
  21. package/react-native/package.json +7 -7
  22. package/src/caseAssist/caseAssistActions.ts +51 -50
  23. package/src/caseAssist/caseAssistClient.spec.ts +328 -297
  24. package/src/caseAssist/caseAssistClient.ts +201 -185
  25. package/src/client/analytics.spec.ts +724 -703
  26. package/src/client/analytics.ts +677 -602
  27. package/src/client/analyticsBeaconClient.spec.ts +195 -188
  28. package/src/client/analyticsBeaconClient.ts +99 -88
  29. package/src/client/analyticsFetchClient.ts +77 -61
  30. package/src/client/analyticsRequestClient.ts +17 -17
  31. package/src/client/location.ts +3 -3
  32. package/src/client/measurementProtocolMapper.ts +54 -45
  33. package/src/client/measurementProtocolMapping/baseMeasurementProtocolMapper.ts +48 -44
  34. package/src/client/measurementProtocolMapping/commerceMeasurementProtocolMapper.ts +133 -121
  35. package/src/client/measurementProtocolMapping/serviceMeasurementProtocolMapper.ts +17 -17
  36. package/src/client/noopAnalytics.ts +80 -68
  37. package/src/client/runtimeEnvironment.ts +50 -41
  38. package/src/client/utils.spec.ts +112 -97
  39. package/src/client/utils.ts +39 -39
  40. package/src/cookieutils.spec.ts +59 -0
  41. package/src/cookieutils.ts +40 -39
  42. package/src/coveoua/browser.ts +14 -12
  43. package/src/coveoua/library.ts +4 -4
  44. package/src/coveoua/plugins.ts +36 -34
  45. package/src/coveoua/simpleanalytics.spec.ts +467 -452
  46. package/src/coveoua/simpleanalytics.ts +146 -140
  47. package/src/detector.ts +17 -17
  48. package/src/donottrack.spec.ts +199 -121
  49. package/src/donottrack.ts +31 -8
  50. package/src/events.ts +86 -79
  51. package/src/formatting/format-array-for-coveo-custom-data.spec.ts +13 -12
  52. package/src/formatting/format-array-for-coveo-custom-data.ts +18 -18
  53. package/src/formatting/format-omnibox-metadata.ts +16 -12
  54. package/src/history.spec.ts +197 -195
  55. package/src/history.ts +143 -133
  56. package/src/hook/addDefaultValues.ts +13 -8
  57. package/src/hook/enhanceViewEvent.ts +17 -17
  58. package/src/insight/insightClient.spec.ts +1848 -1717
  59. package/src/insight/insightClient.ts +866 -761
  60. package/src/insight/insightEvents.ts +57 -56
  61. package/src/plugins/BasePlugin.ts +125 -121
  62. package/src/plugins/ec.spec.ts +457 -429
  63. package/src/plugins/ec.ts +202 -199
  64. package/src/plugins/link.spec.ts +183 -159
  65. package/src/plugins/link.ts +88 -85
  66. package/src/plugins/svc.spec.ts +161 -155
  67. package/src/plugins/svc.ts +93 -91
  68. package/src/react-native/index.ts +8 -1
  69. package/src/react-native/react-native-runtime.ts +33 -33
  70. package/src/react-native/react-native-utils.ts +1 -1
  71. package/src/react-native/react-native.spec.ts +31 -21
  72. package/src/searchPage/searchPageClient.spec.ts +1944 -1794
  73. package/src/searchPage/searchPageClient.ts +1261 -1040
  74. package/src/searchPage/searchPageEvents.ts +524 -511
  75. package/src/storage.spec.ts +51 -51
  76. package/src/storage.ts +47 -47
  77. package/dist/definitions/bundle/browser-fetch.d.ts +0 -1
  78. package/dist/definitions/src/coveoua/browser.d.ts +0 -6
  79. package/dist/definitions/src/coveoua/headless.d.ts +0 -6
  80. package/dist/definitions/src/coveoua/library.d.ts +0 -17
  81. package/dist/definitions/src/coveoua/plugins.d.ts +0 -10
  82. package/dist/definitions/src/coveoua/simpleanalytics.d.ts +0 -33
  83. package/dist/definitions/src/react-native/index.d.ts +0 -3
  84. package/dist/definitions/src/react-native/react-native-runtime.d.ts +0 -19
@@ -2,645 +2,658 @@ import {DocumentInformation, FacetStateRequest} from '../events';
2
2
  import {InsightEvents} from '../insight/insightEvents';
3
3
 
4
4
  export enum SearchPageEvents {
5
- /**
6
- * Identifies the search event that gets logged when the initial query is performed as a result of loading a search interface.
7
- */
8
- interfaceLoad = 'interfaceLoad',
9
- /**
10
- * Identifies the search event that gets logged when a new tab is selected in the search interface.
11
- */
12
- interfaceChange = 'interfaceChange',
13
- /**
14
- * Identifies the search event that gets logged when `enableAutoCorrection: true` and the query is automatically corrected.
15
- */
16
- didyoumeanAutomatic = 'didyoumeanAutomatic',
17
- /**
18
- * Identifies the search event that gets logged when the query suggestion with the corrected term is selected and successfully updates the query.
19
- */
20
- didyoumeanClick = 'didyoumeanClick',
21
- /**
22
- * Identifies the search event that gets logged when a sorting method is selected.
23
- */
24
- resultsSort = 'resultsSort',
25
- /**
26
- * Identifies the search event that gets logged when a submit button is selected on a search box.
27
- */
28
- searchboxSubmit = 'searchboxSubmit',
29
- /**
30
- * Identifies the search event that gets logged when a clear button is selected on a search box.
31
- */
32
- searchboxClear = 'searchboxClear',
33
- /**
34
- * The search-as-you-type event that gets logged when a query is automatically generated, and results are displayed while a user is entering text in the search box before they voluntarily submit the query.
35
- */
36
- searchboxAsYouType = 'searchboxAsYouType',
37
- /**
38
- * The event that gets logged when a breadcrumb facet is selected and the query is updated.
39
- */
40
- breadcrumbFacet = 'breadcrumbFacet',
41
- /**
42
- * Identifies the search event that gets logged when the event to clear the current breadcrumbs is triggered.
43
- */
44
- breadcrumbResetAll = 'breadcrumbResetAll',
45
- /**
46
- * Identifies the click event that gets logged when the Quick View element is selected and a Quick View modal of the document is displayed.
47
- */
48
- documentQuickview = 'documentQuickview',
49
- /**
50
- * Identifies the click event that gets logged when a user clicks on a search result to open an item.
51
- */
52
- documentOpen = 'documentOpen',
53
- /**
54
- * Identifies the search event that gets logged when a user clicks a query suggestion based on the usage analytics recorded queries.
55
- */
56
- omniboxAnalytics = 'omniboxAnalytics',
57
- /**
58
- * Identifies the search event that gets logged when a suggested search query is selected from a standalone searchbox.
59
- */
60
- omniboxFromLink = 'omniboxFromLink',
61
- /**
62
- * Identifies the search event that gets logged when the search page loads with a query, such as when a user clicks a link pointing to a search results page with a query or enters a query in a standalone search box that points to a search page.
63
- */
64
- searchFromLink = 'searchFromLink',
65
- /**
66
- * Identifies the custom event that gets logged when a user action triggers a notification set in the effective query pipeline on the search page.
67
- */
68
- triggerNotify = 'notify',
69
- /**
70
- * Identifies the custom event that gets logged when a user action executes a JavaScript function set in the effective query pipeline on the search page.
71
- */
72
- triggerExecute = 'execute',
73
- /**
74
- * Identifies the custom event that gets logged when a user action triggers a new query set in the effective query pipeline on the search page.
75
- */
76
- triggerQuery = 'query',
77
- /**
78
- * Identifies the custom event that gets logged when a user undoes a query set in the effective query pipeline on the search page.
79
- */
80
- undoTriggerQuery = 'undoQuery',
81
- /**
82
- * Identifies the custom event that gets logged when a user action redirects them to a URL set in the effective query pipeline on the search page.
83
- */
84
- triggerRedirect = 'redirect',
85
- /**
86
- * Identifies the custom event that gets logged when the Results per page component is selected.
87
- */
88
- pagerResize = 'pagerResize',
89
- /**
90
- * Identifies the custom event that gets logged when a page number is selected and more items are loaded.
91
- */
92
- pagerNumber = 'pagerNumber',
93
- /**
94
- * Identifies the custom event that gets logged when the Next Page link is selected and more items are loaded.
95
- */
96
- pagerNext = 'pagerNext',
97
- /**
98
- * Identifies the custom event that gets logged when the Previous Page link is selected and more items are loaded.
99
- */
100
- pagerPrevious = 'pagerPrevious',
101
- /**
102
- * Identifies the custom event that gets logged when the user scrolls to the bottom of the item page and more results are loaded.
103
- */
104
- pagerScrolling = 'pagerScrolling',
105
- /**
106
- * Identifies the search event that gets logged when the clearing all selected values of a static filter.
107
- */
108
- staticFilterClearAll = 'staticFilterClearAll',
109
- /**
110
- * Identifies the search event that gets logged when a static filter check box is selected and the query is updated.
111
- */
112
- staticFilterSelect = 'staticFilterSelect',
113
- /**
114
- * Identifies the search event that gets logged when a static filter check box is deselected and the query is updated.
115
- */
116
- staticFilterDeselect = 'staticFilterDeselect',
117
- /**
118
- * Identifies the search event that gets logged when the Clear Facet button is selected.
119
- */
120
- facetClearAll = 'facetClearAll',
121
- /**
122
- * Identifies the custom event that gets logged when a query is being typed into the facet search box.
123
- */
124
- facetSearch = 'facetSearch',
125
- /**
126
- * Identifies the search event that gets logged when a facet check box is selected and the query is updated.
127
- */
128
- facetSelect = 'facetSelect',
129
- /**
130
- * Identifies the search event that gets logged when all filters on a facet are selected.
131
- */
132
- facetSelectAll = 'facetSelectAll',
133
- /**
134
- * Identifies the search event that gets logged when a facet check box is deselected and the query is updated.
135
- */
136
- facetDeselect = 'facetDeselect',
137
- /**
138
- * Identifies the search event that gets logged when a user clicks a facet value to filter out results containing the facet value.
139
- */
140
- facetExclude = 'facetExclude',
141
- /**
142
- * Identifies the search event that gets logged when a user clicks a facet value to not filter out results containing the facet value.
143
- */
144
- facetUnexclude = 'facetUnexclude',
145
- /**
146
- * Identifies the search event that gets logged when the sort criteria on a facet is updated.
147
- */
148
- facetUpdateSort = 'facetUpdateSort',
149
- /**
150
- * The custom event that gets logged when an end-user expands a facet to see additional values.
151
- */
152
- facetShowMore = 'showMoreFacetResults',
153
- /**
154
- * The custom event that gets logged when an end-user collapses a facet to see less values.
155
- */
156
- facetShowLess = 'showLessFacetResults',
157
- /**
158
- * Identifies the custom event that gets logged when a user query encounters an error during execution.
159
- */
160
- queryError = 'query',
161
- /**
162
- * Identifies the search and custom event that gets logged when a user clicks the Go Back link after an error page.
163
- */
164
- queryErrorBack = 'errorBack',
165
- /**
166
- * Identifies the search and custom event that gets logged when a user clears the query box after an error page.
167
- */
168
- queryErrorClear = 'errorClearQuery',
169
- /**
170
- * Identifies the search and custom event that gets logged when a user clicks the Retry link after an error page.
171
- */
172
- queryErrorRetry = 'errorRetry',
173
- /**
174
- * Identifies the custom event that gets logged when a user performs a query that returns recommendations in the Recommendations panel.
175
- */
176
- recommendation = 'recommendation',
177
- /**
178
- * Identifies the search event that gets logged when a user action (that is not a query) reloads the Recommendations panel with new recommendations.
179
- */
180
- recommendationInterfaceLoad = 'recommendationInterfaceLoad',
181
- /**
182
- * Identifies the click event that gets logged when a user clicks a recommendation in the Recommendations panel.
183
- */
184
- recommendationOpen = 'recommendationOpen',
185
- /**
186
- * Identifies the custom event that gets logged when a user identifies a smart snippet answer as relevant.
187
- */
188
- likeSmartSnippet = 'likeSmartSnippet',
189
- /**
190
- * Identifies the custom event that gets logged when a user identifies a smart snippet answer as irrelevant.
191
- */
192
- dislikeSmartSnippet = 'dislikeSmartSnippet',
193
- /**
194
- * Identifies the custom event that gets logged when a user expand a smart snippet answer.
195
- */
196
- expandSmartSnippet = 'expandSmartSnippet',
197
- /**
198
- * Identifies the custom event that gets logged when a user collapse a smart snippet answer.
199
- */
200
- collapseSmartSnippet = 'collapseSmartSnippet',
201
- /**
202
- * Identifies the custom event that gets logged when a user open a smart snippet explanation modal for feedback.
203
- */
204
- openSmartSnippetFeedbackModal = 'openSmartSnippetFeedbackModal',
205
- /**
206
- * Identifies the custom event that gets logged when a user close a smart snippet explanation modal for feedback.
207
- */
208
- closeSmartSnippetFeedbackModal = 'closeSmartSnippetFeedbackModal',
209
- /**
210
- * Identifies the custom event that gets logged when a user sends an explanation for a smart snippet irrelevant answer.
211
- */
212
- sendSmartSnippetReason = 'sendSmartSnippetReason',
213
- /**
214
- * Identifies the custom event that gets logged when a snippet suggestion for a related question is expanded.
215
- */
216
- expandSmartSnippetSuggestion = 'expandSmartSnippetSuggestion',
217
- /**
218
- * Identifies the custom event that gets logged when a snippet suggestion for a related question is collapsed.
219
- */
220
- collapseSmartSnippetSuggestion = 'collapseSmartSnippetSuggestion',
221
- /**
222
- * Identifies the custom event that gets logged when the user presses "show more" on a snippet suggestion for a related question.
223
- *
224
- * @deprecated
225
- */
226
- showMoreSmartSnippetSuggestion = 'showMoreSmartSnippetSuggestion',
227
- /**
228
- * Identifies the custom event that gets logged when the user presses "show less" on a snippet suggestion for a related question.
229
- *
230
- * @deprecated
231
- */
232
- showLessSmartSnippetSuggestion = 'showLessSmartSnippetSuggestion',
233
- /**
234
- * Identifies the custom event that gets logged when a user clicks on the source of an answer in a smart snippet.
235
- */
236
- openSmartSnippetSource = 'openSmartSnippetSource',
237
- /**
238
- * Identifies the custom event that gets logged when a user clicks on the source of a snippet suggestion for a related question.
239
- */
240
- openSmartSnippetSuggestionSource = 'openSmartSnippetSuggestionSource',
241
- /**
242
- * Identifies the custom event that gets logged when a user clicks on a link in the answer of a smart snippet.
243
- */
244
- openSmartSnippetInlineLink = 'openSmartSnippetInlineLink',
245
- /**
246
- * Identifies the custom event that gets logged when a user clicks on a link in the snippet suggestion for a related question.
247
- */
248
- openSmartSnippetSuggestionInlineLink = 'openSmartSnippetSuggestionInlineLink',
249
- /**
250
- * Identifies the search event that gets logged when a recent queries list item gets clicked.
251
- */
252
- recentQueryClick = 'recentQueriesClick',
253
- /**
254
- * Identifies the custom event that gets logged when a recent queries list gets cleared.
255
- */
256
- clearRecentQueries = 'clearRecentQueries',
257
- /**
258
- * Identifies the custom event that gets logged when a recently clicked results list item gets clicked.
259
- */
260
- recentResultClick = 'recentResultClick',
261
- /**
262
- * Identifies the custom event that gets logged when a recently clicked results list gets cleared.
263
- */
264
- clearRecentResults = 'clearRecentResults',
265
- /**
266
- * Identifies the search event that gets logged when a user clicks the Cancel last action link when no results are returned following their last action.
267
- */
268
- noResultsBack = 'noResultsBack',
269
- /**
270
- * Identifies the click event that gets logged when a user clicks the Show More link under a search result that support the folding component.
271
- */
272
- showMoreFoldedResults = 'showMoreFoldedResults',
273
- /**
274
- * Identifies the custom event that gets logged when a user clicks the Show Less link under a search result that support the folding component.
275
- */
276
- showLessFoldedResults = 'showLessFoldedResults',
277
- /**
278
- * Identifies the click event that gets logged when a user clicks the Copy To Clipboard result action.
279
- */
280
- copyToClipboard = 'copyToClipboard',
281
- /**
282
- * Identifies the click event that gets logged when a user clicks the Send As Email result action.
283
- */
284
- caseSendEmail = 'Case.SendEmail',
285
- /**
286
- * Identifies the click event that gets logged when a user clicks the Post To Feed result action.
287
- */
288
- feedItemTextPost = 'FeedItem.TextPost',
289
- /**
290
- * Identifies the click event that gets logged when a user clicks the Attach To Case result action.
291
- */
292
- caseAttach = 'caseAttach',
293
- /**
294
- * Identifies the custom event that gets logged when a user clicks the Detach From Case result action.
295
- */
296
- caseDetach = 'caseDetach',
297
- /**
298
- * Identifies the cause of a search request being retried in order to regenerate an answer stream that failed.
299
- */
300
- retryGeneratedAnswer = 'retryGeneratedAnswer',
301
- /**
302
- * Identifies the custom event that gets logged when a user identifies a generated answer as relevant.
303
- */
304
- likeGeneratedAnswer = 'likeGeneratedAnswer',
305
- /**
306
- * Identifies the custom event that gets logged when a user identifies a generated answer as irrelevant.
307
- */
308
- dislikeGeneratedAnswer = 'dislikeGeneratedAnswer',
309
- /**
310
- * Identifies the custom event that gets logged when a user opens a generated answer citation.
311
- */
312
- openGeneratedAnswerSource = 'openGeneratedAnswerSource',
313
- /**
314
- * Identifies the custom event that gets logged when a user clicks an inline link in a generated answer.
315
- */
316
- generatedAnswerOpenInlineLink = 'generatedAnswerOpenInlineLink',
317
- /**
318
- * Identified the custom event that gets logged when a generated answer stream is completed.
319
- */
320
- generatedAnswerStreamEnd = 'generatedAnswerStreamEnd',
321
- /**
322
- * Identifies the custom event that gets logged when a user hovers over a generated answer citation.
323
- */
324
- generatedAnswerSourceHover = 'generatedAnswerSourceHover',
325
- /**
326
- * Identifies the custom event that gets logged when a user clicks the copy to clip board button of a generated answer.
327
- */
328
- generatedAnswerCopyToClipboard = 'generatedAnswerCopyToClipboard',
329
- /**
330
- * Identifies the custom event that gets logged when a user deactivates the genQA feature.
331
- */
332
- generatedAnswerHideAnswers = 'generatedAnswerHideAnswers',
333
- /**
334
- * Identifies the custom event that gets logged when a user activates the genQA feature.
335
- */
336
- generatedAnswerShowAnswers = 'generatedAnswerShowAnswers',
337
- /**
338
- * Identifies the custom event that gets logged when a user expand a generated answer.
339
- */
340
- generatedAnswerExpand = 'generatedAnswerExpand',
341
- /**
342
- * Identifies the custom event that gets logged when a user collapse a generated answer.
343
- */
344
- generatedAnswerCollapse = 'generatedAnswerCollapse',
345
- /**
346
- * Identifies the custom event that gets logged when a user submits a feedback of a generated answer.
347
- */
348
- generatedAnswerFeedbackSubmit = 'generatedAnswerFeedbackSubmit',
349
- /**
350
- * Identifies the search event that gets logged when a user clicks the rephrase button in a generated answer.
351
- */
352
- rephraseGeneratedAnswer = 'rephraseGeneratedAnswer',
353
- /**
354
- * Identifies the new version of custom event that gets logged when a user submits a feedback of a generated answer.
355
- */
356
- generatedAnswerFeedbackSubmitV2 = 'generatedAnswerFeedbackSubmitV2',
357
- /**
358
- * Identifies the click event that gets logged when the user clicks on a generated answer citation.
359
- */
360
- generatedAnswerCitationClick = 'generatedAnswerCitationClick',
361
- /**
362
- * Identifies the custom event that gets logged when the user clicks on a generated answer citation.
363
- */
364
- generatedAnswerFollowupOpenSource = 'generatedAnswerFollowupOpenSource',
365
- /**
366
- * Identifies the click event that gets logged when a user clicks the Attach Citation action.
367
- */
368
- generatedAnswerCitationDocumentAttach = 'generatedAnswerCitationDocumentAttach',
5
+ /**
6
+ * Identifies the search event that gets logged when the initial query is performed as a result of loading a search interface.
7
+ */
8
+ interfaceLoad = 'interfaceLoad',
9
+ /**
10
+ * Identifies the search event that gets logged when a new tab is selected in the search interface.
11
+ */
12
+ interfaceChange = 'interfaceChange',
13
+ /**
14
+ * Identifies the search event that gets logged when `enableAutoCorrection: true` and the query is automatically corrected.
15
+ */
16
+ didyoumeanAutomatic = 'didyoumeanAutomatic',
17
+ /**
18
+ * Identifies the search event that gets logged when the query suggestion with the corrected term is selected and successfully updates the query.
19
+ */
20
+ didyoumeanClick = 'didyoumeanClick',
21
+ /**
22
+ * Identifies the search event that gets logged when a sorting method is selected.
23
+ */
24
+ resultsSort = 'resultsSort',
25
+ /**
26
+ * Identifies the search event that gets logged when a submit button is selected on a search box.
27
+ */
28
+ searchboxSubmit = 'searchboxSubmit',
29
+ /**
30
+ * Identifies the search event that gets logged when a clear button is selected on a search box.
31
+ */
32
+ searchboxClear = 'searchboxClear',
33
+ /**
34
+ * The search-as-you-type event that gets logged when a query is automatically generated, and results are displayed while a user is entering text in the search box before they voluntarily submit the query.
35
+ */
36
+ searchboxAsYouType = 'searchboxAsYouType',
37
+ /**
38
+ * The event that gets logged when a breadcrumb facet is selected and the query is updated.
39
+ */
40
+ breadcrumbFacet = 'breadcrumbFacet',
41
+ /**
42
+ * Identifies the search event that gets logged when the event to clear the current breadcrumbs is triggered.
43
+ */
44
+ breadcrumbResetAll = 'breadcrumbResetAll',
45
+ /**
46
+ * Identifies the click event that gets logged when the Quick View element is selected and a Quick View modal of the document is displayed.
47
+ */
48
+ documentQuickview = 'documentQuickview',
49
+ /**
50
+ * Identifies the click event that gets logged when a user clicks on a search result to open an item.
51
+ */
52
+ documentOpen = 'documentOpen',
53
+ /**
54
+ * Identifies the search event that gets logged when a user clicks a query suggestion based on the usage analytics recorded queries.
55
+ */
56
+ omniboxAnalytics = 'omniboxAnalytics',
57
+ /**
58
+ * Identifies the search event that gets logged when a suggested search query is selected from a standalone searchbox.
59
+ */
60
+ omniboxFromLink = 'omniboxFromLink',
61
+ /**
62
+ * Identifies the search event that gets logged when the search page loads with a query, such as when a user clicks a link pointing to a search results page with a query or enters a query in a standalone search box that points to a search page.
63
+ */
64
+ searchFromLink = 'searchFromLink',
65
+ /**
66
+ * Identifies the custom event that gets logged when a user action triggers a notification set in the effective query pipeline on the search page.
67
+ */
68
+ triggerNotify = 'notify',
69
+ /**
70
+ * Identifies the custom event that gets logged when a user action executes a JavaScript function set in the effective query pipeline on the search page.
71
+ */
72
+ triggerExecute = 'execute',
73
+ /**
74
+ * Identifies the custom event that gets logged when a user action triggers a new query set in the effective query pipeline on the search page.
75
+ */
76
+ // oxlint-disable-next-line typescript/no-duplicate-enum-values
77
+ triggerQuery = 'query',
78
+ /**
79
+ * Identifies the custom event that gets logged when a user undoes a query set in the effective query pipeline on the search page.
80
+ */
81
+ undoTriggerQuery = 'undoQuery',
82
+ /**
83
+ * Identifies the custom event that gets logged when a user action redirects them to a URL set in the effective query pipeline on the search page.
84
+ */
85
+ triggerRedirect = 'redirect',
86
+ /**
87
+ * Identifies the custom event that gets logged when the Results per page component is selected.
88
+ */
89
+ pagerResize = 'pagerResize',
90
+ /**
91
+ * Identifies the custom event that gets logged when a page number is selected and more items are loaded.
92
+ */
93
+ pagerNumber = 'pagerNumber',
94
+ /**
95
+ * Identifies the custom event that gets logged when the Next Page link is selected and more items are loaded.
96
+ */
97
+ pagerNext = 'pagerNext',
98
+ /**
99
+ * Identifies the custom event that gets logged when the Previous Page link is selected and more items are loaded.
100
+ */
101
+ pagerPrevious = 'pagerPrevious',
102
+ /**
103
+ * Identifies the custom event that gets logged when the user scrolls to the bottom of the item page and more results are loaded.
104
+ */
105
+ pagerScrolling = 'pagerScrolling',
106
+ /**
107
+ * Identifies the search event that gets logged when the clearing all selected values of a static filter.
108
+ */
109
+ staticFilterClearAll = 'staticFilterClearAll',
110
+ /**
111
+ * Identifies the search event that gets logged when a static filter check box is selected and the query is updated.
112
+ */
113
+ staticFilterSelect = 'staticFilterSelect',
114
+ /**
115
+ * Identifies the search event that gets logged when a static filter check box is deselected and the query is updated.
116
+ */
117
+ staticFilterDeselect = 'staticFilterDeselect',
118
+ /**
119
+ * Identifies the search event that gets logged when the Clear Facet button is selected.
120
+ */
121
+ facetClearAll = 'facetClearAll',
122
+ /**
123
+ * Identifies the custom event that gets logged when a query is being typed into the facet search box.
124
+ */
125
+ facetSearch = 'facetSearch',
126
+ /**
127
+ * Identifies the search event that gets logged when a facet check box is selected and the query is updated.
128
+ */
129
+ facetSelect = 'facetSelect',
130
+ /**
131
+ * Identifies the search event that gets logged when all filters on a facet are selected.
132
+ */
133
+ facetSelectAll = 'facetSelectAll',
134
+ /**
135
+ * Identifies the search event that gets logged when a facet check box is deselected and the query is updated.
136
+ */
137
+ facetDeselect = 'facetDeselect',
138
+ /**
139
+ * Identifies the search event that gets logged when a user clicks a facet value to filter out results containing the facet value.
140
+ */
141
+ facetExclude = 'facetExclude',
142
+ /**
143
+ * Identifies the search event that gets logged when a user clicks a facet value to not filter out results containing the facet value.
144
+ */
145
+ facetUnexclude = 'facetUnexclude',
146
+ /**
147
+ * Identifies the search event that gets logged when the sort criteria on a facet is updated.
148
+ */
149
+ facetUpdateSort = 'facetUpdateSort',
150
+ /**
151
+ * The custom event that gets logged when an end-user expands a facet to see additional values.
152
+ */
153
+ facetShowMore = 'showMoreFacetResults',
154
+ /**
155
+ * The custom event that gets logged when an end-user collapses a facet to see less values.
156
+ */
157
+ facetShowLess = 'showLessFacetResults',
158
+ /**
159
+ * Identifies the custom event that gets logged when a user query encounters an error during execution.
160
+ */
161
+ queryError = 'query',
162
+ /**
163
+ * Identifies the search and custom event that gets logged when a user clicks the Go Back link after an error page.
164
+ */
165
+ queryErrorBack = 'errorBack',
166
+ /**
167
+ * Identifies the search and custom event that gets logged when a user clears the query box after an error page.
168
+ */
169
+ queryErrorClear = 'errorClearQuery',
170
+ /**
171
+ * Identifies the search and custom event that gets logged when a user clicks the Retry link after an error page.
172
+ */
173
+ queryErrorRetry = 'errorRetry',
174
+ /**
175
+ * Identifies the custom event that gets logged when a user performs a query that returns recommendations in the Recommendations panel.
176
+ */
177
+ recommendation = 'recommendation',
178
+ /**
179
+ * Identifies the search event that gets logged when a user action (that is not a query) reloads the Recommendations panel with new recommendations.
180
+ */
181
+ recommendationInterfaceLoad = 'recommendationInterfaceLoad',
182
+ /**
183
+ * Identifies the click event that gets logged when a user clicks a recommendation in the Recommendations panel.
184
+ */
185
+ recommendationOpen = 'recommendationOpen',
186
+ /**
187
+ * Identifies the custom event that gets logged when a user identifies a smart snippet answer as relevant.
188
+ */
189
+ likeSmartSnippet = 'likeSmartSnippet',
190
+ /**
191
+ * Identifies the custom event that gets logged when a user identifies a smart snippet answer as irrelevant.
192
+ */
193
+ dislikeSmartSnippet = 'dislikeSmartSnippet',
194
+ /**
195
+ * Identifies the custom event that gets logged when a user expand a smart snippet answer.
196
+ */
197
+ expandSmartSnippet = 'expandSmartSnippet',
198
+ /**
199
+ * Identifies the custom event that gets logged when a user collapse a smart snippet answer.
200
+ */
201
+ collapseSmartSnippet = 'collapseSmartSnippet',
202
+ /**
203
+ * Identifies the custom event that gets logged when a user open a smart snippet explanation modal for feedback.
204
+ */
205
+ openSmartSnippetFeedbackModal = 'openSmartSnippetFeedbackModal',
206
+ /**
207
+ * Identifies the custom event that gets logged when a user close a smart snippet explanation modal for feedback.
208
+ */
209
+ closeSmartSnippetFeedbackModal = 'closeSmartSnippetFeedbackModal',
210
+ /**
211
+ * Identifies the custom event that gets logged when a user sends an explanation for a smart snippet irrelevant answer.
212
+ */
213
+ sendSmartSnippetReason = 'sendSmartSnippetReason',
214
+ /**
215
+ * Identifies the custom event that gets logged when a snippet suggestion for a related question is expanded.
216
+ */
217
+ expandSmartSnippetSuggestion = 'expandSmartSnippetSuggestion',
218
+ /**
219
+ * Identifies the custom event that gets logged when a snippet suggestion for a related question is collapsed.
220
+ */
221
+ collapseSmartSnippetSuggestion = 'collapseSmartSnippetSuggestion',
222
+ /**
223
+ * Identifies the custom event that gets logged when the user presses "show more" on a snippet suggestion for a related question.
224
+ *
225
+ * @deprecated
226
+ */
227
+ showMoreSmartSnippetSuggestion = 'showMoreSmartSnippetSuggestion',
228
+ /**
229
+ * Identifies the custom event that gets logged when the user presses "show less" on a snippet suggestion for a related question.
230
+ *
231
+ * @deprecated
232
+ */
233
+ showLessSmartSnippetSuggestion = 'showLessSmartSnippetSuggestion',
234
+ /**
235
+ * Identifies the custom event that gets logged when a user clicks on the source of an answer in a smart snippet.
236
+ */
237
+ openSmartSnippetSource = 'openSmartSnippetSource',
238
+ /**
239
+ * Identifies the custom event that gets logged when a user clicks on the source of a snippet suggestion for a related question.
240
+ */
241
+ openSmartSnippetSuggestionSource = 'openSmartSnippetSuggestionSource',
242
+ /**
243
+ * Identifies the custom event that gets logged when a user clicks on a link in the answer of a smart snippet.
244
+ */
245
+ openSmartSnippetInlineLink = 'openSmartSnippetInlineLink',
246
+ /**
247
+ * Identifies the custom event that gets logged when a user clicks on a link in the snippet suggestion for a related question.
248
+ */
249
+ openSmartSnippetSuggestionInlineLink = 'openSmartSnippetSuggestionInlineLink',
250
+ /**
251
+ * Identifies the search event that gets logged when a recent queries list item gets clicked.
252
+ */
253
+ recentQueryClick = 'recentQueriesClick',
254
+ /**
255
+ * Identifies the custom event that gets logged when a recent queries list gets cleared.
256
+ */
257
+ clearRecentQueries = 'clearRecentQueries',
258
+ /**
259
+ * Identifies the custom event that gets logged when a recently clicked results list item gets clicked.
260
+ */
261
+ recentResultClick = 'recentResultClick',
262
+ /**
263
+ * Identifies the custom event that gets logged when a recently clicked results list gets cleared.
264
+ */
265
+ clearRecentResults = 'clearRecentResults',
266
+ /**
267
+ * Identifies the search event that gets logged when a user clicks the Cancel last action link when no results are returned following their last action.
268
+ */
269
+ noResultsBack = 'noResultsBack',
270
+ /**
271
+ * Identifies the click event that gets logged when a user clicks the Show More link under a search result that support the folding component.
272
+ */
273
+ showMoreFoldedResults = 'showMoreFoldedResults',
274
+ /**
275
+ * Identifies the custom event that gets logged when a user clicks the Show Less link under a search result that support the folding component.
276
+ */
277
+ showLessFoldedResults = 'showLessFoldedResults',
278
+ /**
279
+ * Identifies the click event that gets logged when a user clicks the Copy To Clipboard result action.
280
+ */
281
+ copyToClipboard = 'copyToClipboard',
282
+ /**
283
+ * Identifies the click event that gets logged when a user clicks the Send As Email result action.
284
+ */
285
+ caseSendEmail = 'Case.SendEmail',
286
+ /**
287
+ * Identifies the click event that gets logged when a user clicks the Post To Feed result action.
288
+ */
289
+ feedItemTextPost = 'FeedItem.TextPost',
290
+ /**
291
+ * Identifies the click event that gets logged when a user clicks the Attach To Case result action.
292
+ */
293
+ caseAttach = 'caseAttach',
294
+ /**
295
+ * Identifies the custom event that gets logged when a user clicks the Detach From Case result action.
296
+ */
297
+ caseDetach = 'caseDetach',
298
+ /**
299
+ * Identifies the cause of a search request being retried in order to regenerate an answer stream that failed.
300
+ */
301
+ retryGeneratedAnswer = 'retryGeneratedAnswer',
302
+ /**
303
+ * Identifies the custom event that gets logged when a user identifies a generated answer as relevant.
304
+ */
305
+ likeGeneratedAnswer = 'likeGeneratedAnswer',
306
+ /**
307
+ * Identifies the custom event that gets logged when a user identifies a generated answer as irrelevant.
308
+ */
309
+ dislikeGeneratedAnswer = 'dislikeGeneratedAnswer',
310
+ /**
311
+ * Identifies the custom event that gets logged when a user opens a generated answer citation.
312
+ */
313
+ openGeneratedAnswerSource = 'openGeneratedAnswerSource',
314
+ /**
315
+ * Identifies the custom event that gets logged when a user clicks an inline link in a generated answer.
316
+ */
317
+ generatedAnswerOpenInlineLink = 'generatedAnswerOpenInlineLink',
318
+ /**
319
+ * Identified the custom event that gets logged when a generated answer stream is completed.
320
+ */
321
+ generatedAnswerStreamEnd = 'generatedAnswerStreamEnd',
322
+ /**
323
+ * Identifies the custom event that gets logged when a user hovers over a generated answer citation.
324
+ */
325
+ generatedAnswerSourceHover = 'generatedAnswerSourceHover',
326
+ /**
327
+ * Identifies the custom event that gets logged when a user clicks the copy to clip board button of a generated answer.
328
+ */
329
+ generatedAnswerCopyToClipboard = 'generatedAnswerCopyToClipboard',
330
+ /**
331
+ * Identifies the custom event that gets logged when a user deactivates the genQA feature.
332
+ */
333
+ generatedAnswerHideAnswers = 'generatedAnswerHideAnswers',
334
+ /**
335
+ * Identifies the custom event that gets logged when a user activates the genQA feature.
336
+ */
337
+ generatedAnswerShowAnswers = 'generatedAnswerShowAnswers',
338
+ /**
339
+ * Identifies the custom event that gets logged when a user expand a generated answer.
340
+ */
341
+ generatedAnswerExpand = 'generatedAnswerExpand',
342
+ /**
343
+ * Identifies the custom event that gets logged when a user collapse a generated answer.
344
+ */
345
+ generatedAnswerCollapse = 'generatedAnswerCollapse',
346
+ /**
347
+ * Identifies the custom event that gets logged when a user submits a feedback of a generated answer.
348
+ */
349
+ generatedAnswerFeedbackSubmit = 'generatedAnswerFeedbackSubmit',
350
+ /**
351
+ * Identifies the search event that gets logged when a user clicks the rephrase button in a generated answer.
352
+ */
353
+ rephraseGeneratedAnswer = 'rephraseGeneratedAnswer',
354
+ /**
355
+ * Identifies the new version of custom event that gets logged when a user submits a feedback of a generated answer.
356
+ */
357
+ generatedAnswerFeedbackSubmitV2 = 'generatedAnswerFeedbackSubmitV2',
358
+ /**
359
+ * Identifies the click event that gets logged when the user clicks on a generated answer citation.
360
+ */
361
+ generatedAnswerCitationClick = 'generatedAnswerCitationClick',
362
+ /**
363
+ * Identifies the custom event that gets logged when the user clicks on a generated answer citation.
364
+ */
365
+ generatedAnswerFollowupOpenSource = 'generatedAnswerFollowupOpenSource',
366
+ /**
367
+ * Identifies the click event that gets logged when a user clicks the Attach Citation action.
368
+ */
369
+ generatedAnswerCitationDocumentAttach = 'generatedAnswerCitationDocumentAttach',
369
370
  }
370
371
 
371
372
  export const CustomEventsTypes: Partial<Record<SearchPageEvents | InsightEvents, string>> = {
372
- [SearchPageEvents.triggerNotify]: 'queryPipelineTriggers',
373
- [SearchPageEvents.triggerExecute]: 'queryPipelineTriggers',
374
- [SearchPageEvents.triggerQuery]: 'queryPipelineTriggers',
375
- [SearchPageEvents.triggerRedirect]: 'queryPipelineTriggers',
376
- // This value is the same as SearchPageEvents.triggerQuery, which is very likely a mistake.
377
- //[SearchPageEvents.queryError]: 'errors',
378
- [SearchPageEvents.queryErrorBack]: 'errors',
379
- [SearchPageEvents.queryErrorClear]: 'errors',
380
- [SearchPageEvents.queryErrorRetry]: 'errors',
381
- [SearchPageEvents.pagerNext]: 'getMoreResults',
382
- [SearchPageEvents.pagerPrevious]: 'getMoreResults',
383
- [SearchPageEvents.pagerNumber]: 'getMoreResults',
384
- [SearchPageEvents.pagerResize]: 'getMoreResults',
385
- [SearchPageEvents.pagerScrolling]: 'getMoreResults',
386
- [SearchPageEvents.facetSearch]: 'facet',
387
- [SearchPageEvents.facetShowLess]: 'facet',
388
- [SearchPageEvents.facetShowMore]: 'facet',
389
- [SearchPageEvents.recommendation]: 'recommendation',
390
- [SearchPageEvents.likeSmartSnippet]: 'smartSnippet',
391
- [SearchPageEvents.dislikeSmartSnippet]: 'smartSnippet',
392
- [SearchPageEvents.expandSmartSnippet]: 'smartSnippet',
393
- [SearchPageEvents.collapseSmartSnippet]: 'smartSnippet',
394
- [SearchPageEvents.openSmartSnippetFeedbackModal]: 'smartSnippet',
395
- [SearchPageEvents.closeSmartSnippetFeedbackModal]: 'smartSnippet',
396
- [SearchPageEvents.sendSmartSnippetReason]: 'smartSnippet',
397
- [SearchPageEvents.expandSmartSnippetSuggestion]: 'smartSnippetSuggestions',
398
- [SearchPageEvents.collapseSmartSnippetSuggestion]: 'smartSnippetSuggestions',
399
- [SearchPageEvents.showMoreSmartSnippetSuggestion]: 'smartSnippetSuggestions',
400
- [SearchPageEvents.showLessSmartSnippetSuggestion]: 'smartSnippetSuggestions',
401
- [SearchPageEvents.clearRecentQueries]: 'recentQueries',
402
- [SearchPageEvents.recentResultClick]: 'recentlyClickedDocuments',
403
- [SearchPageEvents.clearRecentResults]: 'recentlyClickedDocuments',
404
- [SearchPageEvents.showLessFoldedResults]: 'folding',
405
- [SearchPageEvents.caseDetach]: 'case',
406
- [SearchPageEvents.likeGeneratedAnswer]: 'generatedAnswer',
407
- [SearchPageEvents.dislikeGeneratedAnswer]: 'generatedAnswer',
408
- [SearchPageEvents.openGeneratedAnswerSource]: 'generatedAnswer',
409
- [SearchPageEvents.generatedAnswerOpenInlineLink]: 'generatedAnswer',
410
- [SearchPageEvents.generatedAnswerFollowupOpenSource]: 'generatedAnswer',
411
- [SearchPageEvents.generatedAnswerStreamEnd]: 'generatedAnswer',
412
- [SearchPageEvents.generatedAnswerSourceHover]: 'generatedAnswer',
413
- [SearchPageEvents.generatedAnswerCopyToClipboard]: 'generatedAnswer',
414
- [SearchPageEvents.generatedAnswerHideAnswers]: 'generatedAnswer',
415
- [SearchPageEvents.generatedAnswerShowAnswers]: 'generatedAnswer',
416
- [SearchPageEvents.generatedAnswerExpand]: 'generatedAnswer',
417
- [SearchPageEvents.generatedAnswerCollapse]: 'generatedAnswer',
418
- [SearchPageEvents.generatedAnswerFeedbackSubmit]: 'generatedAnswer',
419
- [SearchPageEvents.generatedAnswerFeedbackSubmitV2]: 'generatedAnswer',
420
- [InsightEvents.expandToFullUI]: 'interface',
421
- [InsightEvents.openUserActions]: 'User Actions',
422
- [InsightEvents.showPrecedingSessions]: 'User Actions',
423
- [InsightEvents.showFollowingSessions]: 'User Actions',
424
- [InsightEvents.clickViewedDocument]: 'User Actions',
425
- [InsightEvents.clickPageView]: 'User Actions',
426
- [InsightEvents.createArticle]: 'createArticle',
373
+ [SearchPageEvents.triggerNotify]: 'queryPipelineTriggers',
374
+ [SearchPageEvents.triggerExecute]: 'queryPipelineTriggers',
375
+ [SearchPageEvents.triggerQuery]: 'queryPipelineTriggers',
376
+ [SearchPageEvents.triggerRedirect]: 'queryPipelineTriggers',
377
+ // This value is the same as SearchPageEvents.triggerQuery, which is very likely a mistake.
378
+ //[SearchPageEvents.queryError]: 'errors',
379
+ [SearchPageEvents.queryErrorBack]: 'errors',
380
+ [SearchPageEvents.queryErrorClear]: 'errors',
381
+ [SearchPageEvents.queryErrorRetry]: 'errors',
382
+ [SearchPageEvents.pagerNext]: 'getMoreResults',
383
+ [SearchPageEvents.pagerPrevious]: 'getMoreResults',
384
+ [SearchPageEvents.pagerNumber]: 'getMoreResults',
385
+ [SearchPageEvents.pagerResize]: 'getMoreResults',
386
+ [SearchPageEvents.pagerScrolling]: 'getMoreResults',
387
+ [SearchPageEvents.facetSearch]: 'facet',
388
+ [SearchPageEvents.facetShowLess]: 'facet',
389
+ [SearchPageEvents.facetShowMore]: 'facet',
390
+ [SearchPageEvents.recommendation]: 'recommendation',
391
+ [SearchPageEvents.likeSmartSnippet]: 'smartSnippet',
392
+ [SearchPageEvents.dislikeSmartSnippet]: 'smartSnippet',
393
+ [SearchPageEvents.expandSmartSnippet]: 'smartSnippet',
394
+ [SearchPageEvents.collapseSmartSnippet]: 'smartSnippet',
395
+ [SearchPageEvents.openSmartSnippetFeedbackModal]: 'smartSnippet',
396
+ [SearchPageEvents.closeSmartSnippetFeedbackModal]: 'smartSnippet',
397
+ [SearchPageEvents.sendSmartSnippetReason]: 'smartSnippet',
398
+ [SearchPageEvents.expandSmartSnippetSuggestion]: 'smartSnippetSuggestions',
399
+ [SearchPageEvents.collapseSmartSnippetSuggestion]: 'smartSnippetSuggestions',
400
+ [SearchPageEvents.showMoreSmartSnippetSuggestion]: 'smartSnippetSuggestions',
401
+ [SearchPageEvents.showLessSmartSnippetSuggestion]: 'smartSnippetSuggestions',
402
+ [SearchPageEvents.clearRecentQueries]: 'recentQueries',
403
+ [SearchPageEvents.recentResultClick]: 'recentlyClickedDocuments',
404
+ [SearchPageEvents.clearRecentResults]: 'recentlyClickedDocuments',
405
+ [SearchPageEvents.showLessFoldedResults]: 'folding',
406
+ [SearchPageEvents.caseDetach]: 'case',
407
+ [SearchPageEvents.likeGeneratedAnswer]: 'generatedAnswer',
408
+ [SearchPageEvents.dislikeGeneratedAnswer]: 'generatedAnswer',
409
+ [SearchPageEvents.openGeneratedAnswerSource]: 'generatedAnswer',
410
+ [SearchPageEvents.generatedAnswerOpenInlineLink]: 'generatedAnswer',
411
+ [SearchPageEvents.generatedAnswerFollowupOpenSource]: 'generatedAnswer',
412
+ [SearchPageEvents.generatedAnswerStreamEnd]: 'generatedAnswer',
413
+ [SearchPageEvents.generatedAnswerSourceHover]: 'generatedAnswer',
414
+ [SearchPageEvents.generatedAnswerCopyToClipboard]: 'generatedAnswer',
415
+ [SearchPageEvents.generatedAnswerHideAnswers]: 'generatedAnswer',
416
+ [SearchPageEvents.generatedAnswerShowAnswers]: 'generatedAnswer',
417
+ [SearchPageEvents.generatedAnswerExpand]: 'generatedAnswer',
418
+ [SearchPageEvents.generatedAnswerCollapse]: 'generatedAnswer',
419
+ [SearchPageEvents.generatedAnswerFeedbackSubmit]: 'generatedAnswer',
420
+ [SearchPageEvents.generatedAnswerFeedbackSubmitV2]: 'generatedAnswer',
421
+ [InsightEvents.expandToFullUI]: 'interface',
422
+ [InsightEvents.openUserActions]: 'User Actions',
423
+ [InsightEvents.showPrecedingSessions]: 'User Actions',
424
+ [InsightEvents.showFollowingSessions]: 'User Actions',
425
+ [InsightEvents.clickViewedDocument]: 'User Actions',
426
+ [InsightEvents.clickPageView]: 'User Actions',
427
+ [InsightEvents.createArticle]: 'createArticle',
427
428
  };
428
429
 
429
430
  export interface StaticFilterMetadata {
430
- staticFilterId: string;
431
+ staticFilterId: string;
431
432
  }
432
433
 
433
434
  export interface StaticFilterToggleValueMetadata extends StaticFilterMetadata {
434
- staticFilterValue: StaticFilterValueMetadata;
435
+ staticFilterValue: StaticFilterValueMetadata;
435
436
  }
436
437
 
437
438
  interface StaticFilterValueMetadata {
438
- caption: string;
439
- expression: string;
439
+ caption: string;
440
+ expression: string;
440
441
  }
441
442
 
442
443
  export interface FacetMetadata {
443
- facetId: string;
444
- facetField: string;
445
- facetValue: string;
446
- facetTitle: string;
444
+ facetId: string;
445
+ facetField: string;
446
+ facetValue: string;
447
+ facetTitle: string;
447
448
  }
448
449
 
449
450
  export type FacetStateMetadata = FacetStateRequest;
450
451
  export interface FacetRangeMetadata extends Omit<FacetMetadata, 'facetValue'> {
451
- facetRangeStart: string;
452
- facetRangeEnd: string;
453
- facetRangeEndInclusive: boolean;
452
+ facetRangeStart: string;
453
+ facetRangeEnd: string;
454
+ facetRangeEndInclusive: boolean;
454
455
  }
455
456
 
456
457
  export interface CategoryFacetMetadata {
457
- categoryFacetId: string;
458
- categoryFacetField: string;
459
- categoryFacetPath: string[];
460
- categoryFacetTitle: string;
458
+ categoryFacetId: string;
459
+ categoryFacetField: string;
460
+ categoryFacetPath: string[];
461
+ categoryFacetTitle: string;
461
462
  }
462
463
 
463
464
  export interface OmniboxSuggestionsMetadata {
464
- suggestionRanking: number;
465
- partialQueries: string | string[];
466
- suggestions: string | string[];
467
- partialQuery: string;
468
- querySuggestResponseId: string;
465
+ suggestionRanking: number;
466
+ partialQueries: string | string[];
467
+ suggestions: string | string[];
468
+ partialQuery: string;
469
+ querySuggestResponseId: string;
469
470
  }
470
471
 
471
472
  export interface DocumentIdentifier {
472
- contentIDKey: string;
473
- contentIDValue: string;
473
+ contentIDKey: string;
474
+ contentIDValue: string;
474
475
  }
475
476
 
476
477
  export interface InterfaceChangeMetadata {
477
- interfaceChangeTo: string;
478
+ interfaceChangeTo: string;
478
479
  }
479
480
 
480
481
  export interface ResultsSortMetadata {
481
- resultsSortBy: string;
482
+ resultsSortBy: string;
482
483
  }
483
484
 
484
485
  export interface TriggerNotifyMetadata {
485
- notifications: string[];
486
+ notifications: string[];
486
487
  }
487
488
 
488
489
  export interface TriggerExecution {
489
- functionName: string;
490
- params: (string | number | boolean)[];
490
+ functionName: string;
491
+ params: (string | number | boolean)[];
491
492
  }
492
493
 
493
494
  export interface TriggerExecuteMetadata {
494
- executions: TriggerExecution[];
495
+ executions: TriggerExecution[];
495
496
  }
496
497
 
497
498
  export interface UndoTriggerRedirectMetadata {
498
- undoneQuery: string;
499
+ undoneQuery: string;
499
500
  }
500
501
 
501
502
  export interface TriggerRedirectMetadata {
502
- redirectedTo: string;
503
+ redirectedTo: string;
503
504
  }
504
505
 
505
506
  export interface PagerResizeMetadata {
506
- currentResultsPerPage: number;
507
+ currentResultsPerPage: number;
507
508
  }
508
509
 
509
510
  export interface PagerMetadata {
510
- pagerNumber: number;
511
+ pagerNumber: number;
511
512
  }
512
513
 
513
514
  export interface FacetBaseMeta {
514
- facetId: string;
515
- facetField: string;
516
- facetTitle: string;
515
+ facetId: string;
516
+ facetField: string;
517
+ facetTitle: string;
517
518
  }
518
519
 
519
520
  export interface FacetMetadata extends FacetBaseMeta {
520
- facetValue: string;
521
+ facetValue: string;
521
522
  }
522
523
 
523
524
  export interface FacetRangeMetadata extends FacetBaseMeta {
524
- facetRangeStart: string;
525
- facetRangeEnd: string;
525
+ facetRangeStart: string;
526
+ facetRangeEnd: string;
526
527
  }
527
528
 
528
529
  export interface FacetSortMeta extends FacetBaseMeta {
529
- criteria: string;
530
+ criteria: string;
530
531
  }
531
532
 
532
533
  export interface QueryErrorMeta {
533
- query: string;
534
- aq: string;
535
- cq: string;
536
- dq: string;
537
- errorType: string;
538
- errorMessage: string;
534
+ query: string;
535
+ aq: string;
536
+ cq: string;
537
+ dq: string;
538
+ errorType: string;
539
+ errorMessage: string;
539
540
  }
540
541
 
541
- export type SmartSnippetFeedbackReason = 'does_not_answer' | 'partially_answers' | 'was_not_a_question' | 'other';
542
+ export type SmartSnippetFeedbackReason =
543
+ | 'does_not_answer'
544
+ | 'partially_answers'
545
+ | 'was_not_a_question'
546
+ | 'other';
542
547
 
543
548
  export interface SmartSnippetSuggestionMeta {
544
- question: string;
545
- answerSnippet: string;
546
- documentId: SmartSnippetDocumentIdentifier;
549
+ question: string;
550
+ answerSnippet: string;
551
+ documentId: SmartSnippetDocumentIdentifier;
547
552
  }
548
553
 
549
554
  export interface LinkMeta {
550
- linkText: string;
551
- linkURL: string;
555
+ linkText: string;
556
+ linkURL: string;
552
557
  }
553
558
 
554
559
  export interface SmartSnippetLinkMeta extends LinkMeta {}
555
560
 
556
561
  export interface SmartSnippetDocumentIdentifier {
557
- contentIdKey: string;
558
- contentIdValue: string;
562
+ contentIdKey: string;
563
+ contentIdValue: string;
559
564
  }
560
565
 
561
- export type PartialDocumentInformation = Omit<DocumentInformation, 'actionCause' | 'searchQueryUid'>;
566
+ export type PartialDocumentInformation = Omit<
567
+ DocumentInformation,
568
+ 'actionCause' | 'searchQueryUid'
569
+ >;
562
570
 
563
571
  export type PartialCitationInformation = Omit<
564
- DocumentInformation,
565
- 'actionCause' | 'searchQueryUid' | 'documentPosition'
572
+ DocumentInformation,
573
+ 'actionCause' | 'searchQueryUid' | 'documentPosition'
566
574
  >;
567
575
 
568
576
  interface AnswerGeneratedWithAnswerAPI {
569
- answerAPIStreamId: string;
570
- generativeQuestionAnsweringId?: never;
571
- conversationId?: never;
577
+ answerAPIStreamId: string;
578
+ generativeQuestionAnsweringId?: never;
579
+ conversationId?: never;
572
580
  }
573
581
 
574
582
  interface AnswerGeneratedWithSearchAPI {
575
- answerAPIStreamId?: never;
576
- generativeQuestionAnsweringId: string;
577
- conversationId?: never;
583
+ answerAPIStreamId?: never;
584
+ generativeQuestionAnsweringId: string;
585
+ conversationId?: never;
578
586
  }
579
587
 
580
588
  interface AnswerGeneratedWithAgent {
581
- answerAPIStreamId?: never;
582
- generativeQuestionAnsweringId: string;
583
- conversationId: string;
589
+ answerAPIStreamId?: never;
590
+ generativeQuestionAnsweringId: string;
591
+ conversationId: string;
584
592
  }
585
593
 
586
594
  export type GeneratedAnswerBaseMeta =
587
- | AnswerGeneratedWithAnswerAPI
588
- | AnswerGeneratedWithSearchAPI
589
- | AnswerGeneratedWithAgent;
595
+ | AnswerGeneratedWithAnswerAPI
596
+ | AnswerGeneratedWithSearchAPI
597
+ | AnswerGeneratedWithAgent;
590
598
 
591
599
  export type GeneratedAnswerStreamEndMeta = GeneratedAnswerBaseMeta & {
592
- answerGenerated: boolean;
593
- answerTextIsEmpty?: boolean;
600
+ answerGenerated: boolean;
601
+ answerTextIsEmpty?: boolean;
594
602
  };
595
603
 
596
604
  export type GeneratedAnswerCitationMeta = GeneratedAnswerBaseMeta & {
597
- permanentId: string;
598
- citationId: string;
605
+ permanentId: string;
606
+ citationId: string;
599
607
  };
600
608
 
601
609
  export type GeneratedAnswerInlineLinkMeta = GeneratedAnswerBaseMeta & LinkMeta;
602
610
 
603
611
  export type GeneratedAnswerCitationClickMeta = GeneratedAnswerBaseMeta & {
604
- citationId: string;
605
- documentId: GeneratedAnswerDocumentIdentifier;
612
+ citationId: string;
613
+ documentId: GeneratedAnswerDocumentIdentifier;
606
614
  };
607
615
 
608
616
  type GeneratedAnswerDocumentIdentifier = {
609
- contentIdKey: string;
610
- contentIdValue: string;
617
+ contentIdKey: string;
618
+ contentIdValue: string;
611
619
  };
612
620
 
613
- export type GeneratedAnswerFeedbackReason = 'irrelevant' | 'notAccurate' | 'outOfDate' | 'harmful' | 'other';
621
+ export type GeneratedAnswerFeedbackReason =
622
+ | 'irrelevant'
623
+ | 'notAccurate'
624
+ | 'outOfDate'
625
+ | 'harmful'
626
+ | 'other';
614
627
 
615
628
  export type GeneratedAnswerRephraseFormat = 'step' | 'bullet' | 'concise' | 'default';
616
629
 
617
630
  export type GeneratedAnswerSourceHoverMeta = GeneratedAnswerCitationMeta & {
618
- citationHoverTimeMs: number;
631
+ citationHoverTimeMs: number;
619
632
  };
620
633
 
621
634
  export type GeneratedAnswerFollowupOpenSourceMeta = PartialCitationInformation &
622
- AnswerGeneratedWithAgent & {
623
- citationId: string;
624
- permanentId: string;
625
- };
635
+ AnswerGeneratedWithAgent & {
636
+ citationId: string;
637
+ permanentId: string;
638
+ };
626
639
 
627
640
  export type GeneratedAnswerRephraseMeta = GeneratedAnswerBaseMeta & {
628
- rephraseFormat: GeneratedAnswerRephraseFormat;
641
+ rephraseFormat: GeneratedAnswerRephraseFormat;
629
642
  };
630
643
 
631
644
  export type GeneratedAnswerFeedbackMeta = GeneratedAnswerBaseMeta & {
632
- reason: GeneratedAnswerFeedbackReason;
633
- details?: string;
645
+ reason: GeneratedAnswerFeedbackReason;
646
+ details?: string;
634
647
  };
635
648
 
636
649
  export type GeneratedAnswerFeedbackReasonOption = 'yes' | 'unknown' | 'no';
637
650
 
638
651
  export type GeneratedAnswerFeedbackMetaV2 = GeneratedAnswerBaseMeta & {
639
- helpful: boolean;
640
- readable: GeneratedAnswerFeedbackReasonOption;
641
- documented: GeneratedAnswerFeedbackReasonOption;
642
- correctTopic: GeneratedAnswerFeedbackReasonOption;
643
- hallucinationFree: GeneratedAnswerFeedbackReasonOption;
644
- details?: string;
645
- documentUrl?: string;
652
+ helpful: boolean;
653
+ readable: GeneratedAnswerFeedbackReasonOption;
654
+ documented: GeneratedAnswerFeedbackReasonOption;
655
+ correctTopic: GeneratedAnswerFeedbackReasonOption;
656
+ hallucinationFree: GeneratedAnswerFeedbackReasonOption;
657
+ details?: string;
658
+ documentUrl?: string;
646
659
  };