@wix/pricing-plans 1.0.53 → 1.0.55

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (97) hide show
  1. package/build/cjs/context.d.ts +2 -2
  2. package/build/cjs/context.js +2 -2
  3. package/build/cjs/context.js.map +1 -1
  4. package/build/cjs/index.d.ts +2 -2
  5. package/build/cjs/index.js +2 -2
  6. package/build/cjs/index.js.map +1 -1
  7. package/build/cjs/meta.d.ts +2 -2
  8. package/build/cjs/meta.js +2 -2
  9. package/build/cjs/meta.js.map +1 -1
  10. package/build/es/context.d.ts +2 -2
  11. package/build/es/context.js +2 -2
  12. package/build/es/context.js.map +1 -1
  13. package/build/es/index.d.ts +2 -2
  14. package/build/es/index.js +2 -2
  15. package/build/es/index.js.map +1 -1
  16. package/build/es/meta.d.ts +2 -2
  17. package/build/es/meta.js +2 -2
  18. package/build/es/meta.js.map +1 -1
  19. package/package.json +12 -9
  20. package/build/cjs/index.typings.d.ts +0 -2
  21. package/build/cjs/index.typings.js +0 -29
  22. package/build/cjs/index.typings.js.map +0 -1
  23. package/build/cjs/src/pricing-plans-v2-order.context.d.ts +0 -15
  24. package/build/cjs/src/pricing-plans-v2-order.context.js +0 -148
  25. package/build/cjs/src/pricing-plans-v2-order.context.js.map +0 -1
  26. package/build/cjs/src/pricing-plans-v2-order.http.d.ts +0 -165
  27. package/build/cjs/src/pricing-plans-v2-order.http.js +0 -818
  28. package/build/cjs/src/pricing-plans-v2-order.http.js.map +0 -1
  29. package/build/cjs/src/pricing-plans-v2-order.meta.d.ts +0 -41
  30. package/build/cjs/src/pricing-plans-v2-order.meta.js +0 -275
  31. package/build/cjs/src/pricing-plans-v2-order.meta.js.map +0 -1
  32. package/build/cjs/src/pricing-plans-v2-order.public.d.ts +0 -103
  33. package/build/cjs/src/pricing-plans-v2-order.public.js +0 -96
  34. package/build/cjs/src/pricing-plans-v2-order.public.js.map +0 -1
  35. package/build/cjs/src/pricing-plans-v2-order.types.d.ts +0 -1801
  36. package/build/cjs/src/pricing-plans-v2-order.types.js +0 -135
  37. package/build/cjs/src/pricing-plans-v2-order.types.js.map +0 -1
  38. package/build/cjs/src/pricing-plans-v2-order.universal.d.ts +0 -2203
  39. package/build/cjs/src/pricing-plans-v2-order.universal.js +0 -1137
  40. package/build/cjs/src/pricing-plans-v2-order.universal.js.map +0 -1
  41. package/build/cjs/src/pricing-plans-v2-plan.context.d.ts +0 -14
  42. package/build/cjs/src/pricing-plans-v2-plan.context.js +0 -137
  43. package/build/cjs/src/pricing-plans-v2-plan.context.js.map +0 -1
  44. package/build/cjs/src/pricing-plans-v2-plan.http.d.ts +0 -134
  45. package/build/cjs/src/pricing-plans-v2-plan.http.js +0 -544
  46. package/build/cjs/src/pricing-plans-v2-plan.http.js.map +0 -1
  47. package/build/cjs/src/pricing-plans-v2-plan.meta.d.ts +0 -34
  48. package/build/cjs/src/pricing-plans-v2-plan.meta.js +0 -256
  49. package/build/cjs/src/pricing-plans-v2-plan.meta.js.map +0 -1
  50. package/build/cjs/src/pricing-plans-v2-plan.public.d.ts +0 -85
  51. package/build/cjs/src/pricing-plans-v2-plan.public.js +0 -84
  52. package/build/cjs/src/pricing-plans-v2-plan.public.js.map +0 -1
  53. package/build/cjs/src/pricing-plans-v2-plan.types.d.ts +0 -732
  54. package/build/cjs/src/pricing-plans-v2-plan.types.js +0 -41
  55. package/build/cjs/src/pricing-plans-v2-plan.types.js.map +0 -1
  56. package/build/cjs/src/pricing-plans-v2-plan.universal.d.ts +0 -1163
  57. package/build/cjs/src/pricing-plans-v2-plan.universal.js +0 -908
  58. package/build/cjs/src/pricing-plans-v2-plan.universal.js.map +0 -1
  59. package/build/es/index.typings.d.ts +0 -2
  60. package/build/es/index.typings.js +0 -3
  61. package/build/es/index.typings.js.map +0 -1
  62. package/build/es/src/pricing-plans-v2-order.context.d.ts +0 -15
  63. package/build/es/src/pricing-plans-v2-order.context.js +0 -132
  64. package/build/es/src/pricing-plans-v2-order.context.js.map +0 -1
  65. package/build/es/src/pricing-plans-v2-order.http.d.ts +0 -165
  66. package/build/es/src/pricing-plans-v2-order.http.js +0 -802
  67. package/build/es/src/pricing-plans-v2-order.http.js.map +0 -1
  68. package/build/es/src/pricing-plans-v2-order.meta.d.ts +0 -41
  69. package/build/es/src/pricing-plans-v2-order.meta.js +0 -236
  70. package/build/es/src/pricing-plans-v2-order.meta.js.map +0 -1
  71. package/build/es/src/pricing-plans-v2-order.public.d.ts +0 -103
  72. package/build/es/src/pricing-plans-v2-order.public.js +0 -69
  73. package/build/es/src/pricing-plans-v2-order.public.js.map +0 -1
  74. package/build/es/src/pricing-plans-v2-order.types.d.ts +0 -1801
  75. package/build/es/src/pricing-plans-v2-order.types.js +0 -132
  76. package/build/es/src/pricing-plans-v2-order.types.js.map +0 -1
  77. package/build/es/src/pricing-plans-v2-order.universal.d.ts +0 -2203
  78. package/build/es/src/pricing-plans-v2-order.universal.js +0 -1098
  79. package/build/es/src/pricing-plans-v2-order.universal.js.map +0 -1
  80. package/build/es/src/pricing-plans-v2-plan.context.d.ts +0 -14
  81. package/build/es/src/pricing-plans-v2-plan.context.js +0 -122
  82. package/build/es/src/pricing-plans-v2-plan.context.js.map +0 -1
  83. package/build/es/src/pricing-plans-v2-plan.http.d.ts +0 -134
  84. package/build/es/src/pricing-plans-v2-plan.http.js +0 -529
  85. package/build/es/src/pricing-plans-v2-plan.http.js.map +0 -1
  86. package/build/es/src/pricing-plans-v2-plan.meta.d.ts +0 -34
  87. package/build/es/src/pricing-plans-v2-plan.meta.js +0 -218
  88. package/build/es/src/pricing-plans-v2-plan.meta.js.map +0 -1
  89. package/build/es/src/pricing-plans-v2-plan.public.d.ts +0 -85
  90. package/build/es/src/pricing-plans-v2-plan.public.js +0 -64
  91. package/build/es/src/pricing-plans-v2-plan.public.js.map +0 -1
  92. package/build/es/src/pricing-plans-v2-plan.types.d.ts +0 -732
  93. package/build/es/src/pricing-plans-v2-plan.types.js +0 -38
  94. package/build/es/src/pricing-plans-v2-plan.types.js.map +0 -1
  95. package/build/es/src/pricing-plans-v2-plan.universal.d.ts +0 -1163
  96. package/build/es/src/pricing-plans-v2-plan.universal.js +0 -870
  97. package/build/es/src/pricing-plans-v2-plan.universal.js.map +0 -1
