@algolia/recommend 5.55.1 → 5.56.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -4
- package/dist/browser.d.ts +146 -23
- package/dist/builds/browser.js +282 -1
- package/dist/builds/browser.js.map +1 -1
- package/dist/builds/browser.min.js +5 -5
- package/dist/builds/browser.min.js.map +1 -1
- package/dist/builds/browser.umd.js +6 -6
- package/dist/builds/fetch.js +282 -1
- package/dist/builds/fetch.js.map +1 -1
- package/dist/builds/node.cjs +282 -1
- package/dist/builds/node.cjs.map +1 -1
- package/dist/builds/node.js +282 -1
- package/dist/builds/node.js.map +1 -1
- package/dist/builds/worker.js +282 -1
- package/dist/builds/worker.js.map +1 -1
- package/dist/fetch.d.ts +146 -23
- package/dist/node.d.cts +146 -23
- package/dist/node.d.ts +146 -23
- package/dist/src/recommendClient.cjs +282 -1
- package/dist/src/recommendClient.cjs.map +1 -1
- package/dist/src/recommendClient.js +282 -1
- package/dist/src/recommendClient.js.map +1 -1
- package/dist/worker.d.ts +146 -23
- package/package.json +9 -9
package/README.md
CHANGED
|
@@ -40,11 +40,11 @@ All of our clients comes with type definition, and are available for both browse
|
|
|
40
40
|
### With a package manager
|
|
41
41
|
|
|
42
42
|
```bash
|
|
43
|
-
yarn add @algolia/recommend@5.
|
|
43
|
+
yarn add @algolia/recommend@5.56.0
|
|
44
44
|
# or
|
|
45
|
-
npm install @algolia/recommend@5.
|
|
45
|
+
npm install @algolia/recommend@5.56.0
|
|
46
46
|
# or
|
|
47
|
-
pnpm add @algolia/recommend@5.
|
|
47
|
+
pnpm add @algolia/recommend@5.56.0
|
|
48
48
|
```
|
|
49
49
|
|
|
50
50
|
### Without a package manager
|
|
@@ -52,7 +52,7 @@ pnpm add @algolia/recommend@5.55.1
|
|
|
52
52
|
Add the following JavaScript snippet to the <head> of your website:
|
|
53
53
|
|
|
54
54
|
```html
|
|
55
|
-
<script src="https://cdn.jsdelivr.net/npm/@algolia/recommend@5.
|
|
55
|
+
<script src="https://cdn.jsdelivr.net/npm/@algolia/recommend@5.56.0/dist/builds/browser.umd.js"></script>
|
|
56
56
|
```
|
|
57
57
|
|
|
58
58
|
### Usage
|
package/dist/browser.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _algolia_client_common from '@algolia/client-common';
|
|
2
|
-
import { CreateClientOptions, RequestOptions, ClientOptions } from '@algolia/client-common';
|
|
2
|
+
import { CreateClientOptions, RequestOptions, AlgoliaHttpResponse, ClientOptions } from '@algolia/client-common';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Response, taskID, and deletion timestamp.
|
|
@@ -53,11 +53,6 @@ type AroundRadiusAll = 'all';
|
|
|
53
53
|
*/
|
|
54
54
|
type AroundRadius = number | AroundRadiusAll;
|
|
55
55
|
|
|
56
|
-
/**
|
|
57
|
-
* Filter the search by facet values, so that only records with the same facet values are retrieved. **Prefer using the `filters` parameter, which supports all filter types and combinations with boolean operators.** - `[filter1, filter2]` is interpreted as `filter1 AND filter2`. - `[[filter1, filter2], filter3]` is interpreted as `filter1 OR filter2 AND filter3`. - `facet:-value` is interpreted as `NOT facet:value`. While it\'s best to avoid attributes that start with a `-`, you can still filter them by escaping with a backslash: `facet:\\-value`.
|
|
58
|
-
*/
|
|
59
|
-
type FacetFilters = Array<FacetFilters> | string;
|
|
60
|
-
|
|
61
56
|
type InsideBoundingBox = string | Array<Array<number>>;
|
|
62
57
|
|
|
63
58
|
/**
|
|
@@ -89,7 +84,6 @@ type BaseRecommendSearchParams = {
|
|
|
89
84
|
* Filter expression to only include items that match the filter criteria in the response. You can use these filter expressions: - **Numeric filters.** `<facet> <op> <number>`, where `<op>` is one of `<`, `<=`, `=`, `!=`, `>`, `>=`. - **Ranges.** `<facet>:<lower> TO <upper>`, where `<lower>` and `<upper>` are the lower and upper limits of the range (inclusive). - **Facet filters.** `<facet>:<value>`, where `<facet>` is a facet attribute (case-sensitive) and `<value>` a facet value. - **Tag filters.** `_tags:<value>` or just `<value>` (case-sensitive). - **Boolean filters.** `<facet>: true | false`. You can combine filters with `AND`, `OR`, and `NOT` operators with the following restrictions: - You can only combine filters of the same type with `OR`. **Not supported:** `facet:value OR num > 3`. - You can\'t use `NOT` with combinations of filters. **Not supported:** `NOT(facet:value OR facet:value)` - You can\'t combine conjunctions (`AND`) with `OR`. **Not supported:** `facet:value OR (facet:value AND facet:value)` Use quotes if the facet attribute name or facet value contains spaces, keywords (`OR`, `AND`, `NOT`), or quotes. If a facet attribute is an array, the filter matches if it matches at least one element of the array. For more information, see [Filters](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering).
|
|
90
85
|
*/
|
|
91
86
|
filters?: string | undefined;
|
|
92
|
-
facetFilters?: FacetFilters | undefined;
|
|
93
87
|
optionalFilters?: OptionalFilters | undefined;
|
|
94
88
|
numericFilters?: NumericFilters | undefined;
|
|
95
89
|
tagFilters?: TagFilters | undefined;
|
|
@@ -168,10 +162,6 @@ type BaseRecommendSearchParams = {
|
|
|
168
162
|
* Whether to include this search when calculating processing-time percentiles.
|
|
169
163
|
*/
|
|
170
164
|
percentileComputation?: boolean | undefined;
|
|
171
|
-
/**
|
|
172
|
-
* Whether to enable A/B testing for this search.
|
|
173
|
-
*/
|
|
174
|
-
enableABTest?: boolean | undefined;
|
|
175
165
|
};
|
|
176
166
|
|
|
177
167
|
type BaseIndexSettings = {
|
|
@@ -418,10 +408,6 @@ type BaseRecommendIndexSettings = {
|
|
|
418
408
|
* Attributes to include in the API response To reduce the size of your response, you can retrieve only some of the attributes. Attribute names are case-sensitive - `*` retrieves all attributes, except attributes included in the `customRanking` and `unretrievableAttributes` settings. - To retrieve all attributes except a specific one, prefix the attribute with a dash and combine it with the `*`: `[\"*\", \"-ATTRIBUTE\"]`. - The `objectID` attribute is always included.
|
|
419
409
|
*/
|
|
420
410
|
attributesToRetrieve?: Array<string> | undefined;
|
|
421
|
-
/**
|
|
422
|
-
* Determines the order in which Algolia returns your results. By default, each entry corresponds to a [ranking criteria](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria). The tie-breaking algorithm sequentially applies each criterion in the order they\'re specified. If you configure a replica index for [sorting by an attribute](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/how-to/sort-by-attribute), you put the sorting attribute at the top of the list. **Modifiers** - `asc(\"ATTRIBUTE\")`. Sort the index by the values of an attribute, in ascending order. - `desc(\"ATTRIBUTE\")`. Sort the index by the values of an attribute, in descending order. Before you modify the default setting, test your changes in the dashboard, and by [A/B testing](https://www.algolia.com/doc/guides/ab-testing/what-is-ab-testing).
|
|
423
|
-
*/
|
|
424
|
-
ranking?: Array<string> | undefined;
|
|
425
411
|
/**
|
|
426
412
|
* Relevancy threshold below which less relevant results aren\'t included in the results You can only set `relevancyStrictness` on [virtual replica indices](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/in-depth/replicas/#what-are-virtual-replicas). Use this setting to strike a balance between the relevance and number of returned results.
|
|
427
413
|
*/
|
|
@@ -477,10 +463,6 @@ type BaseRecommendIndexSettings = {
|
|
|
477
463
|
* Whether to split compound words in the query into their building blocks For more information, see [Word segmentation](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#splitting-compound-words). Word segmentation is supported for these languages: German, Dutch, Finnish, Swedish, and Norwegian. Decompounding doesn\'t work for words with [non-spacing mark Unicode characters](https://www.charactercodes.net/category/non-spacing_mark). For example, `Gartenstühle` won\'t be decompounded if the `ü` consists of `u` (U+0075) and `◌̈` (U+0308).
|
|
478
464
|
*/
|
|
479
465
|
decompoundQuery?: boolean | undefined;
|
|
480
|
-
/**
|
|
481
|
-
* Whether to enable rules.
|
|
482
|
-
*/
|
|
483
|
-
enableRules?: boolean | undefined;
|
|
484
466
|
/**
|
|
485
467
|
* Whether to enable Personalization.
|
|
486
468
|
*/
|
|
@@ -553,7 +535,7 @@ type SearchParamsQuery = {
|
|
|
553
535
|
/**
|
|
554
536
|
* Search parameters for filtering the recommendations.
|
|
555
537
|
*/
|
|
556
|
-
type RecommendSearchParams = BaseRecommendSearchParams & SearchParamsQuery & RecommendIndexSettings
|
|
538
|
+
type RecommendSearchParams = BaseRecommendSearchParams & SearchParamsQuery & RecommendIndexSettings & Record<string, unknown>;
|
|
557
539
|
|
|
558
540
|
type BaseRecommendRequest = {
|
|
559
541
|
/**
|
|
@@ -571,7 +553,10 @@ type BaseRecommendRequest = {
|
|
|
571
553
|
queryParameters?: RecommendSearchParams | undefined;
|
|
572
554
|
};
|
|
573
555
|
|
|
574
|
-
|
|
556
|
+
/**
|
|
557
|
+
* Search parameters to use for a fallback request if there aren\'t enough recommendations.
|
|
558
|
+
*/
|
|
559
|
+
type FallbackParams = BaseRecommendSearchParams & SearchParamsQuery & RecommendIndexSettings & Record<string, unknown>;
|
|
575
560
|
|
|
576
561
|
/**
|
|
577
562
|
* Frequently bought together model. This model recommends items that have been purchased within 1 day with the item with the ID `objectID`.
|
|
@@ -1423,9 +1408,9 @@ type SearchRecommendRulesProps = {
|
|
|
1423
1408
|
searchRecommendRulesParams?: SearchRecommendRulesParams | undefined;
|
|
1424
1409
|
};
|
|
1425
1410
|
|
|
1426
|
-
declare const apiClientVersion = "5.
|
|
1411
|
+
declare const apiClientVersion = "5.56.0";
|
|
1427
1412
|
declare function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, ...options }: CreateClientOptions): {
|
|
1428
|
-
transporter: _algolia_client_common.
|
|
1413
|
+
transporter: _algolia_client_common.TransporterWithHttpInfo;
|
|
1429
1414
|
/**
|
|
1430
1415
|
* The `appId` currently in use.
|
|
1431
1416
|
*/
|
|
@@ -1470,6 +1455,21 @@ declare function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOptio
|
|
|
1470
1455
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1471
1456
|
*/
|
|
1472
1457
|
batchRecommendRules({ indexName, model, recommendRule }: BatchRecommendRulesProps, requestOptions?: RequestOptions): Promise<RecommendUpdatedAtResponse>;
|
|
1458
|
+
/**
|
|
1459
|
+
* Create or update a batch of Recommend Rules Each Recommend Rule is created or updated, depending on whether a Recommend Rule with the same `objectID` already exists. You may also specify `true` for `clearExistingRules`, in which case the batch will atomically replace all the existing Recommend Rules. Recommend Rules are similar to Search Rules, except that the conditions and consequences apply to a [source item](/doc/guides/algolia-recommend/overview/#recommend-models) instead of a query. The main differences are the following: - Conditions `pattern` and `anchoring` are unavailable. - Condition `filters` triggers if the source item matches the specified filters. - Condition `filters` accepts numeric filters. - Consequence `params` only covers filtering parameters. - Consequence `automaticFacetFilters` doesn\'t require a facet value placeholder (it tries to match the data source item\'s attributes instead).
|
|
1460
|
+
*
|
|
1461
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1462
|
+
*
|
|
1463
|
+
* Required API Key ACLs:
|
|
1464
|
+
* - editSettings
|
|
1465
|
+
* @param batchRecommendRules - The batchRecommendRules object.
|
|
1466
|
+
* @param batchRecommendRules.indexName - Name of the index on which to perform the operation.
|
|
1467
|
+
* @param batchRecommendRules.model - [Recommend model](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).
|
|
1468
|
+
* @param batchRecommendRules.recommendRule - The recommendRule object.
|
|
1469
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1470
|
+
* @see batchRecommendRules for the plain version.
|
|
1471
|
+
*/
|
|
1472
|
+
batchRecommendRulesWithHTTPInfo({ indexName, model, recommendRule }: BatchRecommendRulesProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<RecommendUpdatedAtResponse>>;
|
|
1473
1473
|
/**
|
|
1474
1474
|
* This method lets you send requests to the Algolia REST API.
|
|
1475
1475
|
* @param customDelete - The customDelete object.
|
|
@@ -1478,6 +1478,17 @@ declare function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOptio
|
|
|
1478
1478
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1479
1479
|
*/
|
|
1480
1480
|
customDelete({ path, parameters }: CustomDeleteProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>>;
|
|
1481
|
+
/**
|
|
1482
|
+
* This method lets you send requests to the Algolia REST API.
|
|
1483
|
+
*
|
|
1484
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1485
|
+
* @param customDelete - The customDelete object.
|
|
1486
|
+
* @param customDelete.path - Path of the endpoint, for example `1/newFeature`.
|
|
1487
|
+
* @param customDelete.parameters - Query parameters to apply to the current query.
|
|
1488
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1489
|
+
* @see customDelete for the plain version.
|
|
1490
|
+
*/
|
|
1491
|
+
customDeleteWithHTTPInfo({ path, parameters }: CustomDeleteProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<Record<string, unknown>>>;
|
|
1481
1492
|
/**
|
|
1482
1493
|
* This method lets you send requests to the Algolia REST API.
|
|
1483
1494
|
* @param customGet - The customGet object.
|
|
@@ -1486,6 +1497,17 @@ declare function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOptio
|
|
|
1486
1497
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1487
1498
|
*/
|
|
1488
1499
|
customGet({ path, parameters }: CustomGetProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>>;
|
|
1500
|
+
/**
|
|
1501
|
+
* This method lets you send requests to the Algolia REST API.
|
|
1502
|
+
*
|
|
1503
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1504
|
+
* @param customGet - The customGet object.
|
|
1505
|
+
* @param customGet.path - Path of the endpoint, for example `1/newFeature`.
|
|
1506
|
+
* @param customGet.parameters - Query parameters to apply to the current query.
|
|
1507
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1508
|
+
* @see customGet for the plain version.
|
|
1509
|
+
*/
|
|
1510
|
+
customGetWithHTTPInfo({ path, parameters }: CustomGetProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<Record<string, unknown>>>;
|
|
1489
1511
|
/**
|
|
1490
1512
|
* This method lets you send requests to the Algolia REST API.
|
|
1491
1513
|
* @param customPost - The customPost object.
|
|
@@ -1495,6 +1517,18 @@ declare function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOptio
|
|
|
1495
1517
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1496
1518
|
*/
|
|
1497
1519
|
customPost({ path, parameters, body }: CustomPostProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>>;
|
|
1520
|
+
/**
|
|
1521
|
+
* This method lets you send requests to the Algolia REST API.
|
|
1522
|
+
*
|
|
1523
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1524
|
+
* @param customPost - The customPost object.
|
|
1525
|
+
* @param customPost.path - Path of the endpoint, for example `1/newFeature`.
|
|
1526
|
+
* @param customPost.parameters - Query parameters to apply to the current query.
|
|
1527
|
+
* @param customPost.body - Parameters to send with the custom request.
|
|
1528
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1529
|
+
* @see customPost for the plain version.
|
|
1530
|
+
*/
|
|
1531
|
+
customPostWithHTTPInfo({ path, parameters, body }: CustomPostProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<Record<string, unknown>>>;
|
|
1498
1532
|
/**
|
|
1499
1533
|
* This method lets you send requests to the Algolia REST API.
|
|
1500
1534
|
* @param customPut - The customPut object.
|
|
@@ -1504,6 +1538,18 @@ declare function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOptio
|
|
|
1504
1538
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1505
1539
|
*/
|
|
1506
1540
|
customPut({ path, parameters, body }: CustomPutProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>>;
|
|
1541
|
+
/**
|
|
1542
|
+
* This method lets you send requests to the Algolia REST API.
|
|
1543
|
+
*
|
|
1544
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1545
|
+
* @param customPut - The customPut object.
|
|
1546
|
+
* @param customPut.path - Path of the endpoint, for example `1/newFeature`.
|
|
1547
|
+
* @param customPut.parameters - Query parameters to apply to the current query.
|
|
1548
|
+
* @param customPut.body - Parameters to send with the custom request.
|
|
1549
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1550
|
+
* @see customPut for the plain version.
|
|
1551
|
+
*/
|
|
1552
|
+
customPutWithHTTPInfo({ path, parameters, body }: CustomPutProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<Record<string, unknown>>>;
|
|
1507
1553
|
/**
|
|
1508
1554
|
* Deletes a Recommend rule from a recommendation scenario.
|
|
1509
1555
|
*
|
|
@@ -1516,6 +1562,21 @@ declare function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOptio
|
|
|
1516
1562
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1517
1563
|
*/
|
|
1518
1564
|
deleteRecommendRule({ indexName, model, objectID }: DeleteRecommendRuleProps, requestOptions?: RequestOptions): Promise<DeletedAtResponse>;
|
|
1565
|
+
/**
|
|
1566
|
+
* Deletes a Recommend rule from a recommendation scenario.
|
|
1567
|
+
*
|
|
1568
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1569
|
+
*
|
|
1570
|
+
* Required API Key ACLs:
|
|
1571
|
+
* - editSettings
|
|
1572
|
+
* @param deleteRecommendRule - The deleteRecommendRule object.
|
|
1573
|
+
* @param deleteRecommendRule.indexName - Name of the index on which to perform the operation.
|
|
1574
|
+
* @param deleteRecommendRule.model - [Recommend model](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).
|
|
1575
|
+
* @param deleteRecommendRule.objectID - Unique record identifier.
|
|
1576
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1577
|
+
* @see deleteRecommendRule for the plain version.
|
|
1578
|
+
*/
|
|
1579
|
+
deleteRecommendRuleWithHTTPInfo({ indexName, model, objectID }: DeleteRecommendRuleProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<DeletedAtResponse>>;
|
|
1519
1580
|
/**
|
|
1520
1581
|
* Retrieves a Recommend rule that you previously created in the Algolia dashboard.
|
|
1521
1582
|
*
|
|
@@ -1528,6 +1589,21 @@ declare function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOptio
|
|
|
1528
1589
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1529
1590
|
*/
|
|
1530
1591
|
getRecommendRule({ indexName, model, objectID }: GetRecommendRuleProps, requestOptions?: RequestOptions): Promise<RecommendRule>;
|
|
1592
|
+
/**
|
|
1593
|
+
* Retrieves a Recommend rule that you previously created in the Algolia dashboard.
|
|
1594
|
+
*
|
|
1595
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1596
|
+
*
|
|
1597
|
+
* Required API Key ACLs:
|
|
1598
|
+
* - settings
|
|
1599
|
+
* @param getRecommendRule - The getRecommendRule object.
|
|
1600
|
+
* @param getRecommendRule.indexName - Name of the index on which to perform the operation.
|
|
1601
|
+
* @param getRecommendRule.model - [Recommend model](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).
|
|
1602
|
+
* @param getRecommendRule.objectID - Unique record identifier.
|
|
1603
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1604
|
+
* @see getRecommendRule for the plain version.
|
|
1605
|
+
*/
|
|
1606
|
+
getRecommendRuleWithHTTPInfo({ indexName, model, objectID }: GetRecommendRuleProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<RecommendRule>>;
|
|
1531
1607
|
/**
|
|
1532
1608
|
* 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.
|
|
1533
1609
|
*
|
|
@@ -1540,6 +1616,21 @@ declare function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOptio
|
|
|
1540
1616
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1541
1617
|
*/
|
|
1542
1618
|
getRecommendStatus({ indexName, model, taskID }: GetRecommendStatusProps, requestOptions?: RequestOptions): Promise<GetRecommendTaskResponse>;
|
|
1619
|
+
/**
|
|
1620
|
+
* 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.
|
|
1621
|
+
*
|
|
1622
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1623
|
+
*
|
|
1624
|
+
* Required API Key ACLs:
|
|
1625
|
+
* - editSettings
|
|
1626
|
+
* @param getRecommendStatus - The getRecommendStatus object.
|
|
1627
|
+
* @param getRecommendStatus.indexName - Name of the index on which to perform the operation.
|
|
1628
|
+
* @param getRecommendStatus.model - [Recommend model](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).
|
|
1629
|
+
* @param getRecommendStatus.taskID - Unique task identifier.
|
|
1630
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1631
|
+
* @see getRecommendStatus for the plain version.
|
|
1632
|
+
*/
|
|
1633
|
+
getRecommendStatusWithHTTPInfo({ indexName, model, taskID }: GetRecommendStatusProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<GetRecommendTaskResponse>>;
|
|
1543
1634
|
/**
|
|
1544
1635
|
* Retrieves recommendations from selected AI models.
|
|
1545
1636
|
*
|
|
@@ -1549,6 +1640,18 @@ declare function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOptio
|
|
|
1549
1640
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1550
1641
|
*/
|
|
1551
1642
|
getRecommendations(getRecommendationsParams: GetRecommendationsParams | LegacyGetRecommendationsParams, requestOptions?: RequestOptions): Promise<GetRecommendationsResponse>;
|
|
1643
|
+
/**
|
|
1644
|
+
* Retrieves recommendations from selected AI models.
|
|
1645
|
+
*
|
|
1646
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1647
|
+
*
|
|
1648
|
+
* Required API Key ACLs:
|
|
1649
|
+
* - search
|
|
1650
|
+
* @param getRecommendationsParams - The getRecommendationsParams object.
|
|
1651
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1652
|
+
* @see getRecommendations for the plain version.
|
|
1653
|
+
*/
|
|
1654
|
+
getRecommendationsWithHTTPInfo(getRecommendationsParams: GetRecommendationsParams | LegacyGetRecommendationsParams, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<GetRecommendationsResponse>>;
|
|
1552
1655
|
/**
|
|
1553
1656
|
* Searches for Recommend rules. Use an empty query to list all rules for this recommendation scenario.
|
|
1554
1657
|
*
|
|
@@ -1561,6 +1664,21 @@ declare function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOptio
|
|
|
1561
1664
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1562
1665
|
*/
|
|
1563
1666
|
searchRecommendRules({ indexName, model, searchRecommendRulesParams }: SearchRecommendRulesProps, requestOptions?: RequestOptions): Promise<SearchRecommendRulesResponse>;
|
|
1667
|
+
/**
|
|
1668
|
+
* Searches for Recommend rules. Use an empty query to list all rules for this recommendation scenario.
|
|
1669
|
+
*
|
|
1670
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1671
|
+
*
|
|
1672
|
+
* Required API Key ACLs:
|
|
1673
|
+
* - settings
|
|
1674
|
+
* @param searchRecommendRules - The searchRecommendRules object.
|
|
1675
|
+
* @param searchRecommendRules.indexName - Name of the index on which to perform the operation.
|
|
1676
|
+
* @param searchRecommendRules.model - [Recommend model](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).
|
|
1677
|
+
* @param searchRecommendRules.searchRecommendRulesParams - The searchRecommendRulesParams object.
|
|
1678
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1679
|
+
* @see searchRecommendRules for the plain version.
|
|
1680
|
+
*/
|
|
1681
|
+
searchRecommendRulesWithHTTPInfo({ indexName, model, searchRecommendRulesParams }: SearchRecommendRulesProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<SearchRecommendRulesResponse>>;
|
|
1564
1682
|
};
|
|
1565
1683
|
|
|
1566
1684
|
/**
|
|
@@ -1570,6 +1688,11 @@ type ErrorBase = Record<string, any> & {
|
|
|
1570
1688
|
message?: string | undefined;
|
|
1571
1689
|
};
|
|
1572
1690
|
|
|
1691
|
+
/**
|
|
1692
|
+
* Filter the search by facet values, so that only records with the same facet values are retrieved. **Prefer using the `filters` parameter, which supports all filter types and combinations with boolean operators.** - `[filter1, filter2]` is interpreted as `filter1 AND filter2`. - `[[filter1, filter2], filter3]` is interpreted as `filter1 OR filter2 AND filter3`. - `facet:-value` is interpreted as `NOT facet:value`. While it\'s best to avoid attributes that start with a `-`, you can still filter them by escaping with a backslash: `facet:\\-value`.
|
|
1693
|
+
*/
|
|
1694
|
+
type FacetFilters = Array<FacetFilters> | string;
|
|
1695
|
+
|
|
1573
1696
|
declare function recommendClient(appId: string, apiKey: string, options?: ClientOptions | undefined): RecommendClient;
|
|
1574
1697
|
type RecommendClient = ReturnType<typeof createRecommendClient>;
|
|
1575
1698
|
|