@wix/auto_sdk_ecom_recommendations 1.0.5 → 1.0.6
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/build/{es/src/ecom-recommendations-v1-recommendation-recommendations.types.d.ts → ecom-recommendations-v1-recommendation-recommendations.universal-DXecA95A.d.mts} +29 -13
- package/build/{internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.types.d.ts → ecom-recommendations-v1-recommendation-recommendations.universal-DXecA95A.d.ts} +29 -13
- package/build/{internal/es/src/ecom-recommendations-v1-recommendation-recommendations.public.d.ts → index.d.mts} +11 -8
- package/build/{cjs/src/ecom-recommendations-v1-recommendation-recommendations.public.d.ts → index.d.ts} +11 -8
- package/build/index.js +179 -0
- package/build/index.js.map +1 -0
- package/build/index.mjs +153 -0
- package/build/index.mjs.map +1 -0
- package/build/{cjs/src/ecom-recommendations-v1-recommendation-recommendations.types.d.ts → internal/ecom-recommendations-v1-recommendation-recommendations.universal-DXecA95A.d.mts} +29 -13
- package/build/internal/{es/src/ecom-recommendations-v1-recommendation-recommendations.types.d.ts → ecom-recommendations-v1-recommendation-recommendations.universal-DXecA95A.d.ts} +29 -13
- package/build/{es/src/ecom-recommendations-v1-recommendation-recommendations.public.d.ts → internal/index.d.mts} +11 -8
- package/build/internal/{cjs/src/ecom-recommendations-v1-recommendation-recommendations.public.d.ts → index.d.ts} +11 -8
- package/build/internal/index.js +179 -0
- package/build/internal/index.js.map +1 -0
- package/build/internal/index.mjs +153 -0
- package/build/internal/index.mjs.map +1 -0
- package/build/internal/meta.d.mts +162 -0
- package/build/internal/meta.d.ts +162 -0
- package/build/internal/meta.js +128 -0
- package/build/internal/meta.js.map +1 -0
- package/build/internal/meta.mjs +100 -0
- package/build/internal/meta.mjs.map +1 -0
- package/build/meta.d.mts +162 -0
- package/build/meta.d.ts +162 -0
- package/build/meta.js +128 -0
- package/build/meta.js.map +1 -0
- package/build/meta.mjs +100 -0
- package/build/meta.mjs.map +1 -0
- package/package.json +13 -12
- package/build/cjs/index.d.ts +0 -1
- package/build/cjs/index.js +0 -18
- package/build/cjs/index.js.map +0 -1
- package/build/cjs/index.typings.d.ts +0 -1
- package/build/cjs/index.typings.js +0 -18
- package/build/cjs/index.typings.js.map +0 -1
- package/build/cjs/meta.d.ts +0 -1
- package/build/cjs/meta.js +0 -18
- package/build/cjs/meta.js.map +0 -1
- package/build/cjs/src/ecom-recommendations-v1-recommendation-recommendations.context.d.ts +0 -6
- package/build/cjs/src/ecom-recommendations-v1-recommendation-recommendations.context.js +0 -10
- package/build/cjs/src/ecom-recommendations-v1-recommendation-recommendations.context.js.map +0 -1
- package/build/cjs/src/ecom-recommendations-v1-recommendation-recommendations.http.d.ts +0 -37
- package/build/cjs/src/ecom-recommendations-v1-recommendation-recommendations.http.js +0 -94
- package/build/cjs/src/ecom-recommendations-v1-recommendation-recommendations.http.js.map +0 -1
- package/build/cjs/src/ecom-recommendations-v1-recommendation-recommendations.meta.d.ts +0 -14
- package/build/cjs/src/ecom-recommendations-v1-recommendation-recommendations.meta.js +0 -66
- package/build/cjs/src/ecom-recommendations-v1-recommendation-recommendations.meta.js.map +0 -1
- package/build/cjs/src/ecom-recommendations-v1-recommendation-recommendations.public.js +0 -20
- package/build/cjs/src/ecom-recommendations-v1-recommendation-recommendations.public.js.map +0 -1
- package/build/cjs/src/ecom-recommendations-v1-recommendation-recommendations.types.js +0 -10
- package/build/cjs/src/ecom-recommendations-v1-recommendation-recommendations.types.js.map +0 -1
- package/build/cjs/src/ecom-recommendations-v1-recommendation-recommendations.universal.d.ts +0 -258
- package/build/cjs/src/ecom-recommendations-v1-recommendation-recommendations.universal.js +0 -158
- package/build/cjs/src/ecom-recommendations-v1-recommendation-recommendations.universal.js.map +0 -1
- package/build/es/index.d.ts +0 -1
- package/build/es/index.js +0 -2
- package/build/es/index.js.map +0 -1
- package/build/es/index.typings.d.ts +0 -1
- package/build/es/index.typings.js +0 -2
- package/build/es/index.typings.js.map +0 -1
- package/build/es/meta.d.ts +0 -1
- package/build/es/meta.js +0 -2
- package/build/es/meta.js.map +0 -1
- package/build/es/package.json +0 -3
- package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.context.d.ts +0 -6
- package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.context.js +0 -6
- package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.context.js.map +0 -1
- package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.http.d.ts +0 -37
- package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.http.js +0 -89
- package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.http.js.map +0 -1
- package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.meta.d.ts +0 -14
- package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.meta.js +0 -38
- package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.meta.js.map +0 -1
- package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.public.js +0 -14
- package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.public.js.map +0 -1
- package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.types.js +0 -7
- package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.types.js.map +0 -1
- package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.universal.d.ts +0 -258
- package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.universal.js +0 -130
- package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.universal.js.map +0 -1
- package/build/internal/cjs/index.d.ts +0 -1
- package/build/internal/cjs/index.js +0 -18
- package/build/internal/cjs/index.js.map +0 -1
- package/build/internal/cjs/index.typings.d.ts +0 -1
- package/build/internal/cjs/index.typings.js +0 -18
- package/build/internal/cjs/index.typings.js.map +0 -1
- package/build/internal/cjs/meta.d.ts +0 -1
- package/build/internal/cjs/meta.js +0 -18
- package/build/internal/cjs/meta.js.map +0 -1
- package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.context.d.ts +0 -6
- package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.context.js +0 -10
- package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.context.js.map +0 -1
- package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.http.d.ts +0 -37
- package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.http.js +0 -94
- package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.http.js.map +0 -1
- package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.meta.d.ts +0 -14
- package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.meta.js +0 -66
- package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.meta.js.map +0 -1
- package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.public.js +0 -20
- package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.public.js.map +0 -1
- package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.types.js +0 -10
- package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.types.js.map +0 -1
- package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.universal.d.ts +0 -258
- package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.universal.js +0 -158
- package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.universal.js.map +0 -1
- package/build/internal/es/index.d.ts +0 -1
- package/build/internal/es/index.js +0 -2
- package/build/internal/es/index.js.map +0 -1
- package/build/internal/es/index.typings.d.ts +0 -1
- package/build/internal/es/index.typings.js +0 -2
- package/build/internal/es/index.typings.js.map +0 -1
- package/build/internal/es/meta.d.ts +0 -1
- package/build/internal/es/meta.js +0 -2
- package/build/internal/es/meta.js.map +0 -1
- package/build/internal/es/src/ecom-recommendations-v1-recommendation-recommendations.context.d.ts +0 -6
- package/build/internal/es/src/ecom-recommendations-v1-recommendation-recommendations.context.js +0 -6
- package/build/internal/es/src/ecom-recommendations-v1-recommendation-recommendations.context.js.map +0 -1
- package/build/internal/es/src/ecom-recommendations-v1-recommendation-recommendations.http.d.ts +0 -37
- package/build/internal/es/src/ecom-recommendations-v1-recommendation-recommendations.http.js +0 -89
- package/build/internal/es/src/ecom-recommendations-v1-recommendation-recommendations.http.js.map +0 -1
- package/build/internal/es/src/ecom-recommendations-v1-recommendation-recommendations.meta.d.ts +0 -14
- package/build/internal/es/src/ecom-recommendations-v1-recommendation-recommendations.meta.js +0 -38
- package/build/internal/es/src/ecom-recommendations-v1-recommendation-recommendations.meta.js.map +0 -1
- package/build/internal/es/src/ecom-recommendations-v1-recommendation-recommendations.public.js +0 -14
- package/build/internal/es/src/ecom-recommendations-v1-recommendation-recommendations.public.js.map +0 -1
- package/build/internal/es/src/ecom-recommendations-v1-recommendation-recommendations.types.js +0 -7
- package/build/internal/es/src/ecom-recommendations-v1-recommendation-recommendations.types.js.map +0 -1
- package/build/internal/es/src/ecom-recommendations-v1-recommendation-recommendations.universal.d.ts +0 -258
- package/build/internal/es/src/ecom-recommendations-v1-recommendation-recommendations.universal.js +0 -130
- package/build/internal/es/src/ecom-recommendations-v1-recommendation-recommendations.universal.js.map +0 -1
|
@@ -1,130 +0,0 @@
|
|
|
1
|
-
import { transformError as sdkTransformError } from '@wix/sdk-runtime/transform-error';
|
|
2
|
-
import { renameKeysFromSDKRequestToRESTRequest, renameKeysFromRESTResponseToSDKResponse, } from '@wix/sdk-runtime/rename-all-nested-keys';
|
|
3
|
-
import * as ambassadorWixEcomRecommendationsV1Recommendation from './ecom-recommendations-v1-recommendation-recommendations.http.js';
|
|
4
|
-
export var AlgorithmType;
|
|
5
|
-
(function (AlgorithmType) {
|
|
6
|
-
AlgorithmType["UNSPECIFIED"] = "UNSPECIFIED";
|
|
7
|
-
AlgorithmType["RELATED_ITEMS"] = "RELATED_ITEMS";
|
|
8
|
-
AlgorithmType["GLOBAL"] = "GLOBAL";
|
|
9
|
-
})(AlgorithmType || (AlgorithmType = {}));
|
|
10
|
-
/**
|
|
11
|
-
* Returns a list of recommendation algorithms that can be used on your Wix site or project. These algorithms can be used with [`getRecommendation()`](#getRecommendation) to provide item recommendations to the customer.
|
|
12
|
-
*
|
|
13
|
-
* Algorithms are run by the apps that provide them, and can only be used on catalogs they support. Apps may provide algorithms for use with their own catalogs and/or catalogs from other apps.
|
|
14
|
-
*
|
|
15
|
-
* The app which provides an algorithm is referenced by that algorithm’s `appId`. The apps whose catalogs are supported by an algorithm are referenced by the IDs in that algorithm’s `catalogAppIds` array.
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
* For an algorithm to be considered “Available” and returned in this method’s response, the algorithm must meet the following conditions:
|
|
19
|
-
* 1. The algorithm’s `appId` must match the ID of an installed Wix app.
|
|
20
|
-
* 2. At least 1 of the IDs in `catalogAppIds` must match the ID of an installed Wix app.
|
|
21
|
-
*
|
|
22
|
-
* Wix app IDs are [listed here](https://dev.wix.com/api/rest/getting-started/wix-business-solutions#getting-started_wix-business-solutions_about-wix-business-solutions).
|
|
23
|
-
* @public
|
|
24
|
-
* @permissionId RECOMMENDATIONS.READ
|
|
25
|
-
* @permissionScope Manage Stores - all permissions
|
|
26
|
-
* @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
|
|
27
|
-
* @permissionScope Read eCommerce - all read permissions
|
|
28
|
-
* @permissionScopeId SCOPE.DC-ECOM-MEGA.READ-ECOM
|
|
29
|
-
* @permissionScope Manage eCommerce - all permissions
|
|
30
|
-
* @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
|
|
31
|
-
* @permissionScope Picasso private app mega scope
|
|
32
|
-
* @permissionScopeId SCOPE.TEST.MEGA-PICASSO-MANAGE-SITE
|
|
33
|
-
* @applicableIdentity APP
|
|
34
|
-
* @applicableIdentity VISITOR
|
|
35
|
-
* @fqn com.wix.ecom.recommendations.v1.RecommendationsService.ListAvailableAlgorithms
|
|
36
|
-
*/
|
|
37
|
-
export async function listAvailableAlgorithms() {
|
|
38
|
-
// @ts-ignore
|
|
39
|
-
const { httpClient, sideEffects } = arguments[0];
|
|
40
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({});
|
|
41
|
-
const reqOpts = ambassadorWixEcomRecommendationsV1Recommendation.listAvailableAlgorithms(payload);
|
|
42
|
-
sideEffects?.onSiteCall?.();
|
|
43
|
-
try {
|
|
44
|
-
const result = await httpClient.request(reqOpts);
|
|
45
|
-
sideEffects?.onSuccess?.(result);
|
|
46
|
-
return renameKeysFromRESTResponseToSDKResponse(result.data);
|
|
47
|
-
}
|
|
48
|
-
catch (err) {
|
|
49
|
-
const transformedError = sdkTransformError(err, {
|
|
50
|
-
spreadPathsToArguments: {},
|
|
51
|
-
explicitPathsToArguments: {},
|
|
52
|
-
singleArgumentUnchanged: false,
|
|
53
|
-
}, []);
|
|
54
|
-
sideEffects?.onError?.(err);
|
|
55
|
-
throw transformedError;
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
/**
|
|
59
|
-
* Returns a recommendation object containing a list of items to recommend to the customer.
|
|
60
|
-
*
|
|
61
|
-
* `getRecommendation()` determines which items to recommend based on the given recommendation algorithms.
|
|
62
|
-
*
|
|
63
|
-
* `getRecommendation()` doesn’t run the algorithms. It calls the installed apps that provide them.
|
|
64
|
-
*
|
|
65
|
-
* Apps may provide algorithms for use with their own catalogs, or for use with catalogs from other apps.
|
|
66
|
-
* For example, Wix Stores provides algorithms that can only be used on its own catalogs.
|
|
67
|
-
* To run an algorithm, the app providing it must be installed, and an app providing a supported catalog must be installed.
|
|
68
|
-
* For more information and to see which algorithms are available on your site or project, call [`listAvailableAlgorithms()`](#listavailablealgorithms).
|
|
69
|
-
*
|
|
70
|
-
* `getRecommendation()` operates as follows:
|
|
71
|
-
* 1. `getRecommendation()` receives as input a list of algorithms as an array. These algorithms can be provided by different apps and can apply to different catalogs.
|
|
72
|
-
* 2. `getRecommendation()` calls the app that corresponds to the `appId` of the first algorithm in the list of algorithms. It passes that algorithm’s ID and the IDs of any subsequent algorithms in the array for the same app.
|
|
73
|
-
* 3. The app runs the algorithms.
|
|
74
|
-
* 4. `getRecommendation()` returns items recommendations from the first algorithm (according to its position in the `algorithms` array) that meets the minimum number of recommendations. At that point `getRecommendation()` stops calling other apps.
|
|
75
|
-
* 5. If none of the algorithms run by the first app meet the minimum recommended items, `getRecommendation()` finds the next algorithm in the array with a new `appId` (an ID of an app that has not yet been called), and repeats the process.
|
|
76
|
-
* 6. If no algorithms in the `algorithms` array recommend at least the minimum recommended items, `getRecommendation()` returns an empty array.
|
|
77
|
-
* @param algorithms - A list of algorithms checked in a specific order determined by their `appID` and their position in the `algorithms` array.
|
|
78
|
-
* See the method description for more information.
|
|
79
|
-
*
|
|
80
|
-
* If no algorithm is able to return at least `minimumRecommendedItems` items, an empty array is returned.
|
|
81
|
-
* @public
|
|
82
|
-
* @requiredField algorithms
|
|
83
|
-
* @requiredField algorithms._id
|
|
84
|
-
* @requiredField algorithms.appId
|
|
85
|
-
* @requiredField options.items.appId
|
|
86
|
-
* @requiredField options.items.catalogItemId
|
|
87
|
-
* @param options - Get recommendation options.
|
|
88
|
-
* @permissionId RECOMMENDATIONS.READ
|
|
89
|
-
* @permissionScope Manage Stores - all permissions
|
|
90
|
-
* @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
|
|
91
|
-
* @permissionScope Read eCommerce - all read permissions
|
|
92
|
-
* @permissionScopeId SCOPE.DC-ECOM-MEGA.READ-ECOM
|
|
93
|
-
* @permissionScope Manage eCommerce - all permissions
|
|
94
|
-
* @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
|
|
95
|
-
* @permissionScope Picasso private app mega scope
|
|
96
|
-
* @permissionScopeId SCOPE.TEST.MEGA-PICASSO-MANAGE-SITE
|
|
97
|
-
* @applicableIdentity APP
|
|
98
|
-
* @applicableIdentity VISITOR
|
|
99
|
-
* @fqn com.wix.ecom.recommendations.v1.RecommendationsService.GetRecommendation
|
|
100
|
-
*/
|
|
101
|
-
export async function getRecommendation(algorithms, options) {
|
|
102
|
-
// @ts-ignore
|
|
103
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
104
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
105
|
-
algorithms: algorithms,
|
|
106
|
-
items: options?.items,
|
|
107
|
-
minimumRecommendedItems: options?.minimumRecommendedItems,
|
|
108
|
-
});
|
|
109
|
-
const reqOpts = ambassadorWixEcomRecommendationsV1Recommendation.getRecommendation(payload);
|
|
110
|
-
sideEffects?.onSiteCall?.();
|
|
111
|
-
try {
|
|
112
|
-
const result = await httpClient.request(reqOpts);
|
|
113
|
-
sideEffects?.onSuccess?.(result);
|
|
114
|
-
return renameKeysFromRESTResponseToSDKResponse(result.data);
|
|
115
|
-
}
|
|
116
|
-
catch (err) {
|
|
117
|
-
const transformedError = sdkTransformError(err, {
|
|
118
|
-
spreadPathsToArguments: {},
|
|
119
|
-
explicitPathsToArguments: {
|
|
120
|
-
algorithms: '$[0]',
|
|
121
|
-
items: '$[1].items',
|
|
122
|
-
minimumRecommendedItems: '$[1].minimumRecommendedItems',
|
|
123
|
-
},
|
|
124
|
-
singleArgumentUnchanged: false,
|
|
125
|
-
}, ['algorithms', 'options']);
|
|
126
|
-
sideEffects?.onError?.(err);
|
|
127
|
-
throw transformedError;
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
//# sourceMappingURL=ecom-recommendations-v1-recommendation-recommendations.universal.js.map
|
package/build/es/src/ecom-recommendations-v1-recommendation-recommendations.universal.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ecom-recommendations-v1-recommendation-recommendations.universal.js","sourceRoot":"","sources":["../../../src/ecom-recommendations-v1-recommendation-recommendations.universal.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,IAAI,iBAAiB,EAAE,MAAM,kCAAkC,CAAC;AACvF,OAAO,EACL,qCAAqC,EACrC,uCAAuC,GACxC,MAAM,yCAAyC,CAAC;AAEjD,OAAO,KAAK,gDAAgD,MAAM,kEAAkE,CAAC;AAyHrI,MAAM,CAAN,IAAY,aAIX;AAJD,WAAY,aAAa;IACvB,4CAA2B,CAAA;IAC3B,gDAA+B,CAAA;IAC/B,kCAAiB,CAAA;AACnB,CAAC,EAJW,aAAa,KAAb,aAAa,QAIxB;AA8DD;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,MAAM,CAAC,KAAK,UAAU,uBAAuB;IAY3C,aAAa;IACb,MAAM,EAAE,UAAU,EAAE,WAAW,EAAE,GAAG,SAAS,CAAC,CAAC,CAG9C,CAAC;IAEF,MAAM,OAAO,GAAG,qCAAqC,CAAC,EAAE,CAAC,CAAC;IAE1D,MAAM,OAAO,GACX,gDAAgD,CAAC,uBAAuB,CACtE,OAAO,CACR,CAAC;IAEJ,WAAW,EAAE,UAAU,EAAE,EAAE,CAAC;IAC5B,IAAI,CAAC;QACH,MAAM,MAAM,GAAG,MAAM,UAAU,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;QACjD,WAAW,EAAE,SAAS,EAAE,CAAC,MAAM,CAAC,CAAC;QAEjC,OAAO,uCAAuC,CAAC,MAAM,CAAC,IAAI,CAAE,CAAC;IAC/D,CAAC;IAAC,OAAO,GAAQ,EAAE,CAAC;QAClB,MAAM,gBAAgB,GAAG,iBAAiB,CACxC,GAAG,EACH;YACE,sBAAsB,EAAE,EAAE;YAC1B,wBAAwB,EAAE,EAAE;YAC5B,uBAAuB,EAAE,KAAK;SAC/B,EACD,EAAE,CACH,CAAC;QACF,WAAW,EAAE,OAAO,EAAE,CAAC,GAAG,CAAC,CAAC;QAE5B,MAAM,gBAAgB,CAAC;IACzB,CAAC;AACH,CAAC;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0CG;AACH,MAAM,CAAC,KAAK,UAAU,iBAAiB,CACrC,UAA0D,EAC1D,OAGC;IASD,aAAa;IACb,MAAM,EAAE,UAAU,EAAE,WAAW,EAAE,GAAG,SAAS,CAAC,CAAC,CAG9C,CAAC;IAEF,MAAM,OAAO,GAAG,qCAAqC,CAAC;QACpD,UAAU,EAAE,UAAU;QACtB,KAAK,EAAE,OAAO,EAAE,KAAK;QACrB,uBAAuB,EAAE,OAAO,EAAE,uBAAuB;KAC1D,CAAC,CAAC;IAEH,MAAM,OAAO,GACX,gDAAgD,CAAC,iBAAiB,CAAC,OAAO,CAAC,CAAC;IAE9E,WAAW,EAAE,UAAU,EAAE,EAAE,CAAC;IAC5B,IAAI,CAAC;QACH,MAAM,MAAM,GAAG,MAAM,UAAU,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;QACjD,WAAW,EAAE,SAAS,EAAE,CAAC,MAAM,CAAC,CAAC;QAEjC,OAAO,uCAAuC,CAAC,MAAM,CAAC,IAAI,CAAE,CAAC;IAC/D,CAAC;IAAC,OAAO,GAAQ,EAAE,CAAC;QAClB,MAAM,gBAAgB,GAAG,iBAAiB,CACxC,GAAG,EACH;YACE,sBAAsB,EAAE,EAAE;YAC1B,wBAAwB,EAAE;gBACxB,UAAU,EAAE,MAAM;gBAClB,KAAK,EAAE,YAAY;gBACnB,uBAAuB,EAAE,8BAA8B;aACxD;YACD,uBAAuB,EAAE,KAAK;SAC/B,EACD,CAAC,YAAY,EAAE,SAAS,CAAC,CAC1B,CAAC;QACF,WAAW,EAAE,OAAO,EAAE,CAAC,GAAG,CAAC,CAAC;QAE5B,MAAM,gBAAgB,CAAC;IACzB,CAAC;AACH,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './src/ecom-recommendations-v1-recommendation-recommendations.context.js';
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./src/ecom-recommendations-v1-recommendation-recommendations.context.js"), exports);
|
|
18
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,0GAAwF"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './src/ecom-recommendations-v1-recommendation-recommendations.universal.js';
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./src/ecom-recommendations-v1-recommendation-recommendations.universal.js"), exports);
|
|
18
|
-
//# sourceMappingURL=index.typings.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.typings.js","sourceRoot":"","sources":["../../../index.typings.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,4GAA0F"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './src/ecom-recommendations-v1-recommendation-recommendations.meta.js';
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./src/ecom-recommendations-v1-recommendation-recommendations.meta.js"), exports);
|
|
18
|
-
//# sourceMappingURL=meta.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"meta.js","sourceRoot":"","sources":["../../../meta.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,uGAAqF"}
|
package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.context.d.ts
DELETED
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import { listAvailableAlgorithms as publicListAvailableAlgorithms, getRecommendation as publicGetRecommendation } from './ecom-recommendations-v1-recommendation-recommendations.public.js';
|
|
2
|
-
import { BuildRESTFunction, MaybeContext } from '@wix/sdk-types';
|
|
3
|
-
export declare const listAvailableAlgorithms: MaybeContext<BuildRESTFunction<typeof publicListAvailableAlgorithms> & typeof publicListAvailableAlgorithms>;
|
|
4
|
-
export declare const getRecommendation: MaybeContext<BuildRESTFunction<typeof publicGetRecommendation> & typeof publicGetRecommendation>;
|
|
5
|
-
export { AlgorithmType } from './ecom-recommendations-v1-recommendation-recommendations.universal.js';
|
|
6
|
-
export { Recommendation, CatalogReference, Algorithm, ListAvailableAlgorithmsRequest, ListAvailableAlgorithmsResponse, AlgorithmInfo, AlgorithmConfig, GetRecommendationRequest, GetRecommendationResponse, ItemAppIdNotSupportedByProvider, RecommendationAlgorithmNotSupported, GetRecommendationOptions, } from './ecom-recommendations-v1-recommendation-recommendations.universal.js';
|
package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.context.js
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.AlgorithmType = exports.getRecommendation = exports.listAvailableAlgorithms = void 0;
|
|
4
|
-
const ecom_recommendations_v1_recommendation_recommendations_public_js_1 = require("./ecom-recommendations-v1-recommendation-recommendations.public.js");
|
|
5
|
-
const rest_modules_1 = require("@wix/sdk-runtime/rest-modules");
|
|
6
|
-
exports.listAvailableAlgorithms = (0, rest_modules_1.createRESTModule)(ecom_recommendations_v1_recommendation_recommendations_public_js_1.listAvailableAlgorithms);
|
|
7
|
-
exports.getRecommendation = (0, rest_modules_1.createRESTModule)(ecom_recommendations_v1_recommendation_recommendations_public_js_1.getRecommendation);
|
|
8
|
-
var ecom_recommendations_v1_recommendation_recommendations_universal_js_1 = require("./ecom-recommendations-v1-recommendation-recommendations.universal.js");
|
|
9
|
-
Object.defineProperty(exports, "AlgorithmType", { enumerable: true, get: function () { return ecom_recommendations_v1_recommendation_recommendations_universal_js_1.AlgorithmType; } });
|
|
10
|
-
//# sourceMappingURL=ecom-recommendations-v1-recommendation-recommendations.context.js.map
|
package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.context.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ecom-recommendations-v1-recommendation-recommendations.context.js","sourceRoot":"","sources":["../../../../src/ecom-recommendations-v1-recommendation-recommendations.context.ts"],"names":[],"mappings":";;;AAAA,yJAG4E;AAC5E,gEAAiE;AAGpD,QAAA,uBAAuB,GAGlB,IAAA,+BAAgB,EAAC,0FAA6B,CAAC,CAAC;AACrD,QAAA,iBAAiB,GAGZ,IAAA,+BAAgB,EAAC,oFAAuB,CAAC,CAAC;AAE5D,6JAAsG;AAA7F,oKAAA,aAAa,OAAA"}
|
package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.http.d.ts
DELETED
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import { RequestOptionsFactory } from '@wix/sdk-types';
|
|
2
|
-
/**
|
|
3
|
-
* Returns a list of recommendation algorithms that can be used on your Wix site or project. These algorithms can be used with [`getRecommendation()`](#getRecommendation) to provide item recommendations to the customer.
|
|
4
|
-
*
|
|
5
|
-
* Algorithms are run by the apps that provide them, and can only be used on catalogs they support. Apps may provide algorithms for use with their own catalogs and/or catalogs from other apps.
|
|
6
|
-
*
|
|
7
|
-
* The app which provides an algorithm is referenced by that algorithm’s `appId`. The apps whose catalogs are supported by an algorithm are referenced by the IDs in that algorithm’s `catalogAppIds` array.
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
* For an algorithm to be considered “Available” and returned in this method’s response, the algorithm must meet the following conditions:
|
|
11
|
-
* 1. The algorithm’s `appId` must match the ID of an installed Wix app.
|
|
12
|
-
* 2. At least 1 of the IDs in `catalogAppIds` must match the ID of an installed Wix app.
|
|
13
|
-
*
|
|
14
|
-
* Wix app IDs are [listed here](https://dev.wix.com/api/rest/getting-started/wix-business-solutions#getting-started_wix-business-solutions_about-wix-business-solutions).
|
|
15
|
-
*/
|
|
16
|
-
export declare function listAvailableAlgorithms(payload: object): RequestOptionsFactory<any>;
|
|
17
|
-
/**
|
|
18
|
-
* Returns a recommendation object containing a list of items to recommend to the customer.
|
|
19
|
-
*
|
|
20
|
-
* `getRecommendation()` determines which items to recommend based on the given recommendation algorithms.
|
|
21
|
-
*
|
|
22
|
-
* `getRecommendation()` doesn’t run the algorithms. It calls the installed apps that provide them.
|
|
23
|
-
*
|
|
24
|
-
* Apps may provide algorithms for use with their own catalogs, or for use with catalogs from other apps.
|
|
25
|
-
* For example, Wix Stores provides algorithms that can only be used on its own catalogs.
|
|
26
|
-
* To run an algorithm, the app providing it must be installed, and an app providing a supported catalog must be installed.
|
|
27
|
-
* For more information and to see which algorithms are available on your site or project, call [`listAvailableAlgorithms()`](#listavailablealgorithms).
|
|
28
|
-
*
|
|
29
|
-
* `getRecommendation()` operates as follows:
|
|
30
|
-
* 1. `getRecommendation()` receives as input a list of algorithms as an array. These algorithms can be provided by different apps and can apply to different catalogs.
|
|
31
|
-
* 2. `getRecommendation()` calls the app that corresponds to the `appId` of the first algorithm in the list of algorithms. It passes that algorithm’s ID and the IDs of any subsequent algorithms in the array for the same app.
|
|
32
|
-
* 3. The app runs the algorithms.
|
|
33
|
-
* 4. `getRecommendation()` returns items recommendations from the first algorithm (according to its position in the `algorithms` array) that meets the minimum number of recommendations. At that point `getRecommendation()` stops calling other apps.
|
|
34
|
-
* 5. If none of the algorithms run by the first app meet the minimum recommended items, `getRecommendation()` finds the next algorithm in the array with a new `appId` (an ID of an app that has not yet been called), and repeats the process.
|
|
35
|
-
* 6. If no algorithms in the `algorithms` array recommend at least the minimum recommended items, `getRecommendation()` returns an empty array.
|
|
36
|
-
*/
|
|
37
|
-
export declare function getRecommendation(payload: object): RequestOptionsFactory<any>;
|
package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.http.js
DELETED
|
@@ -1,94 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getRecommendation = exports.listAvailableAlgorithms = void 0;
|
|
4
|
-
const rest_modules_1 = require("@wix/sdk-runtime/rest-modules");
|
|
5
|
-
const rest_modules_2 = require("@wix/sdk-runtime/rest-modules");
|
|
6
|
-
function resolveComWixEcomRecommendationsV1RecommendationsServiceUrl(opts) {
|
|
7
|
-
const domainToMappings = {
|
|
8
|
-
'www.wixapis.com': [
|
|
9
|
-
{
|
|
10
|
-
srcPath: '/v1/recommendations',
|
|
11
|
-
destPath: '/v1/recommendations',
|
|
12
|
-
},
|
|
13
|
-
{
|
|
14
|
-
srcPath: '/ecom/v1/recommendations',
|
|
15
|
-
destPath: '/v1/recommendations',
|
|
16
|
-
},
|
|
17
|
-
],
|
|
18
|
-
};
|
|
19
|
-
return (0, rest_modules_2.resolveUrl)(Object.assign(opts, { domainToMappings }));
|
|
20
|
-
}
|
|
21
|
-
const PACKAGE_NAME = '@wix/auto_sdk_ecom_recommendations';
|
|
22
|
-
/**
|
|
23
|
-
* Returns a list of recommendation algorithms that can be used on your Wix site or project. These algorithms can be used with [`getRecommendation()`](#getRecommendation) to provide item recommendations to the customer.
|
|
24
|
-
*
|
|
25
|
-
* Algorithms are run by the apps that provide them, and can only be used on catalogs they support. Apps may provide algorithms for use with their own catalogs and/or catalogs from other apps.
|
|
26
|
-
*
|
|
27
|
-
* The app which provides an algorithm is referenced by that algorithm’s `appId`. The apps whose catalogs are supported by an algorithm are referenced by the IDs in that algorithm’s `catalogAppIds` array.
|
|
28
|
-
*
|
|
29
|
-
*
|
|
30
|
-
* For an algorithm to be considered “Available” and returned in this method’s response, the algorithm must meet the following conditions:
|
|
31
|
-
* 1. The algorithm’s `appId` must match the ID of an installed Wix app.
|
|
32
|
-
* 2. At least 1 of the IDs in `catalogAppIds` must match the ID of an installed Wix app.
|
|
33
|
-
*
|
|
34
|
-
* Wix app IDs are [listed here](https://dev.wix.com/api/rest/getting-started/wix-business-solutions#getting-started_wix-business-solutions_about-wix-business-solutions).
|
|
35
|
-
*/
|
|
36
|
-
function listAvailableAlgorithms(payload) {
|
|
37
|
-
function __listAvailableAlgorithms({ host }) {
|
|
38
|
-
const metadata = {
|
|
39
|
-
entityFqdn: 'wix.ecom.recommendations.v1.recommendation',
|
|
40
|
-
method: 'GET',
|
|
41
|
-
methodFqn: 'com.wix.ecom.recommendations.v1.RecommendationsService.ListAvailableAlgorithms',
|
|
42
|
-
packageName: PACKAGE_NAME,
|
|
43
|
-
url: resolveComWixEcomRecommendationsV1RecommendationsServiceUrl({
|
|
44
|
-
protoPath: '/v1/recommendations/algorithms',
|
|
45
|
-
data: payload,
|
|
46
|
-
host,
|
|
47
|
-
}),
|
|
48
|
-
params: (0, rest_modules_1.toURLSearchParams)(payload),
|
|
49
|
-
};
|
|
50
|
-
return metadata;
|
|
51
|
-
}
|
|
52
|
-
return __listAvailableAlgorithms;
|
|
53
|
-
}
|
|
54
|
-
exports.listAvailableAlgorithms = listAvailableAlgorithms;
|
|
55
|
-
/**
|
|
56
|
-
* Returns a recommendation object containing a list of items to recommend to the customer.
|
|
57
|
-
*
|
|
58
|
-
* `getRecommendation()` determines which items to recommend based on the given recommendation algorithms.
|
|
59
|
-
*
|
|
60
|
-
* `getRecommendation()` doesn’t run the algorithms. It calls the installed apps that provide them.
|
|
61
|
-
*
|
|
62
|
-
* Apps may provide algorithms for use with their own catalogs, or for use with catalogs from other apps.
|
|
63
|
-
* For example, Wix Stores provides algorithms that can only be used on its own catalogs.
|
|
64
|
-
* To run an algorithm, the app providing it must be installed, and an app providing a supported catalog must be installed.
|
|
65
|
-
* For more information and to see which algorithms are available on your site or project, call [`listAvailableAlgorithms()`](#listavailablealgorithms).
|
|
66
|
-
*
|
|
67
|
-
* `getRecommendation()` operates as follows:
|
|
68
|
-
* 1. `getRecommendation()` receives as input a list of algorithms as an array. These algorithms can be provided by different apps and can apply to different catalogs.
|
|
69
|
-
* 2. `getRecommendation()` calls the app that corresponds to the `appId` of the first algorithm in the list of algorithms. It passes that algorithm’s ID and the IDs of any subsequent algorithms in the array for the same app.
|
|
70
|
-
* 3. The app runs the algorithms.
|
|
71
|
-
* 4. `getRecommendation()` returns items recommendations from the first algorithm (according to its position in the `algorithms` array) that meets the minimum number of recommendations. At that point `getRecommendation()` stops calling other apps.
|
|
72
|
-
* 5. If none of the algorithms run by the first app meet the minimum recommended items, `getRecommendation()` finds the next algorithm in the array with a new `appId` (an ID of an app that has not yet been called), and repeats the process.
|
|
73
|
-
* 6. If no algorithms in the `algorithms` array recommend at least the minimum recommended items, `getRecommendation()` returns an empty array.
|
|
74
|
-
*/
|
|
75
|
-
function getRecommendation(payload) {
|
|
76
|
-
function __getRecommendation({ host }) {
|
|
77
|
-
const metadata = {
|
|
78
|
-
entityFqdn: 'wix.ecom.recommendations.v1.recommendation',
|
|
79
|
-
method: 'POST',
|
|
80
|
-
methodFqn: 'com.wix.ecom.recommendations.v1.RecommendationsService.GetRecommendation',
|
|
81
|
-
packageName: PACKAGE_NAME,
|
|
82
|
-
url: resolveComWixEcomRecommendationsV1RecommendationsServiceUrl({
|
|
83
|
-
protoPath: '/v1/recommendations/get',
|
|
84
|
-
data: payload,
|
|
85
|
-
host,
|
|
86
|
-
}),
|
|
87
|
-
data: payload,
|
|
88
|
-
};
|
|
89
|
-
return metadata;
|
|
90
|
-
}
|
|
91
|
-
return __getRecommendation;
|
|
92
|
-
}
|
|
93
|
-
exports.getRecommendation = getRecommendation;
|
|
94
|
-
//# sourceMappingURL=ecom-recommendations-v1-recommendation-recommendations.http.js.map
|
package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.http.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ecom-recommendations-v1-recommendation-recommendations.http.js","sourceRoot":"","sources":["../../../../src/ecom-recommendations-v1-recommendation-recommendations.http.ts"],"names":[],"mappings":";;;AAAA,gEAAkE;AAClE,gEAA2D;AAI3D,SAAS,2DAA2D,CAClE,IAA8C;IAE9C,MAAM,gBAAgB,GAAG;QACvB,iBAAiB,EAAE;YACjB;gBACE,OAAO,EAAE,qBAAqB;gBAC9B,QAAQ,EAAE,qBAAqB;aAChC;YACD;gBACE,OAAO,EAAE,0BAA0B;gBACnC,QAAQ,EAAE,qBAAqB;aAChC;SACF;KACF,CAAC;IAEF,OAAO,IAAA,yBAAU,EAAC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,EAAE,gBAAgB,EAAE,CAAC,CAAC,CAAC;AAC/D,CAAC;AAED,MAAM,YAAY,GAAG,oCAAoC,CAAC;AAE1D;;;;;;;;;;;;;GAaG;AACH,SAAgB,uBAAuB,CACrC,OAAe;IAEf,SAAS,yBAAyB,CAAC,EAAE,IAAI,EAAO;QAC9C,MAAM,QAAQ,GAAG;YACf,UAAU,EAAE,4CAA4C;YACxD,MAAM,EAAE,KAAY;YACpB,SAAS,EACP,gFAAgF;YAClF,WAAW,EAAE,YAAY;YACzB,GAAG,EAAE,2DAA2D,CAAC;gBAC/D,SAAS,EAAE,gCAAgC;gBAC3C,IAAI,EAAE,OAAO;gBACb,IAAI;aACL,CAAC;YACF,MAAM,EAAE,IAAA,gCAAiB,EAAC,OAAO,CAAC;SACnC,CAAC;QAEF,OAAO,QAAQ,CAAC;IAClB,CAAC;IAED,OAAO,yBAAyB,CAAC;AACnC,CAAC;AAtBD,0DAsBC;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,SAAgB,iBAAiB,CAAC,OAAe;IAC/C,SAAS,mBAAmB,CAAC,EAAE,IAAI,EAAO;QACxC,MAAM,QAAQ,GAAG;YACf,UAAU,EAAE,4CAA4C;YACxD,MAAM,EAAE,MAAa;YACrB,SAAS,EACP,0EAA0E;YAC5E,WAAW,EAAE,YAAY;YACzB,GAAG,EAAE,2DAA2D,CAAC;gBAC/D,SAAS,EAAE,yBAAyB;gBACpC,IAAI,EAAE,OAAO;gBACb,IAAI;aACL,CAAC;YACF,IAAI,EAAE,OAAO;SACd,CAAC;QAEF,OAAO,QAAQ,CAAC;IAClB,CAAC;IAED,OAAO,mBAAmB,CAAC;AAC7B,CAAC;AApBD,8CAoBC"}
|
package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.meta.d.ts
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import * as ambassadorWixEcomRecommendationsV1RecommendationTypes from './ecom-recommendations-v1-recommendation-recommendations.types.js';
|
|
2
|
-
import * as ambassadorWixEcomRecommendationsV1RecommendationUniversalTypes from './ecom-recommendations-v1-recommendation-recommendations.universal.js';
|
|
3
|
-
export type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
|
|
4
|
-
getUrl: (context: any) => string;
|
|
5
|
-
httpMethod: K;
|
|
6
|
-
path: string;
|
|
7
|
-
pathParams: M;
|
|
8
|
-
__requestType: T;
|
|
9
|
-
__originalRequestType: S;
|
|
10
|
-
__responseType: Q;
|
|
11
|
-
__originalResponseType: R;
|
|
12
|
-
};
|
|
13
|
-
export declare function listAvailableAlgorithms(): __PublicMethodMetaInfo<'GET', {}, ambassadorWixEcomRecommendationsV1RecommendationUniversalTypes.ListAvailableAlgorithmsRequest, ambassadorWixEcomRecommendationsV1RecommendationTypes.ListAvailableAlgorithmsRequest, ambassadorWixEcomRecommendationsV1RecommendationUniversalTypes.ListAvailableAlgorithmsResponse, ambassadorWixEcomRecommendationsV1RecommendationTypes.ListAvailableAlgorithmsResponse>;
|
|
14
|
-
export declare function getRecommendation(): __PublicMethodMetaInfo<'POST', {}, ambassadorWixEcomRecommendationsV1RecommendationUniversalTypes.GetRecommendationRequest, ambassadorWixEcomRecommendationsV1RecommendationTypes.GetRecommendationRequest, ambassadorWixEcomRecommendationsV1RecommendationUniversalTypes.GetRecommendationResponse, ambassadorWixEcomRecommendationsV1RecommendationTypes.GetRecommendationResponse>;
|
package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.meta.js
DELETED
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
-
if (mod && mod.__esModule) return mod;
|
|
20
|
-
var result = {};
|
|
21
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
-
__setModuleDefault(result, mod);
|
|
23
|
-
return result;
|
|
24
|
-
};
|
|
25
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
-
exports.getRecommendation = exports.listAvailableAlgorithms = void 0;
|
|
27
|
-
const ambassadorWixEcomRecommendationsV1Recommendation = __importStar(require("./ecom-recommendations-v1-recommendation-recommendations.http.js"));
|
|
28
|
-
function listAvailableAlgorithms() {
|
|
29
|
-
const payload = {};
|
|
30
|
-
const getRequestOptions = ambassadorWixEcomRecommendationsV1Recommendation.listAvailableAlgorithms(payload);
|
|
31
|
-
const getUrl = (context) => {
|
|
32
|
-
const { url } = getRequestOptions(context);
|
|
33
|
-
return url;
|
|
34
|
-
};
|
|
35
|
-
return {
|
|
36
|
-
getUrl,
|
|
37
|
-
httpMethod: 'GET',
|
|
38
|
-
path: '/v1/recommendations/algorithms',
|
|
39
|
-
pathParams: {},
|
|
40
|
-
__requestType: null,
|
|
41
|
-
__originalRequestType: null,
|
|
42
|
-
__responseType: null,
|
|
43
|
-
__originalResponseType: null,
|
|
44
|
-
};
|
|
45
|
-
}
|
|
46
|
-
exports.listAvailableAlgorithms = listAvailableAlgorithms;
|
|
47
|
-
function getRecommendation() {
|
|
48
|
-
const payload = {};
|
|
49
|
-
const getRequestOptions = ambassadorWixEcomRecommendationsV1Recommendation.getRecommendation(payload);
|
|
50
|
-
const getUrl = (context) => {
|
|
51
|
-
const { url } = getRequestOptions(context);
|
|
52
|
-
return url;
|
|
53
|
-
};
|
|
54
|
-
return {
|
|
55
|
-
getUrl,
|
|
56
|
-
httpMethod: 'POST',
|
|
57
|
-
path: '/v1/recommendations/get',
|
|
58
|
-
pathParams: {},
|
|
59
|
-
__requestType: null,
|
|
60
|
-
__originalRequestType: null,
|
|
61
|
-
__responseType: null,
|
|
62
|
-
__originalResponseType: null,
|
|
63
|
-
};
|
|
64
|
-
}
|
|
65
|
-
exports.getRecommendation = getRecommendation;
|
|
66
|
-
//# sourceMappingURL=ecom-recommendations-v1-recommendation-recommendations.meta.js.map
|
package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.meta.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ecom-recommendations-v1-recommendation-recommendations.meta.js","sourceRoot":"","sources":["../../../../src/ecom-recommendations-v1-recommendation-recommendations.meta.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,mJAAqI;AAsBrI,SAAgB,uBAAuB;IAQrC,MAAM,OAAO,GAAG,EAAS,CAAC;IAE1B,MAAM,iBAAiB,GACrB,gDAAgD,CAAC,uBAAuB,CACtE,OAAO,CACR,CAAC;IAEJ,MAAM,MAAM,GAAG,CAAC,OAAY,EAAU,EAAE;QACtC,MAAM,EAAE,GAAG,EAAE,GAAG,iBAAiB,CAAC,OAAO,CAAC,CAAC;QAC3C,OAAO,GAAI,CAAC;IACd,CAAC,CAAC;IAEF,OAAO;QACL,MAAM;QACN,UAAU,EAAE,KAAK;QACjB,IAAI,EAAE,gCAAgC;QACtC,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,IAAW;QAC1B,qBAAqB,EAAE,IAAW;QAClC,cAAc,EAAE,IAAW;QAC3B,sBAAsB,EAAE,IAAW;KACpC,CAAC;AACJ,CAAC;AA9BD,0DA8BC;AAED,SAAgB,iBAAiB;IAQ/B,MAAM,OAAO,GAAG,EAAS,CAAC;IAE1B,MAAM,iBAAiB,GACrB,gDAAgD,CAAC,iBAAiB,CAAC,OAAO,CAAC,CAAC;IAE9E,MAAM,MAAM,GAAG,CAAC,OAAY,EAAU,EAAE;QACtC,MAAM,EAAE,GAAG,EAAE,GAAG,iBAAiB,CAAC,OAAO,CAAC,CAAC;QAC3C,OAAO,GAAI,CAAC;IACd,CAAC,CAAC;IAEF,OAAO;QACL,MAAM;QACN,UAAU,EAAE,MAAM;QAClB,IAAI,EAAE,yBAAyB;QAC/B,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,IAAW;QAC1B,qBAAqB,EAAE,IAAW;QAClC,cAAc,EAAE,IAAW;QAC3B,sBAAsB,EAAE,IAAW;KACpC,CAAC;AACJ,CAAC;AA5BD,8CA4BC"}
|
package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.public.js
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.AlgorithmType = exports.getRecommendation = exports.listAvailableAlgorithms = exports.__metadata = void 0;
|
|
4
|
-
const ecom_recommendations_v1_recommendation_recommendations_universal_js_1 = require("./ecom-recommendations-v1-recommendation-recommendations.universal.js");
|
|
5
|
-
exports.__metadata = { PACKAGE_NAME: '@wix/ecom' };
|
|
6
|
-
function listAvailableAlgorithms(httpClient) {
|
|
7
|
-
return () => (0, ecom_recommendations_v1_recommendation_recommendations_universal_js_1.listAvailableAlgorithms)(
|
|
8
|
-
// @ts-ignore
|
|
9
|
-
{ httpClient });
|
|
10
|
-
}
|
|
11
|
-
exports.listAvailableAlgorithms = listAvailableAlgorithms;
|
|
12
|
-
function getRecommendation(httpClient) {
|
|
13
|
-
return (algorithms, options) => (0, ecom_recommendations_v1_recommendation_recommendations_universal_js_1.getRecommendation)(algorithms, options,
|
|
14
|
-
// @ts-ignore
|
|
15
|
-
{ httpClient });
|
|
16
|
-
}
|
|
17
|
-
exports.getRecommendation = getRecommendation;
|
|
18
|
-
var ecom_recommendations_v1_recommendation_recommendations_universal_js_2 = require("./ecom-recommendations-v1-recommendation-recommendations.universal.js");
|
|
19
|
-
Object.defineProperty(exports, "AlgorithmType", { enumerable: true, get: function () { return ecom_recommendations_v1_recommendation_recommendations_universal_js_2.AlgorithmType; } });
|
|
20
|
-
//# sourceMappingURL=ecom-recommendations-v1-recommendation-recommendations.public.js.map
|
package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.public.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ecom-recommendations-v1-recommendation-recommendations.public.js","sourceRoot":"","sources":["../../../../src/ecom-recommendations-v1-recommendation-recommendations.public.ts"],"names":[],"mappings":";;;AACA,+JAO+E;AAElE,QAAA,UAAU,GAAG,EAAE,YAAY,EAAE,WAAW,EAAE,CAAC;AAExD,SAAgB,uBAAuB,CACrC,UAAsB;IAEtB,OAAO,GAAG,EAAE,CACV,IAAA,6FAAgC;IAC9B,aAAa;IACb,EAAE,UAAU,EAAE,CACf,CAAC;AACN,CAAC;AARD,0DAQC;AAoBD,SAAgB,iBAAiB,CAC/B,UAAsB;IAEtB,OAAO,CACL,UAA0D,EAC1D,OAGC,EACD,EAAE,CACF,IAAA,uFAA0B,EACxB,UAAU,EACV,OAAO;IACP,aAAa;IACb,EAAE,UAAU,EAAE,CACf,CAAC;AACN,CAAC;AAhBD,8CAgBC;AAkCD,6JAc+E;AAV7E,oKAAA,aAAa,OAAA"}
|
package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.types.js
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.AlgorithmType = void 0;
|
|
4
|
-
var AlgorithmType;
|
|
5
|
-
(function (AlgorithmType) {
|
|
6
|
-
AlgorithmType["UNSPECIFIED"] = "UNSPECIFIED";
|
|
7
|
-
AlgorithmType["RELATED_ITEMS"] = "RELATED_ITEMS";
|
|
8
|
-
AlgorithmType["GLOBAL"] = "GLOBAL";
|
|
9
|
-
})(AlgorithmType || (exports.AlgorithmType = AlgorithmType = {}));
|
|
10
|
-
//# sourceMappingURL=ecom-recommendations-v1-recommendation-recommendations.types.js.map
|
package/build/internal/cjs/src/ecom-recommendations-v1-recommendation-recommendations.types.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ecom-recommendations-v1-recommendation-recommendations.types.js","sourceRoot":"","sources":["../../../../src/ecom-recommendations-v1-recommendation-recommendations.types.ts"],"names":[],"mappings":";;;AAuHA,IAAY,aAIX;AAJD,WAAY,aAAa;IACvB,4CAA2B,CAAA;IAC3B,gDAA+B,CAAA;IAC/B,kCAAiB,CAAA;AACnB,CAAC,EAJW,aAAa,6BAAb,aAAa,QAIxB"}
|