@@ -1,870 +0,0 @@
1
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
- return new (P || (P = Promise))(function (resolve, reject) {
4
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
- step((generator = generator.apply(thisArg, _arguments || [])).next());
8
- });
9
- };
10
- import { serializer, transformError, resolveQueryFieldsTransformationPaths, } from '@wix/metro-runtime/velo';
11
- import { transformError as sdkTransformError } from '@wix/sdk-runtime/transform-error';
12
- import * as ambassadorWixPricingPlansV2Plan from './pricing-plans-v2-plan.http';
13
- // @ts-ignore
14
- import { wrapWithQueryBuilder } from '@wix/motion-edm-autogen-query-wrapper';
15
- const _toVeloEntity = '$';
16
- const _fromVeloEntity = '$';
17
- export var PeriodUnit;
18
- (function (PeriodUnit) {
19
- PeriodUnit["UNDEFINED"] = "UNDEFINED";
20
- PeriodUnit["DAY"] = "DAY";
21
- PeriodUnit["WEEK"] = "WEEK";
22
- PeriodUnit["MONTH"] = "MONTH";
23
- PeriodUnit["YEAR"] = "YEAR";
24
- })(PeriodUnit || (PeriodUnit = {}));
25
- export var AppliedAt;
26
- (function (AppliedAt) {
27
- AppliedAt["UNKNOWN_CHARGE_EVENT"] = "UNKNOWN_CHARGE_EVENT";
28
- /** Will charge the fee on first payment. If order has a free trial meaning it will charge after the free trial. */
29
- AppliedAt["FIRST_PAYMENT"] = "FIRST_PAYMENT";
30
- })(AppliedAt || (AppliedAt = {}));
31
- export var SortOrder;
32
- (function (SortOrder) {
33
- SortOrder["ASC"] = "ASC";
34
- SortOrder["DESC"] = "DESC";
35
- })(SortOrder || (SortOrder = {}));
36
- export var ArchivedFilter;
37
- (function (ArchivedFilter) {
38
- /** Returns all plans that are active. */
39
- ArchivedFilter["ACTIVE"] = "ACTIVE";
40
- /** Returns all plans that are archived. */
41
- ArchivedFilter["ARCHIVED"] = "ARCHIVED";
42
- /** Returns all plans that are active and archived. */
43
- ArchivedFilter["ARCHIVED_AND_ACTIVE"] = "ARCHIVED_AND_ACTIVE";
44
- })(ArchivedFilter || (ArchivedFilter = {}));
45
- export var PublicFilter;
46
- (function (PublicFilter) {
47
- /** Returns all public and hidden plans. */
48
- PublicFilter["PUBLIC_AND_HIDDEN"] = "PUBLIC_AND_HIDDEN";
49
- /** Returns only public plans. */
50
- PublicFilter["PUBLIC"] = "PUBLIC";
51
- /** Returns only hidden plans. */
52
- PublicFilter["HIDDEN"] = "HIDDEN";
53
- })(PublicFilter || (PublicFilter = {}));
54
- const _archivePlanRequest = {};
55
- const _archivePlanResponse = {};
56
- const _arrangePlansRequest = {};
57
- const _arrangePlansResponse = {};
58
- const _clearPrimaryRequest = {};
59
- const _clearPrimaryResponse = {};
60
- const _createPlanRequest = {};
61
- const _createPlanResponse = {};
62
- const _getPlanRequest = {};
63
- const _getPlanResponse = {};
64
- const _getPlanStatsRequest = {};
65
- const _getPlanStatsResponse = {};
66
- const _listPlansRequest = {};
67
- const _listPlansResponse = {};
68
- const _listPublicPlansRequest = {};
69
- const _listPublicPlansResponse = {};
70
- const _makePlanPrimaryRequest = {};
71
- const _makePlanPrimaryResponse = {};
72
- const _queryPublicPlansRequest = {};
73
- const _queryPublicPlansResponse = {};
74
- const _setPlanVisibilityRequest = {};
75
- const _setPlanVisibilityResponse = {};
76
- const _updatePlanRequest = {};
77
- const _updatePlanResponse = {};
78
- /**
79
- * Retrieves a list of public pricing plans.
80
- *
81
- *
82
- * The `listPublicPlans()` function returns a Promise that resolves to a list of up to 100 public pricing plans. Public plans are visible plans that site visitors can see on the site and purchase.
83
- * @public
84
- * @param options - Options for filtering and paging the list of public plans.
85
- * @permissionScope Read Pricing Plans
86
- * @permissionScopeId SCOPE.DC-PAIDPLANS.READ-PLANS
87
- * @permissionScope Manage Orders
88
- * @permissionScopeId SCOPE.DC-PAIDPLANS.MANAGE-ORDERS
89
- * @permissionScope Manage Bookings Services and Settings
90
- * @permissionScopeId SCOPE.BOOKINGS.CONFIGURATION
91
- * @permissionScope Read Orders
92
- * @permissionScopeId SCOPE.DC-PAIDPLANS.READ-ORDERS
93
- * @permissionScope Manage Pricing Plans
94
- * @permissionScopeId SCOPE.DC-PAIDPLANS.MANAGE-PLANS
95
- * @applicableIdentity APP
96
- * @applicableIdentity MEMBER
97
- * @applicableIdentity VISITOR
98
- * @returns Fulfilled - List of public pricing plans.
99
- */
100
- export function listPublicPlans(options) {
101
- var _a, _b, _c;
102
- return __awaiter(this, arguments, void 0, function* () {
103
- const requestTransformation = {
104
- limit: '$[0].limit',
105
- offset: '$[0].offset',
106
- planIds: '$[0].planIds',
107
- };
108
- const responseTransformation = '$';
109
- // @ts-ignore
110
- const { httpClient, sideEffects } = arguments[1];
111
- const { toAmbassadorRequest } = serializer({
112
- rootSchema: _listPublicPlansRequest,
113
- depSchemas: {},
114
- fqdnTransformation: {
115
- paths: [],
116
- transformation: _fromVeloEntity,
117
- },
118
- customTransformation: requestTransformation,
119
- });
120
- const { fromJSON } = serializer({
121
- rootSchema: _listPublicPlansResponse,
122
- depSchemas: {},
123
- fqdnTransformation: {
124
- paths: [],
125
- transformation: _toVeloEntity,
126
- },
127
- customTransformation: responseTransformation,
128
- });
129
- const payload = toAmbassadorRequest([options]);
130
- const reqOpts = ambassadorWixPricingPlansV2Plan.listPublicPlans(payload);
131
- (_a = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSiteCall) === null || _a === void 0 ? void 0 : _a.call(sideEffects);
132
- try {
133
- const result = yield httpClient.request(reqOpts);
134
- (_b = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSuccess) === null || _b === void 0 ? void 0 : _b.call(sideEffects, result);
135
- return fromJSON(result.data);
136
- }
137
- catch (err) {
138
- const transformedError = sdkTransformError(err, {
139
- spreadPathsToArguments: {},
140
- explicitPathsToArguments: {
141
- limit: '$[0].limit',
142
- offset: '$[0].offset',
143
- planIds: '$[0].planIds',
144
- },
145
- singleArgumentUnchanged: false,
146
- }, ['options']);
147
- (_c = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onError) === null || _c === void 0 ? void 0 : _c.call(sideEffects, err);
148
- throw transformedError;
149
- }
150
- });
151
- }
152
- /**
153
- * Creates a query to retrieve a list of public pricing plans.
154
- *
155
- *
156
- * The `queryPublicPlans()` function builds a query to retrieve a list of up to 1,000 public plans and returns a [`PublicPlansQueryBuilder`](#plansquerybuilder) object.
157
- *
158
- * The returned object contains the query definition which is typically used to run the query using the [`find()`](#plansquerybuilder/find) function.
159
- *
160
- * You can refine the query by chaining `PublicPlansQueryBuilder` functions onto the query. `PublicPlansQueryBuilder` functions enable you to sort, filter, and control the results that `queryPublicPlans()` returns.
161
- *
162
- * `queryPublicPlans()` runs with the following `PublicPlansQueryBuilder` defaults that you can override:
163
- * - [`skip`](#plansquerybuilder/skip): `0`
164
- * - [`limit`](#plansquerybuilder/limit): `50`
165
- *
166
- * The functions that are chained to `queryPublicPlans()` are applied in the order they are called. For example, if you sort on the `_createdDate` property in ascending order and then on the `_id` property in ascending order, the results are sorted first by the created date of the items and then, if there are multiple results with the same date, the items are sorted by `_id` in ascending order, per created date value.
167
- *
168
- * The following `PublicPlansQueryBuilder` functions are supported for the `queryPublicPlans()` function. For a full description of the Plans object, see the object returned for the [`items`](#plansqueryresult/items) property in [`PublicPlansQueryResult`](#plansqueryresult).
169
- * @public
170
- * @permissionScope Read Pricing Plans
171
- * @permissionScopeId SCOPE.DC-PAIDPLANS.READ-PLANS
172
- * @permissionScope Manage Orders
173
- * @permissionScopeId SCOPE.DC-PAIDPLANS.MANAGE-ORDERS
174
- * @permissionScope Manage Bookings Services and Settings
175
- * @permissionScopeId SCOPE.BOOKINGS.CONFIGURATION
176
- * @permissionScope Read Orders
177
- * @permissionScopeId SCOPE.DC-PAIDPLANS.READ-ORDERS
178
- * @permissionScope Manage Pricing Plans
179
- * @permissionScopeId SCOPE.DC-PAIDPLANS.MANAGE-PLANS
180
- * @applicableIdentity APP
181
- * @applicableIdentity MEMBER
182
- * @applicableIdentity VISITOR
183
- */
184
- export function queryPublicPlans() {
185
- const requestTransformation = { '*': '$[1]', query: '$[0]' };
186
- const responseTransformation = {
187
- items: '$.plans',
188
- pagingMetadata: '$.pagingMetadata',
189
- };
190
- // @ts-ignore
191
- const { httpClient, sideEffects } = arguments[0];
192
- const { toAmbassadorRequest } = serializer({
193
- rootSchema: _queryPublicPlansRequest,
194
- depSchemas: {},
195
- fqdnTransformation: {
196
- paths: [],
197
- transformation: _fromVeloEntity,
198
- },
199
- customTransformation: requestTransformation,
200
- });
201
- const { fromJSON } = serializer({
202
- rootSchema: _queryPublicPlansResponse,
203
- depSchemas: {},
204
- fqdnTransformation: {
205
- paths: [],
206
- transformation: _toVeloEntity,
207
- },
208
- customTransformation: responseTransformation,
209
- });
210
- return wrapWithQueryBuilder({
211
- func: (payload) => __awaiter(this, void 0, void 0, function* () {
212
- var _a, _b, _c;
213
- const reqOpts = ambassadorWixPricingPlansV2Plan.queryPublicPlans(payload);
214
- (_a = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSiteCall) === null || _a === void 0 ? void 0 : _a.call(sideEffects);
215
- try {
216
- const result = yield httpClient.request(reqOpts);
217
- (_b = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSuccess) === null || _b === void 0 ? void 0 : _b.call(sideEffects, result);
218
- return result;
219
- }
220
- catch (err) {
221
- (_c = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onError) === null || _c === void 0 ? void 0 : _c.call(sideEffects, err);
222
- throw err;
223
- }
224
- }),
225
- requestTransformer: (...args) => toAmbassadorRequest(args),
226
- responseTransformer: ({ data }) => fromJSON(data),
227
- errorTransformer: (err) => {
228
- const transformedError = transformError(err, requestTransformation);
229
- throw transformedError;
230
- },
231
- pagingMethod: 'OFFSET',
232
- transformationPaths: resolveQueryFieldsTransformationPaths(_toVeloEntity),
233
- })({ cursorWithEmptyFilterAndSort: true });
234
- }
235
- /**
236
- * Retrieves a pricing plan by the specified ID.
237
- *
238
- * The `getPlan()` function returns a Promise that resolves to a plan whose ID matched the specified ID.
239
- * @param _id - Plan ID.
240
- * @public
241
- * @requiredField _id
242
- * @permissionScope Read Pricing Plans
243
- * @permissionScopeId SCOPE.DC-PAIDPLANS.READ-PLANS
244
- * @permissionScope Manage Pricing Plans
245
- * @permissionScopeId SCOPE.DC-PAIDPLANS.MANAGE-PLANS
246
- * @applicableIdentity APP
247
- * @returns Fulfilled - The retrieved plan's information.
248
- */
249
- export function getPlan(_id) {
250
- var _a, _b, _c;
251
- return __awaiter(this, arguments, void 0, function* () {
252
- const requestTransformation = { id: '$[0]' };
253
- const responseTransformation = '$.plan';
254
- // @ts-ignore
255
- const { httpClient, sideEffects } = arguments[1];
256
- const { toAmbassadorRequest } = serializer({
257
- rootSchema: _getPlanRequest,
258
- depSchemas: {},
259
- fqdnTransformation: {
260
- paths: [],
261
- transformation: _fromVeloEntity,
262
- },
263
- customTransformation: requestTransformation,
264
- });
265
- const { fromJSON } = serializer({
266
- rootSchema: _getPlanResponse,
267
- depSchemas: {},
268
- fqdnTransformation: {
269
- paths: [...['plan']],
270
- transformation: _toVeloEntity,
271
- },
272
- customTransformation: responseTransformation,
273
- });
274
- const payload = toAmbassadorRequest([_id]);
275
- const reqOpts = ambassadorWixPricingPlansV2Plan.getPlan(payload);
276
- (_a = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSiteCall) === null || _a === void 0 ? void 0 : _a.call(sideEffects);
277
- try {
278
- const result = yield httpClient.request(reqOpts);
279
- (_b = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSuccess) === null || _b === void 0 ? void 0 : _b.call(sideEffects, result);
280
- return fromJSON(result.data);
281
- }
282
- catch (err) {
283
- const transformedError = sdkTransformError(err, {
284
- spreadPathsToArguments: {},
285
- explicitPathsToArguments: { id: '$[0]' },
286
- singleArgumentUnchanged: false,
287
- }, ['_id']);
288
- (_c = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onError) === null || _c === void 0 ? void 0 : _c.call(sideEffects, err);
289
- throw transformedError;
290
- }
291
- });
292
- }
293
- /**
294
- * Retrieves a list of pricing plans.
295
- *
296
- * The `listPlans()` function returns a Promise that resolves to a list of up to 100 pricing plans. This includes public, hidden, and archived plans.
297
- * @public
298
- * @documentationMaturity preview
299
- * @param options - Options for filtering and paging the list of plans.
300
- * @permissionScope Read Pricing Plans
301
- * @permissionScopeId SCOPE.DC-PAIDPLANS.READ-PLANS
302
- * @permissionScope Manage Pricing Plans
303
- * @permissionScopeId SCOPE.DC-PAIDPLANS.MANAGE-PLANS
304
- * @applicableIdentity APP
305
- * @returns Fulfilled - List of plans that match the given criteria.
306
- */
307
- export function listPlans(options) {
308
- var _a, _b, _c;
309
- return __awaiter(this, arguments, void 0, function* () {
310
- const requestTransformation = {
311
- archived: '$[0].archived',
312
- public: '$[0].public',
313
- limit: '$[0].limit',
314
- offset: '$[0].offset',
315
- planIds: '$[0].planIds',
316
- };
317
- const responseTransformation = '$';
318
- // @ts-ignore
319
- const { httpClient, sideEffects } = arguments[1];
320
- const { toAmbassadorRequest } = serializer({
321
- rootSchema: _listPlansRequest,
322
- depSchemas: {},
323
- fqdnTransformation: {
324
- paths: [],
325
- transformation: _fromVeloEntity,
326
- },
327
- customTransformation: requestTransformation,
328
- });
329
- const { fromJSON } = serializer({
330
- rootSchema: _listPlansResponse,
331
- depSchemas: {},
332
- fqdnTransformation: {
333
- paths: [...['Array#plans']],
334
- transformation: _toVeloEntity,
335
- },
336
- customTransformation: responseTransformation,
337
- });
338
- const payload = toAmbassadorRequest([options]);
339
- const reqOpts = ambassadorWixPricingPlansV2Plan.listPlans(payload);
340
- (_a = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSiteCall) === null || _a === void 0 ? void 0 : _a.call(sideEffects);
341
- try {
342
- const result = yield httpClient.request(reqOpts);
343
- (_b = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSuccess) === null || _b === void 0 ? void 0 : _b.call(sideEffects, result);
344
- return fromJSON(result.data);
345
- }
346
- catch (err) {
347
- const transformedError = sdkTransformError(err, {
348
- spreadPathsToArguments: {},
349
- explicitPathsToArguments: {
350
- archived: '$[0].archived',
351
- public: '$[0].public',
352
- limit: '$[0].limit',
353
- offset: '$[0].offset',
354
- planIds: '$[0].planIds',
355
- },
356
- singleArgumentUnchanged: false,
357
- }, ['options']);
358
- (_c = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onError) === null || _c === void 0 ? void 0 : _c.call(sideEffects, err);
359
- throw transformedError;
360
- }
361
- });
362
- }
363
- /**
364
- * Retrieves statistics about the pricing plans.
365
- *
366
- *
367
- * The `getPlanStats()` function returns a Promise that resolves to statistics about the plan on the site.
368
- *
369
- * Currently this function provides only the total number of pricing plans, including archived plans.
370
- * @public
371
- * @permissionScope Read Pricing Plans
372
- * @permissionScopeId SCOPE.DC-PAIDPLANS.READ-PLANS
373
- * @permissionScope Manage Pricing Plans
374
- * @permissionScopeId SCOPE.DC-PAIDPLANS.MANAGE-PLANS
375
- * @applicableIdentity APP
376
- * @returns Fulfilled - Overall statistics about the pricing plans.
377
- */
378
- export function getPlanStats() {
379
- var _a, _b, _c;
380
- return __awaiter(this, arguments, void 0, function* () {
381
- const requestTransformation = {};
382
- const responseTransformation = '$';
383
- // @ts-ignore
384
- const { httpClient, sideEffects } = arguments[0];
385
- const { toAmbassadorRequest } = serializer({
386
- rootSchema: _getPlanStatsRequest,
387
- depSchemas: {},
388
- fqdnTransformation: {
389
- paths: [],
390
- transformation: _fromVeloEntity,
391
- },
392
- customTransformation: requestTransformation,
393
- });
394
- const { fromJSON } = serializer({
395
- rootSchema: _getPlanStatsResponse,
396
- depSchemas: {},
397
- fqdnTransformation: {
398
- paths: [],
399
- transformation: _toVeloEntity,
400
- },
401
- customTransformation: responseTransformation,
402
- });
403
- const payload = toAmbassadorRequest([]);
404
- const reqOpts = ambassadorWixPricingPlansV2Plan.getPlanStats(payload);
405
- (_a = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSiteCall) === null || _a === void 0 ? void 0 : _a.call(sideEffects);
406
- try {
407
- const result = yield httpClient.request(reqOpts);
408
- (_b = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSuccess) === null || _b === void 0 ? void 0 : _b.call(sideEffects, result);
409
- return fromJSON(result.data);
410
- }
411
- catch (err) {
412
- const transformedError = sdkTransformError(err, {
413
- spreadPathsToArguments: {},
414
- explicitPathsToArguments: {},
415
- singleArgumentUnchanged: false,
416
- }, []);
417
- (_c = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onError) === null || _c === void 0 ? void 0 : _c.call(sideEffects, err);
418
- throw transformedError;
419
- }
420
- });
421
- }
422
- /**
423
- * Creates a pricing plan.
424
- *
425
- *
426
- * The `createPlan()` function returns a Promise that resolves to a newly-created pricing plan after is has successfully been created.
427
- *
428
- * The passed `plan` object must contain a [pricing model](https://www.wix.com/velo/reference/wix-pricing-plans-v2/plans/pricing-models). A pricing model can be one of the following:
429
- * - **A subscription**: A subscription with recurring payment and how often the plan occurs. Subscriptions can have free trial days.
430
- * - **A plan that does not renew**: A single payment for a specific duration that doesn't renew.
431
- * - **An unlimited plan**: A single payment for an unlimited amount of time (until canceled).
432
- *
433
- * Pricing plans created by this function are available to the site owner in the Pricing Plans section in the Dashboard.
434
- * @public
435
- * @requiredField plan
436
- * @requiredField plan.name
437
- * @requiredField plan.pricing
438
- * @requiredField plan.pricing.singlePaymentForDuration.count
439
- * @requiredField plan.pricing.subscription.cycleCount
440
- * @requiredField plan.pricing.subscription.cycleDuration
441
- * @requiredField plan.pricing.subscription.cycleDuration.count
442
- * @param plan - Information for the plan being created.
443
- * @permissionScope Manage Pricing Plans
444
- * @permissionScopeId SCOPE.DC-PAIDPLANS.MANAGE-PLANS
445
- * @applicableIdentity APP
446
- * @returns Fulfilled - The created plan.
447
- *
448
- * Rejected - Error message.
449
- */
450
- export function createPlan(plan) {
451
- var _a, _b, _c;
452
- return __awaiter(this, arguments, void 0, function* () {
453
- const requestTransformation = { plan: '$[0]' };
454
- const responseTransformation = '$.plan';
455
- // @ts-ignore
456
- const { httpClient, sideEffects } = arguments[1];
457
- const { toAmbassadorRequest } = serializer({
458
- rootSchema: _createPlanRequest,
459
- depSchemas: {},
460
- fqdnTransformation: {
461
- paths: [...['plan']],
462
- transformation: _fromVeloEntity,
463
- },
464
- customTransformation: requestTransformation,
465
- });
466
- const { fromJSON } = serializer({
467
- rootSchema: _createPlanResponse,
468
- depSchemas: {},
469
- fqdnTransformation: {
470
- paths: [...['plan']],
471
- transformation: _toVeloEntity,
472
- },
473
- customTransformation: responseTransformation,
474
- });
475
- const payload = toAmbassadorRequest([plan]);
476
- const reqOpts = ambassadorWixPricingPlansV2Plan.createPlan(payload);
477
- (_a = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSiteCall) === null || _a === void 0 ? void 0 : _a.call(sideEffects);
478
- try {
479
- const result = yield httpClient.request(reqOpts);
480
- (_b = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSuccess) === null || _b === void 0 ? void 0 : _b.call(sideEffects, result);
481
- return fromJSON(result.data);
482
- }
483
- catch (err) {
484
- const transformedError = sdkTransformError(err, {
485
- spreadPathsToArguments: {},
486
- explicitPathsToArguments: { plan: '$[0]' },
487
- singleArgumentUnchanged: false,
488
- }, ['plan']);
489
- (_c = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onError) === null || _c === void 0 ? void 0 : _c.call(sideEffects, err);
490
- throw transformedError;
491
- }
492
- });
493
- }
494
- /**
495
- * Updates a pricing plan.
496
- *
497
- *
498
- * The `updatePlan()` function returns a Promise that resolves to an updated plan.
499
- *
500
- * Updating a plan does not impact existing purchases made for the plan. All purchases keep the details of the original plan that was active at the time of the purchase.
501
- * @public
502
- * @requiredField _id
503
- * @requiredField plan
504
- * @param _id - ID of the plan to update.
505
- * @param options - Options for updating the plan.
506
- * @permissionScope Manage Pricing Plans
507
- * @permissionScopeId SCOPE.DC-PAIDPLANS.MANAGE-PLANS
508
- * @applicableIdentity APP
509
- * @returns Fulfilled - The updated plan.
510
- *
511
- * Rejected - Error message.
512
- */
513
- export function updatePlan(_id, plan) {
514
- var _a, _b, _c;
515
- return __awaiter(this, arguments, void 0, function* () {
516
- const requestTransformation = { plan: { '*': '$[1]', id: '$[0]' } };
517
- const responseTransformation = '$.plan';
518
- // @ts-ignore
519
- const { httpClient, sideEffects } = arguments[2];
520
- const { toAmbassadorRequest } = serializer({
521
- rootSchema: _updatePlanRequest,
522
- depSchemas: {},
523
- fqdnTransformation: {
524
- paths: [...['plan']],
525
- transformation: _fromVeloEntity,
526
- },
527
- customTransformation: requestTransformation,
528
- });
529
- const { fromJSON } = serializer({
530
- rootSchema: _updatePlanResponse,
531
- depSchemas: {},
532
- fqdnTransformation: {
533
- paths: [...['plan']],
534
- transformation: _toVeloEntity,
535
- },
536
- customTransformation: responseTransformation,
537
- });
538
- const payload = toAmbassadorRequest([_id, plan]);
539
- const reqOpts = ambassadorWixPricingPlansV2Plan.updatePlan(payload);
540
- (_a = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSiteCall) === null || _a === void 0 ? void 0 : _a.call(sideEffects);
541
- try {
542
- const result = yield httpClient.request(reqOpts);
543
- (_b = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSuccess) === null || _b === void 0 ? void 0 : _b.call(sideEffects, result);
544
- return fromJSON(result.data);
545
- }
546
- catch (err) {
547
- const transformedError = sdkTransformError(err, {
548
- spreadPathsToArguments: { plan: '$[1]' },
549
- explicitPathsToArguments: { 'plan.id': '$[0]' },
550
- singleArgumentUnchanged: false,
551
- }, ['_id', 'plan']);
552
- (_c = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onError) === null || _c === void 0 ? void 0 : _c.call(sideEffects, err);
553
- throw transformedError;
554
- }
555
- });
556
- }
557
- /**
558
- * Sets visibility for non-archived pricing plans.
559
- *
560
- * The `setPlanVisibility()` functions returns a Promise that resolves to a pricing plan when its visibility has successfully been set.
561
- *
562
- * By default, pricing plans are public, meaning they are visible. [Plans can be hidden](https://support.wix.com/en/article/pricing-plans-removing-a-plan-from-your-site#hiding-plans) so that site members and visitors cannot see or choose them.
563
- *
564
- * As opposed to archiving, setting visibility can be reversed. This means that a public plan can be hidden, and a hidden plan can be made public (visible).
565
- *
566
- * >**Note:** An archived plan always remains archived and cannot be made active again. When archiving a plan, its `public` property is automatically set to `false` so that it is hidden.
567
- *
568
- * Changing a plan's visibility does not impact existing orders for the plan. All orders for hidden plans are still active and keep their terms and payment options.
569
- * @param visible - Whether to set the plan as visible.
570
- * @public
571
- * @requiredField _id
572
- * @requiredField visible
573
- * @param _id - The ID of the plan to either display or hide on the site page.
574
- * @param options - Plan visibility options.
575
- * @permissionScope Manage Pricing Plans
576
- * @permissionScopeId SCOPE.DC-PAIDPLANS.MANAGE-PLANS
577
- * @applicableIdentity APP
578
- * @returns Fulfilled - The plan's information.
579
- *
580
- * Rejected - Error message.
581
- */
582
- export function setPlanVisibility(_id, visible) {
583
- var _a, _b, _c;
584
- return __awaiter(this, arguments, void 0, function* () {
585
- const requestTransformation = { id: '$[0]', visible: '$[1]' };
586
- const responseTransformation = '$';
587
- // @ts-ignore
588
- const { httpClient, sideEffects } = arguments[2];
589
- const { toAmbassadorRequest } = serializer({
590
- rootSchema: _setPlanVisibilityRequest,
591
- depSchemas: {},
592
- fqdnTransformation: {
593
- paths: [],
594
- transformation: _fromVeloEntity,
595
- },
596
- customTransformation: requestTransformation,
597
- });
598
- const { fromJSON } = serializer({
599
- rootSchema: _setPlanVisibilityResponse,
600
- depSchemas: {},
601
- fqdnTransformation: {
602
- paths: [...['plan']],
603
- transformation: _toVeloEntity,
604
- },
605
- customTransformation: responseTransformation,
606
- });
607
- const payload = toAmbassadorRequest([_id, visible]);
608
- const reqOpts = ambassadorWixPricingPlansV2Plan.setPlanVisibility(payload);
609
- (_a = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSiteCall) === null || _a === void 0 ? void 0 : _a.call(sideEffects);
610
- try {
611
- const result = yield httpClient.request(reqOpts);
612
- (_b = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSuccess) === null || _b === void 0 ? void 0 : _b.call(sideEffects, result);
613
- return fromJSON(result.data);
614
- }
615
- catch (err) {
616
- const transformedError = sdkTransformError(err, {
617
- spreadPathsToArguments: {},
618
- explicitPathsToArguments: { id: '$[0]', visible: '$[1]' },
619
- singleArgumentUnchanged: false,
620
- }, ['_id', 'visible']);
621
- (_c = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onError) === null || _c === void 0 ? void 0 : _c.call(sideEffects, err);
622
- throw transformedError;
623
- }
624
- });
625
- }
626
- /**
627
- * Marks a pricing plan as the primary pricing plan.
628
- *
629
- *
630
- * The `makePlanPrimary()` function returns a Promise that resolves to the now primary pricing plan.
631
- *
632
- * Only a single plan can be marked as a primary plan at any given time. If there is an existing plan marked as primary, calling `makePlanPrimary()` causes the existing primary plan to lose its primary status.
633
- *
634
- * When viewing pricing plans on the site, the primary plan is highlighted with a customizable ribbon.
635
- * @public
636
- * @requiredField _id
637
- * @param _id - ID of the pricing plan to set as the primary plan.
638
- * @permissionScope Manage Pricing Plans
639
- * @permissionScopeId SCOPE.DC-PAIDPLANS.MANAGE-PLANS
640
- * @applicableIdentity APP
641
- * @returns Fulfilled - The primary plan.
642
- */
643
- export function makePlanPrimary(_id) {
644
- var _a, _b, _c;
645
- return __awaiter(this, arguments, void 0, function* () {
646
- const requestTransformation = { id: '$[0]' };
647
- const responseTransformation = '$';
648
- // @ts-ignore
649
- const { httpClient, sideEffects } = arguments[1];
650
- const { toAmbassadorRequest } = serializer({
651
- rootSchema: _makePlanPrimaryRequest,
652
- depSchemas: {},
653
- fqdnTransformation: {
654
- paths: [],
655
- transformation: _fromVeloEntity,
656
- },
657
- customTransformation: requestTransformation,
658
- });
659
- const { fromJSON } = serializer({
660
- rootSchema: _makePlanPrimaryResponse,
661
- depSchemas: {},
662
- fqdnTransformation: {
663
- paths: [...['plan']],
664
- transformation: _toVeloEntity,
665
- },
666
- customTransformation: responseTransformation,
667
- });
668
- const payload = toAmbassadorRequest([_id]);
669
- const reqOpts = ambassadorWixPricingPlansV2Plan.makePlanPrimary(payload);
670
- (_a = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSiteCall) === null || _a === void 0 ? void 0 : _a.call(sideEffects);
671
- try {
672
- const result = yield httpClient.request(reqOpts);
673
- (_b = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSuccess) === null || _b === void 0 ? void 0 : _b.call(sideEffects, result);
674
- return fromJSON(result.data);
675
- }
676
- catch (err) {
677
- const transformedError = sdkTransformError(err, {
678
- spreadPathsToArguments: {},
679
- explicitPathsToArguments: { id: '$[0]' },
680
- singleArgumentUnchanged: false,
681
- }, ['_id']);
682
- (_c = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onError) === null || _c === void 0 ? void 0 : _c.call(sideEffects, err);
683
- throw transformedError;
684
- }
685
- });
686
- }
687
- /**
688
- * Sets all pricing plans to no longer be primary.
689
- *
690
- * The `clearPrimary()` function returns a Promise that is resolved when there are no pricing plans marked as `primary`.
691
- *
692
- * After clearing the primary plan, when viewing pricing plans on the site, no plan is highlighted with a customizable ribbon.
693
- * @public
694
- * @permissionScope Manage Pricing Plans
695
- * @permissionScopeId SCOPE.DC-PAIDPLANS.MANAGE-PLANS
696
- * @applicableIdentity APP
697
- */
698
- export function clearPrimary() {
699
- var _a, _b, _c;
700
- return __awaiter(this, arguments, void 0, function* () {
701
- const requestTransformation = {};
702
- const responseTransformation = '$';
703
- // @ts-ignore
704
- const { httpClient, sideEffects } = arguments[0];
705
- const { toAmbassadorRequest } = serializer({
706
- rootSchema: _clearPrimaryRequest,
707
- depSchemas: {},
708
- fqdnTransformation: {
709
- paths: [],
710
- transformation: _fromVeloEntity,
711
- },
712
- customTransformation: requestTransformation,
713
- });
714
- const { fromJSON } = serializer({
715
- rootSchema: _clearPrimaryResponse,
716
- depSchemas: {},
717
- fqdnTransformation: {
718
- paths: [],
719
- transformation: _toVeloEntity,
720
- },
721
- customTransformation: responseTransformation,
722
- });
723
- const payload = toAmbassadorRequest([]);
724
- const reqOpts = ambassadorWixPricingPlansV2Plan.clearPrimary(payload);
725
- (_a = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSiteCall) === null || _a === void 0 ? void 0 : _a.call(sideEffects);
726
- try {
727
- const result = yield httpClient.request(reqOpts);
728
- (_b = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSuccess) === null || _b === void 0 ? void 0 : _b.call(sideEffects, result);
729
- }
730
- catch (err) {
731
- const transformedError = sdkTransformError(err, {
732
- spreadPathsToArguments: {},
733
- explicitPathsToArguments: {},
734
- singleArgumentUnchanged: false,
735
- }, []);
736
- (_c = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onError) === null || _c === void 0 ? void 0 : _c.call(sideEffects, err);
737
- throw transformedError;
738
- }
739
- });
740
- }
741
- /**
742
- * Archives a single plan.
743
- *
744
- *
745
- * The `archivePlan()` function returns a Promise that resolves to the newly-archived plan.
746
- *
747
- * When a plan is archived, the plan
748
- * - Is no longer available for display or selection by visitors. This is because the plan's `public` property is automatically set to `false`.
749
- * - Cannot be purchased.
750
- * - Cannot be "un-archived", meaning the plan cannot be made active again.
751
- *
752
- * Plan archiving does not impact existing purchases made for the plan. All purchases for the plan are still active and keep their payment options and terms.
753
- *
754
- * Site owners can see archived plans in the Dashboard under **Pricing Plans -> Archived Plans**.
755
- *
756
- * >**Note:** An attempt to archive an already-archived plan throws an error.
757
- * @public
758
- * @requiredField _id
759
- * @param _id - ID of the active plan to archive.
760
- * @permissionScope Manage Pricing Plans
761
- * @permissionScopeId SCOPE.DC-PAIDPLANS.MANAGE-PLANS
762
- * @applicableIdentity APP
763
- * @returns Fulfilled - The archived plan.
764
- *
765
- * Rejected - Error message.
766
- */
767
- export function archivePlan(_id) {
768
- var _a, _b, _c;
769
- return __awaiter(this, arguments, void 0, function* () {
770
- const requestTransformation = { id: '$[0]' };
771
- const responseTransformation = '$';
772
- // @ts-ignore
773
- const { httpClient, sideEffects } = arguments[1];
774
- const { toAmbassadorRequest } = serializer({
775
- rootSchema: _archivePlanRequest,
776
- depSchemas: {},
777
- fqdnTransformation: {
778
- paths: [],
779
- transformation: _fromVeloEntity,
780
- },
781
- customTransformation: requestTransformation,
782
- });
783
- const { fromJSON } = serializer({
784
- rootSchema: _archivePlanResponse,
785
- depSchemas: {},
786
- fqdnTransformation: {
787
- paths: [...['plan']],
788
- transformation: _toVeloEntity,
789
- },
790
- customTransformation: responseTransformation,
791
- });
792
- const payload = toAmbassadorRequest([_id]);
793
- const reqOpts = ambassadorWixPricingPlansV2Plan.archivePlan(payload);
794
- (_a = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSiteCall) === null || _a === void 0 ? void 0 : _a.call(sideEffects);
795
- try {
796
- const result = yield httpClient.request(reqOpts);
797
- (_b = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSuccess) === null || _b === void 0 ? void 0 : _b.call(sideEffects, result);
798
- return fromJSON(result.data);
799
- }
800
- catch (err) {
801
- const transformedError = sdkTransformError(err, {
802
- spreadPathsToArguments: {},
803
- explicitPathsToArguments: { id: '$[0]' },
804
- singleArgumentUnchanged: false,
805
- }, ['_id']);
806
- (_c = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onError) === null || _c === void 0 ? void 0 : _c.call(sideEffects, err);
807
- throw transformedError;
808
- }
809
- });
810
- }
811
- /**
812
- * Changes the display order of the pricing plans on the site page and in the Dashboard.
813
- *
814
- *
815
- * The `arrangePlans()` function returns a Promise that resolves when the plans are rearranged on the site page and in the Dashboard.
816
- *
817
- * To rearrange the order of the plans, provide a list of the IDs for all non-archived plans in the desired order, including hidden plans.
818
- *
819
- * >**Note:** Make sure to provide *all* non-archived plan IDs to avoid unpredictable results.
820
- * @param ids - IDs of all non-archived plans in the order you want them arranged.
821
- * @public
822
- * @requiredField ids
823
- * @permissionScope Manage Pricing Plans
824
- * @permissionScopeId SCOPE.DC-PAIDPLANS.MANAGE-PLANS
825
- * @applicableIdentity APP
826
- */
827
- export function arrangePlans(ids) {
828
- var _a, _b, _c;
829
- return __awaiter(this, arguments, void 0, function* () {
830
- const requestTransformation = { ids: '$[0]' };
831
- const responseTransformation = '$';
832
- // @ts-ignore
833
- const { httpClient, sideEffects } = arguments[1];
834
- const { toAmbassadorRequest } = serializer({
835
- rootSchema: _arrangePlansRequest,
836
- depSchemas: {},
837
- fqdnTransformation: {
838
- paths: [],
839
- transformation: _fromVeloEntity,
840
- },
841
- customTransformation: requestTransformation,
842
- });
843
- const { fromJSON } = serializer({
844
- rootSchema: _arrangePlansResponse,
845
- depSchemas: {},
846
- fqdnTransformation: {
847
- paths: [],
848
- transformation: _toVeloEntity,
849
- },
850
- customTransformation: responseTransformation,
851
- });
852
- const payload = toAmbassadorRequest([ids]);
853
- const reqOpts = ambassadorWixPricingPlansV2Plan.arrangePlans(payload);
854
- (_a = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSiteCall) === null || _a === void 0 ? void 0 : _a.call(sideEffects);
855
- try {
856
- const result = yield httpClient.request(reqOpts);
857
- (_b = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onSuccess) === null || _b === void 0 ? void 0 : _b.call(sideEffects, result);
858
- }
859
- catch (err) {
860
- const transformedError = sdkTransformError(err, {
861
- spreadPathsToArguments: {},
862
- explicitPathsToArguments: { ids: '$[0]' },
863
- singleArgumentUnchanged: false,
864
- }, ['ids']);
865
- (_c = sideEffects === null || sideEffects === void 0 ? void 0 : sideEffects.onError) === null || _c === void 0 ? void 0 : _c.call(sideEffects, err);
866
- throw transformedError;
867
- }
868
- });
869
- }
870
- //# sourceMappingURL=pricing-plans-v2-plan.universal.js.map