@algolia/client-search 4.9.1 → 4.10.2

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.
@@ -1231,6 +1231,7 @@ const ApiKeyACLEnum = {
1231
1231
  EditSettings: 'editSettings',
1232
1232
  ListIndexes: 'listIndexes',
1233
1233
  Logs: 'logs',
1234
+ Personalization: 'personalization',
1234
1235
  Recommendation: 'recommendation',
1235
1236
  Search: 'search',
1236
1237
  SeeUnretrievableAttributes: 'seeUnretrievableAttributes',
@@ -52,7 +52,7 @@ export declare type AddApiKeyResponse = {
52
52
 
53
53
  export declare const ApiKeyACLEnum: Readonly<Record<string, ApiKeyACLType>>;
54
54
 
55
- export declare type ApiKeyACLType = 'addObject' | 'analytics' | 'browse' | 'deleteIndex' | 'deleteObject' | 'editSettings' | 'listIndexes' | 'logs' | 'recommendation' | 'search' | 'seeUnretrievableAttributes' | 'settings' | 'usage';
55
+ export declare type ApiKeyACLType = 'addObject' | 'analytics' | 'browse' | 'deleteIndex' | 'deleteObject' | 'editSettings' | 'listIndexes' | 'logs' | 'personalization' | 'recommendation' | 'search' | 'seeUnretrievableAttributes' | 'settings' | 'usage';
56
56
 
57
57
  export declare const assignUserID: (base: SearchClient) => (userID: string, clusterName: string, requestOptions?: RequestOptions | undefined) => Readonly<Promise<AssignUserIDResponse>>;
58
58
 
@@ -282,7 +282,12 @@ export declare type ConsequenceParams = {
282
282
  * Same syntax as automaticFacetFilters, but the engine treats the filters as optional.
283
283
  * Behaves like optionalFilters.
284
284
  */
285
- readonly automaticOptionalFacetFilters?: readonly AutomaticFacetFilter[];
285
+ readonly automaticOptionalFacetFilters?: readonly AutomaticFacetFilter[] | readonly string[];
286
+ /**
287
+ * Content defining how the search interface should be rendered.
288
+ * A default value for this can be set via settings
289
+ */
290
+ readonly renderingContent?: Settings['renderingContent'];
286
291
  };
287
292
 
288
293
  export declare type ConsequencePromote = {
@@ -578,13 +583,13 @@ export declare const getApiKey: (base: SearchClient) => (apiKey: string, request
578
583
 
579
584
  export declare type GetApiKeyResponse = {
580
585
  /**
581
- * A Unix timestamp used to define the expiration date of the API key.
586
+ * The api key value
582
587
  */
583
588
  value: string;
584
589
  /**
585
- * Date of creation.
590
+ * Date of creation (Unix timestamp).
586
591
  */
587
- createdAt: string;
592
+ createdAt: number;
588
593
  /**
589
594
  * List of permissions the key contains.
590
595
  */
@@ -1850,6 +1855,7 @@ export declare type SearchResponse<TObject = {}> = {
1850
1855
  * The relevancy threshold applied to search in a virtual index.
1851
1856
  */
1852
1857
  appliedRelevancyStrictness?: number;
1858
+ renderingContent?: Settings['renderingContent'];
1853
1859
  };
1854
1860
 
1855
1861
  export declare const searchRules: (base: SearchIndex) => (query: string, requestOptions?: (RequestOptions & SearchRulesOptions) | undefined) => Readonly<Promise<SearchResponse<Rule>>>;
@@ -2236,6 +2242,44 @@ export declare type Settings = {
2236
2242
  * less relevant results.
2237
2243
  */
2238
2244
  readonly relevancyStrictness?: number;
2245
+ /**
2246
+ * Content defining how the search interface should be rendered.
2247
+ * This is set via the settings for a default value and can be overridden via rules
2248
+ */
2249
+ readonly renderingContent?: {
2250
+ /**
2251
+ * defining how facets should be ordered
2252
+ */
2253
+ readonly facetOrdering?: {
2254
+ /**
2255
+ * the ordering of facets (widgets)
2256
+ */
2257
+ readonly facet?: {
2258
+ /**
2259
+ * pinned order of facet lists
2260
+ */
2261
+ readonly order?: readonly string[];
2262
+ };
2263
+ /**
2264
+ * the ordering of facet values, within an individual list
2265
+ */
2266
+ readonly values?: {
2267
+ readonly [facet: string]: {
2268
+ /**
2269
+ * pinned order of facet values
2270
+ */
2271
+ readonly order?: readonly string[];
2272
+ /**
2273
+ * How to display the remaining items.
2274
+ * - facet count (descending)
2275
+ * - alphabetical (ascending)
2276
+ * - hidden (show only pinned values)
2277
+ */
2278
+ readonly sortRemainingBy?: 'count' | 'alpha' | 'hidden';
2279
+ };
2280
+ };
2281
+ };
2282
+ };
2239
2283
  };
2240
2284
 
2241
2285
  declare type SharedMultipleQueriesQuery = {
@@ -2325,11 +2369,11 @@ export declare type TaskStatusResponse = {
2325
2369
 
2326
2370
  export declare type TimeRange = {
2327
2371
  /**
2328
- * DateTime with UTC offset for Serialization/Deserialization in unix timespam.
2372
+ * DateTime with UTC offset for Serialization/Deserialization in unix timespan.
2329
2373
  */
2330
2374
  readonly from: number;
2331
2375
  /**
2332
- * DateTime with UTC offset for Serialization/Deserialization in unix timespam.
2376
+ * DateTime with UTC offset for Serialization/Deserialization in unix timespan.
2333
2377
  */
2334
2378
  readonly until: number;
2335
2379
  };
@@ -2337,6 +2381,10 @@ export declare type TimeRange = {
2337
2381
  export declare const updateApiKey: (base: SearchClient) => (apiKey: string, requestOptions?: (UpdateApiKeyOptions & Pick<RequestOptions, string | number>) | undefined) => Readonly<WaitablePromise<UpdateApiKeyResponse>>;
2338
2382
 
2339
2383
  export declare type UpdateApiKeyOptions = {
2384
+ /**
2385
+ * List of permissions the key contains.
2386
+ */
2387
+ readonly acl?: readonly ApiKeyACLType[];
2340
2388
  /**
2341
2389
  * A Unix timestamp used to define the expiration date of the API key.
2342
2390
  */
@@ -1227,6 +1227,7 @@ const ApiKeyACLEnum = {
1227
1227
  EditSettings: 'editSettings',
1228
1228
  ListIndexes: 'listIndexes',
1229
1229
  Logs: 'logs',
1230
+ Personalization: 'personalization',
1230
1231
  Recommendation: 'recommendation',
1231
1232
  Search: 'search',
1232
1233
  SeeUnretrievableAttributes: 'seeUnretrievableAttributes',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@algolia/client-search",
3
- "version": "4.9.1",
3
+ "version": "4.10.2",
4
4
  "private": false,
5
5
  "repository": {
6
6
  "type": "git",
@@ -16,8 +16,8 @@
16
16
  "dist"
17
17
  ],
18
18
  "dependencies": {
19
- "@algolia/client-common": "4.9.1",
20
- "@algolia/requester-common": "4.9.1",
21
- "@algolia/transporter": "4.9.1"
19
+ "@algolia/client-common": "4.10.2",
20
+ "@algolia/requester-common": "4.10.2",
21
+ "@algolia/transporter": "4.10.2"
22
22
  }
23
23
  }