@algolia/recommend 5.0.0-alpha.91 → 5.0.0-alpha.98
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/dist/model/baseRecommendedForYouQuery.d.ts +8 -0
- package/dist/model/baseRecommendedForYouQuery.d.ts.map +1 -0
- package/dist/model/baseRecommendedForYouQueryParameters.d.ts +7 -0
- package/dist/model/baseRecommendedForYouQueryParameters.d.ts.map +1 -0
- package/dist/model/clientMethodProps.d.ts +42 -42
- package/dist/model/clientMethodProps.d.ts.map +1 -1
- package/dist/model/getRecommendationsResponse.d.ts +2 -2
- package/dist/model/getRecommendationsResponse.d.ts.map +1 -1
- package/dist/model/highlightResult.d.ts +1 -1
- package/dist/model/highlightResult.d.ts.map +1 -1
- package/dist/model/index.d.ts +9 -2
- package/dist/model/index.d.ts.map +1 -1
- package/dist/model/recommendationsHit.d.ts +4 -0
- package/dist/model/recommendationsHit.d.ts.map +1 -0
- package/dist/model/recommendationsHits.d.ts +13 -0
- package/dist/model/recommendationsHits.d.ts.map +1 -0
- package/dist/model/recommendationsRequest.d.ts +2 -1
- package/dist/model/recommendationsRequest.d.ts.map +1 -1
- package/dist/model/recommendationsResults.d.ts +4 -0
- package/dist/model/recommendationsResults.d.ts.map +1 -0
- package/dist/model/recommendedForYouModel.d.ts +5 -0
- package/dist/model/recommendedForYouModel.d.ts.map +1 -0
- package/dist/model/recommendedForYouQuery.d.ts +4 -0
- package/dist/model/recommendedForYouQuery.d.ts.map +1 -0
- package/dist/model/recommendedForYouQueryParameters.d.ts +4 -0
- package/dist/model/recommendedForYouQueryParameters.d.ts.map +1 -0
- package/dist/model/searchRecommendRulesParams.d.ts +0 -4
- package/dist/model/searchRecommendRulesParams.d.ts.map +1 -1
- package/dist/model/searchRecommendRulesResponse.d.ts +3 -3
- package/dist/model/snippetResult.d.ts +1 -1
- package/dist/model/snippetResult.d.ts.map +1 -1
- package/dist/model/trendingFacetHit.d.ts +18 -0
- package/dist/model/trendingFacetHit.d.ts.map +1 -0
- package/dist/recommend.cjs +82 -82
- package/dist/recommend.esm.browser.js +125 -101
- package/dist/recommend.esm.node.js +82 -82
- package/dist/recommend.umd.js +2 -2
- package/dist/src/recommendClient.d.ts +38 -38
- package/dist/src/recommendClient.d.ts.map +1 -1
- package/model/baseRecommendedForYouQuery.ts +12 -0
- package/model/baseRecommendedForYouQueryParameters.ts +8 -0
- package/model/clientMethodProps.ts +42 -42
- package/model/getRecommendationsResponse.ts +2 -2
- package/model/highlightResult.ts +3 -1
- package/model/index.ts +9 -2
- package/model/recommendationsHit.ts +6 -0
- package/model/{recommendHits.ts → recommendationsHits.ts} +3 -3
- package/model/recommendationsRequest.ts +2 -0
- package/model/{recommendationsResponse.ts → recommendationsResults.ts} +2 -2
- package/model/recommendedForYouModel.ts +6 -0
- package/model/recommendedForYouQuery.ts +7 -0
- package/model/recommendedForYouQueryParameters.ts +7 -0
- package/model/searchRecommendRulesParams.ts +0 -5
- package/model/searchRecommendRulesResponse.ts +3 -3
- package/model/snippetResult.ts +3 -1
- package/model/trendingFacetHit.ts +21 -0
- package/package.json +7 -7
- package/dist/model/recommendHits.d.ts +0 -13
- package/dist/model/recommendHits.d.ts.map +0 -1
- package/dist/model/recommendationsResponse.d.ts +0 -4
- package/dist/model/recommendationsResponse.d.ts.map +0 -1
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { RecommendedForYouModel } from './recommendedForYouModel';
|
|
2
|
+
import type { RecommendedForYouQueryParameters } from './recommendedForYouQueryParameters';
|
|
3
|
+
export type BaseRecommendedForYouQuery = {
|
|
4
|
+
model: RecommendedForYouModel;
|
|
5
|
+
queryParameters?: RecommendedForYouQueryParameters;
|
|
6
|
+
fallbackParameters?: RecommendedForYouQueryParameters;
|
|
7
|
+
};
|
|
8
|
+
//# sourceMappingURL=baseRecommendedForYouQuery.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"baseRecommendedForYouQuery.d.ts","sourceRoot":"","sources":["../../model/baseRecommendedForYouQuery.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AACvE,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,oCAAoC,CAAC;AAE3F,MAAM,MAAM,0BAA0B,GAAG;IACvC,KAAK,EAAE,sBAAsB,CAAC;IAE9B,eAAe,CAAC,EAAE,gCAAgC,CAAC;IAEnD,kBAAkB,CAAC,EAAE,gCAAgC,CAAC;CACvD,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export type BaseRecommendedForYouQueryParameters = {
|
|
2
|
+
/**
|
|
3
|
+
* Associates a [user token](https://www.algolia.com/doc/guides/sending-events/concepts/usertoken/) with the current search.
|
|
4
|
+
*/
|
|
5
|
+
userToken: string;
|
|
6
|
+
};
|
|
7
|
+
//# sourceMappingURL=baseRecommendedForYouQueryParameters.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"baseRecommendedForYouQueryParameters.d.ts","sourceRoot":"","sources":["../../model/baseRecommendedForYouQueryParameters.ts"],"names":[],"mappings":"AAEA,MAAM,MAAM,oCAAoC,GAAG;IACjD;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import type { RecommendModels } from './recommendModels';
|
|
2
2
|
import type { SearchRecommendRulesParams } from './searchRecommendRulesParams';
|
|
3
3
|
/**
|
|
4
|
-
* Properties for the `
|
|
4
|
+
* Properties for the `customDelete` method.
|
|
5
5
|
*/
|
|
6
|
-
export type
|
|
6
|
+
export type CustomDeleteProps = {
|
|
7
7
|
/**
|
|
8
8
|
* Path of the endpoint, anything after \"/1\" must be specified.
|
|
9
9
|
*/
|
|
@@ -14,26 +14,22 @@ export type DelProps = {
|
|
|
14
14
|
parameters?: Record<string, any>;
|
|
15
15
|
};
|
|
16
16
|
/**
|
|
17
|
-
* Properties for the `
|
|
17
|
+
* Properties for the `customGet` method.
|
|
18
18
|
*/
|
|
19
|
-
export type
|
|
19
|
+
export type CustomGetProps = {
|
|
20
20
|
/**
|
|
21
|
-
*
|
|
22
|
-
*/
|
|
23
|
-
indexName: string;
|
|
24
|
-
/**
|
|
25
|
-
* [Recommend models](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).
|
|
21
|
+
* Path of the endpoint, anything after \"/1\" must be specified.
|
|
26
22
|
*/
|
|
27
|
-
|
|
23
|
+
path: string;
|
|
28
24
|
/**
|
|
29
|
-
*
|
|
25
|
+
* Query parameters to apply to the current query.
|
|
30
26
|
*/
|
|
31
|
-
|
|
27
|
+
parameters?: Record<string, any>;
|
|
32
28
|
};
|
|
33
29
|
/**
|
|
34
|
-
* Properties for the `
|
|
30
|
+
* Properties for the `customPost` method.
|
|
35
31
|
*/
|
|
36
|
-
export type
|
|
32
|
+
export type CustomPostProps = {
|
|
37
33
|
/**
|
|
38
34
|
* Path of the endpoint, anything after \"/1\" must be specified.
|
|
39
35
|
*/
|
|
@@ -42,28 +38,32 @@ export type GetProps = {
|
|
|
42
38
|
* Query parameters to apply to the current query.
|
|
43
39
|
*/
|
|
44
40
|
parameters?: Record<string, any>;
|
|
41
|
+
/**
|
|
42
|
+
* Parameters to send with the custom request.
|
|
43
|
+
*/
|
|
44
|
+
body?: Record<string, any>;
|
|
45
45
|
};
|
|
46
46
|
/**
|
|
47
|
-
* Properties for the `
|
|
47
|
+
* Properties for the `customPut` method.
|
|
48
48
|
*/
|
|
49
|
-
export type
|
|
49
|
+
export type CustomPutProps = {
|
|
50
50
|
/**
|
|
51
|
-
*
|
|
51
|
+
* Path of the endpoint, anything after \"/1\" must be specified.
|
|
52
52
|
*/
|
|
53
|
-
|
|
53
|
+
path: string;
|
|
54
54
|
/**
|
|
55
|
-
*
|
|
55
|
+
* Query parameters to apply to the current query.
|
|
56
56
|
*/
|
|
57
|
-
|
|
57
|
+
parameters?: Record<string, any>;
|
|
58
58
|
/**
|
|
59
|
-
*
|
|
59
|
+
* Parameters to send with the custom request.
|
|
60
60
|
*/
|
|
61
|
-
|
|
61
|
+
body?: Record<string, any>;
|
|
62
62
|
};
|
|
63
63
|
/**
|
|
64
|
-
* Properties for the `
|
|
64
|
+
* Properties for the `deleteRecommendRule` method.
|
|
65
65
|
*/
|
|
66
|
-
export type
|
|
66
|
+
export type DeleteRecommendRuleProps = {
|
|
67
67
|
/**
|
|
68
68
|
* Index on which to perform the request.
|
|
69
69
|
*/
|
|
@@ -73,43 +73,43 @@ export type GetRecommendStatusProps = {
|
|
|
73
73
|
*/
|
|
74
74
|
model: RecommendModels;
|
|
75
75
|
/**
|
|
76
|
-
* Unique
|
|
76
|
+
* Unique record (object) identifier.
|
|
77
77
|
*/
|
|
78
|
-
|
|
78
|
+
objectID: string;
|
|
79
79
|
};
|
|
80
80
|
/**
|
|
81
|
-
* Properties for the `
|
|
81
|
+
* Properties for the `getRecommendRule` method.
|
|
82
82
|
*/
|
|
83
|
-
export type
|
|
83
|
+
export type GetRecommendRuleProps = {
|
|
84
84
|
/**
|
|
85
|
-
*
|
|
85
|
+
* Index on which to perform the request.
|
|
86
86
|
*/
|
|
87
|
-
|
|
87
|
+
indexName: string;
|
|
88
88
|
/**
|
|
89
|
-
*
|
|
89
|
+
* [Recommend models](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).
|
|
90
90
|
*/
|
|
91
|
-
|
|
91
|
+
model: RecommendModels;
|
|
92
92
|
/**
|
|
93
|
-
*
|
|
93
|
+
* Unique record (object) identifier.
|
|
94
94
|
*/
|
|
95
|
-
|
|
95
|
+
objectID: string;
|
|
96
96
|
};
|
|
97
97
|
/**
|
|
98
|
-
* Properties for the `
|
|
98
|
+
* Properties for the `getRecommendStatus` method.
|
|
99
99
|
*/
|
|
100
|
-
export type
|
|
100
|
+
export type GetRecommendStatusProps = {
|
|
101
101
|
/**
|
|
102
|
-
*
|
|
102
|
+
* Index on which to perform the request.
|
|
103
103
|
*/
|
|
104
|
-
|
|
104
|
+
indexName: string;
|
|
105
105
|
/**
|
|
106
|
-
*
|
|
106
|
+
* [Recommend models](https://www.algolia.com/doc/guides/algolia-recommend/overview/#recommend-models).
|
|
107
107
|
*/
|
|
108
|
-
|
|
108
|
+
model: RecommendModels;
|
|
109
109
|
/**
|
|
110
|
-
*
|
|
110
|
+
* Unique identifier of a task. Numeric value (up to 64bits).
|
|
111
111
|
*/
|
|
112
|
-
|
|
112
|
+
taskID: number;
|
|
113
113
|
};
|
|
114
114
|
/**
|
|
115
115
|
* Properties for the `searchRecommendRules` method.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"clientMethodProps.d.ts","sourceRoot":"","sources":["../../model/clientMethodProps.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACzD,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,8BAA8B,CAAC;AAE/E;;GAEG;AACH,MAAM,MAAM,
|
|
1
|
+
{"version":3,"file":"clientMethodProps.d.ts","sourceRoot":"","sources":["../../model/clientMethodProps.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACzD,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,8BAA8B,CAAC;AAE/E;;GAEG;AACH,MAAM,MAAM,iBAAiB,GAAG;IAC9B;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IACb;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;CAClC,CAAC;AAEF;;GAEG;AACH,MAAM,MAAM,cAAc,GAAG;IAC3B;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IACb;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;CAClC,CAAC;AAEF;;GAEG;AACH,MAAM,MAAM,eAAe,GAAG;IAC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
-
import type {
|
|
1
|
+
import type { RecommendationsResults } from './recommendationsResults';
|
|
2
2
|
export type GetRecommendationsResponse = {
|
|
3
|
-
results?:
|
|
3
|
+
results?: RecommendationsResults[];
|
|
4
4
|
};
|
|
5
5
|
//# sourceMappingURL=getRecommendationsResponse.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getRecommendationsResponse.d.ts","sourceRoot":"","sources":["../../model/getRecommendationsResponse.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"getRecommendationsResponse.d.ts","sourceRoot":"","sources":["../../model/getRecommendationsResponse.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAEvE,MAAM,MAAM,0BAA0B,GAAG;IACvC,OAAO,CAAC,EAAE,sBAAsB,EAAE,CAAC;CACpC,CAAC"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import type { HighlightResultOption } from './highlightResultOption';
|
|
2
|
-
export type HighlightResult = HighlightResultOption | HighlightResultOption
|
|
2
|
+
export type HighlightResult = HighlightResultOption | Record<string, HighlightResultOption>;
|
|
3
3
|
//# sourceMappingURL=highlightResult.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"highlightResult.d.ts","sourceRoot":"","sources":["../../model/highlightResult.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAErE,MAAM,MAAM,eAAe,
|
|
1
|
+
{"version":3,"file":"highlightResult.d.ts","sourceRoot":"","sources":["../../model/highlightResult.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAErE,MAAM,MAAM,eAAe,GACvB,qBAAqB,GACrB,MAAM,CAAC,MAAM,EAAE,qBAAqB,CAAC,CAAC"}
|
package/dist/model/index.d.ts
CHANGED
|
@@ -9,6 +9,8 @@ export * from './automaticFacetFilter';
|
|
|
9
9
|
export * from './automaticFacetFilters';
|
|
10
10
|
export * from './baseRecommendRequest';
|
|
11
11
|
export * from './baseRecommendationsQuery';
|
|
12
|
+
export * from './baseRecommendedForYouQuery';
|
|
13
|
+
export * from './baseRecommendedForYouQueryParameters';
|
|
12
14
|
export * from './baseSearchParams';
|
|
13
15
|
export * from './baseSearchParamsWithoutQuery';
|
|
14
16
|
export * from './baseSearchResponse';
|
|
@@ -53,12 +55,16 @@ export * from './queryType';
|
|
|
53
55
|
export * from './rankingInfo';
|
|
54
56
|
export * from './reRankingApplyFilter';
|
|
55
57
|
export * from './recommendHit';
|
|
56
|
-
export * from './recommendHits';
|
|
57
58
|
export * from './recommendModels';
|
|
58
59
|
export * from './recommendationModels';
|
|
60
|
+
export * from './recommendationsHit';
|
|
61
|
+
export * from './recommendationsHits';
|
|
59
62
|
export * from './recommendationsQuery';
|
|
60
63
|
export * from './recommendationsRequest';
|
|
61
|
-
export * from './
|
|
64
|
+
export * from './recommendationsResults';
|
|
65
|
+
export * from './recommendedForYouModel';
|
|
66
|
+
export * from './recommendedForYouQuery';
|
|
67
|
+
export * from './recommendedForYouQueryParameters';
|
|
62
68
|
export * from './redirect';
|
|
63
69
|
export * from './redirectRuleIndexMetadata';
|
|
64
70
|
export * from './redirectRuleIndexMetadataData';
|
|
@@ -77,6 +83,7 @@ export * from './snippetResultOption';
|
|
|
77
83
|
export * from './sortRemainingBy';
|
|
78
84
|
export * from './tagFilters';
|
|
79
85
|
export * from './taskStatus';
|
|
86
|
+
export * from './trendingFacetHit';
|
|
80
87
|
export * from './trendingFacetsModel';
|
|
81
88
|
export * from './trendingFacetsQuery';
|
|
82
89
|
export * from './trendingItemsModel';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../model/index.ts"],"names":[],"mappings":"AAEA,cAAc,0BAA0B,CAAC;AACzC,cAAc,uBAAuB,CAAC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;AAC7B,cAAc,cAAc,CAAC;AAC7B,cAAc,oBAAoB,CAAC;AACnC,cAAc,uBAAuB,CAAC;AACtC,cAAc,uBAAuB,CAAC;AACtC,cAAc,sBAAsB,CAAC;AACrC,cAAc,sBAAsB,CAAC;AACrC,cAAc,iBAAiB,CAAC;AAChC,cAAc,qBAAqB,CAAC;AACpC,cAAc,SAAS,CAAC;AACxB,cAAc,qBAAqB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"recommendationsHit.d.ts","sourceRoot":"","sources":["../../model/recommendationsHit.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AACnD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAE3D,MAAM,MAAM,kBAAkB,GAAG,YAAY,GAAG,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { RecommendationsHit } from './recommendationsHit';
|
|
2
|
+
export type RecommendationsHits = {
|
|
3
|
+
hits: RecommendationsHit[];
|
|
4
|
+
/**
|
|
5
|
+
* Text to search for in an index.
|
|
6
|
+
*/
|
|
7
|
+
query?: string;
|
|
8
|
+
/**
|
|
9
|
+
* URL-encoded string of all search parameters.
|
|
10
|
+
*/
|
|
11
|
+
params?: string;
|
|
12
|
+
};
|
|
13
|
+
//# sourceMappingURL=recommendationsHits.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"recommendationsHits.d.ts","sourceRoot":"","sources":["../../model/recommendationsHits.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE/D,MAAM,MAAM,mBAAmB,GAAG;IAChC,IAAI,EAAE,kBAAkB,EAAE,CAAC;IAE3B;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { RecommendationsQuery } from './recommendationsQuery';
|
|
2
|
+
import type { RecommendedForYouQuery } from './recommendedForYouQuery';
|
|
2
3
|
import type { TrendingFacetsQuery } from './trendingFacetsQuery';
|
|
3
4
|
import type { TrendingItemsQuery } from './trendingItemsQuery';
|
|
4
|
-
export type RecommendationsRequest = RecommendationsQuery | TrendingFacetsQuery | TrendingItemsQuery;
|
|
5
|
+
export type RecommendationsRequest = RecommendationsQuery | RecommendedForYouQuery | TrendingFacetsQuery | TrendingItemsQuery;
|
|
5
6
|
//# sourceMappingURL=recommendationsRequest.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"recommendationsRequest.d.ts","sourceRoot":"","sources":["../../model/recommendationsRequest.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AACnE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AACjE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE/D,MAAM,MAAM,sBAAsB,GAC9B,oBAAoB,GACpB,mBAAmB,GACnB,kBAAkB,CAAC"}
|
|
1
|
+
{"version":3,"file":"recommendationsRequest.d.ts","sourceRoot":"","sources":["../../model/recommendationsRequest.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AACnE,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AACvE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AACjE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE/D,MAAM,MAAM,sBAAsB,GAC9B,oBAAoB,GACpB,sBAAsB,GACtB,mBAAmB,GACnB,kBAAkB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"recommendationsResults.d.ts","sourceRoot":"","sources":["../../model/recommendationsResults.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC/D,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAEjE,MAAM,MAAM,sBAAsB,GAAG,kBAAkB,GAAG,mBAAmB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"recommendedForYouModel.d.ts","sourceRoot":"","sources":["../../model/recommendedForYouModel.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,MAAM,MAAM,sBAAsB,GAAG,qBAAqB,CAAC"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { BaseRecommendRequest } from './baseRecommendRequest';
|
|
2
|
+
import type { BaseRecommendedForYouQuery } from './baseRecommendedForYouQuery';
|
|
3
|
+
export type RecommendedForYouQuery = BaseRecommendedForYouQuery & BaseRecommendRequest;
|
|
4
|
+
//# sourceMappingURL=recommendedForYouQuery.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"recommendedForYouQuery.d.ts","sourceRoot":"","sources":["../../model/recommendedForYouQuery.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AACnE,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,8BAA8B,CAAC;AAE/E,MAAM,MAAM,sBAAsB,GAAG,0BAA0B,GAC7D,oBAAoB,CAAC"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { BaseRecommendedForYouQueryParameters } from './baseRecommendedForYouQueryParameters';
|
|
2
|
+
import type { SearchParamsObject } from './searchParamsObject';
|
|
3
|
+
export type RecommendedForYouQueryParameters = BaseRecommendedForYouQueryParameters & SearchParamsObject;
|
|
4
|
+
//# sourceMappingURL=recommendedForYouQueryParameters.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"recommendedForYouQueryParameters.d.ts","sourceRoot":"","sources":["../../model/recommendedForYouQueryParameters.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,oCAAoC,EAAE,MAAM,wCAAwC,CAAC;AACnG,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE/D,MAAM,MAAM,gCAAgC,GAC1C,oCAAoC,GAAG,kBAAkB,CAAC"}
|
|
@@ -22,9 +22,5 @@ export type SearchRecommendRulesParams = {
|
|
|
22
22
|
* Restricts responses to enabled rules. When absent (default), _all_ rules are retrieved.
|
|
23
23
|
*/
|
|
24
24
|
enabled?: boolean | null;
|
|
25
|
-
/**
|
|
26
|
-
* Request options to send with the API call.
|
|
27
|
-
*/
|
|
28
|
-
_requestOptions?: Array<Record<string, any>>;
|
|
29
25
|
};
|
|
30
26
|
//# sourceMappingURL=searchRecommendRulesParams.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"searchRecommendRulesParams.d.ts","sourceRoot":"","sources":["../../model/searchRecommendRulesParams.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,MAAM,MAAM,0BAA0B,GAAG;IACvC;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;OAEG;IACH,OAAO,CAAC,EAAE,OAAO,GAAG,IAAI,CAAC;
|
|
1
|
+
{"version":3,"file":"searchRecommendRulesParams.d.ts","sourceRoot":"","sources":["../../model/searchRecommendRulesParams.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,MAAM,MAAM,0BAA0B,GAAG;IACvC;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;OAEG;IACH,OAAO,CAAC,EAAE,OAAO,GAAG,IAAI,CAAC;CAC1B,CAAC"}
|
|
@@ -5,15 +5,15 @@ export type SearchRecommendRulesResponse = {
|
|
|
5
5
|
*/
|
|
6
6
|
hits: RuleResponse[];
|
|
7
7
|
/**
|
|
8
|
-
* Number of
|
|
8
|
+
* Number of hits the search query matched.
|
|
9
9
|
*/
|
|
10
10
|
nbHits: number;
|
|
11
11
|
/**
|
|
12
|
-
*
|
|
12
|
+
* Page to retrieve (the first page is `0`, not `1`).
|
|
13
13
|
*/
|
|
14
14
|
page: number;
|
|
15
15
|
/**
|
|
16
|
-
* Number of pages.
|
|
16
|
+
* Number of pages of results for the current query.
|
|
17
17
|
*/
|
|
18
18
|
nbPages: number;
|
|
19
19
|
};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import type { SnippetResultOption } from './snippetResultOption';
|
|
2
|
-
export type SnippetResult = SnippetResultOption | SnippetResultOption
|
|
2
|
+
export type SnippetResult = Record<string, SnippetResultOption> | SnippetResultOption;
|
|
3
3
|
//# sourceMappingURL=snippetResult.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"snippetResult.d.ts","sourceRoot":"","sources":["../../model/snippetResult.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAEjE,MAAM,MAAM,aAAa,
|
|
1
|
+
{"version":3,"file":"snippetResult.d.ts","sourceRoot":"","sources":["../../model/snippetResult.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAEjE,MAAM,MAAM,aAAa,GACrB,MAAM,CAAC,MAAM,EAAE,mBAAmB,CAAC,GACnC,mBAAmB,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Trending facet hit.
|
|
3
|
+
*/
|
|
4
|
+
export type TrendingFacetHit = {
|
|
5
|
+
/**
|
|
6
|
+
* Recommendation score.
|
|
7
|
+
*/
|
|
8
|
+
_score: number;
|
|
9
|
+
/**
|
|
10
|
+
* Facet name for trending models.
|
|
11
|
+
*/
|
|
12
|
+
facetName: string;
|
|
13
|
+
/**
|
|
14
|
+
* Facet value for trending models.
|
|
15
|
+
*/
|
|
16
|
+
facetValue: string;
|
|
17
|
+
};
|
|
18
|
+
//# sourceMappingURL=trendingFacetHit.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"trendingFacetHit.d.ts","sourceRoot":"","sources":["../../model/trendingFacetHit.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,MAAM,MAAM,gBAAgB,GAAG;IAC7B;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;IAElB;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;CACpB,CAAC"}
|
package/dist/recommend.cjs
CHANGED
|
@@ -4,7 +4,7 @@ var clientCommon = require('@algolia/client-common');
|
|
|
4
4
|
var requesterNodeHttp = require('@algolia/requester-node-http');
|
|
5
5
|
|
|
6
6
|
// 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.
|
|
7
|
-
const apiClientVersion = '5.0.0-alpha.
|
|
7
|
+
const apiClientVersion = '5.0.0-alpha.98';
|
|
8
8
|
function getDefaultHosts(appId) {
|
|
9
9
|
return [
|
|
10
10
|
{
|
|
@@ -90,14 +90,14 @@ function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOption, authM
|
|
|
90
90
|
* This method allow you to send requests to the Algolia REST API.
|
|
91
91
|
*
|
|
92
92
|
* @summary Send requests to the Algolia REST API.
|
|
93
|
-
* @param
|
|
94
|
-
* @param
|
|
95
|
-
* @param
|
|
93
|
+
* @param customDelete - The customDelete object.
|
|
94
|
+
* @param customDelete.path - Path of the endpoint, anything after \"/1\" must be specified.
|
|
95
|
+
* @param customDelete.parameters - Query parameters to apply to the current query.
|
|
96
96
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
97
97
|
*/
|
|
98
|
-
|
|
98
|
+
customDelete({ path, parameters }, requestOptions) {
|
|
99
99
|
if (!path) {
|
|
100
|
-
throw new Error('Parameter `path` is required when calling `
|
|
100
|
+
throw new Error('Parameter `path` is required when calling `customDelete`.');
|
|
101
101
|
}
|
|
102
102
|
const requestPath = '/1{path}'.replace('{path}', path);
|
|
103
103
|
const headers = {};
|
|
@@ -110,6 +110,82 @@ function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOption, authM
|
|
|
110
110
|
};
|
|
111
111
|
return transporter.request(request, requestOptions);
|
|
112
112
|
},
|
|
113
|
+
/**
|
|
114
|
+
* This method allow you to send requests to the Algolia REST API.
|
|
115
|
+
*
|
|
116
|
+
* @summary Send requests to the Algolia REST API.
|
|
117
|
+
* @param customGet - The customGet object.
|
|
118
|
+
* @param customGet.path - Path of the endpoint, anything after \"/1\" must be specified.
|
|
119
|
+
* @param customGet.parameters - Query parameters to apply to the current query.
|
|
120
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
121
|
+
*/
|
|
122
|
+
customGet({ path, parameters }, requestOptions) {
|
|
123
|
+
if (!path) {
|
|
124
|
+
throw new Error('Parameter `path` is required when calling `customGet`.');
|
|
125
|
+
}
|
|
126
|
+
const requestPath = '/1{path}'.replace('{path}', path);
|
|
127
|
+
const headers = {};
|
|
128
|
+
const queryParameters = parameters ? parameters : {};
|
|
129
|
+
const request = {
|
|
130
|
+
method: 'GET',
|
|
131
|
+
path: requestPath,
|
|
132
|
+
queryParameters,
|
|
133
|
+
headers,
|
|
134
|
+
};
|
|
135
|
+
return transporter.request(request, requestOptions);
|
|
136
|
+
},
|
|
137
|
+
/**
|
|
138
|
+
* This method allow you to send requests to the Algolia REST API.
|
|
139
|
+
*
|
|
140
|
+
* @summary Send requests to the Algolia REST API.
|
|
141
|
+
* @param customPost - The customPost object.
|
|
142
|
+
* @param customPost.path - Path of the endpoint, anything after \"/1\" must be specified.
|
|
143
|
+
* @param customPost.parameters - Query parameters to apply to the current query.
|
|
144
|
+
* @param customPost.body - Parameters to send with the custom request.
|
|
145
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
146
|
+
*/
|
|
147
|
+
customPost({ path, parameters, body }, requestOptions) {
|
|
148
|
+
if (!path) {
|
|
149
|
+
throw new Error('Parameter `path` is required when calling `customPost`.');
|
|
150
|
+
}
|
|
151
|
+
const requestPath = '/1{path}'.replace('{path}', path);
|
|
152
|
+
const headers = {};
|
|
153
|
+
const queryParameters = parameters ? parameters : {};
|
|
154
|
+
const request = {
|
|
155
|
+
method: 'POST',
|
|
156
|
+
path: requestPath,
|
|
157
|
+
queryParameters,
|
|
158
|
+
headers,
|
|
159
|
+
data: body ? body : {},
|
|
160
|
+
};
|
|
161
|
+
return transporter.request(request, requestOptions);
|
|
162
|
+
},
|
|
163
|
+
/**
|
|
164
|
+
* This method allow you to send requests to the Algolia REST API.
|
|
165
|
+
*
|
|
166
|
+
* @summary Send requests to the Algolia REST API.
|
|
167
|
+
* @param customPut - The customPut object.
|
|
168
|
+
* @param customPut.path - Path of the endpoint, anything after \"/1\" must be specified.
|
|
169
|
+
* @param customPut.parameters - Query parameters to apply to the current query.
|
|
170
|
+
* @param customPut.body - Parameters to send with the custom request.
|
|
171
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
172
|
+
*/
|
|
173
|
+
customPut({ path, parameters, body }, requestOptions) {
|
|
174
|
+
if (!path) {
|
|
175
|
+
throw new Error('Parameter `path` is required when calling `customPut`.');
|
|
176
|
+
}
|
|
177
|
+
const requestPath = '/1{path}'.replace('{path}', path);
|
|
178
|
+
const headers = {};
|
|
179
|
+
const queryParameters = parameters ? parameters : {};
|
|
180
|
+
const request = {
|
|
181
|
+
method: 'PUT',
|
|
182
|
+
path: requestPath,
|
|
183
|
+
queryParameters,
|
|
184
|
+
headers,
|
|
185
|
+
data: body ? body : {},
|
|
186
|
+
};
|
|
187
|
+
return transporter.request(request, requestOptions);
|
|
188
|
+
},
|
|
113
189
|
/**
|
|
114
190
|
* Delete a [Recommend rule](https://www.algolia.com/doc/guides/algolia-recommend/how-to/rules/).
|
|
115
191
|
*
|
|
@@ -144,30 +220,6 @@ function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOption, authM
|
|
|
144
220
|
};
|
|
145
221
|
return transporter.request(request, requestOptions);
|
|
146
222
|
},
|
|
147
|
-
/**
|
|
148
|
-
* This method allow you to send requests to the Algolia REST API.
|
|
149
|
-
*
|
|
150
|
-
* @summary Send requests to the Algolia REST API.
|
|
151
|
-
* @param get - The get object.
|
|
152
|
-
* @param get.path - Path of the endpoint, anything after \"/1\" must be specified.
|
|
153
|
-
* @param get.parameters - Query parameters to apply to the current query.
|
|
154
|
-
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
155
|
-
*/
|
|
156
|
-
get({ path, parameters }, requestOptions) {
|
|
157
|
-
if (!path) {
|
|
158
|
-
throw new Error('Parameter `path` is required when calling `get`.');
|
|
159
|
-
}
|
|
160
|
-
const requestPath = '/1{path}'.replace('{path}', path);
|
|
161
|
-
const headers = {};
|
|
162
|
-
const queryParameters = parameters ? parameters : {};
|
|
163
|
-
const request = {
|
|
164
|
-
method: 'GET',
|
|
165
|
-
path: requestPath,
|
|
166
|
-
queryParameters,
|
|
167
|
-
headers,
|
|
168
|
-
};
|
|
169
|
-
return transporter.request(request, requestOptions);
|
|
170
|
-
},
|
|
171
223
|
/**
|
|
172
224
|
* Return a [Recommend rule](https://www.algolia.com/doc/guides/algolia-recommend/how-to/rules/).
|
|
173
225
|
*
|
|
@@ -264,58 +316,6 @@ function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOption, authM
|
|
|
264
316
|
};
|
|
265
317
|
return transporter.request(request, requestOptions);
|
|
266
318
|
},
|
|
267
|
-
/**
|
|
268
|
-
* This method allow you to send requests to the Algolia REST API.
|
|
269
|
-
*
|
|
270
|
-
* @summary Send requests to the Algolia REST API.
|
|
271
|
-
* @param post - The post object.
|
|
272
|
-
* @param post.path - Path of the endpoint, anything after \"/1\" must be specified.
|
|
273
|
-
* @param post.parameters - Query parameters to apply to the current query.
|
|
274
|
-
* @param post.body - Parameters to send with the custom request.
|
|
275
|
-
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
276
|
-
*/
|
|
277
|
-
post({ path, parameters, body }, requestOptions) {
|
|
278
|
-
if (!path) {
|
|
279
|
-
throw new Error('Parameter `path` is required when calling `post`.');
|
|
280
|
-
}
|
|
281
|
-
const requestPath = '/1{path}'.replace('{path}', path);
|
|
282
|
-
const headers = {};
|
|
283
|
-
const queryParameters = parameters ? parameters : {};
|
|
284
|
-
const request = {
|
|
285
|
-
method: 'POST',
|
|
286
|
-
path: requestPath,
|
|
287
|
-
queryParameters,
|
|
288
|
-
headers,
|
|
289
|
-
data: body ? body : {},
|
|
290
|
-
};
|
|
291
|
-
return transporter.request(request, requestOptions);
|
|
292
|
-
},
|
|
293
|
-
/**
|
|
294
|
-
* This method allow you to send requests to the Algolia REST API.
|
|
295
|
-
*
|
|
296
|
-
* @summary Send requests to the Algolia REST API.
|
|
297
|
-
* @param put - The put object.
|
|
298
|
-
* @param put.path - Path of the endpoint, anything after \"/1\" must be specified.
|
|
299
|
-
* @param put.parameters - Query parameters to apply to the current query.
|
|
300
|
-
* @param put.body - Parameters to send with the custom request.
|
|
301
|
-
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
302
|
-
*/
|
|
303
|
-
put({ path, parameters, body }, requestOptions) {
|
|
304
|
-
if (!path) {
|
|
305
|
-
throw new Error('Parameter `path` is required when calling `put`.');
|
|
306
|
-
}
|
|
307
|
-
const requestPath = '/1{path}'.replace('{path}', path);
|
|
308
|
-
const headers = {};
|
|
309
|
-
const queryParameters = parameters ? parameters : {};
|
|
310
|
-
const request = {
|
|
311
|
-
method: 'PUT',
|
|
312
|
-
path: requestPath,
|
|
313
|
-
queryParameters,
|
|
314
|
-
headers,
|
|
315
|
-
data: body ? body : {},
|
|
316
|
-
};
|
|
317
|
-
return transporter.request(request, requestOptions);
|
|
318
|
-
},
|
|
319
319
|
/**
|
|
320
320
|
* List [Recommend rules](https://www.algolia.com/doc/guides/algolia-recommend/how-to/rules/).
|
|
321
321
|
*
|