algoliasearch 5.0.0-alpha.99 → 5.0.0-beta.10

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 (888) hide show
  1. package/LICENSE +21 -0
  2. package/builds/browser.ts +22 -18
  3. package/builds/models.ts +140 -6
  4. package/builds/node.ts +92 -16
  5. package/dist/algoliasearch/builds/browser.d.ts +83 -71
  6. package/dist/algoliasearch/builds/browser.d.ts.map +1 -1
  7. package/dist/algoliasearch/builds/models.d.ts +4 -2
  8. package/dist/algoliasearch/builds/models.d.ts.map +1 -1
  9. package/dist/algoliasearch/builds/node.d.ts +101 -72
  10. package/dist/algoliasearch/builds/node.d.ts.map +1 -1
  11. package/dist/algoliasearch.cjs +1259 -399
  12. package/dist/algoliasearch.esm.browser.js +1226 -423
  13. package/dist/algoliasearch.esm.node.js +1260 -400
  14. package/dist/algoliasearch.umd.js +2 -2
  15. package/dist/client-abtesting/model/aBTest.d.ts +14 -29
  16. package/dist/client-abtesting/model/aBTest.d.ts.map +1 -1
  17. package/dist/client-abtesting/model/aBTestConfiguration.d.ts +12 -0
  18. package/dist/client-abtesting/model/aBTestConfiguration.d.ts.map +1 -0
  19. package/dist/client-abtesting/model/aBTestResponse.d.ts +3 -3
  20. package/dist/client-abtesting/model/abTestsVariant.d.ts +3 -3
  21. package/dist/client-abtesting/model/addABTestsRequest.d.ts +1 -1
  22. package/dist/client-abtesting/model/clientMethodProps.d.ts +7 -7
  23. package/dist/client-abtesting/model/{currenciesValue.d.ts → currency.d.ts} +2 -2
  24. package/dist/client-abtesting/model/currency.d.ts.map +1 -0
  25. package/dist/client-abtesting/model/customSearchParams.d.ts +1 -1
  26. package/dist/client-abtesting/model/effect.d.ts +5 -0
  27. package/dist/client-abtesting/model/effect.d.ts.map +1 -0
  28. package/dist/client-abtesting/model/emptySearch.d.ts +10 -0
  29. package/dist/client-abtesting/model/emptySearch.d.ts.map +1 -0
  30. package/dist/client-abtesting/model/index.d.ts +7 -1
  31. package/dist/client-abtesting/model/index.d.ts.map +1 -1
  32. package/dist/client-abtesting/model/listABTestsResponse.d.ts +2 -2
  33. package/dist/client-abtesting/model/listABTestsResponse.d.ts.map +1 -1
  34. package/dist/client-abtesting/model/minimumDetectableEffect.d.ts +12 -0
  35. package/dist/client-abtesting/model/minimumDetectableEffect.d.ts.map +1 -0
  36. package/dist/client-abtesting/model/outliers.d.ts +10 -0
  37. package/dist/client-abtesting/model/outliers.d.ts.map +1 -0
  38. package/dist/client-abtesting/model/status.d.ts +5 -0
  39. package/dist/client-abtesting/model/status.d.ts.map +1 -0
  40. package/dist/client-abtesting/model/variant.d.ts +29 -25
  41. package/dist/client-abtesting/model/variant.d.ts.map +1 -1
  42. package/dist/client-abtesting/src/abtestingClient.d.ts +28 -26
  43. package/dist/client-abtesting/src/abtestingClient.d.ts.map +1 -1
  44. package/dist/client-analytics/model/clickPositionsInner.d.ts +14 -0
  45. package/dist/client-analytics/model/clickPositionsInner.d.ts.map +1 -0
  46. package/dist/client-analytics/model/clientMethodProps.d.ts +161 -90
  47. package/dist/client-analytics/model/clientMethodProps.d.ts.map +1 -1
  48. package/dist/client-analytics/model/currenciesValue.d.ts +14 -0
  49. package/dist/client-analytics/model/currenciesValue.d.ts.map +1 -0
  50. package/dist/client-analytics/model/dailyAddToCartRates.d.ts +19 -0
  51. package/dist/client-analytics/model/dailyAddToCartRates.d.ts.map +1 -0
  52. package/dist/client-analytics/model/dailyAverageClicks.d.ts +15 -0
  53. package/dist/client-analytics/model/dailyAverageClicks.d.ts.map +1 -0
  54. package/dist/client-analytics/model/dailyClickThroughRates.d.ts +19 -0
  55. package/dist/client-analytics/model/dailyClickThroughRates.d.ts.map +1 -0
  56. package/dist/client-analytics/model/dailyConversionRates.d.ts +19 -0
  57. package/dist/client-analytics/model/dailyConversionRates.d.ts.map +1 -0
  58. package/dist/client-analytics/model/dailyNoClickRates.d.ts +19 -0
  59. package/dist/client-analytics/model/dailyNoClickRates.d.ts.map +1 -0
  60. package/dist/client-analytics/model/dailyNoResultsRates.d.ts +19 -0
  61. package/dist/client-analytics/model/dailyNoResultsRates.d.ts.map +1 -0
  62. package/dist/client-analytics/model/dailyPurchaseRates.d.ts +19 -0
  63. package/dist/client-analytics/model/dailyPurchaseRates.d.ts.map +1 -0
  64. package/dist/client-analytics/model/dailyRevenue.d.ts +12 -0
  65. package/dist/client-analytics/model/dailyRevenue.d.ts.map +1 -0
  66. package/dist/client-analytics/model/dailySearches.d.ts +11 -0
  67. package/dist/client-analytics/model/dailySearches.d.ts.map +1 -0
  68. package/dist/client-analytics/model/dailySearchesNoClicks.d.ts +15 -0
  69. package/dist/client-analytics/model/dailySearchesNoClicks.d.ts.map +1 -0
  70. package/dist/client-analytics/model/dailySearchesNoResults.d.ts +15 -0
  71. package/dist/client-analytics/model/dailySearchesNoResults.d.ts.map +1 -0
  72. package/dist/client-analytics/model/dailyUsers.d.ts +11 -0
  73. package/dist/client-analytics/model/dailyUsers.d.ts.map +1 -0
  74. package/dist/client-analytics/model/getAddToCartRateResponse.d.ts +20 -0
  75. package/dist/client-analytics/model/getAddToCartRateResponse.d.ts.map +1 -0
  76. package/dist/client-analytics/model/getAverageClickPositionResponse.d.ts +6 -6
  77. package/dist/client-analytics/model/getAverageClickPositionResponse.d.ts.map +1 -1
  78. package/dist/client-analytics/model/getClickPositionsResponse.d.ts +3 -3
  79. package/dist/client-analytics/model/getClickPositionsResponse.d.ts.map +1 -1
  80. package/dist/client-analytics/model/getClickThroughRateResponse.d.ts +7 -7
  81. package/dist/client-analytics/model/getClickThroughRateResponse.d.ts.map +1 -1
  82. package/dist/client-analytics/model/getConversionRateResponse.d.ts +20 -0
  83. package/dist/client-analytics/model/getConversionRateResponse.d.ts.map +1 -0
  84. package/dist/client-analytics/model/getNoClickRateResponse.d.ts +6 -6
  85. package/dist/client-analytics/model/getNoClickRateResponse.d.ts.map +1 -1
  86. package/dist/client-analytics/model/getNoResultsRateResponse.d.ts +6 -6
  87. package/dist/client-analytics/model/getNoResultsRateResponse.d.ts.map +1 -1
  88. package/dist/client-analytics/model/getPurchaseRateResponse.d.ts +20 -0
  89. package/dist/client-analytics/model/getPurchaseRateResponse.d.ts.map +1 -0
  90. package/dist/client-analytics/model/getRevenue.d.ts +13 -0
  91. package/dist/client-analytics/model/getRevenue.d.ts.map +1 -0
  92. package/dist/client-analytics/model/getSearchesCountResponse.d.ts +3 -3
  93. package/dist/client-analytics/model/getSearchesCountResponse.d.ts.map +1 -1
  94. package/dist/client-analytics/model/getSearchesNoClicksResponse.d.ts +3 -3
  95. package/dist/client-analytics/model/getSearchesNoClicksResponse.d.ts.map +1 -1
  96. package/dist/client-analytics/model/getSearchesNoResultsResponse.d.ts +3 -3
  97. package/dist/client-analytics/model/getSearchesNoResultsResponse.d.ts.map +1 -1
  98. package/dist/client-analytics/model/getStatusResponse.d.ts +2 -2
  99. package/dist/client-analytics/model/getStatusResponse.d.ts.map +1 -1
  100. package/dist/client-analytics/model/getTopCountriesResponse.d.ts +1 -1
  101. package/dist/client-analytics/model/getTopFilterAttributesResponse.d.ts +1 -1
  102. package/dist/client-analytics/model/getTopFilterForAttribute.d.ts +2 -4
  103. package/dist/client-analytics/model/getTopFilterForAttribute.d.ts.map +1 -1
  104. package/dist/client-analytics/model/getTopFiltersNoResultsResponse.d.ts +2 -2
  105. package/dist/client-analytics/model/getTopFiltersNoResultsResponse.d.ts.map +1 -1
  106. package/dist/client-analytics/model/getTopFiltersNoResultsValue.d.ts +2 -4
  107. package/dist/client-analytics/model/getTopFiltersNoResultsValue.d.ts.map +1 -1
  108. package/dist/client-analytics/model/getTopHitsResponse.d.ts +2 -1
  109. package/dist/client-analytics/model/getTopHitsResponse.d.ts.map +1 -1
  110. package/dist/client-analytics/model/getTopSearchesResponse.d.ts +2 -1
  111. package/dist/client-analytics/model/getTopSearchesResponse.d.ts.map +1 -1
  112. package/dist/client-analytics/model/getUsersCountResponse.d.ts +4 -4
  113. package/dist/client-analytics/model/getUsersCountResponse.d.ts.map +1 -1
  114. package/dist/client-analytics/model/index.d.ts +23 -11
  115. package/dist/client-analytics/model/index.d.ts.map +1 -1
  116. package/dist/client-analytics/model/operator.d.ts +5 -0
  117. package/dist/client-analytics/model/operator.d.ts.map +1 -0
  118. package/dist/client-analytics/model/orderBy.d.ts +1 -1
  119. package/dist/client-analytics/model/topCountry.d.ts +1 -1
  120. package/dist/client-analytics/model/topHit.d.ts +1 -1
  121. package/dist/client-analytics/model/topHitWithAnalytics.d.ts +9 -9
  122. package/dist/client-analytics/model/topHitWithAnalytics.d.ts.map +1 -1
  123. package/dist/client-analytics/model/topHitWithRevenueAnalytics.d.ts +52 -0
  124. package/dist/client-analytics/model/topHitWithRevenueAnalytics.d.ts.map +1 -0
  125. package/dist/client-analytics/model/topHitsResponse.d.ts +1 -1
  126. package/dist/client-analytics/model/topHitsResponseWithAnalytics.d.ts +1 -1
  127. package/dist/client-analytics/model/topHitsResponseWithRevenueAnalytics.d.ts +8 -0
  128. package/dist/client-analytics/model/topHitsResponseWithRevenueAnalytics.d.ts.map +1 -0
  129. package/dist/client-analytics/model/topSearch.d.ts +3 -3
  130. package/dist/client-analytics/model/topSearchWithAnalytics.d.ts +17 -12
  131. package/dist/client-analytics/model/topSearchWithAnalytics.d.ts.map +1 -1
  132. package/dist/client-analytics/model/topSearchWithRevenueAnalytics.d.ts +65 -0
  133. package/dist/client-analytics/model/topSearchWithRevenueAnalytics.d.ts.map +1 -0
  134. package/dist/client-analytics/model/topSearchesResponse.d.ts +1 -1
  135. package/dist/client-analytics/model/topSearchesResponseWithAnalytics.d.ts +1 -1
  136. package/dist/client-analytics/model/topSearchesResponseWithRevenueAnalytics.d.ts +8 -0
  137. package/dist/client-analytics/model/topSearchesResponseWithRevenueAnalytics.d.ts.map +1 -0
  138. package/dist/client-analytics/src/analyticsClient.d.ts +211 -138
  139. package/dist/client-analytics/src/analyticsClient.d.ts.map +1 -1
  140. package/dist/client-personalization/model/clientMethodProps.d.ts +2 -2
  141. package/dist/client-personalization/model/deleteUserProfileResponse.d.ts +2 -2
  142. package/dist/client-personalization/model/eventScoring.d.ts +4 -6
  143. package/dist/client-personalization/model/eventScoring.d.ts.map +1 -1
  144. package/dist/client-personalization/model/eventType.d.ts +5 -0
  145. package/dist/client-personalization/model/eventType.d.ts.map +1 -0
  146. package/dist/client-personalization/model/facetScoring.d.ts +2 -2
  147. package/dist/client-personalization/model/getUserTokenResponse.d.ts +3 -3
  148. package/dist/client-personalization/model/index.d.ts +1 -0
  149. package/dist/client-personalization/model/index.d.ts.map +1 -1
  150. package/dist/client-personalization/model/personalizationStrategyParams.d.ts +3 -3
  151. package/dist/client-personalization/src/personalizationClient.d.ts +19 -19
  152. package/dist/client-personalization/src/personalizationClient.d.ts.map +1 -1
  153. package/dist/client-search/model/acl.d.ts +1 -1
  154. package/dist/client-search/model/action.d.ts +1 -1
  155. package/dist/client-search/model/addApiKeyResponse.d.ts +1 -1
  156. package/dist/client-search/model/anchoring.d.ts +1 -1
  157. package/dist/client-search/model/apiKey.d.ts +8 -8
  158. package/dist/client-search/model/apiKeyOperation.d.ts +2 -0
  159. package/dist/client-search/model/apiKeyOperation.d.ts.map +1 -0
  160. package/dist/client-search/model/aroundPrecision.d.ts +1 -1
  161. package/dist/client-search/model/aroundPrecisionFromValueInner.d.ts +9 -0
  162. package/dist/client-search/model/aroundPrecisionFromValueInner.d.ts.map +1 -1
  163. package/dist/client-search/model/aroundRadius.d.ts +1 -1
  164. package/dist/client-search/model/aroundRadiusAll.d.ts +3 -0
  165. package/dist/client-search/model/aroundRadiusAll.d.ts.map +1 -1
  166. package/dist/client-search/model/automaticFacetFilter.d.ts +4 -4
  167. package/dist/client-search/model/automaticFacetFilters.d.ts +1 -1
  168. package/dist/client-search/model/baseGetApiKeyResponse.d.ts +1 -1
  169. package/dist/client-search/model/baseIndexSettings.d.ts +23 -18
  170. package/dist/client-search/model/baseIndexSettings.d.ts.map +1 -1
  171. package/dist/client-search/model/baseSearchParamsWithoutQuery.d.ts +26 -29
  172. package/dist/client-search/model/baseSearchParamsWithoutQuery.d.ts.map +1 -1
  173. package/dist/client-search/model/baseSearchResponse.d.ts +8 -20
  174. package/dist/client-search/model/baseSearchResponse.d.ts.map +1 -1
  175. package/dist/client-search/model/batchDictionaryEntriesParams.d.ts +3 -3
  176. package/dist/client-search/model/batchResponse.d.ts +2 -2
  177. package/dist/client-search/model/browsePagination.d.ts +19 -0
  178. package/dist/client-search/model/browsePagination.d.ts.map +1 -0
  179. package/dist/client-search/model/browseResponse.d.ts +2 -1
  180. package/dist/client-search/model/browseResponse.d.ts.map +1 -1
  181. package/dist/client-search/model/builtInOperation.d.ts +2 -2
  182. package/dist/client-search/model/builtInOperationType.d.ts +1 -1
  183. package/dist/client-search/model/clientMethodProps.d.ts +137 -70
  184. package/dist/client-search/model/clientMethodProps.d.ts.map +1 -1
  185. package/dist/client-search/model/condition.d.ts +7 -3
  186. package/dist/client-search/model/condition.d.ts.map +1 -1
  187. package/dist/client-search/model/consequence.d.ts +5 -5
  188. package/dist/client-search/model/consequenceHide.d.ts +2 -2
  189. package/dist/client-search/model/consequenceQuery.d.ts +1 -1
  190. package/dist/client-search/model/consequenceQueryObject.d.ts +2 -2
  191. package/dist/client-search/model/createdAtResponse.d.ts +1 -1
  192. package/dist/client-search/model/cursor.d.ts +1 -1
  193. package/dist/client-search/model/deleteApiKeyResponse.d.ts +1 -1
  194. package/dist/client-search/model/deleteByParams.d.ts +4 -4
  195. package/dist/client-search/model/deleteSourceResponse.d.ts +1 -1
  196. package/dist/client-search/model/deletedAtResponse.d.ts +2 -2
  197. package/dist/client-search/model/dictionaryEntry.d.ts +6 -8
  198. package/dist/client-search/model/dictionaryEntry.d.ts.map +1 -1
  199. package/dist/client-search/model/dictionaryEntryState.d.ts +1 -1
  200. package/dist/client-search/model/dictionaryLanguage.d.ts +2 -2
  201. package/dist/client-search/model/dictionarySettingsParams.d.ts +1 -1
  202. package/dist/client-search/model/distinct.d.ts +1 -1
  203. package/dist/client-search/model/edit.d.ts +1 -1
  204. package/dist/client-search/model/exactOnSingleWordQuery.d.ts +1 -1
  205. package/dist/client-search/model/facetFilters.d.ts +2 -3
  206. package/dist/client-search/model/facetFilters.d.ts.map +1 -1
  207. package/dist/client-search/model/facetHits.d.ts +2 -2
  208. package/dist/client-search/model/facetOrdering.d.ts +2 -2
  209. package/dist/client-search/model/facets.d.ts +2 -2
  210. package/dist/client-search/model/fetchedIndex.d.ts +5 -1
  211. package/dist/client-search/model/fetchedIndex.d.ts.map +1 -1
  212. package/dist/client-search/model/getObjectsRequest.d.ts +3 -3
  213. package/dist/client-search/model/getObjectsResponse.d.ts +1 -1
  214. package/dist/client-search/model/hasPendingMappingsResponse.d.ts +1 -1
  215. package/dist/client-search/model/highlightResult.d.ts +1 -1
  216. package/dist/client-search/model/highlightResult.d.ts.map +1 -1
  217. package/dist/client-search/model/highlightResultOption.d.ts +3 -3
  218. package/dist/client-search/model/hit.d.ts +4 -4
  219. package/dist/client-search/model/ignorePlurals.d.ts +3 -2
  220. package/dist/client-search/model/ignorePlurals.d.ts.map +1 -1
  221. package/dist/client-search/model/index.d.ts +8 -1
  222. package/dist/client-search/model/index.d.ts.map +1 -1
  223. package/dist/client-search/model/indexSettings.d.ts +1 -1
  224. package/dist/client-search/model/indexSettingsAsSearchParams.d.ts +32 -35
  225. package/dist/client-search/model/indexSettingsAsSearchParams.d.ts.map +1 -1
  226. package/dist/client-search/model/log.d.ts +11 -11
  227. package/dist/client-search/model/logQuery.d.ts +1 -1
  228. package/dist/client-search/model/matchLevel.d.ts +1 -1
  229. package/dist/client-search/model/mode.d.ts +1 -1
  230. package/dist/client-search/model/multipleBatchRequest.d.ts +1 -1
  231. package/dist/client-search/model/multipleBatchResponse.d.ts +2 -2
  232. package/dist/client-search/model/numericFilters.d.ts +2 -3
  233. package/dist/client-search/model/numericFilters.d.ts.map +1 -1
  234. package/dist/client-search/model/operationIndexParams.d.ts +2 -2
  235. package/dist/client-search/model/operationType.d.ts +1 -1
  236. package/dist/client-search/model/optionalFilters.d.ts +2 -3
  237. package/dist/client-search/model/optionalFilters.d.ts.map +1 -1
  238. package/dist/client-search/model/params.d.ts +1 -1
  239. package/dist/client-search/model/promoteObjectID.d.ts +2 -2
  240. package/dist/client-search/model/promoteObjectIDs.d.ts +2 -2
  241. package/dist/client-search/model/queryType.d.ts +1 -1
  242. package/dist/client-search/model/rankingInfo.d.ts +13 -10
  243. package/dist/client-search/model/rankingInfo.d.ts.map +1 -1
  244. package/dist/client-search/model/reRankingApplyFilter.d.ts +2 -3
  245. package/dist/client-search/model/reRankingApplyFilter.d.ts.map +1 -1
  246. package/dist/client-search/model/redirect.d.ts +1 -1
  247. package/dist/client-search/model/redirectURL.d.ts +7 -0
  248. package/dist/client-search/model/redirectURL.d.ts.map +1 -0
  249. package/dist/client-search/model/removeStopWords.d.ts +3 -2
  250. package/dist/client-search/model/removeStopWords.d.ts.map +1 -1
  251. package/dist/client-search/model/removeUserIdResponse.d.ts +1 -1
  252. package/dist/client-search/model/removeWordsIfNoResults.d.ts +1 -1
  253. package/dist/client-search/model/renderingContent.d.ts +3 -1
  254. package/dist/client-search/model/renderingContent.d.ts.map +1 -1
  255. package/dist/client-search/model/replaceAllObjectsResponse.d.ts +11 -0
  256. package/dist/client-search/model/replaceAllObjectsResponse.d.ts.map +1 -0
  257. package/dist/client-search/model/replaceSourceResponse.d.ts +1 -1
  258. package/dist/client-search/model/rule.d.ts +5 -5
  259. package/dist/client-search/model/saveObjectResponse.d.ts +3 -3
  260. package/dist/client-search/model/saveSynonymResponse.d.ts +2 -2
  261. package/dist/client-search/model/searchDictionaryEntriesParams.d.ts +5 -7
  262. package/dist/client-search/model/searchDictionaryEntriesParams.d.ts.map +1 -1
  263. package/dist/client-search/model/searchDictionaryEntriesResponse.d.ts +20 -0
  264. package/dist/client-search/model/searchDictionaryEntriesResponse.d.ts.map +1 -0
  265. package/dist/client-search/model/searchForFacetValuesRequest.d.ts +1 -1
  266. package/dist/client-search/model/searchForFacetValuesResponse.d.ts +4 -1
  267. package/dist/client-search/model/searchForFacetValuesResponse.d.ts.map +1 -1
  268. package/dist/client-search/model/searchForFacetsOptions.d.ts +2 -2
  269. package/dist/client-search/model/searchForHitsOptions.d.ts +1 -1
  270. package/dist/client-search/model/searchHits.d.ts +6 -3
  271. package/dist/client-search/model/searchHits.d.ts.map +1 -1
  272. package/dist/client-search/model/searchPagination.d.ts +19 -0
  273. package/dist/client-search/model/searchPagination.d.ts.map +1 -0
  274. package/dist/client-search/model/searchParamsObject.d.ts +3 -0
  275. package/dist/client-search/model/searchParamsObject.d.ts.map +1 -1
  276. package/dist/client-search/model/searchParamsQuery.d.ts +1 -1
  277. package/dist/client-search/model/searchResponse.d.ts +2 -1
  278. package/dist/client-search/model/searchResponse.d.ts.map +1 -1
  279. package/dist/client-search/model/searchRulesParams.d.ts +4 -8
  280. package/dist/client-search/model/searchRulesParams.d.ts.map +1 -1
  281. package/dist/client-search/model/searchRulesResponse.d.ts +2 -2
  282. package/dist/client-search/model/searchStrategy.d.ts +1 -1
  283. package/dist/client-search/model/searchSynonymsParams.d.ts +2 -2
  284. package/dist/client-search/model/searchSynonymsResponse.d.ts +2 -2
  285. package/dist/client-search/model/searchUserIdsParams.d.ts +1 -1
  286. package/dist/client-search/model/searchUserIdsResponse.d.ts +3 -3
  287. package/dist/client-search/model/securedApiKeyRestrictions.d.ts +25 -0
  288. package/dist/client-search/model/securedApiKeyRestrictions.d.ts.map +1 -0
  289. package/dist/client-search/model/semanticSearch.d.ts +2 -2
  290. package/dist/client-search/model/snippetResult.d.ts +1 -1
  291. package/dist/client-search/model/snippetResult.d.ts.map +1 -1
  292. package/dist/client-search/model/snippetResultOption.d.ts +2 -2
  293. package/dist/client-search/model/sortRemainingBy.d.ts +1 -1
  294. package/dist/client-search/model/supportedLanguage.d.ts +5 -0
  295. package/dist/client-search/model/supportedLanguage.d.ts.map +1 -0
  296. package/dist/client-search/model/tagFilters.d.ts +2 -3
  297. package/dist/client-search/model/tagFilters.d.ts.map +1 -1
  298. package/dist/client-search/model/taskStatus.d.ts +1 -1
  299. package/dist/client-search/model/timeRange.d.ts +2 -2
  300. package/dist/client-search/model/typoTolerance.d.ts +1 -1
  301. package/dist/client-search/model/typoToleranceEnum.d.ts +3 -0
  302. package/dist/client-search/model/typoToleranceEnum.d.ts.map +1 -1
  303. package/dist/client-search/model/updateApiKeyResponse.d.ts +1 -1
  304. package/dist/client-search/model/updatedAtResponse.d.ts +2 -2
  305. package/dist/client-search/model/updatedAtWithObjectIdResponse.d.ts +3 -3
  306. package/dist/client-search/model/updatedRuleResponse.d.ts +3 -3
  307. package/dist/client-search/model/userHit.d.ts +1 -1
  308. package/dist/client-search/model/userId.d.ts +1 -1
  309. package/dist/client-search/model/value.d.ts +5 -1
  310. package/dist/client-search/model/value.d.ts.map +1 -1
  311. package/dist/client-search/src/searchClient.d.ts +385 -208
  312. package/dist/client-search/src/searchClient.d.ts.map +1 -1
  313. package/dist/lite/builds/browser.d.ts +15 -3
  314. package/dist/lite/builds/browser.d.ts.map +1 -1
  315. package/dist/lite/builds/node.d.ts +15 -3
  316. package/dist/lite/builds/node.d.ts.map +1 -1
  317. package/dist/lite/lite.cjs +45 -6
  318. package/dist/lite/lite.esm.browser.js +59 -30
  319. package/dist/lite/lite.esm.node.js +45 -6
  320. package/dist/lite/lite.umd.js +2 -2
  321. package/dist/lite/model/acl.d.ts +1 -1
  322. package/dist/lite/model/apiKey.d.ts +8 -8
  323. package/dist/lite/model/aroundPrecision.d.ts +1 -1
  324. package/dist/lite/model/aroundPrecisionFromValueInner.d.ts +9 -0
  325. package/dist/lite/model/aroundPrecisionFromValueInner.d.ts.map +1 -1
  326. package/dist/lite/model/aroundRadius.d.ts +1 -1
  327. package/dist/lite/model/aroundRadiusAll.d.ts +3 -0
  328. package/dist/lite/model/aroundRadiusAll.d.ts.map +1 -1
  329. package/dist/lite/model/automaticFacetFilter.d.ts +4 -4
  330. package/dist/lite/model/automaticFacetFilters.d.ts +1 -1
  331. package/dist/lite/model/baseGetApiKeyResponse.d.ts +1 -1
  332. package/dist/lite/model/baseIndexSettings.d.ts +23 -18
  333. package/dist/lite/model/baseIndexSettings.d.ts.map +1 -1
  334. package/dist/lite/model/baseRecommendRequest.d.ts +17 -0
  335. package/dist/lite/model/baseRecommendRequest.d.ts.map +1 -0
  336. package/dist/lite/model/baseSearchParamsWithoutQuery.d.ts +26 -29
  337. package/dist/lite/model/baseSearchParamsWithoutQuery.d.ts.map +1 -1
  338. package/dist/lite/model/baseSearchResponse.d.ts +8 -20
  339. package/dist/lite/model/baseSearchResponse.d.ts.map +1 -1
  340. package/dist/lite/model/boughtTogetherQuery.d.ts +4 -0
  341. package/dist/lite/model/boughtTogetherQuery.d.ts.map +1 -0
  342. package/dist/lite/model/browsePagination.d.ts +19 -0
  343. package/dist/lite/model/browsePagination.d.ts.map +1 -0
  344. package/dist/lite/model/browseResponse.d.ts +2 -1
  345. package/dist/lite/model/browseResponse.d.ts.map +1 -1
  346. package/dist/lite/model/clientMethodProps.d.ts +7 -0
  347. package/dist/lite/model/clientMethodProps.d.ts.map +1 -1
  348. package/dist/lite/model/consequenceQuery.d.ts +1 -1
  349. package/dist/lite/model/consequenceQueryObject.d.ts +2 -2
  350. package/dist/lite/model/cursor.d.ts +1 -1
  351. package/dist/lite/model/distinct.d.ts +1 -1
  352. package/dist/lite/model/edit.d.ts +1 -1
  353. package/dist/lite/model/exactOnSingleWordQuery.d.ts +1 -1
  354. package/dist/lite/model/facetFilters.d.ts +2 -3
  355. package/dist/lite/model/facetFilters.d.ts.map +1 -1
  356. package/dist/lite/model/facetHits.d.ts +2 -2
  357. package/dist/lite/model/facetOrdering.d.ts +2 -2
  358. package/dist/lite/model/facets.d.ts +2 -2
  359. package/dist/lite/model/fallbackParams.d.ts +3 -0
  360. package/dist/lite/model/fallbackParams.d.ts.map +1 -0
  361. package/dist/lite/model/fbtModel.d.ts +5 -0
  362. package/dist/lite/model/fbtModel.d.ts.map +1 -0
  363. package/dist/lite/model/frequentlyBoughtTogether.d.ts +9 -0
  364. package/dist/lite/model/frequentlyBoughtTogether.d.ts.map +1 -0
  365. package/dist/lite/model/getRecommendationsParams.d.ts +11 -0
  366. package/dist/lite/model/getRecommendationsParams.d.ts.map +1 -0
  367. package/dist/lite/model/getRecommendationsResponse.d.ts +5 -0
  368. package/dist/lite/model/getRecommendationsResponse.d.ts.map +1 -0
  369. package/dist/lite/model/highlightResult.d.ts +1 -1
  370. package/dist/lite/model/highlightResult.d.ts.map +1 -1
  371. package/dist/lite/model/highlightResultOption.d.ts +3 -3
  372. package/dist/lite/model/hit.d.ts +4 -4
  373. package/dist/lite/model/ignorePlurals.d.ts +3 -2
  374. package/dist/lite/model/ignorePlurals.d.ts.map +1 -1
  375. package/dist/lite/model/index.d.ts +32 -37
  376. package/dist/lite/model/index.d.ts.map +1 -1
  377. package/dist/lite/model/indexSettings.d.ts +1 -1
  378. package/dist/lite/model/indexSettingsAsSearchParams.d.ts +32 -35
  379. package/dist/lite/model/indexSettingsAsSearchParams.d.ts.map +1 -1
  380. package/dist/lite/model/lookingSimilar.d.ts +11 -0
  381. package/dist/lite/model/lookingSimilar.d.ts.map +1 -0
  382. package/dist/lite/model/lookingSimilarModel.d.ts +5 -0
  383. package/dist/lite/model/lookingSimilarModel.d.ts.map +1 -0
  384. package/dist/lite/model/lookingSimilarQuery.d.ts +4 -0
  385. package/dist/lite/model/lookingSimilarQuery.d.ts.map +1 -0
  386. package/dist/lite/model/matchLevel.d.ts +1 -1
  387. package/dist/lite/model/mode.d.ts +1 -1
  388. package/dist/lite/model/numericFilters.d.ts +2 -3
  389. package/dist/lite/model/numericFilters.d.ts.map +1 -1
  390. package/dist/lite/model/optionalFilters.d.ts +2 -3
  391. package/dist/lite/model/optionalFilters.d.ts.map +1 -1
  392. package/dist/lite/model/params.d.ts +1 -1
  393. package/dist/lite/model/queryType.d.ts +1 -1
  394. package/dist/lite/model/rankingInfo.d.ts +13 -10
  395. package/dist/lite/model/rankingInfo.d.ts.map +1 -1
  396. package/dist/lite/model/reRankingApplyFilter.d.ts +2 -3
  397. package/dist/lite/model/reRankingApplyFilter.d.ts.map +1 -1
  398. package/dist/lite/model/recommendHit.d.ts +27 -0
  399. package/dist/lite/model/recommendHit.d.ts.map +1 -0
  400. package/dist/lite/model/recommendationsHit.d.ts +4 -0
  401. package/dist/lite/model/recommendationsHit.d.ts.map +1 -0
  402. package/dist/lite/model/recommendationsHits.d.ts +5 -0
  403. package/dist/lite/model/recommendationsHits.d.ts.map +1 -0
  404. package/dist/lite/model/recommendationsRequest.d.ts +8 -0
  405. package/dist/lite/model/recommendationsRequest.d.ts.map +1 -0
  406. package/dist/lite/model/recommendationsResults.d.ts +5 -0
  407. package/dist/lite/model/recommendationsResults.d.ts.map +1 -0
  408. package/dist/lite/model/recommendedForYou.d.ts +7 -0
  409. package/dist/lite/model/recommendedForYou.d.ts.map +1 -0
  410. package/dist/lite/model/recommendedForYouModel.d.ts +5 -0
  411. package/dist/lite/model/recommendedForYouModel.d.ts.map +1 -0
  412. package/dist/lite/model/recommendedForYouQuery.d.ts +4 -0
  413. package/dist/lite/model/recommendedForYouQuery.d.ts.map +1 -0
  414. package/dist/lite/model/redirect.d.ts +1 -1
  415. package/dist/lite/model/redirectURL.d.ts +7 -0
  416. package/dist/lite/model/redirectURL.d.ts.map +1 -0
  417. package/dist/lite/model/relatedModel.d.ts +5 -0
  418. package/dist/lite/model/relatedModel.d.ts.map +1 -0
  419. package/dist/lite/model/relatedProducts.d.ts +11 -0
  420. package/dist/lite/model/relatedProducts.d.ts.map +1 -0
  421. package/dist/lite/model/relatedQuery.d.ts +4 -0
  422. package/dist/lite/model/relatedQuery.d.ts.map +1 -0
  423. package/dist/lite/model/removeStopWords.d.ts +3 -2
  424. package/dist/lite/model/removeStopWords.d.ts.map +1 -1
  425. package/dist/lite/model/removeWordsIfNoResults.d.ts +1 -1
  426. package/dist/lite/model/renderingContent.d.ts +3 -1
  427. package/dist/lite/model/renderingContent.d.ts.map +1 -1
  428. package/dist/lite/model/searchForFacetValuesResponse.d.ts +4 -1
  429. package/dist/lite/model/searchForFacetValuesResponse.d.ts.map +1 -1
  430. package/dist/lite/model/searchForFacetsOptions.d.ts +2 -2
  431. package/dist/lite/model/searchForHitsOptions.d.ts +1 -1
  432. package/dist/lite/model/searchHits.d.ts +6 -3
  433. package/dist/lite/model/searchHits.d.ts.map +1 -1
  434. package/dist/lite/model/searchPagination.d.ts +19 -0
  435. package/dist/lite/model/searchPagination.d.ts.map +1 -0
  436. package/dist/lite/model/searchParams.d.ts +1 -2
  437. package/dist/lite/model/searchParams.d.ts.map +1 -1
  438. package/dist/lite/model/searchParamsObject.d.ts +3 -0
  439. package/dist/lite/model/searchParamsObject.d.ts.map +1 -1
  440. package/dist/lite/model/searchParamsQuery.d.ts +1 -1
  441. package/dist/lite/model/searchResponse.d.ts +2 -1
  442. package/dist/lite/model/searchResponse.d.ts.map +1 -1
  443. package/dist/lite/model/searchStrategy.d.ts +1 -1
  444. package/dist/lite/model/semanticSearch.d.ts +2 -2
  445. package/dist/lite/model/snippetResult.d.ts +1 -1
  446. package/dist/lite/model/snippetResult.d.ts.map +1 -1
  447. package/dist/lite/model/snippetResultOption.d.ts +2 -2
  448. package/dist/lite/model/sortRemainingBy.d.ts +1 -1
  449. package/dist/lite/model/supportedLanguage.d.ts +5 -0
  450. package/dist/lite/model/supportedLanguage.d.ts.map +1 -0
  451. package/dist/lite/model/tagFilters.d.ts +2 -3
  452. package/dist/lite/model/tagFilters.d.ts.map +1 -1
  453. package/dist/lite/model/trendingFacetHit.d.ts +18 -0
  454. package/dist/lite/model/trendingFacetHit.d.ts.map +1 -0
  455. package/dist/lite/model/trendingFacets.d.ts +11 -0
  456. package/dist/lite/model/trendingFacets.d.ts.map +1 -0
  457. package/dist/lite/model/trendingFacetsModel.d.ts +5 -0
  458. package/dist/lite/model/trendingFacetsModel.d.ts.map +1 -0
  459. package/dist/lite/model/trendingFacetsQuery.d.ts +4 -0
  460. package/dist/lite/model/trendingFacetsQuery.d.ts.map +1 -0
  461. package/dist/lite/model/trendingItems.d.ts +15 -0
  462. package/dist/lite/model/trendingItems.d.ts.map +1 -0
  463. package/dist/lite/model/trendingItemsModel.d.ts +5 -0
  464. package/dist/lite/model/trendingItemsModel.d.ts.map +1 -0
  465. package/dist/lite/model/trendingItemsQuery.d.ts +4 -0
  466. package/dist/lite/model/trendingItemsQuery.d.ts.map +1 -0
  467. package/dist/lite/model/typoTolerance.d.ts +1 -1
  468. package/dist/lite/model/typoToleranceEnum.d.ts +3 -0
  469. package/dist/lite/model/typoToleranceEnum.d.ts.map +1 -1
  470. package/dist/lite/model/value.d.ts +5 -1
  471. package/dist/lite/model/value.d.ts.map +1 -1
  472. package/dist/lite/src/liteClient.d.ts +19 -10
  473. package/dist/lite/src/liteClient.d.ts.map +1 -1
  474. package/dist/recommend/model/advancedSyntaxFeatures.d.ts +2 -0
  475. package/dist/recommend/model/advancedSyntaxFeatures.d.ts.map +1 -0
  476. package/dist/recommend/model/alternativesAsExact.d.ts +2 -0
  477. package/dist/recommend/model/alternativesAsExact.d.ts.map +1 -0
  478. package/dist/recommend/model/aroundPrecision.d.ts +6 -0
  479. package/dist/recommend/model/aroundPrecision.d.ts.map +1 -0
  480. package/dist/recommend/model/aroundPrecisionFromValueInner.d.ts +14 -0
  481. package/dist/recommend/model/aroundPrecisionFromValueInner.d.ts.map +1 -0
  482. package/dist/recommend/model/aroundRadius.d.ts +6 -0
  483. package/dist/recommend/model/aroundRadius.d.ts.map +1 -0
  484. package/dist/recommend/model/aroundRadiusAll.d.ts +5 -0
  485. package/dist/recommend/model/aroundRadiusAll.d.ts.map +1 -0
  486. package/dist/recommend/model/autoFacetFilter.d.ts +14 -0
  487. package/dist/recommend/model/autoFacetFilter.d.ts.map +1 -0
  488. package/dist/recommend/model/baseRecommendRequest.d.ts +17 -0
  489. package/dist/recommend/model/baseRecommendRequest.d.ts.map +1 -0
  490. package/dist/recommend/model/baseSearchParams.d.ts +4 -0
  491. package/dist/recommend/model/baseSearchParams.d.ts.map +1 -0
  492. package/dist/recommend/model/baseSearchParamsWithoutQuery.d.ts +116 -0
  493. package/dist/recommend/model/baseSearchParamsWithoutQuery.d.ts.map +1 -0
  494. package/dist/recommend/model/baseSearchResponse.d.ts +94 -0
  495. package/dist/recommend/model/baseSearchResponse.d.ts.map +1 -0
  496. package/dist/recommend/model/boughtTogetherQuery.d.ts +4 -0
  497. package/dist/recommend/model/boughtTogetherQuery.d.ts.map +1 -0
  498. package/dist/recommend/model/clientMethodProps.d.ts +135 -0
  499. package/dist/recommend/model/clientMethodProps.d.ts.map +1 -0
  500. package/dist/recommend/model/condition.d.ts +14 -0
  501. package/dist/recommend/model/condition.d.ts.map +1 -0
  502. package/dist/recommend/model/consequence.d.ts +18 -0
  503. package/dist/recommend/model/consequence.d.ts.map +1 -0
  504. package/dist/recommend/model/deletedAtResponse.d.ts +14 -0
  505. package/dist/recommend/model/deletedAtResponse.d.ts.map +1 -0
  506. package/dist/recommend/model/distinct.d.ts +5 -0
  507. package/dist/recommend/model/distinct.d.ts.map +1 -0
  508. package/dist/recommend/model/errorBase.d.ts +7 -0
  509. package/dist/recommend/model/errorBase.d.ts.map +1 -0
  510. package/dist/recommend/model/exactOnSingleWordQuery.d.ts +5 -0
  511. package/dist/recommend/model/exactOnSingleWordQuery.d.ts.map +1 -0
  512. package/dist/recommend/model/exhaustive.d.ts +26 -0
  513. package/dist/recommend/model/exhaustive.d.ts.map +1 -0
  514. package/dist/recommend/model/facetFilters.d.ts +5 -0
  515. package/dist/recommend/model/facetFilters.d.ts.map +1 -0
  516. package/dist/recommend/model/facetOrdering.d.ts +13 -0
  517. package/dist/recommend/model/facetOrdering.d.ts.map +1 -0
  518. package/dist/recommend/model/facets.d.ts +10 -0
  519. package/dist/recommend/model/facets.d.ts.map +1 -0
  520. package/dist/recommend/model/facetsStats.d.ts +19 -0
  521. package/dist/recommend/model/facetsStats.d.ts.map +1 -0
  522. package/dist/recommend/model/fallbackParams.d.ts +3 -0
  523. package/dist/recommend/model/fallbackParams.d.ts.map +1 -0
  524. package/dist/recommend/model/fbtModel.d.ts +5 -0
  525. package/dist/recommend/model/fbtModel.d.ts.map +1 -0
  526. package/dist/recommend/model/frequentlyBoughtTogether.d.ts +9 -0
  527. package/dist/recommend/model/frequentlyBoughtTogether.d.ts.map +1 -0
  528. package/dist/recommend/model/getRecommendTaskResponse.d.ts +5 -0
  529. package/dist/recommend/model/getRecommendTaskResponse.d.ts.map +1 -0
  530. package/dist/recommend/model/getRecommendationsParams.d.ts +11 -0
  531. package/dist/recommend/model/getRecommendationsParams.d.ts.map +1 -0
  532. package/dist/recommend/model/getRecommendationsResponse.d.ts +5 -0
  533. package/dist/recommend/model/getRecommendationsResponse.d.ts.map +1 -0
  534. package/dist/recommend/model/hideConsequenceObject.d.ts +10 -0
  535. package/dist/recommend/model/hideConsequenceObject.d.ts.map +1 -0
  536. package/dist/recommend/model/highlightResult.d.ts +3 -0
  537. package/dist/recommend/model/highlightResult.d.ts.map +1 -0
  538. package/dist/recommend/model/highlightResultOption.d.ts +20 -0
  539. package/dist/recommend/model/highlightResultOption.d.ts.map +1 -0
  540. package/dist/recommend/model/ignorePlurals.d.ts +6 -0
  541. package/dist/recommend/model/ignorePlurals.d.ts.map +1 -0
  542. package/dist/recommend/model/index.d.ts +94 -0
  543. package/dist/recommend/model/index.d.ts.map +1 -0
  544. package/dist/recommend/model/indexSettingsAsSearchParams.d.ts +160 -0
  545. package/dist/recommend/model/indexSettingsAsSearchParams.d.ts.map +1 -0
  546. package/dist/recommend/model/lookingSimilar.d.ts +11 -0
  547. package/dist/recommend/model/lookingSimilar.d.ts.map +1 -0
  548. package/dist/recommend/model/lookingSimilarModel.d.ts +5 -0
  549. package/dist/recommend/model/lookingSimilarModel.d.ts.map +1 -0
  550. package/dist/recommend/model/lookingSimilarQuery.d.ts +4 -0
  551. package/dist/recommend/model/lookingSimilarQuery.d.ts.map +1 -0
  552. package/dist/recommend/model/matchLevel.d.ts +5 -0
  553. package/dist/recommend/model/matchLevel.d.ts.map +1 -0
  554. package/dist/recommend/model/matchedGeoLocation.d.ts +15 -0
  555. package/dist/recommend/model/matchedGeoLocation.d.ts.map +1 -0
  556. package/dist/recommend/model/mode.d.ts +5 -0
  557. package/dist/recommend/model/mode.d.ts.map +1 -0
  558. package/dist/recommend/model/numericFilters.d.ts +5 -0
  559. package/dist/recommend/model/numericFilters.d.ts.map +1 -0
  560. package/dist/recommend/model/optionalFilters.d.ts +5 -0
  561. package/dist/recommend/model/optionalFilters.d.ts.map +1 -0
  562. package/dist/recommend/model/paramsConsequence.d.ts +19 -0
  563. package/dist/recommend/model/paramsConsequence.d.ts.map +1 -0
  564. package/dist/recommend/model/personalization.d.ts +15 -0
  565. package/dist/recommend/model/personalization.d.ts.map +1 -0
  566. package/dist/recommend/model/promoteConsequenceObject.d.ts +14 -0
  567. package/dist/recommend/model/promoteConsequenceObject.d.ts.map +1 -0
  568. package/dist/recommend/model/queryType.d.ts +5 -0
  569. package/dist/recommend/model/queryType.d.ts.map +1 -0
  570. package/dist/recommend/model/rankingInfo.d.ts +54 -0
  571. package/dist/recommend/model/rankingInfo.d.ts.map +1 -0
  572. package/dist/recommend/model/reRankingApplyFilter.d.ts +5 -0
  573. package/dist/recommend/model/reRankingApplyFilter.d.ts.map +1 -0
  574. package/dist/recommend/model/recommendHit.d.ts +27 -0
  575. package/dist/recommend/model/recommendHit.d.ts.map +1 -0
  576. package/dist/recommend/model/recommendModels.d.ts +2 -0
  577. package/dist/recommend/model/recommendModels.d.ts.map +1 -0
  578. package/dist/recommend/model/recommendRule.d.ts +24 -0
  579. package/dist/recommend/model/recommendRule.d.ts.map +1 -0
  580. package/dist/recommend/model/recommendRuleMetadata.d.ts +10 -0
  581. package/dist/recommend/model/recommendRuleMetadata.d.ts.map +1 -0
  582. package/dist/recommend/model/recommendationsHit.d.ts +4 -0
  583. package/dist/recommend/model/recommendationsHit.d.ts.map +1 -0
  584. package/dist/recommend/model/recommendationsHits.d.ts +5 -0
  585. package/dist/recommend/model/recommendationsHits.d.ts.map +1 -0
  586. package/dist/recommend/model/recommendationsRequest.d.ts +8 -0
  587. package/dist/recommend/model/recommendationsRequest.d.ts.map +1 -0
  588. package/dist/recommend/model/recommendationsResults.d.ts +5 -0
  589. package/dist/recommend/model/recommendationsResults.d.ts.map +1 -0
  590. package/dist/recommend/model/recommendedForYou.d.ts +7 -0
  591. package/dist/recommend/model/recommendedForYou.d.ts.map +1 -0
  592. package/dist/recommend/model/recommendedForYouModel.d.ts +5 -0
  593. package/dist/recommend/model/recommendedForYouModel.d.ts.map +1 -0
  594. package/dist/recommend/model/recommendedForYouQuery.d.ts +4 -0
  595. package/dist/recommend/model/recommendedForYouQuery.d.ts.map +1 -0
  596. package/dist/recommend/model/redirect.d.ts +8 -0
  597. package/dist/recommend/model/redirect.d.ts.map +1 -0
  598. package/dist/recommend/model/redirectRuleIndexMetadata.d.ts +21 -0
  599. package/dist/recommend/model/redirectRuleIndexMetadata.d.ts.map +1 -0
  600. package/dist/recommend/model/redirectRuleIndexMetadataData.d.ts +7 -0
  601. package/dist/recommend/model/redirectRuleIndexMetadataData.d.ts.map +1 -0
  602. package/dist/recommend/model/redirectURL.d.ts +7 -0
  603. package/dist/recommend/model/redirectURL.d.ts.map +1 -0
  604. package/dist/recommend/model/relatedModel.d.ts +5 -0
  605. package/dist/recommend/model/relatedModel.d.ts.map +1 -0
  606. package/dist/recommend/model/relatedProducts.d.ts +11 -0
  607. package/dist/recommend/model/relatedProducts.d.ts.map +1 -0
  608. package/dist/recommend/model/relatedQuery.d.ts +4 -0
  609. package/dist/recommend/model/relatedQuery.d.ts.map +1 -0
  610. package/dist/recommend/model/removeStopWords.d.ts +6 -0
  611. package/dist/recommend/model/removeStopWords.d.ts.map +1 -0
  612. package/dist/recommend/model/removeWordsIfNoResults.d.ts +5 -0
  613. package/dist/recommend/model/removeWordsIfNoResults.d.ts.map +1 -0
  614. package/dist/recommend/model/renderingContent.d.ts +10 -0
  615. package/dist/recommend/model/renderingContent.d.ts.map +1 -0
  616. package/dist/recommend/model/searchPagination.d.ts +19 -0
  617. package/dist/recommend/model/searchPagination.d.ts.map +1 -0
  618. package/dist/recommend/model/searchParams.d.ts +3 -0
  619. package/dist/recommend/model/searchParams.d.ts.map +1 -0
  620. package/dist/recommend/model/searchParamsObject.d.ts +7 -0
  621. package/dist/recommend/model/searchParamsObject.d.ts.map +1 -0
  622. package/dist/recommend/model/searchParamsQuery.d.ts +7 -0
  623. package/dist/recommend/model/searchParamsQuery.d.ts.map +1 -0
  624. package/dist/recommend/model/searchRecommendRulesParams.d.ts +38 -0
  625. package/dist/recommend/model/searchRecommendRulesParams.d.ts.map +1 -0
  626. package/dist/recommend/model/searchRecommendRulesResponse.d.ts +20 -0
  627. package/dist/recommend/model/searchRecommendRulesResponse.d.ts.map +1 -0
  628. package/dist/recommend/model/semanticSearch.d.ts +10 -0
  629. package/dist/recommend/model/semanticSearch.d.ts.map +1 -0
  630. package/dist/recommend/model/snippetResult.d.ts +3 -0
  631. package/dist/recommend/model/snippetResult.d.ts.map +1 -0
  632. package/dist/recommend/model/snippetResultOption.d.ts +12 -0
  633. package/dist/recommend/model/snippetResultOption.d.ts.map +1 -0
  634. package/dist/recommend/model/sortRemainingBy.d.ts +5 -0
  635. package/dist/recommend/model/sortRemainingBy.d.ts.map +1 -0
  636. package/dist/recommend/model/supportedLanguage.d.ts +5 -0
  637. package/dist/recommend/model/supportedLanguage.d.ts.map +1 -0
  638. package/dist/recommend/model/tagFilters.d.ts +5 -0
  639. package/dist/recommend/model/tagFilters.d.ts.map +1 -0
  640. package/dist/recommend/model/taskStatus.d.ts +5 -0
  641. package/dist/recommend/model/taskStatus.d.ts.map +1 -0
  642. package/dist/recommend/model/trendingFacetHit.d.ts +18 -0
  643. package/dist/recommend/model/trendingFacetHit.d.ts.map +1 -0
  644. package/dist/recommend/model/trendingFacets.d.ts +11 -0
  645. package/dist/recommend/model/trendingFacets.d.ts.map +1 -0
  646. package/dist/recommend/model/trendingFacetsModel.d.ts +5 -0
  647. package/dist/recommend/model/trendingFacetsModel.d.ts.map +1 -0
  648. package/dist/recommend/model/trendingFacetsQuery.d.ts +4 -0
  649. package/dist/recommend/model/trendingFacetsQuery.d.ts.map +1 -0
  650. package/dist/recommend/model/trendingItems.d.ts +15 -0
  651. package/dist/recommend/model/trendingItems.d.ts.map +1 -0
  652. package/dist/recommend/model/trendingItemsModel.d.ts +5 -0
  653. package/dist/recommend/model/trendingItemsModel.d.ts.map +1 -0
  654. package/dist/recommend/model/trendingItemsQuery.d.ts +4 -0
  655. package/dist/recommend/model/trendingItemsQuery.d.ts.map +1 -0
  656. package/dist/recommend/model/typoTolerance.d.ts +6 -0
  657. package/dist/recommend/model/typoTolerance.d.ts.map +1 -0
  658. package/dist/recommend/model/typoToleranceEnum.d.ts +5 -0
  659. package/dist/recommend/model/typoToleranceEnum.d.ts.map +1 -0
  660. package/dist/recommend/model/value.d.ts +13 -0
  661. package/dist/recommend/model/value.d.ts.map +1 -0
  662. package/dist/recommend/src/recommendClient.d.ts +132 -0
  663. package/dist/recommend/src/recommendClient.d.ts.map +1 -0
  664. package/lite/builds/browser.ts +11 -6
  665. package/lite/builds/node.ts +10 -5
  666. package/lite/model/acl.ts +1 -1
  667. package/lite/model/apiKey.ts +8 -8
  668. package/lite/model/aroundPrecision.ts +1 -1
  669. package/lite/model/aroundPrecisionFromValueInner.ts +9 -0
  670. package/lite/model/aroundRadius.ts +1 -1
  671. package/lite/model/aroundRadiusAll.ts +3 -0
  672. package/lite/model/automaticFacetFilter.ts +4 -4
  673. package/lite/model/automaticFacetFilters.ts +1 -1
  674. package/lite/model/baseGetApiKeyResponse.ts +1 -1
  675. package/lite/model/baseIndexSettings.ts +25 -18
  676. package/lite/model/baseRecommendRequest.ts +22 -0
  677. package/lite/model/baseSearchParamsWithoutQuery.ts +26 -30
  678. package/lite/model/baseSearchResponse.ts +9 -24
  679. package/lite/model/boughtTogetherQuery.ts +7 -0
  680. package/lite/model/browsePagination.ts +23 -0
  681. package/lite/model/browseResponse.ts +2 -0
  682. package/lite/model/clientMethodProps.ts +8 -0
  683. package/lite/model/consequenceQuery.ts +1 -1
  684. package/lite/model/consequenceQueryObject.ts +2 -2
  685. package/lite/model/cursor.ts +1 -1
  686. package/lite/model/distinct.ts +1 -1
  687. package/lite/model/edit.ts +1 -1
  688. package/lite/model/exactOnSingleWordQuery.ts +1 -1
  689. package/lite/model/facetFilters.ts +2 -4
  690. package/lite/model/facetHits.ts +2 -2
  691. package/lite/model/facetOrdering.ts +2 -2
  692. package/lite/model/facets.ts +2 -2
  693. package/lite/model/{attributeToUpdate.ts → fallbackParams.ts} +2 -2
  694. package/lite/model/fbtModel.ts +6 -0
  695. package/lite/model/{consequenceHide.ts → frequentlyBoughtTogether.ts} +6 -5
  696. package/lite/model/getRecommendationsParams.ts +13 -0
  697. package/lite/model/getRecommendationsResponse.ts +7 -0
  698. package/lite/model/highlightResult.ts +1 -0
  699. package/lite/model/highlightResultOption.ts +3 -3
  700. package/lite/model/hit.ts +4 -4
  701. package/lite/model/ignorePlurals.ts +4 -2
  702. package/lite/model/index.ts +32 -37
  703. package/lite/model/indexSettings.ts +1 -1
  704. package/lite/model/indexSettingsAsSearchParams.ts +32 -36
  705. package/lite/model/lookingSimilar.ts +15 -0
  706. package/lite/model/lookingSimilarModel.ts +6 -0
  707. package/lite/model/lookingSimilarQuery.ts +6 -0
  708. package/lite/model/matchLevel.ts +1 -1
  709. package/lite/model/mode.ts +1 -1
  710. package/lite/model/numericFilters.ts +2 -4
  711. package/lite/model/optionalFilters.ts +2 -4
  712. package/lite/model/params.ts +1 -1
  713. package/lite/model/queryType.ts +1 -1
  714. package/lite/model/rankingInfo.ts +13 -10
  715. package/lite/model/reRankingApplyFilter.ts +2 -4
  716. package/lite/model/recommendHit.ts +34 -0
  717. package/lite/model/{promote.ts → recommendationsHit.ts} +3 -3
  718. package/lite/model/{searchParamsString.ts → recommendationsHits.ts} +4 -5
  719. package/lite/model/recommendationsRequest.ts +16 -0
  720. package/lite/model/recommendationsResults.ts +9 -0
  721. package/lite/model/recommendedForYou.ts +10 -0
  722. package/lite/model/{operationType.ts → recommendedForYouModel.ts} +2 -2
  723. package/lite/model/recommendedForYouQuery.ts +6 -0
  724. package/lite/model/redirect.ts +1 -1
  725. package/lite/model/{dictionaryAction.ts → redirectURL.ts} +4 -2
  726. package/lite/model/relatedModel.ts +6 -0
  727. package/lite/model/relatedProducts.ts +15 -0
  728. package/lite/model/relatedQuery.ts +6 -0
  729. package/lite/model/removeStopWords.ts +4 -2
  730. package/lite/model/removeWordsIfNoResults.ts +1 -1
  731. package/lite/model/renderingContent.ts +4 -1
  732. package/lite/model/searchForFacetValuesResponse.ts +4 -1
  733. package/lite/model/searchForFacetsOptions.ts +2 -2
  734. package/lite/model/searchForHitsOptions.ts +1 -1
  735. package/lite/model/searchHits.ts +6 -3
  736. package/lite/model/searchPagination.ts +23 -0
  737. package/lite/model/searchParams.ts +1 -2
  738. package/lite/model/searchParamsObject.ts +3 -0
  739. package/lite/model/searchParamsQuery.ts +1 -1
  740. package/lite/model/searchResponse.ts +3 -1
  741. package/lite/model/searchStrategy.ts +1 -1
  742. package/lite/model/semanticSearch.ts +2 -2
  743. package/lite/model/snippetResult.ts +2 -1
  744. package/lite/model/snippetResultOption.ts +2 -2
  745. package/lite/model/sortRemainingBy.ts +1 -1
  746. package/lite/model/supportedLanguage.ts +74 -0
  747. package/lite/model/tagFilters.ts +2 -4
  748. package/lite/model/trendingFacetHit.ts +21 -0
  749. package/lite/model/trendingFacets.ts +15 -0
  750. package/lite/model/trendingFacetsModel.ts +6 -0
  751. package/lite/model/trendingFacetsQuery.ts +6 -0
  752. package/lite/model/trendingItems.ts +20 -0
  753. package/lite/model/{dictionaryEntryState.ts → trendingItemsModel.ts} +2 -2
  754. package/lite/model/trendingItemsQuery.ts +6 -0
  755. package/lite/model/typoTolerance.ts +1 -1
  756. package/lite/model/typoToleranceEnum.ts +3 -0
  757. package/lite/model/value.ts +6 -1
  758. package/lite/src/liteClient.ts +64 -12
  759. package/package.json +19 -15
  760. package/dist/client-abtesting/model/currenciesValue.d.ts.map +0 -1
  761. package/dist/client-analytics/model/averageClickEvent.d.ts +0 -15
  762. package/dist/client-analytics/model/averageClickEvent.d.ts.map +0 -1
  763. package/dist/client-analytics/model/clickPosition.d.ts +0 -11
  764. package/dist/client-analytics/model/clickPosition.d.ts.map +0 -1
  765. package/dist/client-analytics/model/clickThroughRateEvent.d.ts +0 -19
  766. package/dist/client-analytics/model/clickThroughRateEvent.d.ts.map +0 -1
  767. package/dist/client-analytics/model/conversionRateEvent.d.ts +0 -19
  768. package/dist/client-analytics/model/conversionRateEvent.d.ts.map +0 -1
  769. package/dist/client-analytics/model/getConversationRateResponse.d.ts +0 -20
  770. package/dist/client-analytics/model/getConversationRateResponse.d.ts.map +0 -1
  771. package/dist/client-analytics/model/noClickRateEvent.d.ts +0 -19
  772. package/dist/client-analytics/model/noClickRateEvent.d.ts.map +0 -1
  773. package/dist/client-analytics/model/noResultsRateEvent.d.ts +0 -19
  774. package/dist/client-analytics/model/noResultsRateEvent.d.ts.map +0 -1
  775. package/dist/client-analytics/model/searchEvent.d.ts +0 -11
  776. package/dist/client-analytics/model/searchEvent.d.ts.map +0 -1
  777. package/dist/client-analytics/model/searchNoClickEvent.d.ts +0 -15
  778. package/dist/client-analytics/model/searchNoClickEvent.d.ts.map +0 -1
  779. package/dist/client-analytics/model/searchNoResultEvent.d.ts +0 -15
  780. package/dist/client-analytics/model/searchNoResultEvent.d.ts.map +0 -1
  781. package/dist/client-analytics/model/userWithDate.d.ts +0 -11
  782. package/dist/client-analytics/model/userWithDate.d.ts.map +0 -1
  783. package/dist/client-search/model/mixedSearchFilters.d.ts +0 -2
  784. package/dist/client-search/model/mixedSearchFilters.d.ts.map +0 -1
  785. package/dist/lite/model/action.d.ts +0 -5
  786. package/dist/lite/model/action.d.ts.map +0 -1
  787. package/dist/lite/model/addApiKeyResponse.d.ts +0 -11
  788. package/dist/lite/model/addApiKeyResponse.d.ts.map +0 -1
  789. package/dist/lite/model/anchoring.d.ts +0 -5
  790. package/dist/lite/model/anchoring.d.ts.map +0 -1
  791. package/dist/lite/model/attributeToUpdate.d.ts +0 -3
  792. package/dist/lite/model/attributeToUpdate.d.ts.map +0 -1
  793. package/dist/lite/model/browseParams.d.ts +0 -4
  794. package/dist/lite/model/browseParams.d.ts.map +0 -1
  795. package/dist/lite/model/builtInOperation.d.ts +0 -12
  796. package/dist/lite/model/builtInOperation.d.ts.map +0 -1
  797. package/dist/lite/model/builtInOperationType.d.ts +0 -5
  798. package/dist/lite/model/builtInOperationType.d.ts.map +0 -1
  799. package/dist/lite/model/condition.d.ts +0 -17
  800. package/dist/lite/model/condition.d.ts.map +0 -1
  801. package/dist/lite/model/consequence.d.ts +0 -26
  802. package/dist/lite/model/consequence.d.ts.map +0 -1
  803. package/dist/lite/model/consequenceHide.d.ts +0 -10
  804. package/dist/lite/model/consequenceHide.d.ts.map +0 -1
  805. package/dist/lite/model/deleteByParams.d.ts +0 -27
  806. package/dist/lite/model/deleteByParams.d.ts.map +0 -1
  807. package/dist/lite/model/dictionaryAction.d.ts +0 -5
  808. package/dist/lite/model/dictionaryAction.d.ts.map +0 -1
  809. package/dist/lite/model/dictionaryEntry.d.ts +0 -28
  810. package/dist/lite/model/dictionaryEntry.d.ts.map +0 -1
  811. package/dist/lite/model/dictionaryEntryState.d.ts +0 -5
  812. package/dist/lite/model/dictionaryEntryState.d.ts.map +0 -1
  813. package/dist/lite/model/dictionaryLanguage.d.ts +0 -10
  814. package/dist/lite/model/dictionaryLanguage.d.ts.map +0 -1
  815. package/dist/lite/model/dictionaryType.d.ts +0 -2
  816. package/dist/lite/model/dictionaryType.d.ts.map +0 -1
  817. package/dist/lite/model/fetchedIndex.d.ts +0 -47
  818. package/dist/lite/model/fetchedIndex.d.ts.map +0 -1
  819. package/dist/lite/model/languages.d.ts +0 -10
  820. package/dist/lite/model/languages.d.ts.map +0 -1
  821. package/dist/lite/model/listIndicesResponse.d.ts +0 -12
  822. package/dist/lite/model/listIndicesResponse.d.ts.map +0 -1
  823. package/dist/lite/model/logType.d.ts +0 -2
  824. package/dist/lite/model/logType.d.ts.map +0 -1
  825. package/dist/lite/model/mixedSearchFilters.d.ts +0 -2
  826. package/dist/lite/model/mixedSearchFilters.d.ts.map +0 -1
  827. package/dist/lite/model/operationType.d.ts +0 -5
  828. package/dist/lite/model/operationType.d.ts.map +0 -1
  829. package/dist/lite/model/promote.d.ts +0 -4
  830. package/dist/lite/model/promote.d.ts.map +0 -1
  831. package/dist/lite/model/promoteObjectID.d.ts +0 -14
  832. package/dist/lite/model/promoteObjectID.d.ts.map +0 -1
  833. package/dist/lite/model/promoteObjectIDs.d.ts +0 -14
  834. package/dist/lite/model/promoteObjectIDs.d.ts.map +0 -1
  835. package/dist/lite/model/rule.d.ts +0 -30
  836. package/dist/lite/model/rule.d.ts.map +0 -1
  837. package/dist/lite/model/scopeType.d.ts +0 -2
  838. package/dist/lite/model/scopeType.d.ts.map +0 -1
  839. package/dist/lite/model/searchParamsString.d.ts +0 -7
  840. package/dist/lite/model/searchParamsString.d.ts.map +0 -1
  841. package/dist/lite/model/searchSynonymsResponse.d.ts +0 -12
  842. package/dist/lite/model/searchSynonymsResponse.d.ts.map +0 -1
  843. package/dist/lite/model/source.d.ts +0 -14
  844. package/dist/lite/model/source.d.ts.map +0 -1
  845. package/dist/lite/model/standardEntries.d.ts +0 -18
  846. package/dist/lite/model/standardEntries.d.ts.map +0 -1
  847. package/dist/lite/model/synonymHit.d.ts +0 -36
  848. package/dist/lite/model/synonymHit.d.ts.map +0 -1
  849. package/dist/lite/model/synonymType.d.ts +0 -5
  850. package/dist/lite/model/synonymType.d.ts.map +0 -1
  851. package/dist/lite/model/taskStatus.d.ts +0 -5
  852. package/dist/lite/model/taskStatus.d.ts.map +0 -1
  853. package/dist/lite/model/timeRange.d.ts +0 -11
  854. package/dist/lite/model/timeRange.d.ts.map +0 -1
  855. package/dist/lite/model/updatedRuleResponse.d.ts +0 -15
  856. package/dist/lite/model/updatedRuleResponse.d.ts.map +0 -1
  857. package/dist/lite/model/userId.d.ts +0 -22
  858. package/dist/lite/model/userId.d.ts.map +0 -1
  859. package/lite/model/action.ts +0 -13
  860. package/lite/model/addApiKeyResponse.ts +0 -13
  861. package/lite/model/anchoring.ts +0 -6
  862. package/lite/model/browseParams.ts +0 -6
  863. package/lite/model/builtInOperation.ts +0 -15
  864. package/lite/model/builtInOperationType.ts +0 -13
  865. package/lite/model/condition.ts +0 -22
  866. package/lite/model/consequence.ts +0 -32
  867. package/lite/model/deleteByParams.ts +0 -36
  868. package/lite/model/dictionaryEntry.ts +0 -35
  869. package/lite/model/dictionaryLanguage.ts +0 -11
  870. package/lite/model/dictionaryType.ts +0 -3
  871. package/lite/model/fetchedIndex.ts +0 -58
  872. package/lite/model/languages.ts +0 -14
  873. package/lite/model/listIndicesResponse.ts +0 -15
  874. package/lite/model/logType.ts +0 -3
  875. package/lite/model/mixedSearchFilters.ts +0 -3
  876. package/lite/model/promoteObjectID.ts +0 -16
  877. package/lite/model/promoteObjectIDs.ts +0 -16
  878. package/lite/model/rule.ts +0 -37
  879. package/lite/model/scopeType.ts +0 -3
  880. package/lite/model/searchSynonymsResponse.ts +0 -15
  881. package/lite/model/source.ts +0 -16
  882. package/lite/model/standardEntries.ts +0 -21
  883. package/lite/model/synonymHit.ts +0 -45
  884. package/lite/model/synonymType.ts +0 -11
  885. package/lite/model/taskStatus.ts +0 -6
  886. package/lite/model/timeRange.ts +0 -13
  887. package/lite/model/updatedRuleResponse.ts +0 -18
  888. package/lite/model/userId.ts +0 -26
@@ -235,6 +235,14 @@ function createStatefulHost(host, status = 'up') {
235
235
  };
236
236
  }
237
237
 
238
+ function _defineProperty(e, r, t) {
239
+ return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
240
+ value: t,
241
+ enumerable: !0,
242
+ configurable: !0,
243
+ writable: !0
244
+ }) : e[r] = t, e;
245
+ }
238
246
  function _toPrimitive(t, r) {
239
247
  if ("object" != typeof t || !t) return t;
240
248
  var e = t[Symbol.toPrimitive];
@@ -247,21 +255,7 @@ function _toPrimitive(t, r) {
247
255
  }
248
256
  function _toPropertyKey(t) {
249
257
  var i = _toPrimitive(t, "string");
250
- return "symbol" == typeof i ? i : String(i);
251
- }
252
- function _defineProperty(obj, key, value) {
253
- key = _toPropertyKey(key);
254
- if (key in obj) {
255
- Object.defineProperty(obj, key, {
256
- value: value,
257
- enumerable: true,
258
- configurable: true,
259
- writable: true
260
- });
261
- } else {
262
- obj[key] = value;
263
- }
264
- return obj;
258
+ return "symbol" == typeof i ? i : i + "";
265
259
  }
266
260
 
267
261
  class AlgoliaError extends Error {
@@ -283,7 +277,7 @@ class ErrorWithStackTrace extends AlgoliaError {
283
277
  }
284
278
  class RetryError extends ErrorWithStackTrace {
285
279
  constructor(stackTrace) {
286
- super('Unreachable hosts - your application id may be incorrect. If the error persists, please create a ticket at https://support.algolia.com/ sharing steps we can use to reproduce the issue.', stackTrace, 'RetryError');
280
+ super('Unreachable hosts - your application id may be incorrect. If the error persists, please reach out to the Algolia Support team: https://alg.li/support.', stackTrace, 'RetryError');
287
281
  }
288
282
  }
289
283
  class ApiError extends ErrorWithStackTrace {
@@ -321,15 +315,14 @@ function shuffle(array) {
321
315
  }
322
316
  function serializeUrl(host, path, queryParameters) {
323
317
  const queryParametersAsString = serializeQueryParameters(queryParameters);
324
- let url = `${host.protocol}://${host.url}/${path.charAt(0) === '/' ? path.substr(1) : path}`;
318
+ let url = `${host.protocol}://${host.url}${host.port ? `:${host.port}` : ''}/${path.charAt(0) === '/' ? path.substring(1) : path}`;
325
319
  if (queryParametersAsString.length) {
326
320
  url += `?${queryParametersAsString}`;
327
321
  }
328
322
  return url;
329
323
  }
330
324
  function serializeQueryParameters(parameters) {
331
- const isObjectOrArray = value => Object.prototype.toString.call(value) === '[object Object]' || Object.prototype.toString.call(value) === '[object Array]';
332
- return Object.keys(parameters).map(key => `${key}=${encodeURIComponent(isObjectOrArray(parameters[key]) ? JSON.stringify(parameters[key]) : parameters[key])}`).join('&');
325
+ return Object.keys(parameters).filter(key => parameters[key] !== undefined).sort().map(key => `${key}=${encodeURIComponent(Object.prototype.toString.call(parameters[key]) === '[object Array]' ? parameters[key].join(',') : parameters[key]).replaceAll('+', '%20')}`).join('&');
333
326
  }
334
327
  function serializeData(request, requestOptions) {
335
328
  if (request.method === 'GET' || request.data === undefined && requestOptions.data === undefined) {
@@ -500,16 +493,13 @@ function createTransporter({
500
493
  if (host === undefined) {
501
494
  throw new RetryError(stackTraceWithoutCredentials(stackTrace));
502
495
  }
503
- let responseTimeout = requestOptions.timeout;
504
- if (responseTimeout === undefined) {
505
- responseTimeout = isRead ? timeouts.read : timeouts.write;
506
- }
496
+ let responseTimeout = isRead ? requestOptions.timeouts?.read || timeouts.read : requestOptions.timeouts?.write || timeouts.write;
507
497
  const payload = {
508
498
  data,
509
499
  headers,
510
500
  method: request.method,
511
501
  url: serializeUrl(host, request.path, queryParameters),
512
- connectTimeout: getTimeout(timeoutsCount, timeouts.connect),
502
+ connectTimeout: getTimeout(timeoutsCount, requestOptions.timeouts?.connect || timeouts.connect),
513
503
  responseTimeout: getTimeout(timeoutsCount, responseTimeout)
514
504
  };
515
505
  /**
@@ -685,9 +675,9 @@ const DEFAULT_READ_TIMEOUT_BROWSER = 2000;
685
675
  const DEFAULT_WRITE_TIMEOUT_BROWSER = 30000;
686
676
 
687
677
  // Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
688
- const apiClientVersion$4 = '5.0.0-alpha.99';
678
+ const apiClientVersion$5 = '5.0.0-beta.10';
689
679
  const REGIONS$2 = ['de', 'us'];
690
- function getDefaultHosts$3(region) {
680
+ function getDefaultHosts$4(region) {
691
681
  const url = !region
692
682
  ? 'analytics.algolia.com'
693
683
  : 'analytics.{region}.algolia.com'.replace('{region}', region);
@@ -697,12 +687,12 @@ function getDefaultHosts$3(region) {
697
687
  function createAbtestingClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, region: regionOption, ...options }) {
698
688
  const auth = createAuth(appIdOption, apiKeyOption, authMode);
699
689
  const transporter = createTransporter({
700
- hosts: getDefaultHosts$3(regionOption),
690
+ hosts: getDefaultHosts$4(regionOption),
701
691
  ...options,
702
692
  algoliaAgent: getAlgoliaAgent({
703
693
  algoliaAgents,
704
694
  client: 'Abtesting',
705
- version: apiClientVersion$4,
695
+ version: apiClientVersion$5,
706
696
  }),
707
697
  baseHeaders: {
708
698
  'content-type': 'text/plain',
@@ -745,9 +735,11 @@ function createAbtestingClient({ appId: appIdOption, apiKey: apiKeyOption, authM
745
735
  transporter.algoliaAgent.add({ segment, version });
746
736
  },
747
737
  /**
748
- * Creates an A/B test.
738
+ * Creates a new A/B test.
739
+ *
740
+ * Required API Key ACLs:
741
+ * - editSettings.
749
742
  *
750
- * @summary Create an A/B test.
751
743
  * @param addABTestsRequest - The addABTestsRequest object.
752
744
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
753
745
  */
@@ -779,7 +771,6 @@ function createAbtestingClient({ appId: appIdOption, apiKey: apiKeyOption, authM
779
771
  /**
780
772
  * This method allow you to send requests to the Algolia REST API.
781
773
  *
782
- * @summary Send requests to the Algolia REST API.
783
774
  * @param customDelete - The customDelete object.
784
775
  * @param customDelete.path - Path of the endpoint, anything after \"/1\" must be specified.
785
776
  * @param customDelete.parameters - Query parameters to apply to the current query.
@@ -789,7 +780,7 @@ function createAbtestingClient({ appId: appIdOption, apiKey: apiKeyOption, authM
789
780
  if (!path) {
790
781
  throw new Error('Parameter `path` is required when calling `customDelete`.');
791
782
  }
792
- const requestPath = '/1{path}'.replace('{path}', path);
783
+ const requestPath = '/{path}'.replace('{path}', path);
793
784
  const headers = {};
794
785
  const queryParameters = parameters ? parameters : {};
795
786
  const request = {
@@ -803,7 +794,6 @@ function createAbtestingClient({ appId: appIdOption, apiKey: apiKeyOption, authM
803
794
  /**
804
795
  * This method allow you to send requests to the Algolia REST API.
805
796
  *
806
- * @summary Send requests to the Algolia REST API.
807
797
  * @param customGet - The customGet object.
808
798
  * @param customGet.path - Path of the endpoint, anything after \"/1\" must be specified.
809
799
  * @param customGet.parameters - Query parameters to apply to the current query.
@@ -813,7 +803,7 @@ function createAbtestingClient({ appId: appIdOption, apiKey: apiKeyOption, authM
813
803
  if (!path) {
814
804
  throw new Error('Parameter `path` is required when calling `customGet`.');
815
805
  }
816
- const requestPath = '/1{path}'.replace('{path}', path);
806
+ const requestPath = '/{path}'.replace('{path}', path);
817
807
  const headers = {};
818
808
  const queryParameters = parameters ? parameters : {};
819
809
  const request = {
@@ -827,7 +817,6 @@ function createAbtestingClient({ appId: appIdOption, apiKey: apiKeyOption, authM
827
817
  /**
828
818
  * This method allow you to send requests to the Algolia REST API.
829
819
  *
830
- * @summary Send requests to the Algolia REST API.
831
820
  * @param customPost - The customPost object.
832
821
  * @param customPost.path - Path of the endpoint, anything after \"/1\" must be specified.
833
822
  * @param customPost.parameters - Query parameters to apply to the current query.
@@ -838,7 +827,7 @@ function createAbtestingClient({ appId: appIdOption, apiKey: apiKeyOption, authM
838
827
  if (!path) {
839
828
  throw new Error('Parameter `path` is required when calling `customPost`.');
840
829
  }
841
- const requestPath = '/1{path}'.replace('{path}', path);
830
+ const requestPath = '/{path}'.replace('{path}', path);
842
831
  const headers = {};
843
832
  const queryParameters = parameters ? parameters : {};
844
833
  const request = {
@@ -853,7 +842,6 @@ function createAbtestingClient({ appId: appIdOption, apiKey: apiKeyOption, authM
853
842
  /**
854
843
  * This method allow you to send requests to the Algolia REST API.
855
844
  *
856
- * @summary Send requests to the Algolia REST API.
857
845
  * @param customPut - The customPut object.
858
846
  * @param customPut.path - Path of the endpoint, anything after \"/1\" must be specified.
859
847
  * @param customPut.parameters - Query parameters to apply to the current query.
@@ -864,7 +852,7 @@ function createAbtestingClient({ appId: appIdOption, apiKey: apiKeyOption, authM
864
852
  if (!path) {
865
853
  throw new Error('Parameter `path` is required when calling `customPut`.');
866
854
  }
867
- const requestPath = '/1{path}'.replace('{path}', path);
855
+ const requestPath = '/{path}'.replace('{path}', path);
868
856
  const headers = {};
869
857
  const queryParameters = parameters ? parameters : {};
870
858
  const request = {
@@ -877,11 +865,13 @@ function createAbtestingClient({ appId: appIdOption, apiKey: apiKeyOption, authM
877
865
  return transporter.request(request, requestOptions);
878
866
  },
879
867
  /**
880
- * Delete an A/B test. To determine the `id` for an A/B test, use the [`listABTests` operation](#tag/abtest/operation/listABTests).
868
+ * Deletes an A/B test by its ID.
869
+ *
870
+ * Required API Key ACLs:
871
+ * - editSettings.
881
872
  *
882
- * @summary Delete an A/B test.
883
873
  * @param deleteABTest - The deleteABTest object.
884
- * @param deleteABTest.id - Unique A/B test ID.
874
+ * @param deleteABTest.id - Unique A/B test identifier.
885
875
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
886
876
  */
887
877
  deleteABTest({ id }, requestOptions) {
@@ -900,11 +890,13 @@ function createAbtestingClient({ appId: appIdOption, apiKey: apiKeyOption, authM
900
890
  return transporter.request(request, requestOptions);
901
891
  },
902
892
  /**
903
- * Get specific details for an A/B test. To determine the `id` for an A/B test, use the [`listABTests` operation](#tag/abtest/operation/listABTests).
893
+ * Retrieves the details for an A/B test by its ID.
894
+ *
895
+ * Required API Key ACLs:
896
+ * - analytics.
904
897
  *
905
- * @summary Get A/B test details.
906
898
  * @param getABTest - The getABTest object.
907
- * @param getABTest.id - Unique A/B test ID.
899
+ * @param getABTest.id - Unique A/B test identifier.
908
900
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
909
901
  */
910
902
  getABTest({ id }, requestOptions) {
@@ -923,14 +915,16 @@ function createAbtestingClient({ appId: appIdOption, apiKey: apiKeyOption, authM
923
915
  return transporter.request(request, requestOptions);
924
916
  },
925
917
  /**
926
- * List all A/B tests.
918
+ * Lists all A/B tests you configured for this application.
919
+ *
920
+ * Required API Key ACLs:
921
+ * - analytics.
927
922
  *
928
- * @summary List all A/B tests.
929
923
  * @param listABTests - The listABTests object.
930
- * @param listABTests.offset - Position of the starting record. Used for paging. 0 is the first record.
931
- * @param listABTests.limit - Number of records to return (page size).
932
- * @param listABTests.indexPrefix - Only return A/B tests for indices starting with this prefix.
933
- * @param listABTests.indexSuffix - Only return A/B tests for indices ending with this suffix.
924
+ * @param listABTests.offset - Position of the first item to return.
925
+ * @param listABTests.limit - Number of items to return.
926
+ * @param listABTests.indexPrefix - Index name prefix. Only A/B tests for indices starting with this string are included in the response.
927
+ * @param listABTests.indexSuffix - Index name suffix. Only A/B tests for indices ending with this string are included in the response.
934
928
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
935
929
  */
936
930
  listABTests({ offset, limit, indexPrefix, indexSuffix } = {}, requestOptions = undefined) {
@@ -958,11 +952,13 @@ function createAbtestingClient({ appId: appIdOption, apiKey: apiKeyOption, authM
958
952
  return transporter.request(request, requestOptions);
959
953
  },
960
954
  /**
961
- * If stopped, the test is over and can\'t be restarted. There is now only one index, receiving 100% of all search requests. The data gathered for stopped A/B tests is retained. To determine the `id` for an A/B test, use the [`listABTests` operation](#tag/abtest/operation/listABTests).
955
+ * Stops an A/B test by its ID. You can\'t restart stopped A/B tests.
956
+ *
957
+ * Required API Key ACLs:
958
+ * - editSettings.
962
959
  *
963
- * @summary Stop an A/B test.
964
960
  * @param stopABTest - The stopABTest object.
965
- * @param stopABTest.id - Unique A/B test ID.
961
+ * @param stopABTest.id - Unique A/B test identifier.
966
962
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
967
963
  */
968
964
  stopABTest({ id }, requestOptions) {
@@ -984,9 +980,9 @@ function createAbtestingClient({ appId: appIdOption, apiKey: apiKeyOption, authM
984
980
  }
985
981
 
986
982
  // Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
987
- const apiClientVersion$3 = '5.0.0-alpha.99';
983
+ const apiClientVersion$4 = '5.0.0-beta.10';
988
984
  const REGIONS$1 = ['de', 'us'];
989
- function getDefaultHosts$2(region) {
985
+ function getDefaultHosts$3(region) {
990
986
  const url = !region
991
987
  ? 'analytics.algolia.com'
992
988
  : 'analytics.{region}.algolia.com'.replace('{region}', region);
@@ -996,12 +992,12 @@ function getDefaultHosts$2(region) {
996
992
  function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, region: regionOption, ...options }) {
997
993
  const auth = createAuth(appIdOption, apiKeyOption, authMode);
998
994
  const transporter = createTransporter({
999
- hosts: getDefaultHosts$2(regionOption),
995
+ hosts: getDefaultHosts$3(regionOption),
1000
996
  ...options,
1001
997
  algoliaAgent: getAlgoliaAgent({
1002
998
  algoliaAgents,
1003
999
  client: 'Analytics',
1004
- version: apiClientVersion$3,
1000
+ version: apiClientVersion$4,
1005
1001
  }),
1006
1002
  baseHeaders: {
1007
1003
  'content-type': 'text/plain',
@@ -1046,7 +1042,6 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1046
1042
  /**
1047
1043
  * This method allow you to send requests to the Algolia REST API.
1048
1044
  *
1049
- * @summary Send requests to the Algolia REST API.
1050
1045
  * @param customDelete - The customDelete object.
1051
1046
  * @param customDelete.path - Path of the endpoint, anything after \"/1\" must be specified.
1052
1047
  * @param customDelete.parameters - Query parameters to apply to the current query.
@@ -1056,7 +1051,7 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1056
1051
  if (!path) {
1057
1052
  throw new Error('Parameter `path` is required when calling `customDelete`.');
1058
1053
  }
1059
- const requestPath = '/1{path}'.replace('{path}', path);
1054
+ const requestPath = '/{path}'.replace('{path}', path);
1060
1055
  const headers = {};
1061
1056
  const queryParameters = parameters ? parameters : {};
1062
1057
  const request = {
@@ -1070,7 +1065,6 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1070
1065
  /**
1071
1066
  * This method allow you to send requests to the Algolia REST API.
1072
1067
  *
1073
- * @summary Send requests to the Algolia REST API.
1074
1068
  * @param customGet - The customGet object.
1075
1069
  * @param customGet.path - Path of the endpoint, anything after \"/1\" must be specified.
1076
1070
  * @param customGet.parameters - Query parameters to apply to the current query.
@@ -1080,7 +1074,7 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1080
1074
  if (!path) {
1081
1075
  throw new Error('Parameter `path` is required when calling `customGet`.');
1082
1076
  }
1083
- const requestPath = '/1{path}'.replace('{path}', path);
1077
+ const requestPath = '/{path}'.replace('{path}', path);
1084
1078
  const headers = {};
1085
1079
  const queryParameters = parameters ? parameters : {};
1086
1080
  const request = {
@@ -1094,7 +1088,6 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1094
1088
  /**
1095
1089
  * This method allow you to send requests to the Algolia REST API.
1096
1090
  *
1097
- * @summary Send requests to the Algolia REST API.
1098
1091
  * @param customPost - The customPost object.
1099
1092
  * @param customPost.path - Path of the endpoint, anything after \"/1\" must be specified.
1100
1093
  * @param customPost.parameters - Query parameters to apply to the current query.
@@ -1105,7 +1098,7 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1105
1098
  if (!path) {
1106
1099
  throw new Error('Parameter `path` is required when calling `customPost`.');
1107
1100
  }
1108
- const requestPath = '/1{path}'.replace('{path}', path);
1101
+ const requestPath = '/{path}'.replace('{path}', path);
1109
1102
  const headers = {};
1110
1103
  const queryParameters = parameters ? parameters : {};
1111
1104
  const request = {
@@ -1120,7 +1113,6 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1120
1113
  /**
1121
1114
  * This method allow you to send requests to the Algolia REST API.
1122
1115
  *
1123
- * @summary Send requests to the Algolia REST API.
1124
1116
  * @param customPut - The customPut object.
1125
1117
  * @param customPut.path - Path of the endpoint, anything after \"/1\" must be specified.
1126
1118
  * @param customPut.parameters - Query parameters to apply to the current query.
@@ -1131,7 +1123,7 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1131
1123
  if (!path) {
1132
1124
  throw new Error('Parameter `path` is required when calling `customPut`.');
1133
1125
  }
1134
- const requestPath = '/1{path}'.replace('{path}', path);
1126
+ const requestPath = '/{path}'.replace('{path}', path);
1135
1127
  const headers = {};
1136
1128
  const queryParameters = parameters ? parameters : {};
1137
1129
  const request = {
@@ -1144,14 +1136,56 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1144
1136
  return transporter.request(request, requestOptions);
1145
1137
  },
1146
1138
  /**
1147
- * Return the average click position for the complete time range and for individual days. > **Note**: If all `positions` have a `clickCount` of `0` or `null`, it means Algolia didn\'t receive any click events for tracked searches. A _tracked_ search is a search request where the `clickAnalytics` parameter is `true`.
1139
+ * Retrieves the add-to-cart rate for all of your searches with at least one add-to-cart event, including a daily breakdown. By default, the analyzed period includes the last eight days including the current day.
1140
+ *
1141
+ * Required API Key ACLs:
1142
+ * - analytics.
1143
+ *
1144
+ * @param getAddToCartRate - The getAddToCartRate object.
1145
+ * @param getAddToCartRate.index - Index name.
1146
+ * @param getAddToCartRate.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1147
+ * @param getAddToCartRate.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1148
+ * @param getAddToCartRate.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1149
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1150
+ */
1151
+ getAddToCartRate({ index, startDate, endDate, tags }, requestOptions) {
1152
+ if (!index) {
1153
+ throw new Error('Parameter `index` is required when calling `getAddToCartRate`.');
1154
+ }
1155
+ const requestPath = '/2/conversions/addToCartRate';
1156
+ const headers = {};
1157
+ const queryParameters = {};
1158
+ if (index !== undefined) {
1159
+ queryParameters.index = index.toString();
1160
+ }
1161
+ if (startDate !== undefined) {
1162
+ queryParameters.startDate = startDate.toString();
1163
+ }
1164
+ if (endDate !== undefined) {
1165
+ queryParameters.endDate = endDate.toString();
1166
+ }
1167
+ if (tags !== undefined) {
1168
+ queryParameters.tags = tags.toString();
1169
+ }
1170
+ const request = {
1171
+ method: 'GET',
1172
+ path: requestPath,
1173
+ queryParameters,
1174
+ headers,
1175
+ };
1176
+ return transporter.request(request, requestOptions);
1177
+ },
1178
+ /**
1179
+ * Retrieves the average click position of your search results, including a daily breakdown. The average click position is the average of all clicked search results\' positions. For example, if users only ever click on the first result for any search, the average click position is 1. By default, the analyzed period includes the last eight days including the current day.
1180
+ *
1181
+ * Required API Key ACLs:
1182
+ * - analytics.
1148
1183
  *
1149
- * @summary Get average click position.
1150
1184
  * @param getAverageClickPosition - The getAverageClickPosition object.
1151
- * @param getAverageClickPosition.index - Index name to target.
1152
- * @param getAverageClickPosition.startDate - Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1153
- * @param getAverageClickPosition.endDate - End date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1154
- * @param getAverageClickPosition.tags - Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.
1185
+ * @param getAverageClickPosition.index - Index name.
1186
+ * @param getAverageClickPosition.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1187
+ * @param getAverageClickPosition.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1188
+ * @param getAverageClickPosition.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1155
1189
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1156
1190
  */
1157
1191
  getAverageClickPosition({ index, startDate, endDate, tags }, requestOptions) {
@@ -1182,14 +1216,16 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1182
1216
  return transporter.request(request, requestOptions);
1183
1217
  },
1184
1218
  /**
1185
- * Show the number of clicks events and their associated position in the search results. > **Note**: If all `positions` have a `clickCount` of `0` or `null`, it means Algolia didn\'t receive any click events for tracked searches. A _tracked_ search is a search request where the `clickAnalytics` parameter is `true`.
1219
+ * Retrieves the positions in the search results and their associated number of clicks. This lets you check how many clicks the first, second, or tenth search results receive.
1220
+ *
1221
+ * Required API Key ACLs:
1222
+ * - analytics.
1186
1223
  *
1187
- * @summary Get click positions.
1188
1224
  * @param getClickPositions - The getClickPositions object.
1189
- * @param getClickPositions.index - Index name to target.
1190
- * @param getClickPositions.startDate - Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1191
- * @param getClickPositions.endDate - End date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1192
- * @param getClickPositions.tags - Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.
1225
+ * @param getClickPositions.index - Index name.
1226
+ * @param getClickPositions.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1227
+ * @param getClickPositions.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1228
+ * @param getClickPositions.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1193
1229
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1194
1230
  */
1195
1231
  getClickPositions({ index, startDate, endDate, tags }, requestOptions) {
@@ -1220,14 +1256,16 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1220
1256
  return transporter.request(request, requestOptions);
1221
1257
  },
1222
1258
  /**
1223
- * Returns a [click-through rate (CTR)](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#click-through-rate).
1259
+ * Retrieves the click-through rate for all of your searches with at least one click event, including a daily breakdown By default, the analyzed period includes the last eight days including the current day.
1260
+ *
1261
+ * Required API Key ACLs:
1262
+ * - analytics.
1224
1263
  *
1225
- * @summary Get click-through rate (CTR).
1226
1264
  * @param getClickThroughRate - The getClickThroughRate object.
1227
- * @param getClickThroughRate.index - Index name to target.
1228
- * @param getClickThroughRate.startDate - Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1229
- * @param getClickThroughRate.endDate - End date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1230
- * @param getClickThroughRate.tags - Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.
1265
+ * @param getClickThroughRate.index - Index name.
1266
+ * @param getClickThroughRate.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1267
+ * @param getClickThroughRate.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1268
+ * @param getClickThroughRate.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1231
1269
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1232
1270
  */
1233
1271
  getClickThroughRate({ index, startDate, endDate, tags }, requestOptions) {
@@ -1258,19 +1296,21 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1258
1296
  return transporter.request(request, requestOptions);
1259
1297
  },
1260
1298
  /**
1261
- * Return a [conversion rate](https://www.algolia.com/doc/guides/search-analytics/concepts/metrics/#conversion-rate).
1299
+ * Retrieves the conversion rate for all of your searches with at least one conversion event, including a daily breakdown. By default, the analyzed period includes the last eight days including the current day.
1300
+ *
1301
+ * Required API Key ACLs:
1302
+ * - analytics.
1262
1303
  *
1263
- * @summary Get conversion rate (CR).
1264
- * @param getConversationRate - The getConversationRate object.
1265
- * @param getConversationRate.index - Index name to target.
1266
- * @param getConversationRate.startDate - Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1267
- * @param getConversationRate.endDate - End date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1268
- * @param getConversationRate.tags - Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.
1304
+ * @param getConversionRate - The getConversionRate object.
1305
+ * @param getConversionRate.index - Index name.
1306
+ * @param getConversionRate.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1307
+ * @param getConversionRate.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1308
+ * @param getConversionRate.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1269
1309
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1270
1310
  */
1271
- getConversationRate({ index, startDate, endDate, tags }, requestOptions) {
1311
+ getConversionRate({ index, startDate, endDate, tags }, requestOptions) {
1272
1312
  if (!index) {
1273
- throw new Error('Parameter `index` is required when calling `getConversationRate`.');
1313
+ throw new Error('Parameter `index` is required when calling `getConversionRate`.');
1274
1314
  }
1275
1315
  const requestPath = '/2/conversions/conversionRate';
1276
1316
  const headers = {};
@@ -1296,14 +1336,16 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1296
1336
  return transporter.request(request, requestOptions);
1297
1337
  },
1298
1338
  /**
1299
- * Returns the rate at which searches don\'t lead to any clicks. The endpoint returns a value for the complete given time range, as well as a value per day. It also returns the count of searches and searches without clicks.
1339
+ * Retrieves the fraction of searches that didn\'t lead to any click within a time range, including a daily breakdown. By default, the analyzed period includes the last eight days including the current day.
1340
+ *
1341
+ * Required API Key ACLs:
1342
+ * - analytics.
1300
1343
  *
1301
- * @summary Get no click rate.
1302
1344
  * @param getNoClickRate - The getNoClickRate object.
1303
- * @param getNoClickRate.index - Index name to target.
1304
- * @param getNoClickRate.startDate - Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1305
- * @param getNoClickRate.endDate - End date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1306
- * @param getNoClickRate.tags - Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.
1345
+ * @param getNoClickRate.index - Index name.
1346
+ * @param getNoClickRate.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1347
+ * @param getNoClickRate.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1348
+ * @param getNoClickRate.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1307
1349
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1308
1350
  */
1309
1351
  getNoClickRate({ index, startDate, endDate, tags }, requestOptions) {
@@ -1334,14 +1376,16 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1334
1376
  return transporter.request(request, requestOptions);
1335
1377
  },
1336
1378
  /**
1337
- * Returns the rate at which searches didn\'t return any results.
1379
+ * Retrieves the fraction of searches that didn\'t return any results within a time range, including a daily breakdown. By default, the analyzed period includes the last eight days including the current day.
1380
+ *
1381
+ * Required API Key ACLs:
1382
+ * - analytics.
1338
1383
  *
1339
- * @summary Get no results rate.
1340
1384
  * @param getNoResultsRate - The getNoResultsRate object.
1341
- * @param getNoResultsRate.index - Index name to target.
1342
- * @param getNoResultsRate.startDate - Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1343
- * @param getNoResultsRate.endDate - End date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1344
- * @param getNoResultsRate.tags - Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.
1385
+ * @param getNoResultsRate.index - Index name.
1386
+ * @param getNoResultsRate.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1387
+ * @param getNoResultsRate.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1388
+ * @param getNoResultsRate.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1345
1389
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1346
1390
  */
1347
1391
  getNoResultsRate({ index, startDate, endDate, tags }, requestOptions) {
@@ -1372,14 +1416,96 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1372
1416
  return transporter.request(request, requestOptions);
1373
1417
  },
1374
1418
  /**
1375
- * Returns the number of searches within a time range.
1419
+ * Retrieves the purchase rate for all of your searches with at least one purchase event, including a daily breakdown. By default, the analyzed period includes the last eight days including the current day.
1420
+ *
1421
+ * Required API Key ACLs:
1422
+ * - analytics.
1423
+ *
1424
+ * @param getPurchaseRate - The getPurchaseRate object.
1425
+ * @param getPurchaseRate.index - Index name.
1426
+ * @param getPurchaseRate.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1427
+ * @param getPurchaseRate.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1428
+ * @param getPurchaseRate.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1429
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1430
+ */
1431
+ getPurchaseRate({ index, startDate, endDate, tags }, requestOptions) {
1432
+ if (!index) {
1433
+ throw new Error('Parameter `index` is required when calling `getPurchaseRate`.');
1434
+ }
1435
+ const requestPath = '/2/conversions/purchaseRate';
1436
+ const headers = {};
1437
+ const queryParameters = {};
1438
+ if (index !== undefined) {
1439
+ queryParameters.index = index.toString();
1440
+ }
1441
+ if (startDate !== undefined) {
1442
+ queryParameters.startDate = startDate.toString();
1443
+ }
1444
+ if (endDate !== undefined) {
1445
+ queryParameters.endDate = endDate.toString();
1446
+ }
1447
+ if (tags !== undefined) {
1448
+ queryParameters.tags = tags.toString();
1449
+ }
1450
+ const request = {
1451
+ method: 'GET',
1452
+ path: requestPath,
1453
+ queryParameters,
1454
+ headers,
1455
+ };
1456
+ return transporter.request(request, requestOptions);
1457
+ },
1458
+ /**
1459
+ * Retrieves revenue-related metrics, such as the total revenue or the average order value. To retrieve revenue-related metrics, sent purchase events. By default, the analyzed period includes the last eight days including the current day.
1460
+ *
1461
+ * Required API Key ACLs:
1462
+ * - analytics.
1463
+ *
1464
+ * @param getRevenue - The getRevenue object.
1465
+ * @param getRevenue.index - Index name.
1466
+ * @param getRevenue.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1467
+ * @param getRevenue.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1468
+ * @param getRevenue.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1469
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1470
+ */
1471
+ getRevenue({ index, startDate, endDate, tags }, requestOptions) {
1472
+ if (!index) {
1473
+ throw new Error('Parameter `index` is required when calling `getRevenue`.');
1474
+ }
1475
+ const requestPath = '/2/conversions/revenue';
1476
+ const headers = {};
1477
+ const queryParameters = {};
1478
+ if (index !== undefined) {
1479
+ queryParameters.index = index.toString();
1480
+ }
1481
+ if (startDate !== undefined) {
1482
+ queryParameters.startDate = startDate.toString();
1483
+ }
1484
+ if (endDate !== undefined) {
1485
+ queryParameters.endDate = endDate.toString();
1486
+ }
1487
+ if (tags !== undefined) {
1488
+ queryParameters.tags = tags.toString();
1489
+ }
1490
+ const request = {
1491
+ method: 'GET',
1492
+ path: requestPath,
1493
+ queryParameters,
1494
+ headers,
1495
+ };
1496
+ return transporter.request(request, requestOptions);
1497
+ },
1498
+ /**
1499
+ * Retrieves the number of searches within a time range, including a daily breakdown. By default, the analyzed period includes the last eight days including the current day.
1500
+ *
1501
+ * Required API Key ACLs:
1502
+ * - analytics.
1376
1503
  *
1377
- * @summary Get number of searches.
1378
1504
  * @param getSearchesCount - The getSearchesCount object.
1379
- * @param getSearchesCount.index - Index name to target.
1380
- * @param getSearchesCount.startDate - Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1381
- * @param getSearchesCount.endDate - End date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1382
- * @param getSearchesCount.tags - Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.
1505
+ * @param getSearchesCount.index - Index name.
1506
+ * @param getSearchesCount.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1507
+ * @param getSearchesCount.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1508
+ * @param getSearchesCount.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1383
1509
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1384
1510
  */
1385
1511
  getSearchesCount({ index, startDate, endDate, tags }, requestOptions) {
@@ -1410,16 +1536,18 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1410
1536
  return transporter.request(request, requestOptions);
1411
1537
  },
1412
1538
  /**
1413
- * Return the most popular of the last 1,000 searches that didn\'t lead to any clicks.
1539
+ * Retrieves the most popular searches that didn\'t lead to any clicks, from the 1,000 most frequent searches.
1540
+ *
1541
+ * Required API Key ACLs:
1542
+ * - analytics.
1414
1543
  *
1415
- * @summary Get top searches with no clicks.
1416
1544
  * @param getSearchesNoClicks - The getSearchesNoClicks object.
1417
- * @param getSearchesNoClicks.index - Index name to target.
1418
- * @param getSearchesNoClicks.startDate - Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1419
- * @param getSearchesNoClicks.endDate - End date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1420
- * @param getSearchesNoClicks.limit - Number of records to return (page size).
1421
- * @param getSearchesNoClicks.offset - Position of the starting record. Used for paging. 0 is the first record.
1422
- * @param getSearchesNoClicks.tags - Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.
1545
+ * @param getSearchesNoClicks.index - Index name.
1546
+ * @param getSearchesNoClicks.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1547
+ * @param getSearchesNoClicks.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1548
+ * @param getSearchesNoClicks.limit - Number of items to return.
1549
+ * @param getSearchesNoClicks.offset - Position of the first item to return.
1550
+ * @param getSearchesNoClicks.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1423
1551
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1424
1552
  */
1425
1553
  getSearchesNoClicks({ index, startDate, endDate, limit, offset, tags, }, requestOptions) {
@@ -1456,16 +1584,18 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1456
1584
  return transporter.request(request, requestOptions);
1457
1585
  },
1458
1586
  /**
1459
- * Returns the most popular of the latest 1,000 searches that didn\'t return any results.
1587
+ * Retrieves the most popular searches that didn\'t return any results.
1588
+ *
1589
+ * Required API Key ACLs:
1590
+ * - analytics.
1460
1591
  *
1461
- * @summary Get top searches with no results.
1462
1592
  * @param getSearchesNoResults - The getSearchesNoResults object.
1463
- * @param getSearchesNoResults.index - Index name to target.
1464
- * @param getSearchesNoResults.startDate - Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1465
- * @param getSearchesNoResults.endDate - End date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1466
- * @param getSearchesNoResults.limit - Number of records to return (page size).
1467
- * @param getSearchesNoResults.offset - Position of the starting record. Used for paging. 0 is the first record.
1468
- * @param getSearchesNoResults.tags - Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.
1593
+ * @param getSearchesNoResults.index - Index name.
1594
+ * @param getSearchesNoResults.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1595
+ * @param getSearchesNoResults.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1596
+ * @param getSearchesNoResults.limit - Number of items to return.
1597
+ * @param getSearchesNoResults.offset - Position of the first item to return.
1598
+ * @param getSearchesNoResults.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1469
1599
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1470
1600
  */
1471
1601
  getSearchesNoResults({ index, startDate, endDate, limit, offset, tags, }, requestOptions) {
@@ -1502,11 +1632,13 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1502
1632
  return transporter.request(request, requestOptions);
1503
1633
  },
1504
1634
  /**
1505
- * Return the latest update time of the Analytics API for an index. If the index has been recently created or no search has been performed yet, `updatedAt` will be `null`. > **Note**: The Analytics API is updated every 5 minutes.
1635
+ * Retrieves the time when the Analytics data for the specified index was last updated. The Analytics data is updated every 5 minutes.
1636
+ *
1637
+ * Required API Key ACLs:
1638
+ * - analytics.
1506
1639
  *
1507
- * @summary Get Analytics API status.
1508
1640
  * @param getStatus - The getStatus object.
1509
- * @param getStatus.index - Index name to target.
1641
+ * @param getStatus.index - Index name.
1510
1642
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1511
1643
  */
1512
1644
  getStatus({ index }, requestOptions) {
@@ -1528,16 +1660,18 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1528
1660
  return transporter.request(request, requestOptions);
1529
1661
  },
1530
1662
  /**
1531
- * Returns top countries. Limited to the 1,000 most frequent ones.
1663
+ * Retrieves the countries with the most searches to your index.
1664
+ *
1665
+ * Required API Key ACLs:
1666
+ * - analytics.
1532
1667
  *
1533
- * @summary Get top countries.
1534
1668
  * @param getTopCountries - The getTopCountries object.
1535
- * @param getTopCountries.index - Index name to target.
1536
- * @param getTopCountries.startDate - Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1537
- * @param getTopCountries.endDate - End date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1538
- * @param getTopCountries.limit - Number of records to return (page size).
1539
- * @param getTopCountries.offset - Position of the starting record. Used for paging. 0 is the first record.
1540
- * @param getTopCountries.tags - Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.
1669
+ * @param getTopCountries.index - Index name.
1670
+ * @param getTopCountries.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1671
+ * @param getTopCountries.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1672
+ * @param getTopCountries.limit - Number of items to return.
1673
+ * @param getTopCountries.offset - Position of the first item to return.
1674
+ * @param getTopCountries.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1541
1675
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1542
1676
  */
1543
1677
  getTopCountries({ index, startDate, endDate, limit, offset, tags }, requestOptions) {
@@ -1574,17 +1708,19 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1574
1708
  return transporter.request(request, requestOptions);
1575
1709
  },
1576
1710
  /**
1577
- * Return the most popular [filterable attributes](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/) in the 1,000 most recently used filters.
1711
+ * Retrieves the most frequently used filter attributes. These are attributes of your records that you included in the `attributesForFaceting` setting.
1712
+ *
1713
+ * Required API Key ACLs:
1714
+ * - analytics.
1578
1715
  *
1579
- * @summary Get top filterable attributes.
1580
1716
  * @param getTopFilterAttributes - The getTopFilterAttributes object.
1581
- * @param getTopFilterAttributes.index - Index name to target.
1582
- * @param getTopFilterAttributes.search - User query.
1583
- * @param getTopFilterAttributes.startDate - Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1584
- * @param getTopFilterAttributes.endDate - End date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1585
- * @param getTopFilterAttributes.limit - Number of records to return (page size).
1586
- * @param getTopFilterAttributes.offset - Position of the starting record. Used for paging. 0 is the first record.
1587
- * @param getTopFilterAttributes.tags - Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.
1717
+ * @param getTopFilterAttributes.index - Index name.
1718
+ * @param getTopFilterAttributes.search - Search query.
1719
+ * @param getTopFilterAttributes.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1720
+ * @param getTopFilterAttributes.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1721
+ * @param getTopFilterAttributes.limit - Number of items to return.
1722
+ * @param getTopFilterAttributes.offset - Position of the first item to return.
1723
+ * @param getTopFilterAttributes.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1588
1724
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1589
1725
  */
1590
1726
  getTopFilterAttributes({ index, search, startDate, endDate, limit, offset, tags, }, requestOptions) {
@@ -1624,18 +1760,20 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1624
1760
  return transporter.request(request, requestOptions);
1625
1761
  },
1626
1762
  /**
1627
- * Returns the most popular filter values for an attribute in the 1,000 most recently used filters.
1763
+ * Retrieves the most frequent filter (facet) values for a filter attribute. These are attributes of your records that you included in the `attributesForFaceting` setting.
1764
+ *
1765
+ * Required API Key ACLs:
1766
+ * - analytics.
1628
1767
  *
1629
- * @summary Get top filter values for an attribute.
1630
1768
  * @param getTopFilterForAttribute - The getTopFilterForAttribute object.
1631
1769
  * @param getTopFilterForAttribute.attribute - Attribute name.
1632
- * @param getTopFilterForAttribute.index - Index name to target.
1633
- * @param getTopFilterForAttribute.search - User query.
1634
- * @param getTopFilterForAttribute.startDate - Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1635
- * @param getTopFilterForAttribute.endDate - End date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1636
- * @param getTopFilterForAttribute.limit - Number of records to return (page size).
1637
- * @param getTopFilterForAttribute.offset - Position of the starting record. Used for paging. 0 is the first record.
1638
- * @param getTopFilterForAttribute.tags - Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.
1770
+ * @param getTopFilterForAttribute.index - Index name.
1771
+ * @param getTopFilterForAttribute.search - Search query.
1772
+ * @param getTopFilterForAttribute.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1773
+ * @param getTopFilterForAttribute.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1774
+ * @param getTopFilterForAttribute.limit - Number of items to return.
1775
+ * @param getTopFilterForAttribute.offset - Position of the first item to return.
1776
+ * @param getTopFilterForAttribute.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1639
1777
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1640
1778
  */
1641
1779
  getTopFilterForAttribute({ attribute, index, search, startDate, endDate, limit, offset, tags, }, requestOptions) {
@@ -1678,17 +1816,19 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1678
1816
  return transporter.request(request, requestOptions);
1679
1817
  },
1680
1818
  /**
1681
- * Returns top filters for filter-enabled searches that don\'t return results. Limited to the 1,000 most recently used filters.
1819
+ * Retrieves the most frequently used filters for a search that didn\'t return any results. To get the most frequent searches without results, use the [Retrieve searches without results](#tag/search/operation/getSearchesNoResults) operation.
1820
+ *
1821
+ * Required API Key ACLs:
1822
+ * - analytics.
1682
1823
  *
1683
- * @summary Get top filters for a no result search.
1684
1824
  * @param getTopFiltersNoResults - The getTopFiltersNoResults object.
1685
- * @param getTopFiltersNoResults.index - Index name to target.
1686
- * @param getTopFiltersNoResults.search - User query.
1687
- * @param getTopFiltersNoResults.startDate - Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1688
- * @param getTopFiltersNoResults.endDate - End date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1689
- * @param getTopFiltersNoResults.limit - Number of records to return (page size).
1690
- * @param getTopFiltersNoResults.offset - Position of the starting record. Used for paging. 0 is the first record.
1691
- * @param getTopFiltersNoResults.tags - Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.
1825
+ * @param getTopFiltersNoResults.index - Index name.
1826
+ * @param getTopFiltersNoResults.search - Search query.
1827
+ * @param getTopFiltersNoResults.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1828
+ * @param getTopFiltersNoResults.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1829
+ * @param getTopFiltersNoResults.limit - Number of items to return.
1830
+ * @param getTopFiltersNoResults.offset - Position of the first item to return.
1831
+ * @param getTopFiltersNoResults.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1692
1832
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1693
1833
  */
1694
1834
  getTopFiltersNoResults({ index, search, startDate, endDate, limit, offset, tags, }, requestOptions) {
@@ -1728,21 +1868,24 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1728
1868
  return transporter.request(request, requestOptions);
1729
1869
  },
1730
1870
  /**
1731
- * Return the most popular clicked results in the last 1,000 searches.
1871
+ * Retrieves the object IDs of the most frequent search results.
1872
+ *
1873
+ * Required API Key ACLs:
1874
+ * - analytics.
1732
1875
  *
1733
- * @summary Get top hits.
1734
1876
  * @param getTopHits - The getTopHits object.
1735
- * @param getTopHits.index - Index name to target.
1736
- * @param getTopHits.search - User query.
1737
- * @param getTopHits.clickAnalytics - Whether to include [click and conversion](https://www.algolia.com/doc/guides/sending-events/getting-started/) rates for a search.
1738
- * @param getTopHits.startDate - Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1739
- * @param getTopHits.endDate - End date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1740
- * @param getTopHits.limit - Number of records to return (page size).
1741
- * @param getTopHits.offset - Position of the starting record. Used for paging. 0 is the first record.
1742
- * @param getTopHits.tags - Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.
1877
+ * @param getTopHits.index - Index name.
1878
+ * @param getTopHits.search - Search query.
1879
+ * @param getTopHits.clickAnalytics - Whether to include metrics related to click and conversion events in the response.
1880
+ * @param getTopHits.revenueAnalytics - Whether to include revenue-related metrics in the response. If true, metrics related to click and conversion events are also included in the response.
1881
+ * @param getTopHits.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1882
+ * @param getTopHits.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1883
+ * @param getTopHits.limit - Number of items to return.
1884
+ * @param getTopHits.offset - Position of the first item to return.
1885
+ * @param getTopHits.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1743
1886
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1744
1887
  */
1745
- getTopHits({ index, search, clickAnalytics, startDate, endDate, limit, offset, tags, }, requestOptions) {
1888
+ getTopHits({ index, search, clickAnalytics, revenueAnalytics, startDate, endDate, limit, offset, tags, }, requestOptions) {
1746
1889
  if (!index) {
1747
1890
  throw new Error('Parameter `index` is required when calling `getTopHits`.');
1748
1891
  }
@@ -1758,6 +1901,9 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1758
1901
  if (clickAnalytics !== undefined) {
1759
1902
  queryParameters.clickAnalytics = clickAnalytics.toString();
1760
1903
  }
1904
+ if (revenueAnalytics !== undefined) {
1905
+ queryParameters.revenueAnalytics = revenueAnalytics.toString();
1906
+ }
1761
1907
  if (startDate !== undefined) {
1762
1908
  queryParameters.startDate = startDate.toString();
1763
1909
  }
@@ -1782,22 +1928,25 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1782
1928
  return transporter.request(request, requestOptions);
1783
1929
  },
1784
1930
  /**
1785
- * Returns the most popular of the latest 1,000 searches. For each search, also returns the number of hits.
1931
+ * Returns the most popular search terms.
1932
+ *
1933
+ * Required API Key ACLs:
1934
+ * - analytics.
1786
1935
  *
1787
- * @summary Get top searches.
1788
1936
  * @param getTopSearches - The getTopSearches object.
1789
- * @param getTopSearches.index - Index name to target.
1790
- * @param getTopSearches.clickAnalytics - Whether to include [click and conversion](https://www.algolia.com/doc/guides/sending-events/getting-started/) rates for a search.
1791
- * @param getTopSearches.startDate - Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1792
- * @param getTopSearches.endDate - End date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1793
- * @param getTopSearches.orderBy - Reorder the results.
1937
+ * @param getTopSearches.index - Index name.
1938
+ * @param getTopSearches.clickAnalytics - Whether to include metrics related to click and conversion events in the response.
1939
+ * @param getTopSearches.revenueAnalytics - Whether to include revenue-related metrics in the response. If true, metrics related to click and conversion events are also included in the response.
1940
+ * @param getTopSearches.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
1941
+ * @param getTopSearches.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
1942
+ * @param getTopSearches.orderBy - Attribute by which to order the response items. If the `clickAnalytics` parameter is false, only `searchCount` is available.
1794
1943
  * @param getTopSearches.direction - Sorting direction of the results: ascending or descending.
1795
- * @param getTopSearches.limit - Number of records to return (page size).
1796
- * @param getTopSearches.offset - Position of the starting record. Used for paging. 0 is the first record.
1797
- * @param getTopSearches.tags - Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.
1944
+ * @param getTopSearches.limit - Number of items to return.
1945
+ * @param getTopSearches.offset - Position of the first item to return.
1946
+ * @param getTopSearches.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1798
1947
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1799
1948
  */
1800
- getTopSearches({ index, clickAnalytics, startDate, endDate, orderBy, direction, limit, offset, tags, }, requestOptions) {
1949
+ getTopSearches({ index, clickAnalytics, revenueAnalytics, startDate, endDate, orderBy, direction, limit, offset, tags, }, requestOptions) {
1801
1950
  if (!index) {
1802
1951
  throw new Error('Parameter `index` is required when calling `getTopSearches`.');
1803
1952
  }
@@ -1810,6 +1959,9 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1810
1959
  if (clickAnalytics !== undefined) {
1811
1960
  queryParameters.clickAnalytics = clickAnalytics.toString();
1812
1961
  }
1962
+ if (revenueAnalytics !== undefined) {
1963
+ queryParameters.revenueAnalytics = revenueAnalytics.toString();
1964
+ }
1813
1965
  if (startDate !== undefined) {
1814
1966
  queryParameters.startDate = startDate.toString();
1815
1967
  }
@@ -1840,14 +1992,16 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1840
1992
  return transporter.request(request, requestOptions);
1841
1993
  },
1842
1994
  /**
1843
- * Return the count of unique users.
1995
+ * Retrieves the number of unique users within a time range, including a daily breakdown. Since this endpoint returns the number of unique users, the sum of the daily values might be different from the total number. By default, Algolia distinguishes search users by their IP address, _unless_ you include a pseudonymous user identifier in your search requests with the `userToken` API parameter or `x-algolia-usertoken` request header. By default, the analyzed period includes the last eight days including the current day.
1996
+ *
1997
+ * Required API Key ACLs:
1998
+ * - analytics.
1844
1999
  *
1845
- * @summary Get user count.
1846
2000
  * @param getUsersCount - The getUsersCount object.
1847
- * @param getUsersCount.index - Index name to target.
1848
- * @param getUsersCount.startDate - Start date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1849
- * @param getUsersCount.endDate - End date (a string in the format `YYYY-MM-DD`) of the period to analyze.
1850
- * @param getUsersCount.tags - Filter analytics on the [`analyticsTags`](https://www.algolia.com/doc/api-reference/api-parameters/analyticsTags/) set at search time. Multiple tags can be combined with the operators OR and AND. If a tag contains characters like spaces or parentheses, it must be URL-encoded.
2001
+ * @param getUsersCount.index - Index name.
2002
+ * @param getUsersCount.startDate - Start date of the period to analyze, in `YYYY-MM-DD` format.
2003
+ * @param getUsersCount.endDate - End date of the period to analyze, in `YYYY-MM-DD` format.
2004
+ * @param getUsersCount.tags - Tags by which to segment the analytics. You can combine multiple tags with `OR` and `AND`. Tags must be URL-encoded. For more information, see [Segment your analytics data](https://www.algolia.com/doc/guides/search-analytics/guides/segments/).
1851
2005
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
1852
2006
  */
1853
2007
  getUsersCount({ index, startDate, endDate, tags }, requestOptions) {
@@ -1881,9 +2035,9 @@ function createAnalyticsClient({ appId: appIdOption, apiKey: apiKeyOption, authM
1881
2035
  }
1882
2036
 
1883
2037
  // Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
1884
- const apiClientVersion$2 = '5.0.0-alpha.99';
2038
+ const apiClientVersion$3 = '5.0.0-beta.10';
1885
2039
  const REGIONS = ['eu', 'us'];
1886
- function getDefaultHosts$1(region) {
2040
+ function getDefaultHosts$2(region) {
1887
2041
  const url = 'personalization.{region}.algolia.com'.replace('{region}', region);
1888
2042
  return [{ url, accept: 'readWrite', protocol: 'https' }];
1889
2043
  }
@@ -1891,12 +2045,12 @@ function getDefaultHosts$1(region) {
1891
2045
  function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, region: regionOption, ...options }) {
1892
2046
  const auth = createAuth(appIdOption, apiKeyOption, authMode);
1893
2047
  const transporter = createTransporter({
1894
- hosts: getDefaultHosts$1(regionOption),
2048
+ hosts: getDefaultHosts$2(regionOption),
1895
2049
  ...options,
1896
2050
  algoliaAgent: getAlgoliaAgent({
1897
2051
  algoliaAgents,
1898
2052
  client: 'Personalization',
1899
- version: apiClientVersion$2,
2053
+ version: apiClientVersion$3,
1900
2054
  }),
1901
2055
  baseHeaders: {
1902
2056
  'content-type': 'text/plain',
@@ -1941,7 +2095,6 @@ function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption,
1941
2095
  /**
1942
2096
  * This method allow you to send requests to the Algolia REST API.
1943
2097
  *
1944
- * @summary Send requests to the Algolia REST API.
1945
2098
  * @param customDelete - The customDelete object.
1946
2099
  * @param customDelete.path - Path of the endpoint, anything after \"/1\" must be specified.
1947
2100
  * @param customDelete.parameters - Query parameters to apply to the current query.
@@ -1951,7 +2104,7 @@ function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption,
1951
2104
  if (!path) {
1952
2105
  throw new Error('Parameter `path` is required when calling `customDelete`.');
1953
2106
  }
1954
- const requestPath = '/1{path}'.replace('{path}', path);
2107
+ const requestPath = '/{path}'.replace('{path}', path);
1955
2108
  const headers = {};
1956
2109
  const queryParameters = parameters ? parameters : {};
1957
2110
  const request = {
@@ -1965,7 +2118,6 @@ function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption,
1965
2118
  /**
1966
2119
  * This method allow you to send requests to the Algolia REST API.
1967
2120
  *
1968
- * @summary Send requests to the Algolia REST API.
1969
2121
  * @param customGet - The customGet object.
1970
2122
  * @param customGet.path - Path of the endpoint, anything after \"/1\" must be specified.
1971
2123
  * @param customGet.parameters - Query parameters to apply to the current query.
@@ -1975,7 +2127,7 @@ function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption,
1975
2127
  if (!path) {
1976
2128
  throw new Error('Parameter `path` is required when calling `customGet`.');
1977
2129
  }
1978
- const requestPath = '/1{path}'.replace('{path}', path);
2130
+ const requestPath = '/{path}'.replace('{path}', path);
1979
2131
  const headers = {};
1980
2132
  const queryParameters = parameters ? parameters : {};
1981
2133
  const request = {
@@ -1989,7 +2141,6 @@ function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption,
1989
2141
  /**
1990
2142
  * This method allow you to send requests to the Algolia REST API.
1991
2143
  *
1992
- * @summary Send requests to the Algolia REST API.
1993
2144
  * @param customPost - The customPost object.
1994
2145
  * @param customPost.path - Path of the endpoint, anything after \"/1\" must be specified.
1995
2146
  * @param customPost.parameters - Query parameters to apply to the current query.
@@ -2000,7 +2151,7 @@ function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption,
2000
2151
  if (!path) {
2001
2152
  throw new Error('Parameter `path` is required when calling `customPost`.');
2002
2153
  }
2003
- const requestPath = '/1{path}'.replace('{path}', path);
2154
+ const requestPath = '/{path}'.replace('{path}', path);
2004
2155
  const headers = {};
2005
2156
  const queryParameters = parameters ? parameters : {};
2006
2157
  const request = {
@@ -2015,7 +2166,6 @@ function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption,
2015
2166
  /**
2016
2167
  * This method allow you to send requests to the Algolia REST API.
2017
2168
  *
2018
- * @summary Send requests to the Algolia REST API.
2019
2169
  * @param customPut - The customPut object.
2020
2170
  * @param customPut.path - Path of the endpoint, anything after \"/1\" must be specified.
2021
2171
  * @param customPut.parameters - Query parameters to apply to the current query.
@@ -2026,7 +2176,7 @@ function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption,
2026
2176
  if (!path) {
2027
2177
  throw new Error('Parameter `path` is required when calling `customPut`.');
2028
2178
  }
2029
- const requestPath = '/1{path}'.replace('{path}', path);
2179
+ const requestPath = '/{path}'.replace('{path}', path);
2030
2180
  const headers = {};
2031
2181
  const queryParameters = parameters ? parameters : {};
2032
2182
  const request = {
@@ -2039,11 +2189,13 @@ function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption,
2039
2189
  return transporter.request(request, requestOptions);
2040
2190
  },
2041
2191
  /**
2042
- * Delete the user profile and all its associated data. Returns, as part of the response, a date until which the data can safely be considered as deleted for the given user. This means if you send events for the given user before this date, they will be ignored. Any data received after the deletedUntil date will start building a new user profile. It might take a couple hours for the deletion request to be fully processed.
2192
+ * Deletes a user profile. The response includes a date and time when the user profile can safely be considered deleted.
2193
+ *
2194
+ * Required API Key ACLs:
2195
+ * - recommendation.
2043
2196
  *
2044
- * @summary Delete a user profile.
2045
2197
  * @param deleteUserProfile - The deleteUserProfile object.
2046
- * @param deleteUserProfile.userToken - UserToken representing the user for which to fetch the Personalization profile.
2198
+ * @param deleteUserProfile.userToken - Unique identifier representing a user for which to fetch the personalization profile.
2047
2199
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2048
2200
  */
2049
2201
  deleteUserProfile({ userToken }, requestOptions) {
@@ -2062,9 +2214,11 @@ function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption,
2062
2214
  return transporter.request(request, requestOptions);
2063
2215
  },
2064
2216
  /**
2065
- * The strategy contains information on the events and facets that impact user profiles and personalized search results.
2217
+ * Retrieves the current personalization strategy.
2218
+ *
2219
+ * Required API Key ACLs:
2220
+ * - recommendation.
2066
2221
  *
2067
- * @summary Get the current strategy.
2068
2222
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2069
2223
  */
2070
2224
  getPersonalizationStrategy(requestOptions) {
@@ -2080,11 +2234,13 @@ function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption,
2080
2234
  return transporter.request(request, requestOptions);
2081
2235
  },
2082
2236
  /**
2083
- * Get the user profile built from Personalization strategy. The profile is structured by facet name used in the strategy. Each facet value is mapped to its score. Each score represents the user affinity for a specific facet value given the userToken past events and the Personalization strategy defined. Scores are bounded to 20. The last processed event timestamp is provided using the ISO 8601 format for debugging purposes.
2237
+ * Retrieves a user profile and their affinities for different facets.
2238
+ *
2239
+ * Required API Key ACLs:
2240
+ * - recommendation.
2084
2241
  *
2085
- * @summary Get a user profile.
2086
2242
  * @param getUserTokenProfile - The getUserTokenProfile object.
2087
- * @param getUserTokenProfile.userToken - UserToken representing the user for which to fetch the Personalization profile.
2243
+ * @param getUserTokenProfile.userToken - Unique identifier representing a user for which to fetch the personalization profile.
2088
2244
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2089
2245
  */
2090
2246
  getUserTokenProfile({ userToken }, requestOptions) {
@@ -2103,9 +2259,11 @@ function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption,
2103
2259
  return transporter.request(request, requestOptions);
2104
2260
  },
2105
2261
  /**
2106
- * A strategy defines the events and facets that impact user profiles and personalized search results.
2262
+ * Creates a new personalization strategy.
2263
+ *
2264
+ * Required API Key ACLs:
2265
+ * - recommendation.
2107
2266
  *
2108
- * @summary Set a new strategy.
2109
2267
  * @param personalizationStrategyParams - The personalizationStrategyParams object.
2110
2268
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2111
2269
  */
@@ -2138,8 +2296,8 @@ function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption,
2138
2296
  }
2139
2297
 
2140
2298
  // Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
2141
- const apiClientVersion$1 = '5.0.0-alpha.99';
2142
- function getDefaultHosts(appId) {
2299
+ const apiClientVersion$2 = '5.0.0-beta.10';
2300
+ function getDefaultHosts$1(appId) {
2143
2301
  return [
2144
2302
  {
2145
2303
  url: `${appId}-dsn.algolia.net`,
@@ -2173,12 +2331,12 @@ function getDefaultHosts(appId) {
2173
2331
  function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, ...options }) {
2174
2332
  const auth = createAuth(appIdOption, apiKeyOption, authMode);
2175
2333
  const transporter = createTransporter({
2176
- hosts: getDefaultHosts(appIdOption),
2334
+ hosts: getDefaultHosts$1(appIdOption),
2177
2335
  ...options,
2178
2336
  algoliaAgent: getAlgoliaAgent({
2179
2337
  algoliaAgents,
2180
2338
  client: 'Search',
2181
- version: apiClientVersion$1,
2339
+ version: apiClientVersion$2,
2182
2340
  }),
2183
2341
  baseHeaders: {
2184
2342
  'content-type': 'text/plain',
@@ -2224,7 +2382,7 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2224
2382
  * Helper: Wait for a task to be published (completed) for a given `indexName` and `taskID`.
2225
2383
  *
2226
2384
  * @summary Helper method that waits for a task to be published (completed).
2227
- * @param waitForTaskOptions - The waitForTaskOptions object.
2385
+ * @param waitForTaskOptions - The `waitForTaskOptions` object.
2228
2386
  * @param waitForTaskOptions.indexName - The `indexName` where the operation was performed.
2229
2387
  * @param waitForTaskOptions.taskID - The `taskID` returned in the method response.
2230
2388
  * @param waitForTaskOptions.maxRetries - The maximum number of retries. 50 by default.
@@ -2244,11 +2402,34 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2244
2402
  timeout: () => timeout(retryCount),
2245
2403
  });
2246
2404
  },
2405
+ /**
2406
+ * Helper: Wait for an application-level task to complete for a given `taskID`.
2407
+ *
2408
+ * @summary Helper method that waits for a task to be published (completed).
2409
+ * @param waitForAppTaskOptions - The `waitForTaskOptions` object.
2410
+ * @param waitForAppTaskOptions.taskID - The `taskID` returned in the method response.
2411
+ * @param waitForAppTaskOptions.maxRetries - The maximum number of retries. 50 by default.
2412
+ * @param waitForAppTaskOptions.timeout - The function to decide how long to wait between retries.
2413
+ * @param requestOptions - The requestOptions to send along with the query, they will be forwarded to the `getTask` method and merged with the transporter requestOptions.
2414
+ */
2415
+ waitForAppTask({ taskID, maxRetries = 50, timeout = (retryCount) => Math.min(retryCount * 200, 5000), }, requestOptions) {
2416
+ let retryCount = 0;
2417
+ return createIterablePromise({
2418
+ func: () => this.getAppTask({ taskID }, requestOptions),
2419
+ validate: (response) => response.status === 'published',
2420
+ aggregator: () => (retryCount += 1),
2421
+ error: {
2422
+ validate: () => retryCount >= maxRetries,
2423
+ message: () => `The maximum number of retries exceeded. (${retryCount}/${maxRetries})`,
2424
+ },
2425
+ timeout: () => timeout(retryCount),
2426
+ });
2427
+ },
2247
2428
  /**
2248
2429
  * Helper: Wait for an API key to be added, updated or deleted based on a given `operation`.
2249
2430
  *
2250
2431
  * @summary Helper method that waits for an API key task to be processed.
2251
- * @param waitForApiKeyOptions - The waitForApiKeyOptions object.
2432
+ * @param waitForApiKeyOptions - The `waitForApiKeyOptions` object.
2252
2433
  * @param waitForApiKeyOptions.operation - The `operation` that was done on a `key`.
2253
2434
  * @param waitForApiKeyOptions.key - The `key` that has been added, deleted or updated.
2254
2435
  * @param waitForApiKeyOptions.apiKey - Necessary to know if an `update` operation has been processed, compare fields of the response with it.
@@ -2301,7 +2482,7 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2301
2482
  * Helper: Iterate on the `browse` method of the client to allow aggregating objects of an index.
2302
2483
  *
2303
2484
  * @summary Helper method that iterates on the `browse` method.
2304
- * @param browseObjects - The browseObjects object.
2485
+ * @param browseObjects - The `browseObjects` object.
2305
2486
  * @param browseObjects.indexName - The index in which to perform the request.
2306
2487
  * @param browseObjects.browseParams - The `browse` parameters.
2307
2488
  * @param browseObjects.validate - The validator function. It receive the resolved return of the API call. By default, stops when there is no `cursor` in the response.
@@ -2327,11 +2508,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2327
2508
  * Helper: Iterate on the `searchRules` method of the client to allow aggregating rules of an index.
2328
2509
  *
2329
2510
  * @summary Helper method that iterates on the `searchRules` method.
2330
- * @param browseObjects - The browseObjects object.
2331
- * @param browseObjects.indexName - The index in which to perform the request.
2332
- * @param browseObjects.searchRulesParams - The `searchRules` method parameters.
2333
- * @param browseObjects.validate - The validator function. It receive the resolved return of the API call. By default, stops when there is less hits returned than the number of maximum hits (1000).
2334
- * @param browseObjects.aggregator - The function that runs right after the API call has been resolved, allows you to do anything with the response before `validate`.
2511
+ * @param browseRules - The `browseRules` object.
2512
+ * @param browseRules.indexName - The index in which to perform the request.
2513
+ * @param browseRules.searchRulesParams - The `searchRules` method parameters.
2514
+ * @param browseRules.validate - The validator function. It receive the resolved return of the API call. By default, stops when there is less hits returned than the number of maximum hits (1000).
2515
+ * @param browseRules.aggregator - The function that runs right after the API call has been resolved, allows you to do anything with the response before `validate`.
2335
2516
  * @param requestOptions - The requestOptions to send along with the query, they will be forwarded to the `searchRules` method and merged with the transporter requestOptions.
2336
2517
  */
2337
2518
  browseRules({ indexName, searchRulesParams, ...browseRulesOptions }, requestOptions) {
@@ -2359,11 +2540,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2359
2540
  * Helper: Iterate on the `searchSynonyms` method of the client to allow aggregating rules of an index.
2360
2541
  *
2361
2542
  * @summary Helper method that iterates on the `searchSynonyms` method.
2362
- * @param browseObjects - The browseObjects object.
2363
- * @param browseObjects.indexName - The index in which to perform the request.
2364
- * @param browseObjects.validate - The validator function. It receive the resolved return of the API call. By default, stops when there is less hits returned than the number of maximum hits (1000).
2365
- * @param browseObjects.aggregator - The function that runs right after the API call has been resolved, allows you to do anything with the response before `validate`.
2366
- * @param browseObjects.searchSynonymsParams - The `searchSynonyms` method parameters.
2543
+ * @param browseSynonyms - The `browseSynonyms` object.
2544
+ * @param browseSynonyms.indexName - The index in which to perform the request.
2545
+ * @param browseSynonyms.validate - The validator function. It receive the resolved return of the API call. By default, stops when there is less hits returned than the number of maximum hits (1000).
2546
+ * @param browseSynonyms.aggregator - The function that runs right after the API call has been resolved, allows you to do anything with the response before `validate`.
2547
+ * @param browseSynonyms.searchSynonymsParams - The `searchSynonyms` method parameters.
2367
2548
  * @param requestOptions - The requestOptions to send along with the query, they will be forwarded to the `searchSynonyms` method and merged with the transporter requestOptions.
2368
2549
  */
2369
2550
  browseSynonyms({ indexName, searchSynonymsParams, ...browseSynonymsOptions }, requestOptions) {
@@ -2373,16 +2554,16 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2373
2554
  hitsPerPage: 1000,
2374
2555
  };
2375
2556
  return createIterablePromise({
2376
- func: (previousResponse) => {
2377
- return this.searchSynonyms({
2557
+ func: (_) => {
2558
+ const resp = this.searchSynonyms({
2378
2559
  indexName,
2379
2560
  searchSynonymsParams: {
2380
2561
  ...params,
2381
- page: previousResponse
2382
- ? previousResponse.page + 1
2383
- : params.page,
2562
+ page: params.page,
2384
2563
  },
2385
2564
  }, requestOptions);
2565
+ params.page += 1;
2566
+ return resp;
2386
2567
  },
2387
2568
  validate: (response) => response.nbHits < params.hitsPerPage,
2388
2569
  ...browseSynonymsOptions,
@@ -2411,9 +2592,137 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2411
2592
  return this.search(searchMethodParams, requestOptions);
2412
2593
  },
2413
2594
  /**
2414
- * Add a new API key with specific permissions and restrictions. The request must be authenticated with the admin API key. The response returns an API key string.
2595
+ * Helper: Chunks the given `objects` list in subset of 1000 elements max in order to make it fit in `batch` requests.
2596
+ *
2597
+ * @summary Helper: Chunks the given `objects` list in subset of 1000 elements max in order to make it fit in `batch` requests.
2598
+ * @param chunkedBatch - The `chunkedBatch` object.
2599
+ * @param chunkedBatch.indexName - The `indexName` to replace `objects` in.
2600
+ * @param chunkedBatch.objects - The array of `objects` to store in the given Algolia `indexName`.
2601
+ * @param chunkedBatch.action - The `batch` `action` to perform on the given array of `objects`, defaults to `addObject`.
2602
+ * @param chunkedBatch.waitForTasks - Whether or not we should wait until every `batch` tasks has been processed, this operation may slow the total execution time of this method but is more reliable.
2603
+ * @param chunkedBatch.batchSize - The size of the chunk of `objects`. The number of `batch` calls will be equal to `length(objects) / batchSize`. Defaults to 1000.
2604
+ * @param requestOptions - The requestOptions to send along with the query, they will be forwarded to the `getTask` method and merged with the transporter requestOptions.
2605
+ */
2606
+ async chunkedBatch({ indexName, objects, action = 'addObject', waitForTasks, batchSize = 1000, }, requestOptions) {
2607
+ let requests = [];
2608
+ const responses = [];
2609
+ const objectEntries = objects.entries();
2610
+ for (const [i, obj] of objectEntries) {
2611
+ requests.push({ action, body: obj });
2612
+ if (requests.length === batchSize || i === objects.length - 1) {
2613
+ responses.push(await this.batch({ indexName, batchWriteParams: { requests } }, requestOptions));
2614
+ requests = [];
2615
+ }
2616
+ }
2617
+ if (waitForTasks) {
2618
+ for (const resp of responses) {
2619
+ await this.waitForTask({ indexName, taskID: resp.taskID });
2620
+ }
2621
+ }
2622
+ return responses;
2623
+ },
2624
+ /**
2625
+ * Helper: Saves the given array of objects in the given index. The `chunkedBatch` helper is used under the hood, which creates a `batch` requests with at most 1000 objects in it.
2626
+ *
2627
+ * @summary Helper: Saves the given array of objects in the given index. The `chunkedBatch` helper is used under the hood, which creates a `batch` requests with at most 1000 objects in it.
2628
+ * @param saveObjects - The `saveObjects` object.
2629
+ * @param saveObjects.indexName - The `indexName` to save `objects` in.
2630
+ * @param saveObjects.objects - The array of `objects` to store in the given Algolia `indexName`.
2631
+ * @param requestOptions - The requestOptions to send along with the query, they will be forwarded to the `batch` method and merged with the transporter requestOptions.
2632
+ */
2633
+ async saveObjects({ indexName, objects }, requestOptions) {
2634
+ return await this.chunkedBatch({ indexName, objects, action: 'addObject' }, requestOptions);
2635
+ },
2636
+ /**
2637
+ * Helper: Deletes every records for the given objectIDs. The `chunkedBatch` helper is used under the hood, which creates a `batch` requests with at most 1000 objectIDs in it.
2638
+ *
2639
+ * @summary Helper: Deletes every records for the given objectIDs. The `chunkedBatch` helper is used under the hood, which creates a `batch` requests with at most 1000 objectIDs in it.
2640
+ * @param deleteObjects - The `deleteObjects` object.
2641
+ * @param deleteObjects.indexName - The `indexName` to delete `objectIDs` from.
2642
+ * @param deleteObjects.objectIDs - The objectIDs to delete.
2643
+ * @param requestOptions - The requestOptions to send along with the query, they will be forwarded to the `batch` method and merged with the transporter requestOptions.
2644
+ */
2645
+ async deleteObjects({ indexName, objectIDs }, requestOptions) {
2646
+ return await this.chunkedBatch({
2647
+ indexName,
2648
+ objects: objectIDs.map((objectID) => ({ objectID })),
2649
+ action: 'deleteObject',
2650
+ }, requestOptions);
2651
+ },
2652
+ /**
2653
+ * Helper: Replaces object content of all the given objects according to their respective `objectID` field. The `chunkedBatch` helper is used under the hood, which creates a `batch` requests with at most 1000 objects in it.
2654
+ *
2655
+ * @summary Helper: Replaces object content of all the given objects according to their respective `objectID` field. The `chunkedBatch` helper is used under the hood, which creates a `batch` requests with at most 1000 objects in it.
2656
+ * @param partialUpdateObjects - The `partialUpdateObjects` object.
2657
+ * @param partialUpdateObjects.indexName - The `indexName` to update `objects` in.
2658
+ * @param partialUpdateObjects.objects - The array of `objects` to update in the given Algolia `indexName`.
2659
+ * @param partialUpdateObjects.createIfNotExists - To be provided if non-existing objects are passed, otherwise, the call will fail..
2660
+ * @param requestOptions - The requestOptions to send along with the query, they will be forwarded to the `getTask` method and merged with the transporter requestOptions.
2661
+ */
2662
+ async partialUpdateObjects({ indexName, objects, createIfNotExists }, requestOptions) {
2663
+ return await this.chunkedBatch({
2664
+ indexName,
2665
+ objects,
2666
+ action: createIfNotExists
2667
+ ? 'partialUpdateObject'
2668
+ : 'partialUpdateObjectNoCreate',
2669
+ }, requestOptions);
2670
+ },
2671
+ /**
2672
+ * Helper: Replaces all objects (records) in the given `index_name` with the given `objects`. A temporary index is created during this process in order to backup your data.
2673
+ * See https://api-clients-automation.netlify.app/docs/contributing/add-new-api-client#5-helpers for implementation details.
2674
+ *
2675
+ * @summary Helper: Replaces all objects (records) in the given `index_name` with the given `objects`. A temporary index is created during this process in order to backup your data.
2676
+ * @param replaceAllObjects - The `replaceAllObjects` object.
2677
+ * @param replaceAllObjects.indexName - The `indexName` to replace `objects` in.
2678
+ * @param replaceAllObjects.objects - The array of `objects` to store in the given Algolia `indexName`.
2679
+ * @param replaceAllObjects.batchSize - The size of the chunk of `objects`. The number of `batch` calls will be equal to `objects.length / batchSize`. Defaults to 1000.
2680
+ * @param requestOptions - The requestOptions to send along with the query, they will be forwarded to the `batch`, `operationIndex` and `getTask` method and merged with the transporter requestOptions.
2681
+ */
2682
+ async replaceAllObjects({ indexName, objects, batchSize }, requestOptions) {
2683
+ const randomSuffix = Math.floor(Math.random() * 1000000) + 100000;
2684
+ const tmpIndexName = `${indexName}_tmp_${randomSuffix}`;
2685
+ let copyOperationResponse = await this.operationIndex({
2686
+ indexName,
2687
+ operationIndexParams: {
2688
+ operation: 'copy',
2689
+ destination: tmpIndexName,
2690
+ scope: ['settings', 'rules', 'synonyms'],
2691
+ },
2692
+ }, requestOptions);
2693
+ const batchResponses = await this.chunkedBatch({ indexName: tmpIndexName, objects, waitForTasks: true, batchSize }, requestOptions);
2694
+ await this.waitForTask({
2695
+ indexName: tmpIndexName,
2696
+ taskID: copyOperationResponse.taskID,
2697
+ });
2698
+ copyOperationResponse = await this.operationIndex({
2699
+ indexName,
2700
+ operationIndexParams: {
2701
+ operation: 'copy',
2702
+ destination: tmpIndexName,
2703
+ scope: ['settings', 'rules', 'synonyms'],
2704
+ },
2705
+ }, requestOptions);
2706
+ await this.waitForTask({
2707
+ indexName: tmpIndexName,
2708
+ taskID: copyOperationResponse.taskID,
2709
+ });
2710
+ const moveOperationResponse = await this.operationIndex({
2711
+ indexName: tmpIndexName,
2712
+ operationIndexParams: { operation: 'move', destination: indexName },
2713
+ }, requestOptions);
2714
+ await this.waitForTask({
2715
+ indexName: tmpIndexName,
2716
+ taskID: moveOperationResponse.taskID,
2717
+ });
2718
+ return { copyOperationResponse, batchResponses, moveOperationResponse };
2719
+ },
2720
+ /**
2721
+ * Creates a new API key with specific permissions and restrictions.
2722
+ *
2723
+ * Required API Key ACLs:
2724
+ * - admin.
2415
2725
  *
2416
- * @summary Add API key.
2417
2726
  * @param apiKey - The apiKey object.
2418
2727
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2419
2728
  */
@@ -2437,13 +2746,15 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2437
2746
  return transporter.request(request, requestOptions);
2438
2747
  },
2439
2748
  /**
2440
- * If you use an existing `objectID`, the existing record will be replaced with the new one. To update only some attributes of an existing record, use the [`partial` operation](#tag/Records/operation/partialUpdateObject) instead. To add multiple records to your index in a single API request, use the [`batch` operation](#tag/Records/operation/batch).
2749
+ * If a record with the specified object ID exists, the existing record is replaced. Otherwise, a new record is added to the index. To update _some_ attributes of an existing record, use the [`partial` operation](#tag/Records/operation/partialUpdateObject) instead. To add, update, or replace multiple records, use the [`batch` operation](#tag/Records/operation/batch).
2750
+ *
2751
+ * Required API Key ACLs:
2752
+ * - addObject.
2441
2753
  *
2442
- * @summary Add or update a record (using objectID).
2443
2754
  * @param addOrUpdateObject - The addOrUpdateObject object.
2444
- * @param addOrUpdateObject.indexName - Index on which to perform the request.
2445
- * @param addOrUpdateObject.objectID - Unique record (object) identifier.
2446
- * @param addOrUpdateObject.body - Algolia record.
2755
+ * @param addOrUpdateObject.indexName - Name of the index on which to perform the operation.
2756
+ * @param addOrUpdateObject.objectID - Unique record identifier.
2757
+ * @param addOrUpdateObject.body - The record, a schemaless object with attributes that are useful in the context of search and discovery.
2447
2758
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2448
2759
  */
2449
2760
  addOrUpdateObject({ indexName, objectID, body }, requestOptions) {
@@ -2471,9 +2782,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2471
2782
  return transporter.request(request, requestOptions);
2472
2783
  },
2473
2784
  /**
2474
- * Add a source to the list of allowed sources.
2785
+ * Adds a source to the list of allowed sources.
2786
+ *
2787
+ * Required API Key ACLs:
2788
+ * - admin.
2475
2789
  *
2476
- * @summary Add a source.
2477
2790
  * @param source - Source to add.
2478
2791
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2479
2792
  */
@@ -2497,11 +2810,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2497
2810
  return transporter.request(request, requestOptions);
2498
2811
  },
2499
2812
  /**
2500
- * Assign or move a user ID to a cluster. The time it takes to move a user is proportional to the amount of data linked to the user ID.
2813
+ * Assigns or moves a user ID to a cluster. The time it takes to move a user is proportional to the amount of data linked to the user ID.
2814
+ *
2815
+ * Required API Key ACLs:
2816
+ * - admin.
2501
2817
  *
2502
- * @summary Assign or move a user ID.
2503
2818
  * @param assignUserId - The assignUserId object.
2504
- * @param assignUserId.xAlgoliaUserID - UserID to assign.
2819
+ * @param assignUserId.xAlgoliaUserID - Unique identifier of the user who makes the search request.
2505
2820
  * @param assignUserId.assignUserIdParams - The assignUserIdParams object.
2506
2821
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2507
2822
  */
@@ -2531,11 +2846,10 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2531
2846
  return transporter.request(request, requestOptions);
2532
2847
  },
2533
2848
  /**
2534
- * To reduce the time spent on network round trips, you can perform several write actions in a single API call. Actions are applied in the order they are specified. The supported `action`s are equivalent to the individual operations of the same name.
2849
+ * Adds, updates, or deletes records in one index with a single API request. Batching index updates reduces latency and increases data integrity. - Actions are applied in the order they\'re specified. - Actions are equivalent to the individual API requests of the same name.
2535
2850
  *
2536
- * @summary Batch write operations on one index.
2537
2851
  * @param batch - The batch object.
2538
- * @param batch.indexName - Index on which to perform the request.
2852
+ * @param batch.indexName - Name of the index on which to perform the operation.
2539
2853
  * @param batch.batchWriteParams - The batchWriteParams object.
2540
2854
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2541
2855
  */
@@ -2562,11 +2876,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2562
2876
  return transporter.request(request, requestOptions);
2563
2877
  },
2564
2878
  /**
2565
- * Assign multiple user IDs to a cluster. **You can\'t _move_ users with this operation.**.
2879
+ * Assigns multiple user IDs to a cluster. **You can\'t move users with this operation**.
2880
+ *
2881
+ * Required API Key ACLs:
2882
+ * - admin.
2566
2883
  *
2567
- * @summary Batch assign userIDs.
2568
2884
  * @param batchAssignUserIds - The batchAssignUserIds object.
2569
- * @param batchAssignUserIds.xAlgoliaUserID - UserID to assign.
2885
+ * @param batchAssignUserIds.xAlgoliaUserID - Unique identifier of the user who makes the search request.
2570
2886
  * @param batchAssignUserIds.batchAssignUserIdsParams - The batchAssignUserIdsParams object.
2571
2887
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2572
2888
  */
@@ -2599,11 +2915,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2599
2915
  return transporter.request(request, requestOptions);
2600
2916
  },
2601
2917
  /**
2602
- * Add or remove a batch of dictionary entries.
2918
+ * Adds or deletes multiple entries from your plurals, segmentation, or stop word dictionaries.
2919
+ *
2920
+ * Required API Key ACLs:
2921
+ * - editSettings.
2603
2922
  *
2604
- * @summary Batch dictionary entries.
2605
2923
  * @param batchDictionaryEntries - The batchDictionaryEntries object.
2606
- * @param batchDictionaryEntries.dictionaryName - Dictionary to search in.
2924
+ * @param batchDictionaryEntries.dictionaryName - Dictionary type in which to search.
2607
2925
  * @param batchDictionaryEntries.batchDictionaryEntriesParams - The batchDictionaryEntriesParams object.
2608
2926
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2609
2927
  */
@@ -2630,11 +2948,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2630
2948
  return transporter.request(request, requestOptions);
2631
2949
  },
2632
2950
  /**
2633
- * Retrieve up to 1,000 records per call. Supports full-text search and filters. For better performance, it doesn\'t support: - The `distinct` query parameter - Sorting by typos, proximity, words, or geographical distance.
2951
+ * Retrieves records from an index, up to 1,000 per request. While searching retrieves _hits_ (records augmented with attributes for highlighting and ranking details), browsing _just_ returns matching records. This can be useful if you want to export your indices. - The Analytics API doesn\'t collect data when using `browse`. - Records are ranked by attributes and custom ranking. - There\'s no ranking for: typo-tolerance, number of matched words, proximity, geo distance. Browse requests automatically apply these settings: - `advancedSyntax`: `false` - `attributesToHighlight`: `[]` - `attributesToSnippet`: `[]` - `distinct`: `false` - `enablePersonalization`: `false` - `enableRules`: `false` - `facets`: `[]` - `getRankingInfo`: `false` - `ignorePlurals`: `false` - `optionalFilters`: `[]` - `typoTolerance`: `true` or `false` (`min` and `strict` is evaluated to `true`) If you send these parameters with your browse requests, they\'ll be ignored.
2952
+ *
2953
+ * Required API Key ACLs:
2954
+ * - browse.
2634
2955
  *
2635
- * @summary Get all records from an index.
2636
2956
  * @param browse - The browse object.
2637
- * @param browse.indexName - Index on which to perform the request.
2957
+ * @param browse.indexName - Name of the index on which to perform the operation.
2638
2958
  * @param browse.browseParams - The browseParams object.
2639
2959
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2640
2960
  */
@@ -2655,11 +2975,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2655
2975
  return transporter.request(request, requestOptions);
2656
2976
  },
2657
2977
  /**
2658
- * Delete the records but leave settings and index-specific API keys untouched.
2978
+ * Deletes only the records from an index while keeping settings, synonyms, and rules.
2979
+ *
2980
+ * Required API Key ACLs:
2981
+ * - deleteIndex.
2659
2982
  *
2660
- * @summary Delete all records from an index.
2661
2983
  * @param clearObjects - The clearObjects object.
2662
- * @param clearObjects.indexName - Index on which to perform the request.
2984
+ * @param clearObjects.indexName - Name of the index on which to perform the operation.
2663
2985
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2664
2986
  */
2665
2987
  clearObjects({ indexName }, requestOptions) {
@@ -2678,12 +3000,14 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2678
3000
  return transporter.request(request, requestOptions);
2679
3001
  },
2680
3002
  /**
2681
- * Delete all rules in the index.
3003
+ * Deletes all rules from the index.
3004
+ *
3005
+ * Required API Key ACLs:
3006
+ * - editSettings.
2682
3007
  *
2683
- * @summary Delete all rules.
2684
3008
  * @param clearRules - The clearRules object.
2685
- * @param clearRules.indexName - Index on which to perform the request.
2686
- * @param clearRules.forwardToReplicas - Indicates whether changed index settings are forwarded to the replica indices.
3009
+ * @param clearRules.indexName - Name of the index on which to perform the operation.
3010
+ * @param clearRules.forwardToReplicas - Whether changes are applied to replica indices.
2687
3011
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2688
3012
  */
2689
3013
  clearRules({ indexName, forwardToReplicas }, requestOptions) {
@@ -2705,12 +3029,14 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2705
3029
  return transporter.request(request, requestOptions);
2706
3030
  },
2707
3031
  /**
2708
- * Delete all synonyms in the index.
3032
+ * Deletes all synonyms from the index.
3033
+ *
3034
+ * Required API Key ACLs:
3035
+ * - editSettings.
2709
3036
  *
2710
- * @summary Delete all synonyms.
2711
3037
  * @param clearSynonyms - The clearSynonyms object.
2712
- * @param clearSynonyms.indexName - Index on which to perform the request.
2713
- * @param clearSynonyms.forwardToReplicas - Indicates whether changed index settings are forwarded to the replica indices.
3038
+ * @param clearSynonyms.indexName - Name of the index on which to perform the operation.
3039
+ * @param clearSynonyms.forwardToReplicas - Whether changes are applied to replica indices.
2714
3040
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2715
3041
  */
2716
3042
  clearSynonyms({ indexName, forwardToReplicas }, requestOptions) {
@@ -2734,7 +3060,6 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2734
3060
  /**
2735
3061
  * This method allow you to send requests to the Algolia REST API.
2736
3062
  *
2737
- * @summary Send requests to the Algolia REST API.
2738
3063
  * @param customDelete - The customDelete object.
2739
3064
  * @param customDelete.path - Path of the endpoint, anything after \"/1\" must be specified.
2740
3065
  * @param customDelete.parameters - Query parameters to apply to the current query.
@@ -2744,7 +3069,7 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2744
3069
  if (!path) {
2745
3070
  throw new Error('Parameter `path` is required when calling `customDelete`.');
2746
3071
  }
2747
- const requestPath = '/1{path}'.replace('{path}', path);
3072
+ const requestPath = '/{path}'.replace('{path}', path);
2748
3073
  const headers = {};
2749
3074
  const queryParameters = parameters ? parameters : {};
2750
3075
  const request = {
@@ -2758,7 +3083,6 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2758
3083
  /**
2759
3084
  * This method allow you to send requests to the Algolia REST API.
2760
3085
  *
2761
- * @summary Send requests to the Algolia REST API.
2762
3086
  * @param customGet - The customGet object.
2763
3087
  * @param customGet.path - Path of the endpoint, anything after \"/1\" must be specified.
2764
3088
  * @param customGet.parameters - Query parameters to apply to the current query.
@@ -2768,7 +3092,7 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2768
3092
  if (!path) {
2769
3093
  throw new Error('Parameter `path` is required when calling `customGet`.');
2770
3094
  }
2771
- const requestPath = '/1{path}'.replace('{path}', path);
3095
+ const requestPath = '/{path}'.replace('{path}', path);
2772
3096
  const headers = {};
2773
3097
  const queryParameters = parameters ? parameters : {};
2774
3098
  const request = {
@@ -2782,7 +3106,6 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2782
3106
  /**
2783
3107
  * This method allow you to send requests to the Algolia REST API.
2784
3108
  *
2785
- * @summary Send requests to the Algolia REST API.
2786
3109
  * @param customPost - The customPost object.
2787
3110
  * @param customPost.path - Path of the endpoint, anything after \"/1\" must be specified.
2788
3111
  * @param customPost.parameters - Query parameters to apply to the current query.
@@ -2793,7 +3116,7 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2793
3116
  if (!path) {
2794
3117
  throw new Error('Parameter `path` is required when calling `customPost`.');
2795
3118
  }
2796
- const requestPath = '/1{path}'.replace('{path}', path);
3119
+ const requestPath = '/{path}'.replace('{path}', path);
2797
3120
  const headers = {};
2798
3121
  const queryParameters = parameters ? parameters : {};
2799
3122
  const request = {
@@ -2808,7 +3131,6 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2808
3131
  /**
2809
3132
  * This method allow you to send requests to the Algolia REST API.
2810
3133
  *
2811
- * @summary Send requests to the Algolia REST API.
2812
3134
  * @param customPut - The customPut object.
2813
3135
  * @param customPut.path - Path of the endpoint, anything after \"/1\" must be specified.
2814
3136
  * @param customPut.parameters - Query parameters to apply to the current query.
@@ -2819,7 +3141,7 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2819
3141
  if (!path) {
2820
3142
  throw new Error('Parameter `path` is required when calling `customPut`.');
2821
3143
  }
2822
- const requestPath = '/1{path}'.replace('{path}', path);
3144
+ const requestPath = '/{path}'.replace('{path}', path);
2823
3145
  const headers = {};
2824
3146
  const queryParameters = parameters ? parameters : {};
2825
3147
  const request = {
@@ -2832,9 +3154,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2832
3154
  return transporter.request(request, requestOptions);
2833
3155
  },
2834
3156
  /**
2835
- * Delete an existing API key. The request must be authenticated with the admin API key.
3157
+ * Deletes the API key.
3158
+ *
3159
+ * Required API Key ACLs:
3160
+ * - admin.
2836
3161
  *
2837
- * @summary Delete API key.
2838
3162
  * @param deleteApiKey - The deleteApiKey object.
2839
3163
  * @param deleteApiKey.key - API key.
2840
3164
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -2855,11 +3179,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2855
3179
  return transporter.request(request, requestOptions);
2856
3180
  },
2857
3181
  /**
2858
- * This operation doesn\'t support all the query options, only its filters (numeric, facet, or tag) and geo queries. It doesn\'t accept empty filters or queries.
3182
+ * This operation doesn\'t accept empty queries or filters. It\'s more efficient to get a list of object IDs with the [`browse` operation](#tag/Search/operation/browse), and then delete the records using the [`batch` operation](tag/Records/operation/batch).
3183
+ *
3184
+ * Required API Key ACLs:
3185
+ * - deleteIndex.
2859
3186
  *
2860
- * @summary Delete all records matching a query.
2861
3187
  * @param deleteBy - The deleteBy object.
2862
- * @param deleteBy.indexName - Index on which to perform the request.
3188
+ * @param deleteBy.indexName - Name of the index on which to perform the operation.
2863
3189
  * @param deleteBy.deleteByParams - The deleteByParams object.
2864
3190
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2865
3191
  */
@@ -2883,11 +3209,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2883
3209
  return transporter.request(request, requestOptions);
2884
3210
  },
2885
3211
  /**
2886
- * Delete an existing index.
3212
+ * Deletes an index and all its settings. - Deleting an index doesn\'t delete its analytics data. - If you try to delete a non-existing index, the operation is ignored without warning. - If the index you want to delete has replica indices, the replicas become independent indices. - If the index you want to delete is a replica index, you must first unlink it from its primary index before you can delete it. For more information, see [Delete replica indices](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/how-to/deleting-replicas/).
3213
+ *
3214
+ * Required API Key ACLs:
3215
+ * - deleteIndex.
2887
3216
  *
2888
- * @summary Delete index.
2889
3217
  * @param deleteIndex - The deleteIndex object.
2890
- * @param deleteIndex.indexName - Index on which to perform the request.
3218
+ * @param deleteIndex.indexName - Name of the index on which to perform the operation.
2891
3219
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2892
3220
  */
2893
3221
  deleteIndex({ indexName }, requestOptions) {
@@ -2906,12 +3234,14 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2906
3234
  return transporter.request(request, requestOptions);
2907
3235
  },
2908
3236
  /**
2909
- * To delete a set of records matching a query, use the [`deleteByQuery` operation](#tag/Records/operation/deleteBy) instead.
3237
+ * Deletes a record by its object ID. To delete more than one record, use the [`batch` operation](#tag/Records/operation/batch). To delete records matching a query, use the [`deleteByQuery` operation](#tag/Records/operation/deleteBy).
3238
+ *
3239
+ * Required API Key ACLs:
3240
+ * - deleteObject.
2910
3241
  *
2911
- * @summary Delete a record.
2912
3242
  * @param deleteObject - The deleteObject object.
2913
- * @param deleteObject.indexName - Index on which to perform the request.
2914
- * @param deleteObject.objectID - Unique record (object) identifier.
3243
+ * @param deleteObject.indexName - Name of the index on which to perform the operation.
3244
+ * @param deleteObject.objectID - Unique record identifier.
2915
3245
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2916
3246
  */
2917
3247
  deleteObject({ indexName, objectID }, requestOptions) {
@@ -2935,13 +3265,15 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2935
3265
  return transporter.request(request, requestOptions);
2936
3266
  },
2937
3267
  /**
2938
- * Delete a rule by its `objectID`. To find the `objectID` for rules, use the [`search` operation](#tag/Rules/operation/searchRules).
3268
+ * Deletes a rule by its ID. To find the object ID for rules, use the [`search` operation](#tag/Rules/operation/searchRules).
3269
+ *
3270
+ * Required API Key ACLs:
3271
+ * - editSettings.
2939
3272
  *
2940
- * @summary Delete a rule.
2941
3273
  * @param deleteRule - The deleteRule object.
2942
- * @param deleteRule.indexName - Index on which to perform the request.
3274
+ * @param deleteRule.indexName - Name of the index on which to perform the operation.
2943
3275
  * @param deleteRule.objectID - Unique identifier of a rule object.
2944
- * @param deleteRule.forwardToReplicas - Indicates whether changed index settings are forwarded to the replica indices.
3276
+ * @param deleteRule.forwardToReplicas - Whether changes are applied to replica indices.
2945
3277
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
2946
3278
  */
2947
3279
  deleteRule({ indexName, objectID, forwardToReplicas }, requestOptions) {
@@ -2968,9 +3300,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2968
3300
  return transporter.request(request, requestOptions);
2969
3301
  },
2970
3302
  /**
2971
- * Remove a source from the list of allowed sources.
3303
+ * Deletes a source from the list of allowed sources.
3304
+ *
3305
+ * Required API Key ACLs:
3306
+ * - admin.
2972
3307
  *
2973
- * @summary Remove a source.
2974
3308
  * @param deleteSource - The deleteSource object.
2975
3309
  * @param deleteSource.source - IP address range of the source.
2976
3310
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -2991,13 +3325,15 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
2991
3325
  return transporter.request(request, requestOptions);
2992
3326
  },
2993
3327
  /**
2994
- * Delete a synonym by its `objectID`. To find the object IDs of your synonyms, use the [`search` operation](#tag/Synonyms/operation/searchSynonyms).
3328
+ * Deletes a synonym by its ID. To find the object IDs of your synonyms, use the [`search` operation](#tag/Synonyms/operation/searchSynonyms).
3329
+ *
3330
+ * Required API Key ACLs:
3331
+ * - editSettings.
2995
3332
  *
2996
- * @summary Delete a synonym.
2997
3333
  * @param deleteSynonym - The deleteSynonym object.
2998
- * @param deleteSynonym.indexName - Index on which to perform the request.
3334
+ * @param deleteSynonym.indexName - Name of the index on which to perform the operation.
2999
3335
  * @param deleteSynonym.objectID - Unique identifier of a synonym object.
3000
- * @param deleteSynonym.forwardToReplicas - Indicates whether changed index settings are forwarded to the replica indices.
3336
+ * @param deleteSynonym.forwardToReplicas - Whether changes are applied to replica indices.
3001
3337
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3002
3338
  */
3003
3339
  deleteSynonym({ indexName, objectID, forwardToReplicas }, requestOptions) {
@@ -3024,9 +3360,8 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3024
3360
  return transporter.request(request, requestOptions);
3025
3361
  },
3026
3362
  /**
3027
- * Get the permissions and restrictions of a specific API key. When authenticating with the admin API key, you can request information for any of your application\'s keys. When authenticating with other API keys, you can only retrieve information for that key.
3363
+ * Gets the permissions and restrictions of an API key. When authenticating with the admin API key, you can request information for any of your application\'s keys. When authenticating with other API keys, you can only retrieve information for that key.
3028
3364
  *
3029
- * @summary Get API key permissions.
3030
3365
  * @param getApiKey - The getApiKey object.
3031
3366
  * @param getApiKey.key - API key.
3032
3367
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -3047,9 +3382,36 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3047
3382
  return transporter.request(request, requestOptions);
3048
3383
  },
3049
3384
  /**
3050
- * Lists Algolia\'s [supported languages](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/supported-languages/) and any customizations applied to each language\'s [stop word](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-stop-words/), [plural](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-plurals-and-other-declensions/), and [segmentation (compound)](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-segmentation/) features.
3385
+ * Checks the status of a given application task.
3386
+ *
3387
+ * Required API Key ACLs:
3388
+ * - editSettings.
3389
+ *
3390
+ * @param getAppTask - The getAppTask object.
3391
+ * @param getAppTask.taskID - Unique task identifier.
3392
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3393
+ */
3394
+ getAppTask({ taskID }, requestOptions) {
3395
+ if (!taskID) {
3396
+ throw new Error('Parameter `taskID` is required when calling `getAppTask`.');
3397
+ }
3398
+ const requestPath = '/1/task/{taskID}'.replace('{taskID}', encodeURIComponent(taskID));
3399
+ const headers = {};
3400
+ const queryParameters = {};
3401
+ const request = {
3402
+ method: 'GET',
3403
+ path: requestPath,
3404
+ queryParameters,
3405
+ headers,
3406
+ };
3407
+ return transporter.request(request, requestOptions);
3408
+ },
3409
+ /**
3410
+ * Lists supported languages with their supported dictionary types and number of custom entries.
3411
+ *
3412
+ * Required API Key ACLs:
3413
+ * - settings.
3051
3414
  *
3052
- * @summary List available languages.
3053
3415
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3054
3416
  */
3055
3417
  getDictionaryLanguages(requestOptions) {
@@ -3065,9 +3427,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3065
3427
  return transporter.request(request, requestOptions);
3066
3428
  },
3067
3429
  /**
3068
- * Get the languages for which [stop words are turned off](#tag/Dictionaries/operation/setDictionarySettings).
3430
+ * Retrieves the languages for which standard dictionary entries are turned off.
3431
+ *
3432
+ * Required API Key ACLs:
3433
+ * - settings.
3069
3434
  *
3070
- * @summary Get stop word settings.
3071
3435
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3072
3436
  */
3073
3437
  getDictionarySettings(requestOptions) {
@@ -3083,14 +3447,16 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3083
3447
  return transporter.request(request, requestOptions);
3084
3448
  },
3085
3449
  /**
3086
- * The request must be authenticated by an API key with the [`logs` ACL](https://www.algolia.com/doc/guides/security/api-keys/#access-control-list-acl). Logs are held for the last seven days. There\'s also a logging limit of 1,000 API calls per server. This request counts towards your [operations quota](https://support.algolia.com/hc/en-us/articles/4406981829777-How-does-Algolia-count-records-and-operations-) but doesn\'t appear in the logs itself. > **Note**: To fetch the logs for a Distributed Search Network (DSN) cluster, target the [DSN\'s endpoint](https://www.algolia.com/doc/guides/scaling/distributed-search-network-dsn/#accessing-dsn-servers).
3450
+ * The request must be authenticated by an API key with the [`logs` ACL](https://www.algolia.com/doc/guides/security/api-keys/#access-control-list-acl). - Logs are held for the last seven days. - Up to 1,000 API requests per server are logged. - This request counts towards your [operations quota](https://support.algolia.com/hc/en-us/articles/4406981829777-How-does-Algolia-count-records-and-operations-) but doesn\'t appear in the logs itself.
3451
+ *
3452
+ * Required API Key ACLs:
3453
+ * - logs.
3087
3454
  *
3088
- * @summary Return the latest log entries.
3089
3455
  * @param getLogs - The getLogs object.
3090
- * @param getLogs.offset - First log entry to retrieve. Sorted by decreasing date with 0 being the most recent.
3456
+ * @param getLogs.offset - First log entry to retrieve. The most recent entries are listed first.
3091
3457
  * @param getLogs.length - Maximum number of entries to retrieve.
3092
- * @param getLogs.indexName - Index for which log entries should be retrieved. When omitted, log entries are retrieved for all indices.
3093
- * @param getLogs.type - Type of log entries to retrieve. When omitted, all log entries are retrieved.
3458
+ * @param getLogs.indexName - Index for which to retrieve log entries. By default, log entries are retrieved for all indices.
3459
+ * @param getLogs.type - Type of log entries to retrieve. By default, all log entries are retrieved.
3094
3460
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3095
3461
  */
3096
3462
  getLogs({ offset, length, indexName, type } = {}, requestOptions = undefined) {
@@ -3118,13 +3484,15 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3118
3484
  return transporter.request(request, requestOptions);
3119
3485
  },
3120
3486
  /**
3121
- * To get more than one record, use the [`objects` operation](#tag/Records/operation/getObjects).
3487
+ * Retrieves one record by its object ID. To retrieve more than one record, use the [`objects` operation](#tag/Records/operation/getObjects).
3488
+ *
3489
+ * Required API Key ACLs:
3490
+ * - search.
3122
3491
  *
3123
- * @summary Get a record.
3124
3492
  * @param getObject - The getObject object.
3125
- * @param getObject.indexName - Index on which to perform the request.
3126
- * @param getObject.objectID - Unique record (object) identifier.
3127
- * @param getObject.attributesToRetrieve - Attributes to include with the records in the response. This is useful to reduce the size of the API response. By default, all retrievable attributes are returned. `objectID` is always retrieved, even when not specified. [`unretrievableAttributes`](https://www.algolia.com/doc/api-reference/api-parameters/unretrievableAttributes/) won\'t be retrieved unless the request is authenticated with the admin API key.
3493
+ * @param getObject.indexName - Name of the index on which to perform the operation.
3494
+ * @param getObject.objectID - Unique record identifier.
3495
+ * @param getObject.attributesToRetrieve - Attributes to include with the records in the response. This is useful to reduce the size of the API response. By default, all retrievable attributes are returned. `objectID` is always retrieved. Attributes included in `unretrievableAttributes` won\'t be retrieved unless the request is authenticated with the admin API key.
3128
3496
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3129
3497
  */
3130
3498
  getObject({ indexName, objectID, attributesToRetrieve }, requestOptions) {
@@ -3151,9 +3519,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3151
3519
  return transporter.request(request, requestOptions);
3152
3520
  },
3153
3521
  /**
3154
- * Retrieve one or more records, potentially from different indices, in a single API operation. Results will be received in the same order as the requests.
3522
+ * Retrieves one or more records, potentially from different indices. Records are returned in the same order as the requests.
3523
+ *
3524
+ * Required API Key ACLs:
3525
+ * - search.
3155
3526
  *
3156
- * @summary Get multiple records.
3157
3527
  * @param getObjectsParams - Request object.
3158
3528
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3159
3529
  */
@@ -3179,11 +3549,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3179
3549
  return transporter.request(request, requestOptions);
3180
3550
  },
3181
3551
  /**
3182
- * Get a rule by its `objectID`. To find the `objectID` for rules, use the [`search` operation](#tag/Rules/operation/searchRules).
3552
+ * Retrieves a rule by its ID. To find the object ID of rules, use the [`search` operation](#tag/Rules/operation/searchRules).
3553
+ *
3554
+ * Required API Key ACLs:
3555
+ * - settings.
3183
3556
  *
3184
- * @summary Get a rule.
3185
3557
  * @param getRule - The getRule object.
3186
- * @param getRule.indexName - Index on which to perform the request.
3558
+ * @param getRule.indexName - Name of the index on which to perform the operation.
3187
3559
  * @param getRule.objectID - Unique identifier of a rule object.
3188
3560
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3189
3561
  */
@@ -3208,11 +3580,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3208
3580
  return transporter.request(request, requestOptions);
3209
3581
  },
3210
3582
  /**
3211
- * Return an object containing an index\'s [configuration settings](https://www.algolia.com/doc/api-reference/settings-api-parameters/).
3583
+ * Retrieves an object with non-null index settings.
3584
+ *
3585
+ * Required API Key ACLs:
3586
+ * - search.
3212
3587
  *
3213
- * @summary Get index settings.
3214
3588
  * @param getSettings - The getSettings object.
3215
- * @param getSettings.indexName - Index on which to perform the request.
3589
+ * @param getSettings.indexName - Name of the index on which to perform the operation.
3216
3590
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3217
3591
  */
3218
3592
  getSettings({ indexName }, requestOptions) {
@@ -3231,9 +3605,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3231
3605
  return transporter.request(request, requestOptions);
3232
3606
  },
3233
3607
  /**
3234
- * Get all allowed sources (IP addresses).
3608
+ * Retrieves all allowed IP addresses with access to your application.
3609
+ *
3610
+ * Required API Key ACLs:
3611
+ * - admin.
3235
3612
  *
3236
- * @summary Get all allowed IP addresses.
3237
3613
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3238
3614
  */
3239
3615
  getSources(requestOptions) {
@@ -3249,11 +3625,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3249
3625
  return transporter.request(request, requestOptions);
3250
3626
  },
3251
3627
  /**
3252
- * Get a syonym by its `objectID`. To find the object IDs for your synonyms, use the [`search` operation](#tag/Synonyms/operation/searchSynonyms).
3628
+ * Retrieves a syonym by its ID. To find the object IDs for your synonyms, use the [`search` operation](#tag/Synonyms/operation/searchSynonyms).
3629
+ *
3630
+ * Required API Key ACLs:
3631
+ * - settings.
3253
3632
  *
3254
- * @summary Get a synonym object.
3255
3633
  * @param getSynonym - The getSynonym object.
3256
- * @param getSynonym.indexName - Index on which to perform the request.
3634
+ * @param getSynonym.indexName - Name of the index on which to perform the operation.
3257
3635
  * @param getSynonym.objectID - Unique identifier of a synonym object.
3258
3636
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3259
3637
  */
@@ -3278,11 +3656,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3278
3656
  return transporter.request(request, requestOptions);
3279
3657
  },
3280
3658
  /**
3281
- * Some operations, such as copying an index, will respond with a `taskID` value. Use this value here to check the status of that task.
3659
+ * Checks the status of a given task. Indexing tasks are asynchronous. When you add, update, or delete records or indices, a task is created on a queue and completed depending on the load on the server. The indexing tasks\' responses include a task ID that you can use to check the status.
3660
+ *
3661
+ * Required API Key ACLs:
3662
+ * - addObject.
3282
3663
  *
3283
- * @summary Check a task\'s status.
3284
3664
  * @param getTask - The getTask object.
3285
- * @param getTask.indexName - Index on which to perform the request.
3665
+ * @param getTask.indexName - Name of the index on which to perform the operation.
3286
3666
  * @param getTask.taskID - Unique task identifier.
3287
3667
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3288
3668
  */
@@ -3307,9 +3687,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3307
3687
  return transporter.request(request, requestOptions);
3308
3688
  },
3309
3689
  /**
3310
- * Get the IDs of the 10 users with the highest number of records per cluster. Since it can take up to a few seconds to get the data from the different clusters, the response isn\'t real-time.
3690
+ * Get the IDs of the 10 users with the highest number of records per cluster. Since it can take a few seconds to get the data from the different clusters, the response isn\'t real-time.
3691
+ *
3692
+ * Required API Key ACLs:
3693
+ * - admin.
3311
3694
  *
3312
- * @summary Get top userID.
3313
3695
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3314
3696
  */
3315
3697
  getTopUserIds(requestOptions) {
@@ -3325,11 +3707,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3325
3707
  return transporter.request(request, requestOptions);
3326
3708
  },
3327
3709
  /**
3328
- * Returns the userID data stored in the mapping. Since it can take up to a few seconds to get the data from the different clusters, the response isn\'t real-time.
3710
+ * Returns the user ID data stored in the mapping. Since it can take a few seconds to get the data from the different clusters, the response isn\'t real-time.
3711
+ *
3712
+ * Required API Key ACLs:
3713
+ * - admin.
3329
3714
  *
3330
- * @summary Get userID.
3331
3715
  * @param getUserId - The getUserId object.
3332
- * @param getUserId.userID - UserID to assign.
3716
+ * @param getUserId.userID - Unique identifier of the user who makes the search request.
3333
3717
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3334
3718
  */
3335
3719
  getUserId({ userID }, requestOptions) {
@@ -3350,9 +3734,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3350
3734
  /**
3351
3735
  * To determine when the time-consuming process of creating a large batch of users or migrating users from one cluster to another is complete, this operation retrieves the status of the process.
3352
3736
  *
3353
- * @summary Get migration and user mapping status.
3737
+ * Required API Key ACLs:
3738
+ * - admin.
3739
+ *
3354
3740
  * @param hasPendingMappings - The hasPendingMappings object.
3355
- * @param hasPendingMappings.getClusters - Indicates whether to include the cluster\'s pending mapping state in the response.
3741
+ * @param hasPendingMappings.getClusters - Whether to include the cluster\'s pending mapping state in the response.
3356
3742
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3357
3743
  */
3358
3744
  hasPendingMappings({ getClusters } = {}, requestOptions = undefined) {
@@ -3371,9 +3757,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3371
3757
  return transporter.request(request, requestOptions);
3372
3758
  },
3373
3759
  /**
3374
- * List all API keys associated with your Algolia application, including their permissions and restrictions.
3760
+ * Lists all API keys associated with your Algolia application, including their permissions and restrictions.
3761
+ *
3762
+ * Required API Key ACLs:
3763
+ * - admin.
3375
3764
  *
3376
- * @summary List API keys.
3377
3765
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3378
3766
  */
3379
3767
  listApiKeys(requestOptions) {
@@ -3389,9 +3777,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3389
3777
  return transporter.request(request, requestOptions);
3390
3778
  },
3391
3779
  /**
3392
- * List the available clusters in a multi-cluster setup.
3780
+ * Lists the available clusters in a multi-cluster setup.
3781
+ *
3782
+ * Required API Key ACLs:
3783
+ * - admin.
3393
3784
  *
3394
- * @summary List clusters.
3395
3785
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3396
3786
  */
3397
3787
  listClusters(requestOptions) {
@@ -3407,12 +3797,14 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3407
3797
  return transporter.request(request, requestOptions);
3408
3798
  },
3409
3799
  /**
3410
- * List indices in an Algolia application.
3800
+ * Lists all indices in the current Algolia application. The request follows any index restrictions of the API key you use to make the request.
3801
+ *
3802
+ * Required API Key ACLs:
3803
+ * - listIndexes.
3411
3804
  *
3412
- * @summary List indices.
3413
3805
  * @param listIndices - The listIndices object.
3414
- * @param listIndices.page - Returns the requested page number. The page size is determined by the `hitsPerPage` parameter. You can see the number of available pages in the `nbPages` response attribute. When `page` is null, the API response is not paginated.
3415
- * @param listIndices.hitsPerPage - Maximum number of hits per page.
3806
+ * @param listIndices.page - Requested page of the API response. If `null`, the API response is not paginated.
3807
+ * @param listIndices.hitsPerPage - Number of hits per page.
3416
3808
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3417
3809
  */
3418
3810
  listIndices({ page, hitsPerPage } = {}, requestOptions = undefined) {
@@ -3434,12 +3826,14 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3434
3826
  return transporter.request(request, requestOptions);
3435
3827
  },
3436
3828
  /**
3437
- * List the userIDs assigned to a multi-cluster application. Since it can take up to a few seconds to get the data from the different clusters, the response isn\'t real-time.
3829
+ * Lists the userIDs assigned to a multi-cluster application. Since it can take a few seconds to get the data from the different clusters, the response isn\'t real-time.
3830
+ *
3831
+ * Required API Key ACLs:
3832
+ * - admin.
3438
3833
  *
3439
- * @summary List userIDs.
3440
3834
  * @param listUserIds - The listUserIds object.
3441
- * @param listUserIds.page - Returns the requested page number. The page size is determined by the `hitsPerPage` parameter. You can see the number of available pages in the `nbPages` response attribute. When `page` is null, the API response is not paginated.
3442
- * @param listUserIds.hitsPerPage - Maximum number of hits per page.
3835
+ * @param listUserIds.page - Requested page of the API response. If `null`, the API response is not paginated.
3836
+ * @param listUserIds.hitsPerPage - Number of hits per page.
3443
3837
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3444
3838
  */
3445
3839
  listUserIds({ page, hitsPerPage } = {}, requestOptions = undefined) {
@@ -3461,9 +3855,8 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3461
3855
  return transporter.request(request, requestOptions);
3462
3856
  },
3463
3857
  /**
3464
- * To reduce the time spent on network round trips, you can perform several write actions in a single request. It\'s a multi-index version of the [`batch` operation](#tag/Records/operation/batch). Actions are applied in the order they are specified. The supported actions are equivalent to the individual operations of the same name.
3858
+ * Adds, updates, or deletes records in multiple indices with a single API request. - Actions are applied in the order they are specified. - Actions are equivalent to the individual API requests of the same name.
3465
3859
  *
3466
- * @summary Batch write operations on multiple indices.
3467
3860
  * @param batchParams - The batchParams object.
3468
3861
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3469
3862
  */
@@ -3487,11 +3880,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3487
3880
  return transporter.request(request, requestOptions);
3488
3881
  },
3489
3882
  /**
3490
- * This `operation`, _copy_ or _move_, will copy or move a source index\'s (`IndexName`) records, settings, synonyms, and rules to a `destination` index. If the destination index exists, it will be replaced, except for index-specific API keys and analytics data. If the destination index doesn\'t exist, it will be created. The choice between moving or copying an index depends on your needs. Choose: - **Move** to rename an index. - **Copy** to create a new index with the same records and configuration as an existing one. > **Note**: When considering copying or moving, be aware of the [rate limitations](https://www.algolia.com/doc/guides/scaling/algolia-service-limits/#application-record-and-index-limits) on these processes and the [impact on your analytics data](https://www.algolia.com/doc/guides/sending-and-managing-data/manage-indices-and-apps/manage-indices/concepts/indices-analytics/).
3883
+ * Copies or moves (renames) an index within the same Algolia application. - Existing destination indices are overwritten, except for their analytics data. - If the destination index doesn\'t exist yet, it\'ll be created. **Copy** - Copying a source index that doesn\'t exist creates a new index with 0 records and default settings. - The API keys of the source index are merged with the existing keys in the destination index. - You can\'t copy the `enableReRanking`, `mode`, and `replicas` settings. - You can\'t copy to a destination index that already has replicas. - Be aware of the [size limits](https://www.algolia.com/doc/guides/scaling/algolia-service-limits/#application-record-and-index-limits). - Related guide: [Copy indices](https://www.algolia.com/doc/guides/sending-and-managing-data/manage-indices-and-apps/manage-indices/how-to/copy-indices/) **Move** - Moving a source index that doesn\'t exist is ignored without returning an error. - When moving an index, the analytics data keep their original name and a new set of analytics data is started for the new name. To access the original analytics in the dashboard, create an index with the original name. - If the destination index has replicas, moving will overwrite the existing index and copy the data to the replica indices. - Related guide: [Move indices](https://www.algolia.com/doc/guides/sending-and-managing-data/manage-indices-and-apps/manage-indices/how-to/move-indices/).
3884
+ *
3885
+ * Required API Key ACLs:
3886
+ * - addObject.
3491
3887
  *
3492
- * @summary Copy, move, or rename an index.
3493
3888
  * @param operationIndex - The operationIndex object.
3494
- * @param operationIndex.indexName - Index on which to perform the request.
3889
+ * @param operationIndex.indexName - Name of the index on which to perform the operation.
3495
3890
  * @param operationIndex.operationIndexParams - The operationIndexParams object.
3496
3891
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3497
3892
  */
@@ -3521,14 +3916,16 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3521
3916
  return transporter.request(request, requestOptions);
3522
3917
  },
3523
3918
  /**
3524
- * Add new attributes or update current ones in an existing record. You can use any first-level attribute but not nested attributes. If you specify a [nested attribute](https://www.algolia.com/doc/guides/sending-and-managing-data/prepare-your-data/how-to/creating-and-using-nested-attributes/), the engine treats it as a replacement for its first-level ancestor.
3919
+ * Adds new attributes to a record, or update existing ones. - If a record with the specified object ID doesn\'t exist, a new record is added to the index **if** `createIfNotExists` is true. - If the index doesn\'t exist yet, this method creates a new index. - You can use any first-level attribute but not nested attributes. If you specify a nested attribute, the engine treats it as a replacement for its first-level ancestor.
3920
+ *
3921
+ * Required API Key ACLs:
3922
+ * - addObject.
3525
3923
  *
3526
- * @summary Update record attributes.
3527
3924
  * @param partialUpdateObject - The partialUpdateObject object.
3528
- * @param partialUpdateObject.indexName - Index on which to perform the request.
3529
- * @param partialUpdateObject.objectID - Unique record (object) identifier.
3530
- * @param partialUpdateObject.attributesToUpdate - Object with attributes to update.
3531
- * @param partialUpdateObject.createIfNotExists - Indicates whether to create a new record if it doesn\'t exist yet.
3925
+ * @param partialUpdateObject.indexName - Name of the index on which to perform the operation.
3926
+ * @param partialUpdateObject.objectID - Unique record identifier.
3927
+ * @param partialUpdateObject.attributesToUpdate - Attributes with their values.
3928
+ * @param partialUpdateObject.createIfNotExists - Whether to create a new record if it doesn\'t exist.
3532
3929
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3533
3930
  */
3534
3931
  partialUpdateObject({ indexName, objectID, attributesToUpdate, createIfNotExists, }, requestOptions) {
@@ -3559,11 +3956,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3559
3956
  return transporter.request(request, requestOptions);
3560
3957
  },
3561
3958
  /**
3562
- * Remove a userID and its associated data from the multi-clusters.
3959
+ * Deletes a user ID and its associated data from the clusters.
3960
+ *
3961
+ * Required API Key ACLs:
3962
+ * - admin.
3563
3963
  *
3564
- * @summary Remove userID.
3565
3964
  * @param removeUserId - The removeUserId object.
3566
- * @param removeUserId.userID - UserID to assign.
3965
+ * @param removeUserId.userID - Unique identifier of the user who makes the search request.
3567
3966
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3568
3967
  */
3569
3968
  removeUserId({ userID }, requestOptions) {
@@ -3582,9 +3981,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3582
3981
  return transporter.request(request, requestOptions);
3583
3982
  },
3584
3983
  /**
3585
- * Replace all allowed sources.
3984
+ * Replaces the list of allowed sources.
3985
+ *
3986
+ * Required API Key ACLs:
3987
+ * - admin.
3586
3988
  *
3587
- * @summary Replace all sources.
3588
3989
  * @param replaceSources - The replaceSources object.
3589
3990
  * @param replaceSources.source - Allowed sources.
3590
3991
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -3606,9 +4007,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3606
4007
  return transporter.request(request, requestOptions);
3607
4008
  },
3608
4009
  /**
3609
- * Restore a deleted API key, along with its associated permissions. The request must be authenticated with the admin API key.
4010
+ * Restores a deleted API key. Restoring resets the `validity` attribute to `0`. Algolia stores up to 1,000 API keys per application. If you create more, the oldest API keys are deleted and can\'t be restored.
4011
+ *
4012
+ * Required API Key ACLs:
4013
+ * - admin.
3610
4014
  *
3611
- * @summary Restore API key.
3612
4015
  * @param restoreApiKey - The restoreApiKey object.
3613
4016
  * @param restoreApiKey.key - API key.
3614
4017
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -3629,12 +4032,14 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3629
4032
  return transporter.request(request, requestOptions);
3630
4033
  },
3631
4034
  /**
3632
- * Add a record (object) to an index or replace it. If the record doesn\'t contain an `objectID`, Algolia automatically adds it. If you use an existing `objectID`, the existing record is replaced with the new one. To add multiple records to your index in a single API request, use the [`batch` operation](#tag/Records/operation/batch).
4035
+ * Adds a record to an index or replace it. - If the record doesn\'t have an object ID, a new record with an auto-generated object ID is added to your index. - If a record with the specified object ID exists, the existing record is replaced. - If a record with the specified object ID doesn\'t exist, a new record is added to your index. - If you add a record to an index that doesn\'t exist yet, a new index is created. To update _some_ attributes of a record, use the [`partial` operation](#tag/Records/operation/partial). To add, update, or replace multiple records, use the [`batch` operation](#tag/Records/operation/batch).
4036
+ *
4037
+ * Required API Key ACLs:
4038
+ * - addObject.
3633
4039
  *
3634
- * @summary Add or update a record.
3635
4040
  * @param saveObject - The saveObject object.
3636
- * @param saveObject.indexName - Index on which to perform the request.
3637
- * @param saveObject.body - The Algolia record.
4041
+ * @param saveObject.indexName - Name of the index on which to perform the operation.
4042
+ * @param saveObject.body - The record, a schemaless object with attributes that are useful in the context of search and discovery.
3638
4043
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3639
4044
  */
3640
4045
  saveObject({ indexName, body }, requestOptions) {
@@ -3657,14 +4062,16 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3657
4062
  return transporter.request(request, requestOptions);
3658
4063
  },
3659
4064
  /**
3660
- * To create or update more than one rule, use the [`batch` operation](#tag/Rules/operation/saveRules).
4065
+ * If a rule with the specified object ID doesn\'t exist, it\'s created. Otherwise, the existing rule is replaced. To create or update more than one rule, use the [`batch` operation](#tag/Rules/operation/saveRules).
4066
+ *
4067
+ * Required API Key ACLs:
4068
+ * - editSettings.
3661
4069
  *
3662
- * @summary Create or update a rule.
3663
4070
  * @param saveRule - The saveRule object.
3664
- * @param saveRule.indexName - Index on which to perform the request.
4071
+ * @param saveRule.indexName - Name of the index on which to perform the operation.
3665
4072
  * @param saveRule.objectID - Unique identifier of a rule object.
3666
4073
  * @param saveRule.rule - The rule object.
3667
- * @param saveRule.forwardToReplicas - Indicates whether changed index settings are forwarded to the replica indices.
4074
+ * @param saveRule.forwardToReplicas - Whether changes are applied to replica indices.
3668
4075
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3669
4076
  */
3670
4077
  saveRule({ indexName, objectID, rule, forwardToReplicas }, requestOptions) {
@@ -3698,14 +4105,16 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3698
4105
  return transporter.request(request, requestOptions);
3699
4106
  },
3700
4107
  /**
3701
- * Create or update multiple rules.
4108
+ * Create or update multiple rules. If a rule with the specified object ID doesn\'t exist, Algolia creates a new one. Otherwise, existing rules are replaced.
4109
+ *
4110
+ * Required API Key ACLs:
4111
+ * - editSettings.
3702
4112
  *
3703
- * @summary Save a batch of rules.
3704
4113
  * @param saveRules - The saveRules object.
3705
- * @param saveRules.indexName - Index on which to perform the request.
4114
+ * @param saveRules.indexName - Name of the index on which to perform the operation.
3706
4115
  * @param saveRules.rules - The rules object.
3707
- * @param saveRules.forwardToReplicas - Indicates whether changed index settings are forwarded to the replica indices.
3708
- * @param saveRules.clearExistingRules - Indicates whether existing rules should be deleted before adding this batch.
4116
+ * @param saveRules.forwardToReplicas - Whether changes are applied to replica indices.
4117
+ * @param saveRules.clearExistingRules - Whether existing rules should be deleted before adding this batch.
3709
4118
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3710
4119
  */
3711
4120
  saveRules({ indexName, rules, forwardToReplicas, clearExistingRules, }, requestOptions) {
@@ -3734,14 +4143,16 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3734
4143
  return transporter.request(request, requestOptions);
3735
4144
  },
3736
4145
  /**
3737
- * Add a [synonym](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/#the-different-types-of-synonyms) to an index or replace it. If the synonym `objectID` doesn\'t exist, Algolia adds a new one. If you use an existing synonym `objectID`, the existing synonym is replaced with the new one. To add multiple synonyms in a single API request, use the [`batch` operation](#tag/Synonyms/operation/saveSynonyms).
4146
+ * If a synonym with the specified object ID doesn\'t exist, Algolia adds a new one. Otherwise, the existing synonym is replaced. To add multiple synonyms in a single API request, use the [`batch` operation](#tag/Synonyms/operation/saveSynonyms).
4147
+ *
4148
+ * Required API Key ACLs:
4149
+ * - editSettings.
3738
4150
  *
3739
- * @summary Save a synonym.
3740
4151
  * @param saveSynonym - The saveSynonym object.
3741
- * @param saveSynonym.indexName - Index on which to perform the request.
4152
+ * @param saveSynonym.indexName - Name of the index on which to perform the operation.
3742
4153
  * @param saveSynonym.objectID - Unique identifier of a synonym object.
3743
4154
  * @param saveSynonym.synonymHit - The synonymHit object.
3744
- * @param saveSynonym.forwardToReplicas - Indicates whether changed index settings are forwarded to the replica indices.
4155
+ * @param saveSynonym.forwardToReplicas - Whether changes are applied to replica indices.
3745
4156
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3746
4157
  */
3747
4158
  saveSynonym({ indexName, objectID, synonymHit, forwardToReplicas }, requestOptions) {
@@ -3778,14 +4189,16 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3778
4189
  return transporter.request(request, requestOptions);
3779
4190
  },
3780
4191
  /**
3781
- * Create or update multiple synonyms.
4192
+ * If a synonym with the `objectID` doesn\'t exist, Algolia adds a new one. Otherwise, existing synonyms are replaced.
4193
+ *
4194
+ * Required API Key ACLs:
4195
+ * - editSettings.
3782
4196
  *
3783
- * @summary Save a batch of synonyms.
3784
4197
  * @param saveSynonyms - The saveSynonyms object.
3785
- * @param saveSynonyms.indexName - Index on which to perform the request.
4198
+ * @param saveSynonyms.indexName - Name of the index on which to perform the operation.
3786
4199
  * @param saveSynonyms.synonymHit - The synonymHit object.
3787
- * @param saveSynonyms.forwardToReplicas - Indicates whether changed index settings are forwarded to the replica indices.
3788
- * @param saveSynonyms.replaceExistingSynonyms - Indicates whether to replace all synonyms in the index with the ones sent with this request.
4200
+ * @param saveSynonyms.forwardToReplicas - Whether changes are applied to replica indices.
4201
+ * @param saveSynonyms.replaceExistingSynonyms - Whether to replace all synonyms in the index with the ones sent with this request.
3789
4202
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3790
4203
  */
3791
4204
  saveSynonyms({ indexName, synonymHit, forwardToReplicas, replaceExistingSynonyms, }, requestOptions) {
@@ -3815,10 +4228,12 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3815
4228
  return transporter.request(request, requestOptions);
3816
4229
  },
3817
4230
  /**
3818
- * Send multiple search queries to one or more indices.
4231
+ * Sends multiple search request to one or more indices. This can be useful in these cases: - Different indices for different purposes, such as, one index for products, another one for marketing content. - Multiple searches to the same index—for example, with different filters.
3819
4232
  *
3820
- * @summary Search multiple indices.
3821
- * @param searchMethodParams - Query requests and strategies. Results will be received in the same order as the queries.
4233
+ * Required API Key ACLs:
4234
+ * - search.
4235
+ *
4236
+ * @param searchMethodParams - Muli-search request body. Results are returned in the same order as the requests.
3822
4237
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3823
4238
  */
3824
4239
  search(searchMethodParams, requestOptions) {
@@ -3865,11 +4280,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3865
4280
  return transporter.request(request, requestOptions);
3866
4281
  },
3867
4282
  /**
3868
- * Search for standard and [custom](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-stop-words/) entries in the [stop words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-stop-words/), [plurals](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-plurals-and-other-declensions/), or [segmentation (compounds)](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/how-to/customize-segmentation/) dictionaries.
4283
+ * Searches for standard and custom dictionary entries.
4284
+ *
4285
+ * Required API Key ACLs:
4286
+ * - settings.
3869
4287
  *
3870
- * @summary Search dictionary entries.
3871
4288
  * @param searchDictionaryEntries - The searchDictionaryEntries object.
3872
- * @param searchDictionaryEntries.dictionaryName - Dictionary to search in.
4289
+ * @param searchDictionaryEntries.dictionaryName - Dictionary type in which to search.
3873
4290
  * @param searchDictionaryEntries.searchDictionaryEntriesParams - The searchDictionaryEntriesParams object.
3874
4291
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3875
4292
  */
@@ -3898,12 +4315,14 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3898
4315
  return transporter.request(request, requestOptions);
3899
4316
  },
3900
4317
  /**
3901
- * [Search for a facet\'s values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values), optionally restricting the returned values to those contained in records matching other search criteria. > **Note**: Pagination isn\'t supported (`page` and `hitsPerPage` are ignored). By default, the engine returns a maximum of 10 values but you can adjust this with `maxFacetHits`.
4318
+ * Searches for values of a specified facet attribute. - By default, facet values are sorted by decreasing count. You can adjust this with the `sortFacetValueBy` parameter. - Searching for facet values doesn\'t work if you have **more than 65 searchable facets and searchable attributes combined**.
4319
+ *
4320
+ * Required API Key ACLs:
4321
+ * - search.
3902
4322
  *
3903
- * @summary Search for facet values.
3904
4323
  * @param searchForFacetValues - The searchForFacetValues object.
3905
- * @param searchForFacetValues.indexName - Index on which to perform the request.
3906
- * @param searchForFacetValues.facetName - Facet name.
4324
+ * @param searchForFacetValues.indexName - Name of the index on which to perform the operation.
4325
+ * @param searchForFacetValues.facetName - Facet attribute in which to search for values. This attribute must be included in the `attributesForFaceting` index setting with the `searchable()` modifier.
3907
4326
  * @param searchForFacetValues.searchForFacetValuesRequest - The searchForFacetValuesRequest object.
3908
4327
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3909
4328
  */
@@ -3931,11 +4350,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3931
4350
  return transporter.request(request, requestOptions);
3932
4351
  },
3933
4352
  /**
3934
- * Search for rules in your index. You can control the search with parameters. To list all rules, send an empty request body.
4353
+ * Searches for rules in your index.
4354
+ *
4355
+ * Required API Key ACLs:
4356
+ * - settings.
3935
4357
  *
3936
- * @summary Search for rules.
3937
4358
  * @param searchRules - The searchRules object.
3938
- * @param searchRules.indexName - Index on which to perform the request.
4359
+ * @param searchRules.indexName - Name of the index on which to perform the operation.
3939
4360
  * @param searchRules.searchRulesParams - The searchRulesParams object.
3940
4361
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3941
4362
  */
@@ -3958,11 +4379,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3958
4379
  return transporter.request(request, requestOptions);
3959
4380
  },
3960
4381
  /**
3961
- * Return records that match the query.
4382
+ * Searches a single index and return matching search results (_hits_). This method lets you retrieve up to 1,000 hits. If you need more, use the [`browse` operation](#tag/Search/operation/browse) or increase the `paginatedLimitedTo` index setting.
4383
+ *
4384
+ * Required API Key ACLs:
4385
+ * - search.
3962
4386
  *
3963
- * @summary Search an index.
3964
4387
  * @param searchSingleIndex - The searchSingleIndex object.
3965
- * @param searchSingleIndex.indexName - Index on which to perform the request.
4388
+ * @param searchSingleIndex.indexName - Name of the index on which to perform the operation.
3966
4389
  * @param searchSingleIndex.searchParams - The searchParams object.
3967
4390
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3968
4391
  */
@@ -3985,11 +4408,13 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
3985
4408
  return transporter.request(request, requestOptions);
3986
4409
  },
3987
4410
  /**
3988
- * Search for synonyms in your index. You can control and filter the search with parameters. To get all synonyms, send an empty request body.
4411
+ * Searches for synonyms in your index.
4412
+ *
4413
+ * Required API Key ACLs:
4414
+ * - settings.
3989
4415
  *
3990
- * @summary Search for synonyms.
3991
4416
  * @param searchSynonyms - The searchSynonyms object.
3992
- * @param searchSynonyms.indexName - Index on which to perform the request.
4417
+ * @param searchSynonyms.indexName - Name of the index on which to perform the operation.
3993
4418
  * @param searchSynonyms.searchSynonymsParams - Body of the `searchSynonyms` operation.
3994
4419
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
3995
4420
  */
@@ -4012,9 +4437,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
4012
4437
  return transporter.request(request, requestOptions);
4013
4438
  },
4014
4439
  /**
4015
- * Since it can take up to a few seconds to get the data from the different clusters, the response isn\'t real-time. To ensure rapid updates, the user IDs index isn\'t built at the same time as the mapping. Instead, it\'s built every 12 hours, at the same time as the update of user ID usage. For example, if you add or move a user ID, the search will show an old value until the next time the mapping is rebuilt (every 12 hours).
4440
+ * Since it can take a few seconds to get the data from the different clusters, the response isn\'t real-time. To ensure rapid updates, the user IDs index isn\'t built at the same time as the mapping. Instead, it\'s built every 12 hours, at the same time as the update of user ID usage. For example, if you add or move a user ID, the search will show an old value until the next time the mapping is rebuilt (every 12 hours).
4441
+ *
4442
+ * Required API Key ACLs:
4443
+ * - admin.
4016
4444
  *
4017
- * @summary Search for a user ID.
4018
4445
  * @param searchUserIdsParams - The searchUserIdsParams object.
4019
4446
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
4020
4447
  */
@@ -4040,9 +4467,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
4040
4467
  return transporter.request(request, requestOptions);
4041
4468
  },
4042
4469
  /**
4043
- * Set stop word settings for a specific language.
4470
+ * Turns standard stop word dictionary entries on or off for a given language.
4471
+ *
4472
+ * Required API Key ACLs:
4473
+ * - editSettings.
4044
4474
  *
4045
- * @summary Set stop word settings.
4046
4475
  * @param dictionarySettingsParams - The dictionarySettingsParams object.
4047
4476
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
4048
4477
  */
@@ -4066,13 +4495,15 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
4066
4495
  return transporter.request(request, requestOptions);
4067
4496
  },
4068
4497
  /**
4069
- * Update the specified [index settings](https://www.algolia.com/doc/api-reference/settings-api-parameters/). Specifying null for a setting resets it to its default value.
4498
+ * Update the specified index settings. Index settings that you don\'t specify are left unchanged. Specify `null` to reset a setting to its default value. For best performance, update the index settings before you add new records to your index.
4499
+ *
4500
+ * Required API Key ACLs:
4501
+ * - editSettings.
4070
4502
  *
4071
- * @summary Update index settings.
4072
4503
  * @param setSettings - The setSettings object.
4073
- * @param setSettings.indexName - Index on which to perform the request.
4504
+ * @param setSettings.indexName - Name of the index on which to perform the operation.
4074
4505
  * @param setSettings.indexSettings - The indexSettings object.
4075
- * @param setSettings.forwardToReplicas - Indicates whether changed index settings are forwarded to the replica indices.
4506
+ * @param setSettings.forwardToReplicas - Whether changes are applied to replica indices.
4076
4507
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
4077
4508
  */
4078
4509
  setSettings({ indexName, indexSettings, forwardToReplicas }, requestOptions) {
@@ -4098,9 +4529,11 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
4098
4529
  return transporter.request(request, requestOptions);
4099
4530
  },
4100
4531
  /**
4101
- * Replace the permissions of an existing API key. Any unspecified parameter resets that permission to its default value. The request must be authenticated with the admin API key.
4532
+ * Replaces the permissions of an existing API key. Any unspecified attribute resets that attribute to its default value.
4533
+ *
4534
+ * Required API Key ACLs:
4535
+ * - admin.
4102
4536
  *
4103
- * @summary Update an API key.
4104
4537
  * @param updateApiKey - The updateApiKey object.
4105
4538
  * @param updateApiKey.key - API key.
4106
4539
  * @param updateApiKey.apiKey - The apiKey object.
@@ -4131,6 +4564,368 @@ function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode
4131
4564
  };
4132
4565
  }
4133
4566
 
4567
+ // Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
4568
+ const apiClientVersion$1 = '5.0.0-beta.10';
4569
+ function getDefaultHosts(appId) {
4570
+ return [
4571
+ {
4572
+ url: `${appId}-dsn.algolia.net`,
4573
+ accept: 'read',
4574
+ protocol: 'https',
4575
+ },
4576
+ {
4577
+ url: `${appId}.algolia.net`,
4578
+ accept: 'write',
4579
+ protocol: 'https',
4580
+ },
4581
+ ].concat(shuffle([
4582
+ {
4583
+ url: `${appId}-1.algolianet.com`,
4584
+ accept: 'readWrite',
4585
+ protocol: 'https',
4586
+ },
4587
+ {
4588
+ url: `${appId}-2.algolianet.com`,
4589
+ accept: 'readWrite',
4590
+ protocol: 'https',
4591
+ },
4592
+ {
4593
+ url: `${appId}-3.algolianet.com`,
4594
+ accept: 'readWrite',
4595
+ protocol: 'https',
4596
+ },
4597
+ ]));
4598
+ }
4599
+ // eslint-disable-next-line @typescript-eslint/explicit-function-return-type
4600
+ function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, ...options }) {
4601
+ const auth = createAuth(appIdOption, apiKeyOption, authMode);
4602
+ const transporter = createTransporter({
4603
+ hosts: getDefaultHosts(appIdOption),
4604
+ ...options,
4605
+ algoliaAgent: getAlgoliaAgent({
4606
+ algoliaAgents,
4607
+ client: 'Recommend',
4608
+ version: apiClientVersion$1,
4609
+ }),
4610
+ baseHeaders: {
4611
+ 'content-type': 'text/plain',
4612
+ ...auth.headers(),
4613
+ ...options.baseHeaders,
4614
+ },
4615
+ baseQueryParameters: {
4616
+ ...auth.queryParameters(),
4617
+ ...options.baseQueryParameters,
4618
+ },
4619
+ });
4620
+ return {
4621
+ transporter,
4622
+ /**
4623
+ * The `appId` currently in use.
4624
+ */
4625
+ appId: appIdOption,
4626
+ /**
4627
+ * Clears the cache of the transporter for the `requestsCache` and `responsesCache` properties.
4628
+ */
4629
+ clearCache() {
4630
+ return Promise.all([
4631
+ transporter.requestsCache.clear(),
4632
+ transporter.responsesCache.clear(),
4633
+ ]).then(() => undefined);
4634
+ },
4635
+ /**
4636
+ * Get the value of the `algoliaAgent`, used by our libraries internally and telemetry system.
4637
+ */
4638
+ get _ua() {
4639
+ return transporter.algoliaAgent.value;
4640
+ },
4641
+ /**
4642
+ * Adds a `segment` to the `x-algolia-agent` sent with every requests.
4643
+ *
4644
+ * @param segment - The algolia agent (user-agent) segment to add.
4645
+ * @param version - The version of the agent.
4646
+ */
4647
+ addAlgoliaAgent(segment, version) {
4648
+ transporter.algoliaAgent.add({ segment, version });
4649
+ },
4650
+ /**
4651
+ * This method allow you to send requests to the Algolia REST API.
4652
+ *
4653
+ * @param customDelete - The customDelete object.
4654
+ * @param customDelete.path - Path of the endpoint, anything after \"/1\" must be specified.
4655
+ * @param customDelete.parameters - Query parameters to apply to the current query.
4656
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
4657
+ */
4658
+ customDelete({ path, parameters }, requestOptions) {
4659
+ if (!path) {
4660
+ throw new Error('Parameter `path` is required when calling `customDelete`.');
4661
+ }
4662
+ const requestPath = '/{path}'.replace('{path}', path);
4663
+ const headers = {};
4664
+ const queryParameters = parameters ? parameters : {};
4665
+ const request = {
4666
+ method: 'DELETE',
4667
+ path: requestPath,
4668
+ queryParameters,
4669
+ headers,
4670
+ };
4671
+ return transporter.request(request, requestOptions);
4672
+ },
4673
+ /**
4674
+ * This method allow you to send requests to the Algolia REST API.
4675
+ *
4676
+ * @param customGet - The customGet object.
4677
+ * @param customGet.path - Path of the endpoint, anything after \"/1\" must be specified.
4678
+ * @param customGet.parameters - Query parameters to apply to the current query.
4679
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
4680
+ */
4681
+ customGet({ path, parameters }, requestOptions) {
4682
+ if (!path) {
4683
+ throw new Error('Parameter `path` is required when calling `customGet`.');
4684
+ }
4685
+ const requestPath = '/{path}'.replace('{path}', path);
4686
+ const headers = {};
4687
+ const queryParameters = parameters ? parameters : {};
4688
+ const request = {
4689
+ method: 'GET',
4690
+ path: requestPath,
4691
+ queryParameters,
4692
+ headers,
4693
+ };
4694
+ return transporter.request(request, requestOptions);
4695
+ },
4696
+ /**
4697
+ * This method allow you to send requests to the Algolia REST API.
4698
+ *
4699
+ * @param customPost - The customPost object.
4700
+ * @param customPost.path - Path of the endpoint, anything after \"/1\" must be specified.
4701
+ * @param customPost.parameters - Query parameters to apply to the current query.
4702
+ * @param customPost.body - Parameters to send with the custom request.
4703
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
4704
+ */
4705
+ customPost({ path, parameters, body }, requestOptions) {
4706
+ if (!path) {
4707
+ throw new Error('Parameter `path` is required when calling `customPost`.');
4708
+ }
4709
+ const requestPath = '/{path}'.replace('{path}', path);
4710
+ const headers = {};
4711
+ const queryParameters = parameters ? parameters : {};
4712
+ const request = {
4713
+ method: 'POST',
4714
+ path: requestPath,
4715
+ queryParameters,
4716
+ headers,
4717
+ data: body ? body : {},
4718
+ };
4719
+ return transporter.request(request, requestOptions);
4720
+ },
4721
+ /**
4722
+ * This method allow you to send requests to the Algolia REST API.
4723
+ *
4724
+ * @param customPut - The customPut object.
4725
+ * @param customPut.path - Path of the endpoint, anything after \"/1\" must be specified.
4726
+ * @param customPut.parameters - Query parameters to apply to the current query.
4727
+ * @param customPut.body - Parameters to send with the custom request.
4728
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
4729
+ */
4730
+ customPut({ path, parameters, body }, requestOptions) {
4731
+ if (!path) {
4732
+ throw new Error('Parameter `path` is required when calling `customPut`.');
4733
+ }
4734
+ const requestPath = '/{path}'.replace('{path}', path);
4735
+ const headers = {};
4736
+ const queryParameters = parameters ? parameters : {};
4737
+ const request = {
4738
+ method: 'PUT',
4739
+ path: requestPath,
4740
+ queryParameters,
4741
+ headers,
4742
+ data: body ? body : {},
4743
+ };
4744
+ return transporter.request(request, requestOptions);
4745
+ },
4746
+ /**
4747
+ * Deletes a Recommend rule from a recommendation scenario.
4748
+ *
4749
+ * Required API Key ACLs:
4750
+ * - editSettings.
4751
+ *
4752
+ * @param deleteRecommendRule - The deleteRecommendRule object.
4753
+ * @param deleteRecommendRule.indexName - Name of the index on which to perform the operation.
4754
+ * @param deleteRecommendRule.model - [Recommend model](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).
4755
+ * @param deleteRecommendRule.objectID - Unique record identifier.
4756
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
4757
+ */
4758
+ deleteRecommendRule({ indexName, model, objectID }, requestOptions) {
4759
+ if (!indexName) {
4760
+ throw new Error('Parameter `indexName` is required when calling `deleteRecommendRule`.');
4761
+ }
4762
+ if (!model) {
4763
+ throw new Error('Parameter `model` is required when calling `deleteRecommendRule`.');
4764
+ }
4765
+ if (!objectID) {
4766
+ throw new Error('Parameter `objectID` is required when calling `deleteRecommendRule`.');
4767
+ }
4768
+ const requestPath = '/1/indexes/{indexName}/{model}/recommend/rules/{objectID}'
4769
+ .replace('{indexName}', encodeURIComponent(indexName))
4770
+ .replace('{model}', encodeURIComponent(model))
4771
+ .replace('{objectID}', encodeURIComponent(objectID));
4772
+ const headers = {};
4773
+ const queryParameters = {};
4774
+ const request = {
4775
+ method: 'DELETE',
4776
+ path: requestPath,
4777
+ queryParameters,
4778
+ headers,
4779
+ };
4780
+ return transporter.request(request, requestOptions);
4781
+ },
4782
+ /**
4783
+ * Retrieves a Recommend rule that you previously created in the Algolia dashboard.
4784
+ *
4785
+ * Required API Key ACLs:
4786
+ * - settings.
4787
+ *
4788
+ * @param getRecommendRule - The getRecommendRule object.
4789
+ * @param getRecommendRule.indexName - Name of the index on which to perform the operation.
4790
+ * @param getRecommendRule.model - [Recommend model](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).
4791
+ * @param getRecommendRule.objectID - Unique record identifier.
4792
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
4793
+ */
4794
+ getRecommendRule({ indexName, model, objectID }, requestOptions) {
4795
+ if (!indexName) {
4796
+ throw new Error('Parameter `indexName` is required when calling `getRecommendRule`.');
4797
+ }
4798
+ if (!model) {
4799
+ throw new Error('Parameter `model` is required when calling `getRecommendRule`.');
4800
+ }
4801
+ if (!objectID) {
4802
+ throw new Error('Parameter `objectID` is required when calling `getRecommendRule`.');
4803
+ }
4804
+ const requestPath = '/1/indexes/{indexName}/{model}/recommend/rules/{objectID}'
4805
+ .replace('{indexName}', encodeURIComponent(indexName))
4806
+ .replace('{model}', encodeURIComponent(model))
4807
+ .replace('{objectID}', encodeURIComponent(objectID));
4808
+ const headers = {};
4809
+ const queryParameters = {};
4810
+ const request = {
4811
+ method: 'GET',
4812
+ path: requestPath,
4813
+ queryParameters,
4814
+ headers,
4815
+ };
4816
+ return transporter.request(request, requestOptions);
4817
+ },
4818
+ /**
4819
+ * Checks the status of a given task. Deleting a Recommend rule is asynchronous. When you delete a rule, a task is created on a queue and completed depending on the load on the server. The API response includes a task ID that you can use to check the status.
4820
+ *
4821
+ * Required API Key ACLs:
4822
+ * - editSettings.
4823
+ *
4824
+ * @param getRecommendStatus - The getRecommendStatus object.
4825
+ * @param getRecommendStatus.indexName - Name of the index on which to perform the operation.
4826
+ * @param getRecommendStatus.model - [Recommend model](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).
4827
+ * @param getRecommendStatus.taskID - Unique task identifier.
4828
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
4829
+ */
4830
+ getRecommendStatus({ indexName, model, taskID }, requestOptions) {
4831
+ if (!indexName) {
4832
+ throw new Error('Parameter `indexName` is required when calling `getRecommendStatus`.');
4833
+ }
4834
+ if (!model) {
4835
+ throw new Error('Parameter `model` is required when calling `getRecommendStatus`.');
4836
+ }
4837
+ if (!taskID) {
4838
+ throw new Error('Parameter `taskID` is required when calling `getRecommendStatus`.');
4839
+ }
4840
+ const requestPath = '/1/indexes/{indexName}/{model}/task/{taskID}'
4841
+ .replace('{indexName}', encodeURIComponent(indexName))
4842
+ .replace('{model}', encodeURIComponent(model))
4843
+ .replace('{taskID}', encodeURIComponent(taskID));
4844
+ const headers = {};
4845
+ const queryParameters = {};
4846
+ const request = {
4847
+ method: 'GET',
4848
+ path: requestPath,
4849
+ queryParameters,
4850
+ headers,
4851
+ };
4852
+ return transporter.request(request, requestOptions);
4853
+ },
4854
+ /**
4855
+ * Retrieves recommendations from selected AI models.
4856
+ *
4857
+ * Required API Key ACLs:
4858
+ * - search.
4859
+ *
4860
+ * @param getRecommendationsParams - The getRecommendationsParams object.
4861
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
4862
+ */
4863
+ getRecommendations(getRecommendationsParams, requestOptions) {
4864
+ if (getRecommendationsParams && Array.isArray(getRecommendationsParams)) {
4865
+ const newSignatureRequest = {
4866
+ requests: getRecommendationsParams,
4867
+ };
4868
+ // eslint-disable-next-line no-param-reassign
4869
+ getRecommendationsParams = newSignatureRequest;
4870
+ }
4871
+ if (!getRecommendationsParams) {
4872
+ throw new Error('Parameter `getRecommendationsParams` is required when calling `getRecommendations`.');
4873
+ }
4874
+ if (!getRecommendationsParams.requests) {
4875
+ throw new Error('Parameter `getRecommendationsParams.requests` is required when calling `getRecommendations`.');
4876
+ }
4877
+ const requestPath = '/1/indexes/*/recommendations';
4878
+ const headers = {};
4879
+ const queryParameters = {};
4880
+ const request = {
4881
+ method: 'POST',
4882
+ path: requestPath,
4883
+ queryParameters,
4884
+ headers,
4885
+ data: getRecommendationsParams,
4886
+ useReadTransporter: true,
4887
+ cacheable: true,
4888
+ };
4889
+ return transporter.request(request, requestOptions);
4890
+ },
4891
+ /**
4892
+ * Searches for Recommend rules. Use an empty query to list all rules for this recommendation scenario.
4893
+ *
4894
+ * Required API Key ACLs:
4895
+ * - settings.
4896
+ *
4897
+ * @param searchRecommendRules - The searchRecommendRules object.
4898
+ * @param searchRecommendRules.indexName - Name of the index on which to perform the operation.
4899
+ * @param searchRecommendRules.model - [Recommend model](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).
4900
+ * @param searchRecommendRules.searchRecommendRulesParams - The searchRecommendRulesParams object.
4901
+ * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
4902
+ */
4903
+ searchRecommendRules({ indexName, model, searchRecommendRulesParams, }, requestOptions) {
4904
+ if (!indexName) {
4905
+ throw new Error('Parameter `indexName` is required when calling `searchRecommendRules`.');
4906
+ }
4907
+ if (!model) {
4908
+ throw new Error('Parameter `model` is required when calling `searchRecommendRules`.');
4909
+ }
4910
+ const requestPath = '/1/indexes/{indexName}/{model}/recommend/rules/search'
4911
+ .replace('{indexName}', encodeURIComponent(indexName))
4912
+ .replace('{model}', encodeURIComponent(model));
4913
+ const headers = {};
4914
+ const queryParameters = {};
4915
+ const request = {
4916
+ method: 'POST',
4917
+ path: requestPath,
4918
+ queryParameters,
4919
+ headers,
4920
+ data: searchRecommendRulesParams ? searchRecommendRulesParams : {},
4921
+ useReadTransporter: true,
4922
+ cacheable: true,
4923
+ };
4924
+ return transporter.request(request, requestOptions);
4925
+ },
4926
+ };
4927
+ }
4928
+
4134
4929
  function createXhrRequester() {
4135
4930
  function send(request) {
4136
4931
  return new Promise((resolve) => {
@@ -4184,7 +4979,7 @@ function createXhrRequester() {
4184
4979
  }
4185
4980
 
4186
4981
  // Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
4187
- const apiClientVersion = apiClientVersion$1;
4982
+ const apiClientVersion = apiClientVersion$2;
4188
4983
  // eslint-disable-next-line @typescript-eslint/explicit-function-return-type
4189
4984
  function algoliasearch(appId, apiKey, options) {
4190
4985
  if (!appId || typeof appId !== 'string') {
@@ -4214,6 +5009,13 @@ function algoliasearch(appId, apiKey, options) {
4214
5009
  }),
4215
5010
  ...options,
4216
5011
  };
5012
+ function initRecommend(initOptions = {}) {
5013
+ return createRecommendClient({
5014
+ ...commonOptions,
5015
+ ...initOptions.options,
5016
+ ...initOptions,
5017
+ });
5018
+ }
4217
5019
  function initAnalytics(initOptions = {}) {
4218
5020
  if (initOptions.region &&
4219
5021
  (typeof initOptions.region !== 'string' ||
@@ -4259,9 +5061,10 @@ function algoliasearch(appId, apiKey, options) {
4259
5061
  get _ua() {
4260
5062
  return this.transporter.algoliaAgent.value;
4261
5063
  },
5064
+ initAbtesting,
4262
5065
  initAnalytics,
4263
5066
  initPersonalization,
4264
- initAbtesting,
5067
+ initRecommend,
4265
5068
  };
4266
5069
  }
4267
5070