@wix/pricing-plans 1.0.70 → 1.0.72
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/context/package.json +2 -1
- package/meta/package.json +2 -1
- package/package.json +12 -6
- package/type-bundles/context.bundle.d.ts +2350 -0
- package/type-bundles/index.bundle.d.ts +3551 -0
- package/type-bundles/meta.bundle.d.ts +3978 -0
@@ -0,0 +1,2350 @@
|
|
1
|
+
/**
|
2
|
+
* An order object includes all of the details related to the purchase of a Pricing Plan.
|
3
|
+
* You can manage existing orders, create offline orders, and preview orders not yet purchased.
|
4
|
+
*
|
5
|
+
* Orders are based on pricing models based on the payment and duration cycles for each plan. See here to
|
6
|
+
* [learn more about pricing models](https://dev.wix.com/api/rest/wix-pricing-plans/pricing-plans/introduction#wix-pricing-plans_pricing-plans_introduction_pricing-models).
|
7
|
+
*/
|
8
|
+
interface Order {
|
9
|
+
/**
|
10
|
+
* Order ID.
|
11
|
+
* @readonly
|
12
|
+
*/
|
13
|
+
_id?: string;
|
14
|
+
/**
|
15
|
+
* ID of the plan purchased with the order.
|
16
|
+
* @readonly
|
17
|
+
*/
|
18
|
+
planId?: string;
|
19
|
+
/**
|
20
|
+
* ID of the related Wix subscription.
|
21
|
+
*
|
22
|
+
* Every pricing plan order corresponds to a Wix subscription, including orders for single payment plans. See a [Pricing Plans overview](https://support.wix.com/en/article/pricing-plans-an-overview#create-plans-to-suit-your-business).
|
23
|
+
* @readonly
|
24
|
+
*/
|
25
|
+
subscriptionId?: string;
|
26
|
+
/**
|
27
|
+
* Wix Pay order ID.
|
28
|
+
*
|
29
|
+
* Provided by Wix whether the order is created online or offline. The field is omitted when the order is free.
|
30
|
+
* @readonly
|
31
|
+
*/
|
32
|
+
wixPayOrderId?: string | null;
|
33
|
+
/**
|
34
|
+
* The buyer's IDs. Includes `memberId` and `contactId`.
|
35
|
+
*
|
36
|
+
* Currently, Pricing Plan purchases are limited to members only. `contactId` is returned,
|
37
|
+
* but a buyer will not be able to purchase a plan without a `memberId`.
|
38
|
+
* @readonly
|
39
|
+
*/
|
40
|
+
buyer?: Buyer;
|
41
|
+
/**
|
42
|
+
* @internal
|
43
|
+
* @internal
|
44
|
+
* @readonly
|
45
|
+
* @deprecated __Deprecated.__ Use `pricing` instead. This property will be removed on September 30, 2022.
|
46
|
+
* @replacedBy pricing
|
47
|
+
* @removalDate 2022-10-01
|
48
|
+
*/
|
49
|
+
priceDetails?: PriceDetails;
|
50
|
+
/**
|
51
|
+
* Pricing model, price, and payment schedule for the order.
|
52
|
+
* @readonly
|
53
|
+
*/
|
54
|
+
pricing?: PricingDetails;
|
55
|
+
/**
|
56
|
+
* How the order was processed. Supported values:
|
57
|
+
* + `"ONLINE"`: The buyer purchased the plan using the site.
|
58
|
+
* + `"OFFLINE"`: The buyer made a manual, offline purchase without using the site.
|
59
|
+
* @readonly
|
60
|
+
*/
|
61
|
+
type?: OrderType;
|
62
|
+
/**
|
63
|
+
* Status of the order. Supported values:
|
64
|
+
* + `DRAFT`: Order has been initiated but payment hasn't been processed yet. The plan isn't yet available for use to the buyer.
|
65
|
+
* + `PENDING`: Order has been purchased and its start date is set in the future.
|
66
|
+
* + `ACTIVE`: Order has been processed. The plan is available for use.
|
67
|
+
* + `PAUSED`: Order, and use of the plan, is [paused](#pauseorder). The order, and use of the plan, can be [resumed](#resumeorder).
|
68
|
+
* + `ENDED`: Order has completed its duration and is no longer available for use.
|
69
|
+
* + `CANCELED`: Order has been [canceled](#cancelorder).
|
70
|
+
* @readonly
|
71
|
+
*/
|
72
|
+
status?: OrderStatus;
|
73
|
+
/**
|
74
|
+
* Whether the order will be canceled at the next payment date.
|
75
|
+
*
|
76
|
+
* If `true`, the order status will be `CANCELED` and the next payment won't be charged. Omitted for single payment orders.
|
77
|
+
* @readonly
|
78
|
+
*/
|
79
|
+
autoRenewCanceled?: boolean | null;
|
80
|
+
/**
|
81
|
+
* Details about the cancellation of an order.
|
82
|
+
*
|
83
|
+
*
|
84
|
+
* @readonly
|
85
|
+
*/
|
86
|
+
cancellation?: Cancellation;
|
87
|
+
/**
|
88
|
+
* Status of the last payment for the order.
|
89
|
+
* Updated automatically for online orders. Updated manually by the site owner for offline orders.
|
90
|
+
*
|
91
|
+
* Supported values:
|
92
|
+
* + `PAID`: The last payment was paid.
|
93
|
+
* + `REFUNDED`: The last payment was refunded.
|
94
|
+
* + `FAILED`: The last payment transaction didn't complete.
|
95
|
+
* + `UNPAID`: The last payment wasn't paid.
|
96
|
+
* + `PENDING`: Awaiting payment.
|
97
|
+
* + `NOT_APPLICABLE`: No payment was necessary. For example, for free plans or free trials.
|
98
|
+
* @readonly
|
99
|
+
*/
|
100
|
+
lastPaymentStatus?: PaymentStatus;
|
101
|
+
/**
|
102
|
+
* Start date and time for the ordered plan.
|
103
|
+
* @readonly
|
104
|
+
*/
|
105
|
+
startDate?: Date;
|
106
|
+
/**
|
107
|
+
* Current end date and time for the ordered plan.
|
108
|
+
*
|
109
|
+
* `endDate` may be updated over the course of an order. If the order is [paused](#pauseorder),
|
110
|
+
* it will have a later `endDate` once it [resumes](#resumeorder). `endDate` may also be [postponed](#postponeenddate).
|
111
|
+
*
|
112
|
+
* Omitted if the order is valid until canceled and still `ACTIVE`.
|
113
|
+
* @readonly
|
114
|
+
*/
|
115
|
+
endDate?: Date;
|
116
|
+
/**
|
117
|
+
* List of periods during which the order is paused.
|
118
|
+
* @readonly
|
119
|
+
*/
|
120
|
+
pausePeriods?: PausePeriod[];
|
121
|
+
/**
|
122
|
+
* Free trial period for the order, in days.
|
123
|
+
*
|
124
|
+
* Only available for recurring plans.
|
125
|
+
* @readonly
|
126
|
+
*/
|
127
|
+
freeTrialDays?: number | null;
|
128
|
+
/**
|
129
|
+
* Earliest end date and time that the plan for the order can expire.
|
130
|
+
*
|
131
|
+
* Calculated by using the original end date plus any pause periods. Omitted if the order is active until canceled. Reserved for future use.
|
132
|
+
* @readonly
|
133
|
+
*/
|
134
|
+
earliestEndDate?: Date;
|
135
|
+
/**
|
136
|
+
* Current payment cycle for the order.
|
137
|
+
*
|
138
|
+
* `currentCycle` will be omitted if the order's status is `CANCELED` or `ENDED`, or if the `startDate` hasn't passed yet.
|
139
|
+
* @readonly
|
140
|
+
*/
|
141
|
+
currentCycle?: CurrentCycle;
|
142
|
+
/**
|
143
|
+
* Plan name at the time of purchase.
|
144
|
+
* @readonly
|
145
|
+
*/
|
146
|
+
planName?: string;
|
147
|
+
/**
|
148
|
+
* Plan description at the time of purchase
|
149
|
+
* @readonly
|
150
|
+
*/
|
151
|
+
planDescription?: string;
|
152
|
+
/**
|
153
|
+
* Plan price as it was at the moment of order creation.
|
154
|
+
* @readonly
|
155
|
+
*/
|
156
|
+
planPrice?: string;
|
157
|
+
/**
|
158
|
+
* Date and time the order was created.
|
159
|
+
* @readonly
|
160
|
+
*/
|
161
|
+
_createdDate?: Date;
|
162
|
+
/**
|
163
|
+
* Date and time the order was updated.
|
164
|
+
* @readonly
|
165
|
+
*/
|
166
|
+
_updatedDate?: Date;
|
167
|
+
/**
|
168
|
+
* Information about the form submitted during the plan's checkout.
|
169
|
+
* @readonly
|
170
|
+
*/
|
171
|
+
formData?: FormData;
|
172
|
+
}
|
173
|
+
interface Buyer {
|
174
|
+
/**
|
175
|
+
* Member ID for a buyer.
|
176
|
+
* @readonly
|
177
|
+
*/
|
178
|
+
memberId?: string;
|
179
|
+
/**
|
180
|
+
* Contact ID for a buyer.
|
181
|
+
* @readonly
|
182
|
+
*/
|
183
|
+
contactId?: string;
|
184
|
+
}
|
185
|
+
interface PriceDetails extends PriceDetailsPricingModelOneOf {
|
186
|
+
/** Order has recurring payments. */
|
187
|
+
subscription?: Recurrence$1;
|
188
|
+
/** One-time payment. Order is valid for a specified duration. */
|
189
|
+
singlePaymentForDuration?: Duration$1;
|
190
|
+
/** One-time payment. Order is valid until it is canceled. */
|
191
|
+
singlePaymentUnlimited?: boolean | null;
|
192
|
+
/** Price of the order excluding tax, specified as a monetary amount. for example, `"9.99"`. */
|
193
|
+
subtotal?: string;
|
194
|
+
/** Total discount applied. */
|
195
|
+
discount?: string;
|
196
|
+
/** Tax applied. */
|
197
|
+
tax?: Tax;
|
198
|
+
/**
|
199
|
+
* Price after tax and discount is applied, specified as a monetary amount. For example, `"13.98"`.
|
200
|
+
*
|
201
|
+
* If no tax is applied, the amount is the same as `subtotal`.
|
202
|
+
*/
|
203
|
+
total?: string;
|
204
|
+
/** Plan price as it was at the moment of order creation. */
|
205
|
+
planPrice?: string;
|
206
|
+
/** Currency code. Must be valid ISO 4217 currency code (e.g., USD). */
|
207
|
+
currency?: string;
|
208
|
+
/** Free trial period for the order in days. Only available for recurring plans. */
|
209
|
+
freeTrialDays?: number | null;
|
210
|
+
/** Coupon applied to the order. Empty means no coupon was applied. */
|
211
|
+
coupon?: Coupon;
|
212
|
+
}
|
213
|
+
/** @oneof */
|
214
|
+
interface PriceDetailsPricingModelOneOf {
|
215
|
+
/** Order has recurring payments. */
|
216
|
+
subscription?: Recurrence$1;
|
217
|
+
/** One-time payment. Order is valid for a specified duration. */
|
218
|
+
singlePaymentForDuration?: Duration$1;
|
219
|
+
/** One-time payment. Order is valid until it is canceled. */
|
220
|
+
singlePaymentUnlimited?: boolean | null;
|
221
|
+
}
|
222
|
+
interface Tax {
|
223
|
+
/** Name of the tax. For example, VAT. */
|
224
|
+
name?: string;
|
225
|
+
/** Whether tax is included in the original price. When `false`, tax is added at checkout. */
|
226
|
+
includedInPrice?: boolean;
|
227
|
+
/** Tax rate percentage, as a number between 0 and 100. For example, a 7% tax rate is `"7.00"`. */
|
228
|
+
rate?: string;
|
229
|
+
/** Total tax, specified as a monetary amount. For example, `"3.99"`. */
|
230
|
+
amount?: string;
|
231
|
+
}
|
232
|
+
/** An object specifying how often and for how long payments recur (may be forever). */
|
233
|
+
interface Recurrence$1 {
|
234
|
+
/** Length of one payment cycle. */
|
235
|
+
cycleDuration?: Duration$1;
|
236
|
+
/**
|
237
|
+
* Amount of payment cycles this subscription is valid for.
|
238
|
+
*
|
239
|
+
* `0` for unlimited or until-canceled.
|
240
|
+
*/
|
241
|
+
cycleCount?: number | null;
|
242
|
+
}
|
243
|
+
/** A duration expressed in number of time units. */
|
244
|
+
interface Duration$1 {
|
245
|
+
/**
|
246
|
+
* The amount of a duration `unit` in a single payment cycle.
|
247
|
+
*
|
248
|
+
* Currently limited to support only `1`.
|
249
|
+
*/
|
250
|
+
count?: number | null;
|
251
|
+
/** Unit of time for the cycle duration. */
|
252
|
+
unit?: PeriodUnit$1;
|
253
|
+
}
|
254
|
+
declare enum PeriodUnit$1 {
|
255
|
+
UNDEFINED = "UNDEFINED",
|
256
|
+
DAY = "DAY",
|
257
|
+
WEEK = "WEEK",
|
258
|
+
MONTH = "MONTH",
|
259
|
+
YEAR = "YEAR"
|
260
|
+
}
|
261
|
+
interface Coupon {
|
262
|
+
/** Code of the applied coupon. */
|
263
|
+
code?: string;
|
264
|
+
/** Total discount of the coupon, as a monetary amount. */
|
265
|
+
amount?: string;
|
266
|
+
/**
|
267
|
+
* Coupon ID.
|
268
|
+
* @readonly
|
269
|
+
*/
|
270
|
+
_id?: string;
|
271
|
+
}
|
272
|
+
interface PricingDetails extends PricingDetailsPricingModelOneOf {
|
273
|
+
/** Pricing model for an order with recurring payment cycles. */
|
274
|
+
subscription?: Recurrence$1;
|
275
|
+
/** Pricing model for an order with a one-time payment and the order is valid for a specific amount of time. */
|
276
|
+
singlePaymentForDuration?: Duration$1;
|
277
|
+
/** Pricing model for an order with a one-time payment and the order is valid until canceled. */
|
278
|
+
singlePaymentUnlimited?: boolean | null;
|
279
|
+
/**
|
280
|
+
* Pricing details for all pricing models.
|
281
|
+
* @readonly
|
282
|
+
*/
|
283
|
+
prices?: SpannedPrice[];
|
284
|
+
}
|
285
|
+
/** @oneof */
|
286
|
+
interface PricingDetailsPricingModelOneOf {
|
287
|
+
/** Pricing model for an order with recurring payment cycles. */
|
288
|
+
subscription?: Recurrence$1;
|
289
|
+
/** Pricing model for an order with a one-time payment and the order is valid for a specific amount of time. */
|
290
|
+
singlePaymentForDuration?: Duration$1;
|
291
|
+
/** Pricing model for an order with a one-time payment and the order is valid until canceled. */
|
292
|
+
singlePaymentUnlimited?: boolean | null;
|
293
|
+
}
|
294
|
+
interface SpannedPrice {
|
295
|
+
/**
|
296
|
+
* Cycle duration to apply `price` for.
|
297
|
+
*
|
298
|
+
* Use with all pricing models.
|
299
|
+
* Can apply the same price to multiple payment cycles.
|
300
|
+
*/
|
301
|
+
duration?: PriceDuration;
|
302
|
+
/** Order price. */
|
303
|
+
price?: Price;
|
304
|
+
}
|
305
|
+
interface PriceDuration {
|
306
|
+
/**
|
307
|
+
* Price starts to apply with this cycle.
|
308
|
+
*
|
309
|
+
* `1` is the first payment cycle for all pricing models.
|
310
|
+
*/
|
311
|
+
cycleFrom?: number;
|
312
|
+
/**
|
313
|
+
* Amount of cycles to apply price for.
|
314
|
+
*
|
315
|
+
* For `subscription` pricing models with a finite number of cycles, the `numberOfCycles` is the same as `pricing.subscription.cycleCount`.
|
316
|
+
*
|
317
|
+
* For `subscription` pricing models that are unlimited or until-canceled, the `numberOfCycles` is not returned.
|
318
|
+
*
|
319
|
+
* For `singlePaymentForDuration` and `singlePaymentUnlimited` pricing models, the `numberOfCycles` is `1`.
|
320
|
+
*/
|
321
|
+
numberOfCycles?: number | null;
|
322
|
+
}
|
323
|
+
interface Price {
|
324
|
+
/** Price of the order excluding tax, specified as a monetary amount. For example, `"9.99"`. */
|
325
|
+
subtotal?: string;
|
326
|
+
/** Coupon applied to the order. */
|
327
|
+
coupon?: Coupon;
|
328
|
+
/** Total discount applied to the order. */
|
329
|
+
discount?: string;
|
330
|
+
/**
|
331
|
+
* Tax applied to the order.
|
332
|
+
*
|
333
|
+
* Tax is only applied if the site [has it configured](https://support.wix.com/en/article/pricing-plans-setting-up-tax-collection).
|
334
|
+
*/
|
335
|
+
tax?: Tax;
|
336
|
+
/**
|
337
|
+
* Price after tax and discount is applied. Specified as a monetary amount, for example, `"13.98"`.
|
338
|
+
*
|
339
|
+
* If no tax is applied, the amount is the same as `subtotal`.
|
340
|
+
*/
|
341
|
+
total?: string;
|
342
|
+
/**
|
343
|
+
* Three-letter currency code in
|
344
|
+
* [ISO-4217 alphabetic](https://en.wikipedia.org/wiki/ISO_4217#Active_codes) format.
|
345
|
+
*/
|
346
|
+
currency?: string;
|
347
|
+
/** Price change after billing date was change and price was adjusted. Could be positive and negative values. */
|
348
|
+
proration?: string;
|
349
|
+
}
|
350
|
+
declare enum OrderType {
|
351
|
+
UNDEFINED = "UNDEFINED",
|
352
|
+
/** Payments made by the buyer */
|
353
|
+
ONLINE = "ONLINE",
|
354
|
+
/** Payments managed manually by the site owner */
|
355
|
+
OFFLINE = "OFFLINE",
|
356
|
+
/** Payments managed externally */
|
357
|
+
EXTERNAL = "EXTERNAL"
|
358
|
+
}
|
359
|
+
declare enum OrderStatus {
|
360
|
+
/** Order status undefined */
|
361
|
+
UNDEFINED = "UNDEFINED",
|
362
|
+
/** Order created, but hasn't been paid for yet. Filtered out in ListOrders response by default. */
|
363
|
+
DRAFT = "DRAFT",
|
364
|
+
/** Order has been paid for, but the start date is in the future */
|
365
|
+
PENDING = "PENDING",
|
366
|
+
/** Order is active */
|
367
|
+
ACTIVE = "ACTIVE",
|
368
|
+
/** Order is paused until site owner resumes it */
|
369
|
+
PAUSED = "PAUSED",
|
370
|
+
/** Order has ended */
|
371
|
+
ENDED = "ENDED",
|
372
|
+
/** Order has been canceled */
|
373
|
+
CANCELED = "CANCELED"
|
374
|
+
}
|
375
|
+
interface Cancellation {
|
376
|
+
/** Date and time the cancellation was requested. */
|
377
|
+
requestedDate?: Date;
|
378
|
+
/**
|
379
|
+
* Reason for the cancellation. One of:
|
380
|
+
* + `OWNER_ACTION`: Site owner canceled the order.
|
381
|
+
* + `MEMBER_ACTION`: Buyer initiated the cancellation.
|
382
|
+
* + `PAYMENT_FAILURE`: Payment transaction failed.
|
383
|
+
* + `PAYMENT_SETUP_FAILURE`: Buyer's payment details weren't set up correctly.
|
384
|
+
* + `UNKNOWN`: Reason for the cancellation is unknown.
|
385
|
+
*/
|
386
|
+
cause?: CancellationCause;
|
387
|
+
/**
|
388
|
+
* When the cancellation takes effect. Set when cancelling the order. One of:
|
389
|
+
* + `IMMEDIATELY`: Cancellation occurs immediately and the buyer can no longer use the plan.
|
390
|
+
* + `NEXT_PAYMENT_DATE`: Cancellation occurs at the next payment date and time. Buyer can continue to use the plan until that date and time.
|
391
|
+
*/
|
392
|
+
effectiveAt?: CancellationEffectiveAt;
|
393
|
+
}
|
394
|
+
declare enum CancellationCause {
|
395
|
+
/** Cancellation initiator undefined */
|
396
|
+
UNDEFINED = "UNDEFINED",
|
397
|
+
/** Order was canceled by site owner (default if canceled by user or service identity) */
|
398
|
+
OWNER_ACTION = "OWNER_ACTION",
|
399
|
+
/** Order was canceled by member (default if canceled by member identity) */
|
400
|
+
MEMBER_ACTION = "MEMBER_ACTION",
|
401
|
+
/** Order was canceled because of payment failure */
|
402
|
+
PAYMENT_FAILURE = "PAYMENT_FAILURE",
|
403
|
+
/** Order was canceled because of payment setup failure */
|
404
|
+
PAYMENT_SETUP_FAILURE = "PAYMENT_SETUP_FAILURE",
|
405
|
+
/** Order was cancelled because of an unknown reason. It's not possible to know with certain payment providers (e.g. paypal) */
|
406
|
+
UNKNOWN = "UNKNOWN"
|
407
|
+
}
|
408
|
+
declare enum CancellationEffectiveAt {
|
409
|
+
/** Cancellation time undefined */
|
410
|
+
UNDEFINED = "UNDEFINED",
|
411
|
+
/** Will cancel the order now, i.e. update validUntil to the current date */
|
412
|
+
IMMEDIATELY = "IMMEDIATELY",
|
413
|
+
/** Will cancel the order at the date when next payment should have been made */
|
414
|
+
NEXT_PAYMENT_DATE = "NEXT_PAYMENT_DATE"
|
415
|
+
}
|
416
|
+
declare enum PaymentStatus {
|
417
|
+
/** Payment status undefined */
|
418
|
+
UNDEFINED = "UNDEFINED",
|
419
|
+
/** Payment has been paid */
|
420
|
+
PAID = "PAID",
|
421
|
+
/** Payment has been refunded */
|
422
|
+
REFUNDED = "REFUNDED",
|
423
|
+
/** Recurring payment has failed */
|
424
|
+
FAILED = "FAILED",
|
425
|
+
/** Payment has not been paid */
|
426
|
+
UNPAID = "UNPAID",
|
427
|
+
/** Billing has been initialized, but actual charge is yet to be made. Can happen for free trial and PayPal */
|
428
|
+
PENDING = "PENDING",
|
429
|
+
/** Used in cases where the plan is free */
|
430
|
+
NOT_APPLICABLE = "NOT_APPLICABLE"
|
431
|
+
}
|
432
|
+
interface PausePeriod {
|
433
|
+
/**
|
434
|
+
* Status of the pause period. Supported values:
|
435
|
+
* + `ACTIVE`: Status while the order is [paused](#pauseorder).
|
436
|
+
* + `ENDED`: Status when the order is [resumed](#resumeorder).
|
437
|
+
*/
|
438
|
+
status?: Status;
|
439
|
+
/** Start date and time of the pause period. */
|
440
|
+
pauseDate?: Date;
|
441
|
+
/**
|
442
|
+
* End date and time of the pause period.
|
443
|
+
*
|
444
|
+
* Omitted while the pause period remains `ACTIVE`.
|
445
|
+
*/
|
446
|
+
resumeDate?: Date;
|
447
|
+
}
|
448
|
+
declare enum Status {
|
449
|
+
UNDEFINED = "UNDEFINED",
|
450
|
+
/** Order suspension is active */
|
451
|
+
ACTIVE = "ACTIVE",
|
452
|
+
/** Order suspension has ended */
|
453
|
+
ENDED = "ENDED"
|
454
|
+
}
|
455
|
+
/**
|
456
|
+
* Current cycle will be empty when order is cancelled, expired or order start date is in the future
|
457
|
+
* Current cycle start and end dates take into account free trial days and suspensions
|
458
|
+
*/
|
459
|
+
interface CurrentCycle {
|
460
|
+
/**
|
461
|
+
* Index of the current payment cycle in the order.
|
462
|
+
*
|
463
|
+
* `0` when order is in a free trial period. In all other cases, the index starts with `1`.
|
464
|
+
*/
|
465
|
+
index?: number;
|
466
|
+
/** Start date and time for the current payment cycle. */
|
467
|
+
startedDate?: Date;
|
468
|
+
/** End date and time for the current payment cycle. */
|
469
|
+
endedDate?: Date;
|
470
|
+
}
|
471
|
+
interface FormData {
|
472
|
+
/** ID of the form associated with the plan at checkout. */
|
473
|
+
formId?: string | null;
|
474
|
+
/** ID of a submission to the plan's order form at checkout. Every time a visitor completes the checkout process for a plan, a new submission is created. */
|
475
|
+
submissionId?: string | null;
|
476
|
+
/**
|
477
|
+
* Data submitted to the plan's order form at checkout.
|
478
|
+
*
|
479
|
+
* This field is returned when a method's `fieldset` is set to `"FULL"`.
|
480
|
+
*
|
481
|
+
* @readonly
|
482
|
+
*/
|
483
|
+
submissionData?: Record<string, any>;
|
484
|
+
}
|
485
|
+
declare enum Set {
|
486
|
+
/** Same behavior as BASIC */
|
487
|
+
UNKNOWN_SET = "UNKNOWN_SET",
|
488
|
+
/**
|
489
|
+
* Returns fields of the entity that are available in the database.
|
490
|
+
* By default a field is available in the database unless explicitly specified in the documentation
|
491
|
+
*/
|
492
|
+
BASIC = "BASIC",
|
493
|
+
/**
|
494
|
+
* Returns all fields in the entity.
|
495
|
+
* This might make additional calls to gather the full entity
|
496
|
+
*/
|
497
|
+
FULL = "FULL"
|
498
|
+
}
|
499
|
+
interface Sorting {
|
500
|
+
/** Name of the field to sort by. */
|
501
|
+
fieldName?: string;
|
502
|
+
/** Sort order. */
|
503
|
+
order?: SortOrder;
|
504
|
+
}
|
505
|
+
declare enum SortOrder {
|
506
|
+
ASC = "ASC",
|
507
|
+
DESC = "DESC"
|
508
|
+
}
|
509
|
+
interface MemberListOrdersResponse {
|
510
|
+
/** List of orders. */
|
511
|
+
orders?: Order[];
|
512
|
+
/** Object containing paging-related data (number of orders returned, offset). */
|
513
|
+
pagingMetadata?: PagingMetadataV2$1;
|
514
|
+
}
|
515
|
+
interface PagingMetadataV2$1 {
|
516
|
+
/** Number of items returned in the response. */
|
517
|
+
count?: number | null;
|
518
|
+
/** Offset that was requested. */
|
519
|
+
offset?: number | null;
|
520
|
+
/** Total number of items that match the query. Returned if offset paging is used and the `tooManyToCount` flag is not set. */
|
521
|
+
total?: number | null;
|
522
|
+
/** Flag that indicates the server failed to calculate the `total` field. */
|
523
|
+
tooManyToCount?: boolean | null;
|
524
|
+
/** Cursors to navigate through the result pages using `next` and `prev`. Returned if cursor paging is used. */
|
525
|
+
cursors?: Cursors$1;
|
526
|
+
}
|
527
|
+
interface Cursors$1 {
|
528
|
+
/** Cursor string pointing to the next page in the list of results. */
|
529
|
+
next?: string | null;
|
530
|
+
/** Cursor pointing to the previous page in the list of results. */
|
531
|
+
prev?: string | null;
|
532
|
+
}
|
533
|
+
/**
|
534
|
+
* Emitted when an order is canceled immediately or when cycle ends for an order with canceled auto renewal
|
535
|
+
*
|
536
|
+
* To determine the specific reason of the cancellation check `order.cancellation.cause` field.
|
537
|
+
*/
|
538
|
+
interface OrderCanceled {
|
539
|
+
/** Canceled order. */
|
540
|
+
order?: Order;
|
541
|
+
}
|
542
|
+
interface IdentificationData$1 extends IdentificationDataIdOneOf$1 {
|
543
|
+
/** ID of a site visitor that has not logged in to the site. */
|
544
|
+
anonymousVisitorId?: string;
|
545
|
+
/** ID of a site visitor that has logged in to the site. */
|
546
|
+
memberId?: string;
|
547
|
+
/** ID of a Wix user (site owner, contributor, etc.). */
|
548
|
+
wixUserId?: string;
|
549
|
+
/** ID of an app. */
|
550
|
+
appId?: string;
|
551
|
+
/** @readonly */
|
552
|
+
identityType?: WebhookIdentityType$1;
|
553
|
+
}
|
554
|
+
/** @oneof */
|
555
|
+
interface IdentificationDataIdOneOf$1 {
|
556
|
+
/** ID of a site visitor that has not logged in to the site. */
|
557
|
+
anonymousVisitorId?: string;
|
558
|
+
/** ID of a site visitor that has logged in to the site. */
|
559
|
+
memberId?: string;
|
560
|
+
/** ID of a Wix user (site owner, contributor, etc.). */
|
561
|
+
wixUserId?: string;
|
562
|
+
/** ID of an app. */
|
563
|
+
appId?: string;
|
564
|
+
}
|
565
|
+
declare enum WebhookIdentityType$1 {
|
566
|
+
UNKNOWN = "UNKNOWN",
|
567
|
+
ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
|
568
|
+
MEMBER = "MEMBER",
|
569
|
+
WIX_USER = "WIX_USER",
|
570
|
+
APP = "APP"
|
571
|
+
}
|
572
|
+
interface CreateOfflineOrderResponse {
|
573
|
+
/** Order. */
|
574
|
+
order?: Order;
|
575
|
+
}
|
576
|
+
interface GetOfflineOrderPreviewResponse {
|
577
|
+
/** The previewed order, as if the plan had been ordered. */
|
578
|
+
order?: Order;
|
579
|
+
/**
|
580
|
+
* Whether this previewed order would exceed the permitted amount of purchases available
|
581
|
+
* for this plan for this buyer.
|
582
|
+
*
|
583
|
+
* Always `false` for plans that do not have purchase limits.
|
584
|
+
*/
|
585
|
+
purchaseLimitExceeded?: boolean;
|
586
|
+
}
|
587
|
+
interface GetPricePreviewResponse {
|
588
|
+
/**
|
589
|
+
* @internal
|
590
|
+
* @internal
|
591
|
+
* @deprecated __Deprecated.__ Use `prices` instead. This property will be removed on September 30, 2022.
|
592
|
+
* @replacedBy prices
|
593
|
+
* @removalDate 2022-10-01
|
594
|
+
*/
|
595
|
+
price?: PriceDetails;
|
596
|
+
/** Pricing details. */
|
597
|
+
prices?: SpannedPrice[];
|
598
|
+
}
|
599
|
+
interface OrderStartDateChanged {
|
600
|
+
/** Order whose `startDate` changed. */
|
601
|
+
order?: Order;
|
602
|
+
}
|
603
|
+
interface OrderPurchased {
|
604
|
+
/** Order that was paid for. If a free or an offline order, the order that was created. */
|
605
|
+
order?: Order;
|
606
|
+
}
|
607
|
+
interface OrderStarted {
|
608
|
+
/** Order that reached its `startDate`. */
|
609
|
+
order?: Order;
|
610
|
+
}
|
611
|
+
/**
|
612
|
+
* Triggered at the start of a new payment cycle for an existing order.
|
613
|
+
*
|
614
|
+
* This webhook does not trigger at the initial start of an offline order.
|
615
|
+
*/
|
616
|
+
interface OrderCycleStarted {
|
617
|
+
/** Order whose new cycle started. */
|
618
|
+
order?: Order;
|
619
|
+
/** Number of the payment cycle will be 0 when the order is in the free trial period. In other cases, the cycle number starts from 1. */
|
620
|
+
cycleNumber?: number;
|
621
|
+
}
|
622
|
+
/** Emitted when a recurring order is canceled for the next payment cycle */
|
623
|
+
interface OrderAutoRenewCanceled {
|
624
|
+
/** Order that is canceled, effective at the end of the current payment cycle. */
|
625
|
+
order?: Order;
|
626
|
+
}
|
627
|
+
interface OrderEnded {
|
628
|
+
/** Order that ended. */
|
629
|
+
order?: Order;
|
630
|
+
}
|
631
|
+
interface GetOrderResponse {
|
632
|
+
/** Order. */
|
633
|
+
order?: Order;
|
634
|
+
}
|
635
|
+
interface ListOrdersResponse {
|
636
|
+
/** List of orders. */
|
637
|
+
orders?: Order[];
|
638
|
+
/** Object containing paging-related data (number of orders returned, offset). */
|
639
|
+
pagingMetadata?: PagingMetadataV2$1;
|
640
|
+
}
|
641
|
+
interface OrderEndDatePostponed {
|
642
|
+
/** Order whose `endDate` was postponed. */
|
643
|
+
order?: Order;
|
644
|
+
}
|
645
|
+
interface OrderMarkedAsPaid {
|
646
|
+
/** Order that was marked as paid. */
|
647
|
+
order?: Order;
|
648
|
+
}
|
649
|
+
interface OrderPaused {
|
650
|
+
/** Paused order. */
|
651
|
+
order?: Order;
|
652
|
+
}
|
653
|
+
interface OrderResumed {
|
654
|
+
/** Resumed order. */
|
655
|
+
order?: Order;
|
656
|
+
}
|
657
|
+
interface MemberListOrdersResponseNonNullableFields {
|
658
|
+
orders: {
|
659
|
+
_id: string;
|
660
|
+
planId: string;
|
661
|
+
subscriptionId: string;
|
662
|
+
buyer?: {
|
663
|
+
memberId: string;
|
664
|
+
contactId: string;
|
665
|
+
};
|
666
|
+
priceDetails?: {
|
667
|
+
subscription?: {
|
668
|
+
cycleDuration?: {
|
669
|
+
unit: PeriodUnit$1;
|
670
|
+
};
|
671
|
+
};
|
672
|
+
singlePaymentForDuration?: {
|
673
|
+
unit: PeriodUnit$1;
|
674
|
+
};
|
675
|
+
subtotal: string;
|
676
|
+
discount: string;
|
677
|
+
tax?: {
|
678
|
+
name: string;
|
679
|
+
includedInPrice: boolean;
|
680
|
+
rate: string;
|
681
|
+
amount: string;
|
682
|
+
};
|
683
|
+
total: string;
|
684
|
+
planPrice: string;
|
685
|
+
currency: string;
|
686
|
+
coupon?: {
|
687
|
+
code: string;
|
688
|
+
amount: string;
|
689
|
+
_id: string;
|
690
|
+
};
|
691
|
+
};
|
692
|
+
pricing?: {
|
693
|
+
subscription?: {
|
694
|
+
cycleDuration?: {
|
695
|
+
unit: PeriodUnit$1;
|
696
|
+
};
|
697
|
+
};
|
698
|
+
singlePaymentForDuration?: {
|
699
|
+
unit: PeriodUnit$1;
|
700
|
+
};
|
701
|
+
prices: {
|
702
|
+
duration?: {
|
703
|
+
cycleFrom: number;
|
704
|
+
};
|
705
|
+
price?: {
|
706
|
+
subtotal: string;
|
707
|
+
coupon?: {
|
708
|
+
code: string;
|
709
|
+
amount: string;
|
710
|
+
_id: string;
|
711
|
+
};
|
712
|
+
discount: string;
|
713
|
+
tax?: {
|
714
|
+
name: string;
|
715
|
+
includedInPrice: boolean;
|
716
|
+
rate: string;
|
717
|
+
amount: string;
|
718
|
+
};
|
719
|
+
total: string;
|
720
|
+
currency: string;
|
721
|
+
proration: string;
|
722
|
+
};
|
723
|
+
}[];
|
724
|
+
};
|
725
|
+
type: OrderType;
|
726
|
+
status: OrderStatus;
|
727
|
+
cancellation?: {
|
728
|
+
cause: CancellationCause;
|
729
|
+
effectiveAt: CancellationEffectiveAt;
|
730
|
+
};
|
731
|
+
lastPaymentStatus: PaymentStatus;
|
732
|
+
pausePeriods: {
|
733
|
+
status: Status;
|
734
|
+
}[];
|
735
|
+
currentCycle?: {
|
736
|
+
index: number;
|
737
|
+
};
|
738
|
+
planName: string;
|
739
|
+
planDescription: string;
|
740
|
+
planPrice: string;
|
741
|
+
}[];
|
742
|
+
}
|
743
|
+
interface CreateOfflineOrderResponseNonNullableFields {
|
744
|
+
order?: {
|
745
|
+
_id: string;
|
746
|
+
planId: string;
|
747
|
+
subscriptionId: string;
|
748
|
+
buyer?: {
|
749
|
+
memberId: string;
|
750
|
+
contactId: string;
|
751
|
+
};
|
752
|
+
priceDetails?: {
|
753
|
+
subscription?: {
|
754
|
+
cycleDuration?: {
|
755
|
+
unit: PeriodUnit$1;
|
756
|
+
};
|
757
|
+
};
|
758
|
+
singlePaymentForDuration?: {
|
759
|
+
unit: PeriodUnit$1;
|
760
|
+
};
|
761
|
+
subtotal: string;
|
762
|
+
discount: string;
|
763
|
+
tax?: {
|
764
|
+
name: string;
|
765
|
+
includedInPrice: boolean;
|
766
|
+
rate: string;
|
767
|
+
amount: string;
|
768
|
+
};
|
769
|
+
total: string;
|
770
|
+
planPrice: string;
|
771
|
+
currency: string;
|
772
|
+
coupon?: {
|
773
|
+
code: string;
|
774
|
+
amount: string;
|
775
|
+
_id: string;
|
776
|
+
};
|
777
|
+
};
|
778
|
+
pricing?: {
|
779
|
+
subscription?: {
|
780
|
+
cycleDuration?: {
|
781
|
+
unit: PeriodUnit$1;
|
782
|
+
};
|
783
|
+
};
|
784
|
+
singlePaymentForDuration?: {
|
785
|
+
unit: PeriodUnit$1;
|
786
|
+
};
|
787
|
+
prices: {
|
788
|
+
duration?: {
|
789
|
+
cycleFrom: number;
|
790
|
+
};
|
791
|
+
price?: {
|
792
|
+
subtotal: string;
|
793
|
+
coupon?: {
|
794
|
+
code: string;
|
795
|
+
amount: string;
|
796
|
+
_id: string;
|
797
|
+
};
|
798
|
+
discount: string;
|
799
|
+
tax?: {
|
800
|
+
name: string;
|
801
|
+
includedInPrice: boolean;
|
802
|
+
rate: string;
|
803
|
+
amount: string;
|
804
|
+
};
|
805
|
+
total: string;
|
806
|
+
currency: string;
|
807
|
+
proration: string;
|
808
|
+
};
|
809
|
+
}[];
|
810
|
+
};
|
811
|
+
type: OrderType;
|
812
|
+
status: OrderStatus;
|
813
|
+
cancellation?: {
|
814
|
+
cause: CancellationCause;
|
815
|
+
effectiveAt: CancellationEffectiveAt;
|
816
|
+
};
|
817
|
+
lastPaymentStatus: PaymentStatus;
|
818
|
+
pausePeriods: {
|
819
|
+
status: Status;
|
820
|
+
}[];
|
821
|
+
currentCycle?: {
|
822
|
+
index: number;
|
823
|
+
};
|
824
|
+
planName: string;
|
825
|
+
planDescription: string;
|
826
|
+
planPrice: string;
|
827
|
+
};
|
828
|
+
}
|
829
|
+
interface GetOfflineOrderPreviewResponseNonNullableFields {
|
830
|
+
order?: {
|
831
|
+
_id: string;
|
832
|
+
planId: string;
|
833
|
+
subscriptionId: string;
|
834
|
+
buyer?: {
|
835
|
+
memberId: string;
|
836
|
+
contactId: string;
|
837
|
+
};
|
838
|
+
priceDetails?: {
|
839
|
+
subscription?: {
|
840
|
+
cycleDuration?: {
|
841
|
+
unit: PeriodUnit$1;
|
842
|
+
};
|
843
|
+
};
|
844
|
+
singlePaymentForDuration?: {
|
845
|
+
unit: PeriodUnit$1;
|
846
|
+
};
|
847
|
+
subtotal: string;
|
848
|
+
discount: string;
|
849
|
+
tax?: {
|
850
|
+
name: string;
|
851
|
+
includedInPrice: boolean;
|
852
|
+
rate: string;
|
853
|
+
amount: string;
|
854
|
+
};
|
855
|
+
total: string;
|
856
|
+
planPrice: string;
|
857
|
+
currency: string;
|
858
|
+
coupon?: {
|
859
|
+
code: string;
|
860
|
+
amount: string;
|
861
|
+
_id: string;
|
862
|
+
};
|
863
|
+
};
|
864
|
+
pricing?: {
|
865
|
+
subscription?: {
|
866
|
+
cycleDuration?: {
|
867
|
+
unit: PeriodUnit$1;
|
868
|
+
};
|
869
|
+
};
|
870
|
+
singlePaymentForDuration?: {
|
871
|
+
unit: PeriodUnit$1;
|
872
|
+
};
|
873
|
+
prices: {
|
874
|
+
duration?: {
|
875
|
+
cycleFrom: number;
|
876
|
+
};
|
877
|
+
price?: {
|
878
|
+
subtotal: string;
|
879
|
+
coupon?: {
|
880
|
+
code: string;
|
881
|
+
amount: string;
|
882
|
+
_id: string;
|
883
|
+
};
|
884
|
+
discount: string;
|
885
|
+
tax?: {
|
886
|
+
name: string;
|
887
|
+
includedInPrice: boolean;
|
888
|
+
rate: string;
|
889
|
+
amount: string;
|
890
|
+
};
|
891
|
+
total: string;
|
892
|
+
currency: string;
|
893
|
+
proration: string;
|
894
|
+
};
|
895
|
+
}[];
|
896
|
+
};
|
897
|
+
type: OrderType;
|
898
|
+
status: OrderStatus;
|
899
|
+
cancellation?: {
|
900
|
+
cause: CancellationCause;
|
901
|
+
effectiveAt: CancellationEffectiveAt;
|
902
|
+
};
|
903
|
+
lastPaymentStatus: PaymentStatus;
|
904
|
+
pausePeriods: {
|
905
|
+
status: Status;
|
906
|
+
}[];
|
907
|
+
currentCycle?: {
|
908
|
+
index: number;
|
909
|
+
};
|
910
|
+
planName: string;
|
911
|
+
planDescription: string;
|
912
|
+
planPrice: string;
|
913
|
+
};
|
914
|
+
purchaseLimitExceeded: boolean;
|
915
|
+
}
|
916
|
+
interface GetPricePreviewResponseNonNullableFields {
|
917
|
+
price?: {
|
918
|
+
subscription?: {
|
919
|
+
cycleDuration?: {
|
920
|
+
unit: PeriodUnit$1;
|
921
|
+
};
|
922
|
+
};
|
923
|
+
singlePaymentForDuration?: {
|
924
|
+
unit: PeriodUnit$1;
|
925
|
+
};
|
926
|
+
subtotal: string;
|
927
|
+
discount: string;
|
928
|
+
tax?: {
|
929
|
+
name: string;
|
930
|
+
includedInPrice: boolean;
|
931
|
+
rate: string;
|
932
|
+
amount: string;
|
933
|
+
};
|
934
|
+
total: string;
|
935
|
+
planPrice: string;
|
936
|
+
currency: string;
|
937
|
+
coupon?: {
|
938
|
+
code: string;
|
939
|
+
amount: string;
|
940
|
+
_id: string;
|
941
|
+
};
|
942
|
+
};
|
943
|
+
prices: {
|
944
|
+
duration?: {
|
945
|
+
cycleFrom: number;
|
946
|
+
};
|
947
|
+
price?: {
|
948
|
+
subtotal: string;
|
949
|
+
coupon?: {
|
950
|
+
code: string;
|
951
|
+
amount: string;
|
952
|
+
_id: string;
|
953
|
+
};
|
954
|
+
discount: string;
|
955
|
+
tax?: {
|
956
|
+
name: string;
|
957
|
+
includedInPrice: boolean;
|
958
|
+
rate: string;
|
959
|
+
amount: string;
|
960
|
+
};
|
961
|
+
total: string;
|
962
|
+
currency: string;
|
963
|
+
proration: string;
|
964
|
+
};
|
965
|
+
}[];
|
966
|
+
}
|
967
|
+
interface GetOrderResponseNonNullableFields {
|
968
|
+
order?: {
|
969
|
+
_id: string;
|
970
|
+
planId: string;
|
971
|
+
subscriptionId: string;
|
972
|
+
buyer?: {
|
973
|
+
memberId: string;
|
974
|
+
contactId: string;
|
975
|
+
};
|
976
|
+
priceDetails?: {
|
977
|
+
subscription?: {
|
978
|
+
cycleDuration?: {
|
979
|
+
unit: PeriodUnit$1;
|
980
|
+
};
|
981
|
+
};
|
982
|
+
singlePaymentForDuration?: {
|
983
|
+
unit: PeriodUnit$1;
|
984
|
+
};
|
985
|
+
subtotal: string;
|
986
|
+
discount: string;
|
987
|
+
tax?: {
|
988
|
+
name: string;
|
989
|
+
includedInPrice: boolean;
|
990
|
+
rate: string;
|
991
|
+
amount: string;
|
992
|
+
};
|
993
|
+
total: string;
|
994
|
+
planPrice: string;
|
995
|
+
currency: string;
|
996
|
+
coupon?: {
|
997
|
+
code: string;
|
998
|
+
amount: string;
|
999
|
+
_id: string;
|
1000
|
+
};
|
1001
|
+
};
|
1002
|
+
pricing?: {
|
1003
|
+
subscription?: {
|
1004
|
+
cycleDuration?: {
|
1005
|
+
unit: PeriodUnit$1;
|
1006
|
+
};
|
1007
|
+
};
|
1008
|
+
singlePaymentForDuration?: {
|
1009
|
+
unit: PeriodUnit$1;
|
1010
|
+
};
|
1011
|
+
prices: {
|
1012
|
+
duration?: {
|
1013
|
+
cycleFrom: number;
|
1014
|
+
};
|
1015
|
+
price?: {
|
1016
|
+
subtotal: string;
|
1017
|
+
coupon?: {
|
1018
|
+
code: string;
|
1019
|
+
amount: string;
|
1020
|
+
_id: string;
|
1021
|
+
};
|
1022
|
+
discount: string;
|
1023
|
+
tax?: {
|
1024
|
+
name: string;
|
1025
|
+
includedInPrice: boolean;
|
1026
|
+
rate: string;
|
1027
|
+
amount: string;
|
1028
|
+
};
|
1029
|
+
total: string;
|
1030
|
+
currency: string;
|
1031
|
+
proration: string;
|
1032
|
+
};
|
1033
|
+
}[];
|
1034
|
+
};
|
1035
|
+
type: OrderType;
|
1036
|
+
status: OrderStatus;
|
1037
|
+
cancellation?: {
|
1038
|
+
cause: CancellationCause;
|
1039
|
+
effectiveAt: CancellationEffectiveAt;
|
1040
|
+
};
|
1041
|
+
lastPaymentStatus: PaymentStatus;
|
1042
|
+
pausePeriods: {
|
1043
|
+
status: Status;
|
1044
|
+
}[];
|
1045
|
+
currentCycle?: {
|
1046
|
+
index: number;
|
1047
|
+
};
|
1048
|
+
planName: string;
|
1049
|
+
planDescription: string;
|
1050
|
+
planPrice: string;
|
1051
|
+
};
|
1052
|
+
}
|
1053
|
+
interface ListOrdersResponseNonNullableFields {
|
1054
|
+
orders: {
|
1055
|
+
_id: string;
|
1056
|
+
planId: string;
|
1057
|
+
subscriptionId: string;
|
1058
|
+
buyer?: {
|
1059
|
+
memberId: string;
|
1060
|
+
contactId: string;
|
1061
|
+
};
|
1062
|
+
priceDetails?: {
|
1063
|
+
subscription?: {
|
1064
|
+
cycleDuration?: {
|
1065
|
+
unit: PeriodUnit$1;
|
1066
|
+
};
|
1067
|
+
};
|
1068
|
+
singlePaymentForDuration?: {
|
1069
|
+
unit: PeriodUnit$1;
|
1070
|
+
};
|
1071
|
+
subtotal: string;
|
1072
|
+
discount: string;
|
1073
|
+
tax?: {
|
1074
|
+
name: string;
|
1075
|
+
includedInPrice: boolean;
|
1076
|
+
rate: string;
|
1077
|
+
amount: string;
|
1078
|
+
};
|
1079
|
+
total: string;
|
1080
|
+
planPrice: string;
|
1081
|
+
currency: string;
|
1082
|
+
coupon?: {
|
1083
|
+
code: string;
|
1084
|
+
amount: string;
|
1085
|
+
_id: string;
|
1086
|
+
};
|
1087
|
+
};
|
1088
|
+
pricing?: {
|
1089
|
+
subscription?: {
|
1090
|
+
cycleDuration?: {
|
1091
|
+
unit: PeriodUnit$1;
|
1092
|
+
};
|
1093
|
+
};
|
1094
|
+
singlePaymentForDuration?: {
|
1095
|
+
unit: PeriodUnit$1;
|
1096
|
+
};
|
1097
|
+
prices: {
|
1098
|
+
duration?: {
|
1099
|
+
cycleFrom: number;
|
1100
|
+
};
|
1101
|
+
price?: {
|
1102
|
+
subtotal: string;
|
1103
|
+
coupon?: {
|
1104
|
+
code: string;
|
1105
|
+
amount: string;
|
1106
|
+
_id: string;
|
1107
|
+
};
|
1108
|
+
discount: string;
|
1109
|
+
tax?: {
|
1110
|
+
name: string;
|
1111
|
+
includedInPrice: boolean;
|
1112
|
+
rate: string;
|
1113
|
+
amount: string;
|
1114
|
+
};
|
1115
|
+
total: string;
|
1116
|
+
currency: string;
|
1117
|
+
proration: string;
|
1118
|
+
};
|
1119
|
+
}[];
|
1120
|
+
};
|
1121
|
+
type: OrderType;
|
1122
|
+
status: OrderStatus;
|
1123
|
+
cancellation?: {
|
1124
|
+
cause: CancellationCause;
|
1125
|
+
effectiveAt: CancellationEffectiveAt;
|
1126
|
+
};
|
1127
|
+
lastPaymentStatus: PaymentStatus;
|
1128
|
+
pausePeriods: {
|
1129
|
+
status: Status;
|
1130
|
+
}[];
|
1131
|
+
currentCycle?: {
|
1132
|
+
index: number;
|
1133
|
+
};
|
1134
|
+
planName: string;
|
1135
|
+
planDescription: string;
|
1136
|
+
planPrice: string;
|
1137
|
+
}[];
|
1138
|
+
}
|
1139
|
+
interface BaseEventMetadata$1 {
|
1140
|
+
/** App instance ID. */
|
1141
|
+
instanceId?: string | null;
|
1142
|
+
/** Event type. */
|
1143
|
+
eventType?: string;
|
1144
|
+
/** The identification type and identity data. */
|
1145
|
+
identity?: IdentificationData$1;
|
1146
|
+
}
|
1147
|
+
interface EventMetadata$1 extends BaseEventMetadata$1 {
|
1148
|
+
/**
|
1149
|
+
* Unique event ID.
|
1150
|
+
* Allows clients to ignore duplicate webhooks.
|
1151
|
+
*/
|
1152
|
+
_id?: string;
|
1153
|
+
/**
|
1154
|
+
* Assumes actions are also always typed to an entity_type
|
1155
|
+
* Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
|
1156
|
+
*/
|
1157
|
+
entityFqdn?: string;
|
1158
|
+
/**
|
1159
|
+
* This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug)
|
1160
|
+
* This is although the created/updated/deleted notion is duplication of the oneof types
|
1161
|
+
* Example: created/updated/deleted/started/completed/email_opened
|
1162
|
+
*/
|
1163
|
+
slug?: string;
|
1164
|
+
/** ID of the entity associated with the event. */
|
1165
|
+
entityId?: string;
|
1166
|
+
/** Event timestamp. */
|
1167
|
+
eventTime?: Date;
|
1168
|
+
/**
|
1169
|
+
* Whether the event was triggered as a result of a privacy regulation application
|
1170
|
+
* (for example, GDPR).
|
1171
|
+
*/
|
1172
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
1173
|
+
/** If present, indicates the action that triggered the event. */
|
1174
|
+
originatedFrom?: string | null;
|
1175
|
+
/**
|
1176
|
+
* A sequence number defining the order of updates to the underlying entity.
|
1177
|
+
* For example, given that some entity was updated at 16:00 and than again at 16:01,
|
1178
|
+
* it is guaranteed that the sequence number of the second update is strictly higher than the first.
|
1179
|
+
* As the consumer, you can use this value to ensure that you handle messages in the correct order.
|
1180
|
+
* To do so, you will need to persist this number on your end, and compare the sequence number from the
|
1181
|
+
* message against the one you have stored. Given that the stored number is higher, you should ignore the message.
|
1182
|
+
*/
|
1183
|
+
entityEventSequence?: string | null;
|
1184
|
+
}
|
1185
|
+
interface OrderCanceledEnvelope {
|
1186
|
+
data: OrderCanceled;
|
1187
|
+
metadata: EventMetadata$1;
|
1188
|
+
}
|
1189
|
+
interface OrderCreatedEnvelope {
|
1190
|
+
entity: Order;
|
1191
|
+
metadata: EventMetadata$1;
|
1192
|
+
}
|
1193
|
+
interface OrderUpdatedEnvelope {
|
1194
|
+
entity: Order;
|
1195
|
+
metadata: EventMetadata$1;
|
1196
|
+
}
|
1197
|
+
interface OrderStartDateChangedEnvelope {
|
1198
|
+
data: OrderStartDateChanged;
|
1199
|
+
metadata: EventMetadata$1;
|
1200
|
+
}
|
1201
|
+
interface OrderPurchasedEnvelope {
|
1202
|
+
data: OrderPurchased;
|
1203
|
+
metadata: EventMetadata$1;
|
1204
|
+
}
|
1205
|
+
interface OrderStartedEnvelope {
|
1206
|
+
data: OrderStarted;
|
1207
|
+
metadata: EventMetadata$1;
|
1208
|
+
}
|
1209
|
+
interface OrderCycleStartedEnvelope {
|
1210
|
+
data: OrderCycleStarted;
|
1211
|
+
metadata: EventMetadata$1;
|
1212
|
+
}
|
1213
|
+
interface OrderAutoRenewCanceledEnvelope {
|
1214
|
+
data: OrderAutoRenewCanceled;
|
1215
|
+
metadata: EventMetadata$1;
|
1216
|
+
}
|
1217
|
+
interface OrderEndedEnvelope {
|
1218
|
+
data: OrderEnded;
|
1219
|
+
metadata: EventMetadata$1;
|
1220
|
+
}
|
1221
|
+
interface OrderEndDatePostponedEnvelope {
|
1222
|
+
data: OrderEndDatePostponed;
|
1223
|
+
metadata: EventMetadata$1;
|
1224
|
+
}
|
1225
|
+
interface OrderMarkedAsPaidEnvelope {
|
1226
|
+
data: OrderMarkedAsPaid;
|
1227
|
+
metadata: EventMetadata$1;
|
1228
|
+
}
|
1229
|
+
interface OrderPausedEnvelope {
|
1230
|
+
data: OrderPaused;
|
1231
|
+
metadata: EventMetadata$1;
|
1232
|
+
}
|
1233
|
+
interface OrderResumedEnvelope {
|
1234
|
+
data: OrderResumed;
|
1235
|
+
metadata: EventMetadata$1;
|
1236
|
+
}
|
1237
|
+
interface MemberGetOrderOptions {
|
1238
|
+
fieldSet?: Set;
|
1239
|
+
}
|
1240
|
+
interface MemberListOrdersOptions {
|
1241
|
+
/** Filter by plan IDs. */
|
1242
|
+
planIds?: string[];
|
1243
|
+
/** Filter for orders where auto renewal was canceled. */
|
1244
|
+
autoRenewCanceled?: boolean | null;
|
1245
|
+
/**
|
1246
|
+
* Filter by the order status. Supported values:
|
1247
|
+
* + `DRAFT`: Order has been initiated but payment hasn't been processed yet. The plan isn't yet available for use to the buyer.
|
1248
|
+
* + `PENDING`: Order has been purchased and its start date is set in the future.
|
1249
|
+
* + `ACTIVE`: Order has been processed. The plan is available for use.
|
1250
|
+
* + `PAUSED`: Order, and use of the plan, is [paused](#pauseorder). The order, and use of the plan, can be [resumed](#resumeorder).
|
1251
|
+
* + `ENDED`: Order has completed its duration and is no longer available for use.
|
1252
|
+
* + `CANCELED`: Order has been [canceled](#cancelorder).
|
1253
|
+
*/
|
1254
|
+
orderStatuses?: OrderStatus[];
|
1255
|
+
/**
|
1256
|
+
* Key Path to edit
|
1257
|
+
* ManagementListOrdersOptions.paymentStatuses
|
1258
|
+
* Production value
|
1259
|
+
* Filter by payment status.
|
1260
|
+
* Override
|
1261
|
+
* Filter by payment status.
|
1262
|
+
*
|
1263
|
+
* Supported values:
|
1264
|
+
* + `PAID`: The last payment was paid.
|
1265
|
+
* + `REFUNDED`: The last payment was refunded.
|
1266
|
+
* + `FAILED`: The last payment transaction didn't complete.
|
1267
|
+
* + `UNPAID`: The last payment wasn't paid.
|
1268
|
+
* + `PENDING`: Awaiting payment.
|
1269
|
+
* + `NOT_APPLICABLE`: No payment was necessary. For example, for free plans or free trials.
|
1270
|
+
* Mark down view
|
1271
|
+
* Filter by payment status.
|
1272
|
+
*
|
1273
|
+
* Supported values:
|
1274
|
+
*
|
1275
|
+
* PAID: The last payment was paid.
|
1276
|
+
* REFUNDED: The last payment was refunded.
|
1277
|
+
* FAILED: The last payment transaction didn't complete.
|
1278
|
+
* UNPAID: The last payment wasn't paid.
|
1279
|
+
* PENDING: Awaiting payment.
|
1280
|
+
* NOT_APPLICABLE: No payment was necessary. For example, for free plans or free trials.
|
1281
|
+
*/
|
1282
|
+
paymentStatuses?: PaymentStatus[];
|
1283
|
+
/**
|
1284
|
+
* Number of pricing plan orders to return.
|
1285
|
+
*
|
1286
|
+
* Default: `50`
|
1287
|
+
*/
|
1288
|
+
limit?: number | null;
|
1289
|
+
/** Number of orders to skip in the current sort order. */
|
1290
|
+
offset?: number | null;
|
1291
|
+
/**
|
1292
|
+
* Sort order.
|
1293
|
+
*
|
1294
|
+
* Use `ASC` for ascending order or `DESC` for descending order.
|
1295
|
+
*
|
1296
|
+
* Default: `ASC`
|
1297
|
+
*/
|
1298
|
+
sorting?: Sorting;
|
1299
|
+
fieldSet?: Set;
|
1300
|
+
}
|
1301
|
+
interface CreateOfflineOrderOptions {
|
1302
|
+
/**
|
1303
|
+
* Start date and time for the ordered plan.
|
1304
|
+
*
|
1305
|
+
* Default: Current date and time
|
1306
|
+
*/
|
1307
|
+
startDate?: Date;
|
1308
|
+
/**
|
1309
|
+
* Whether the order is paid.
|
1310
|
+
*
|
1311
|
+
* Default: `false`
|
1312
|
+
*/
|
1313
|
+
paid?: boolean | null;
|
1314
|
+
/** Coupon code to apply. */
|
1315
|
+
couponCode?: string | null;
|
1316
|
+
/** Form submission ID that was submitted together with the order. */
|
1317
|
+
submissionId?: string | null;
|
1318
|
+
}
|
1319
|
+
interface GetOfflineOrderPreviewOptions {
|
1320
|
+
/**
|
1321
|
+
* Start date and time for plan of the previewed order.
|
1322
|
+
*
|
1323
|
+
* Default: Current date and time
|
1324
|
+
*/
|
1325
|
+
startDate?: Date;
|
1326
|
+
/** Coupon code to apply. */
|
1327
|
+
couponCode?: string | null;
|
1328
|
+
}
|
1329
|
+
interface GetPricePreviewOptions {
|
1330
|
+
/** Coupon code to apply. */
|
1331
|
+
couponCode?: string | null;
|
1332
|
+
}
|
1333
|
+
interface ManagementGetOrderOptions {
|
1334
|
+
fieldSet?: Set;
|
1335
|
+
}
|
1336
|
+
interface ManagementListOrdersOptions {
|
1337
|
+
/** Filter by specific member IDs of buyers who ordered a pricing plan. */
|
1338
|
+
buyerIds?: string[];
|
1339
|
+
/** Filter by specific IDs of plans that were ordered. */
|
1340
|
+
planIds?: string[];
|
1341
|
+
/** Filter by whether or not the auto-renewal of recurring orders was canceled. */
|
1342
|
+
autoRenewCanceled?: boolean | null;
|
1343
|
+
/**
|
1344
|
+
* Filter by the order status. Supported values:
|
1345
|
+
* + `DRAFT`: Order has been initiated but payment hasn't been processed yet. The plan isn't yet available for use to the buyer.
|
1346
|
+
* + `PENDING`: Order has been purchased and its start date is set in the future.
|
1347
|
+
* + `ACTIVE`: Order has been processed. The plan is available for use.
|
1348
|
+
* + `PAUSED`: Order, and use of the plan, is [paused](#pauseorder). The order, and use of the plan, can be [resumed](#resumeorder).
|
1349
|
+
* + `ENDED`: Order has completed its duration and is no longer available for use.
|
1350
|
+
* + `CANCELED`: Order has been [canceled](#cancelorder).
|
1351
|
+
*/
|
1352
|
+
orderStatuses?: OrderStatus[];
|
1353
|
+
/**
|
1354
|
+
* Filter by payment status.
|
1355
|
+
*
|
1356
|
+
* Supported values:
|
1357
|
+
* + `PAID`: The last payment was paid.
|
1358
|
+
* + `REFUNDED`: The last payment was refunded.
|
1359
|
+
* + `FAILED`: The last payment transaction didn't complete.
|
1360
|
+
* + `UNPAID`: The last payment wasn't paid.
|
1361
|
+
* + `PENDING`: Awaiting payment.
|
1362
|
+
* + `NOT_APPLICABLE`: No payment was necessary. For example, for free plans or free trials.
|
1363
|
+
*/
|
1364
|
+
paymentStatuses?: PaymentStatus[];
|
1365
|
+
/**
|
1366
|
+
* Number of pricing plan orders to return.
|
1367
|
+
*
|
1368
|
+
* Default: `50`
|
1369
|
+
*/
|
1370
|
+
limit?: number | null;
|
1371
|
+
/** Number of orders to skip in the current sort order. */
|
1372
|
+
offset?: number | null;
|
1373
|
+
/**
|
1374
|
+
* Sort order.
|
1375
|
+
*
|
1376
|
+
* Use `ASC` for ascending order or `DESC` for descending order.
|
1377
|
+
*
|
1378
|
+
* Default: `DESC`
|
1379
|
+
*/
|
1380
|
+
sorting?: Sorting;
|
1381
|
+
/** Parameter to define amount of fields to return. FULL returns each order's submission data. Supported values: UNKNOWN_SET, BASIC, FULL */
|
1382
|
+
fieldSet?: Set;
|
1383
|
+
}
|
1384
|
+
|
1385
|
+
type RESTFunctionDescriptor<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient) => T;
|
1386
|
+
interface HttpClient {
|
1387
|
+
request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
|
1388
|
+
}
|
1389
|
+
type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
|
1390
|
+
type HttpResponse<T = any> = {
|
1391
|
+
data: T;
|
1392
|
+
status: number;
|
1393
|
+
statusText: string;
|
1394
|
+
headers: any;
|
1395
|
+
request?: any;
|
1396
|
+
};
|
1397
|
+
type RequestOptions<_TResponse = any, Data = any> = {
|
1398
|
+
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
1399
|
+
url: string;
|
1400
|
+
data?: Data;
|
1401
|
+
params?: URLSearchParams;
|
1402
|
+
} & APIMetadata;
|
1403
|
+
type APIMetadata = {
|
1404
|
+
methodFqn?: string;
|
1405
|
+
entityFqdn?: string;
|
1406
|
+
packageName?: string;
|
1407
|
+
};
|
1408
|
+
type BuildRESTFunction<T extends RESTFunctionDescriptor> = T extends RESTFunctionDescriptor<infer U> ? U : never;
|
1409
|
+
type EventDefinition<Payload = unknown, Type extends string = string> = {
|
1410
|
+
__type: 'event-definition';
|
1411
|
+
type: Type;
|
1412
|
+
isDomainEvent?: boolean;
|
1413
|
+
transformations?: unknown;
|
1414
|
+
__payload: Payload;
|
1415
|
+
};
|
1416
|
+
declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, _transformations?: unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
|
1417
|
+
type EventHandler<T extends EventDefinition> = (payload: T['__payload']) => void | Promise<void>;
|
1418
|
+
type BuildEventDefinition<T extends EventDefinition<any, string>> = (handler: EventHandler<T>) => void;
|
1419
|
+
|
1420
|
+
declare function memberGetOrder$1(httpClient: HttpClient): (_id: string, options?: MemberGetOrderOptions) => Promise<Order & {
|
1421
|
+
_id: string;
|
1422
|
+
planId: string;
|
1423
|
+
subscriptionId: string;
|
1424
|
+
buyer?: {
|
1425
|
+
memberId: string;
|
1426
|
+
contactId: string;
|
1427
|
+
} | undefined;
|
1428
|
+
priceDetails?: {
|
1429
|
+
subscription?: {
|
1430
|
+
cycleDuration?: {
|
1431
|
+
unit: PeriodUnit$1;
|
1432
|
+
} | undefined;
|
1433
|
+
} | undefined;
|
1434
|
+
singlePaymentForDuration?: {
|
1435
|
+
unit: PeriodUnit$1;
|
1436
|
+
} | undefined;
|
1437
|
+
subtotal: string;
|
1438
|
+
discount: string;
|
1439
|
+
tax?: {
|
1440
|
+
name: string;
|
1441
|
+
includedInPrice: boolean;
|
1442
|
+
rate: string;
|
1443
|
+
amount: string;
|
1444
|
+
} | undefined;
|
1445
|
+
total: string;
|
1446
|
+
planPrice: string;
|
1447
|
+
currency: string;
|
1448
|
+
coupon?: {
|
1449
|
+
code: string;
|
1450
|
+
amount: string;
|
1451
|
+
_id: string;
|
1452
|
+
} | undefined;
|
1453
|
+
} | undefined;
|
1454
|
+
pricing?: {
|
1455
|
+
subscription?: {
|
1456
|
+
cycleDuration?: {
|
1457
|
+
unit: PeriodUnit$1;
|
1458
|
+
} | undefined;
|
1459
|
+
} | undefined;
|
1460
|
+
singlePaymentForDuration?: {
|
1461
|
+
unit: PeriodUnit$1;
|
1462
|
+
} | undefined;
|
1463
|
+
prices: {
|
1464
|
+
duration?: {
|
1465
|
+
cycleFrom: number;
|
1466
|
+
} | undefined;
|
1467
|
+
price?: {
|
1468
|
+
subtotal: string;
|
1469
|
+
coupon?: {
|
1470
|
+
code: string;
|
1471
|
+
amount: string;
|
1472
|
+
_id: string;
|
1473
|
+
} | undefined;
|
1474
|
+
discount: string;
|
1475
|
+
tax?: {
|
1476
|
+
name: string;
|
1477
|
+
includedInPrice: boolean;
|
1478
|
+
rate: string;
|
1479
|
+
amount: string;
|
1480
|
+
} | undefined;
|
1481
|
+
total: string;
|
1482
|
+
currency: string;
|
1483
|
+
proration: string;
|
1484
|
+
} | undefined;
|
1485
|
+
}[];
|
1486
|
+
} | undefined;
|
1487
|
+
type: OrderType;
|
1488
|
+
status: OrderStatus;
|
1489
|
+
cancellation?: {
|
1490
|
+
cause: CancellationCause;
|
1491
|
+
effectiveAt: CancellationEffectiveAt;
|
1492
|
+
} | undefined;
|
1493
|
+
lastPaymentStatus: PaymentStatus;
|
1494
|
+
pausePeriods: {
|
1495
|
+
status: Status;
|
1496
|
+
}[];
|
1497
|
+
currentCycle?: {
|
1498
|
+
index: number;
|
1499
|
+
} | undefined;
|
1500
|
+
planName: string;
|
1501
|
+
planDescription: string;
|
1502
|
+
planPrice: string;
|
1503
|
+
}>;
|
1504
|
+
declare function memberListOrders$1(httpClient: HttpClient): (options?: MemberListOrdersOptions) => Promise<MemberListOrdersResponse & MemberListOrdersResponseNonNullableFields>;
|
1505
|
+
declare function requestCancellation$1(httpClient: HttpClient): (_id: string, effectiveAt: CancellationEffectiveAt) => Promise<void>;
|
1506
|
+
declare function createOfflineOrder$1(httpClient: HttpClient): (planId: string, memberId: string, options?: CreateOfflineOrderOptions) => Promise<CreateOfflineOrderResponse & CreateOfflineOrderResponseNonNullableFields>;
|
1507
|
+
declare function getOfflineOrderPreview$1(httpClient: HttpClient): (planId: string, memberId: string, options?: GetOfflineOrderPreviewOptions) => Promise<GetOfflineOrderPreviewResponse & GetOfflineOrderPreviewResponseNonNullableFields>;
|
1508
|
+
declare function getPricePreview$1(httpClient: HttpClient): (planId: string, options?: GetPricePreviewOptions) => Promise<GetPricePreviewResponse & GetPricePreviewResponseNonNullableFields>;
|
1509
|
+
declare function managementGetOrder$1(httpClient: HttpClient): (_id: string, options?: ManagementGetOrderOptions) => Promise<GetOrderResponse & GetOrderResponseNonNullableFields>;
|
1510
|
+
declare function managementListOrders$1(httpClient: HttpClient): (options?: ManagementListOrdersOptions) => Promise<ListOrdersResponse & ListOrdersResponseNonNullableFields>;
|
1511
|
+
declare function postponeEndDate$1(httpClient: HttpClient): (_id: string, endDate: Date) => Promise<void>;
|
1512
|
+
declare function cancelOrder$1(httpClient: HttpClient): (_id: string, effectiveAt: CancellationEffectiveAt) => Promise<void>;
|
1513
|
+
declare function markAsPaid$1(httpClient: HttpClient): (_id: string) => Promise<void>;
|
1514
|
+
declare function pauseOrder$1(httpClient: HttpClient): (_id: string) => Promise<void>;
|
1515
|
+
declare function resumeOrder$1(httpClient: HttpClient): (_id: string) => Promise<void>;
|
1516
|
+
declare const onOrderCanceled$1: EventDefinition<OrderCanceledEnvelope, "wix.pricing_plans.v2.order_canceled">;
|
1517
|
+
declare const onOrderCreated$1: EventDefinition<OrderCreatedEnvelope, "wix.pricing_plans.v2.order_created">;
|
1518
|
+
declare const onOrderUpdated$1: EventDefinition<OrderUpdatedEnvelope, "wix.pricing_plans.v2.order_updated">;
|
1519
|
+
declare const onOrderStartDateChanged$1: EventDefinition<OrderStartDateChangedEnvelope, "wix.pricing_plans.v2.order_start_date_changed">;
|
1520
|
+
declare const onOrderPurchased$1: EventDefinition<OrderPurchasedEnvelope, "wix.pricing_plans.v2.order_purchased">;
|
1521
|
+
declare const onOrderStarted$1: EventDefinition<OrderStartedEnvelope, "wix.pricing_plans.v2.order_started">;
|
1522
|
+
declare const onOrderCycleStarted$1: EventDefinition<OrderCycleStartedEnvelope, "wix.pricing_plans.v2.order_cycle_started">;
|
1523
|
+
declare const onOrderAutoRenewCanceled$1: EventDefinition<OrderAutoRenewCanceledEnvelope, "wix.pricing_plans.v2.order_auto_renew_canceled">;
|
1524
|
+
declare const onOrderEnded$1: EventDefinition<OrderEndedEnvelope, "wix.pricing_plans.v2.order_ended">;
|
1525
|
+
declare const onOrderEndDatePostponed$1: EventDefinition<OrderEndDatePostponedEnvelope, "wix.pricing_plans.v2.order_end_date_postponed">;
|
1526
|
+
declare const onOrderMarkedAsPaid$1: EventDefinition<OrderMarkedAsPaidEnvelope, "wix.pricing_plans.v2.order_marked_as_paid">;
|
1527
|
+
declare const onOrderPaused$1: EventDefinition<OrderPausedEnvelope, "wix.pricing_plans.v2.order_paused">;
|
1528
|
+
declare const onOrderResumed$1: EventDefinition<OrderResumedEnvelope, "wix.pricing_plans.v2.order_resumed">;
|
1529
|
+
|
1530
|
+
declare const memberGetOrder: BuildRESTFunction<typeof memberGetOrder$1>;
|
1531
|
+
declare const memberListOrders: BuildRESTFunction<typeof memberListOrders$1>;
|
1532
|
+
declare const requestCancellation: BuildRESTFunction<typeof requestCancellation$1>;
|
1533
|
+
declare const createOfflineOrder: BuildRESTFunction<typeof createOfflineOrder$1>;
|
1534
|
+
declare const getOfflineOrderPreview: BuildRESTFunction<typeof getOfflineOrderPreview$1>;
|
1535
|
+
declare const getPricePreview: BuildRESTFunction<typeof getPricePreview$1>;
|
1536
|
+
declare const managementGetOrder: BuildRESTFunction<typeof managementGetOrder$1>;
|
1537
|
+
declare const managementListOrders: BuildRESTFunction<typeof managementListOrders$1>;
|
1538
|
+
declare const postponeEndDate: BuildRESTFunction<typeof postponeEndDate$1>;
|
1539
|
+
declare const cancelOrder: BuildRESTFunction<typeof cancelOrder$1>;
|
1540
|
+
declare const markAsPaid: BuildRESTFunction<typeof markAsPaid$1>;
|
1541
|
+
declare const pauseOrder: BuildRESTFunction<typeof pauseOrder$1>;
|
1542
|
+
declare const resumeOrder: BuildRESTFunction<typeof resumeOrder$1>;
|
1543
|
+
declare const onOrderCanceled: BuildEventDefinition<typeof onOrderCanceled$1>;
|
1544
|
+
declare const onOrderCreated: BuildEventDefinition<typeof onOrderCreated$1>;
|
1545
|
+
declare const onOrderUpdated: BuildEventDefinition<typeof onOrderUpdated$1>;
|
1546
|
+
declare const onOrderStartDateChanged: BuildEventDefinition<typeof onOrderStartDateChanged$1>;
|
1547
|
+
declare const onOrderPurchased: BuildEventDefinition<typeof onOrderPurchased$1>;
|
1548
|
+
declare const onOrderStarted: BuildEventDefinition<typeof onOrderStarted$1>;
|
1549
|
+
declare const onOrderCycleStarted: BuildEventDefinition<typeof onOrderCycleStarted$1>;
|
1550
|
+
declare const onOrderAutoRenewCanceled: BuildEventDefinition<typeof onOrderAutoRenewCanceled$1>;
|
1551
|
+
declare const onOrderEnded: BuildEventDefinition<typeof onOrderEnded$1>;
|
1552
|
+
declare const onOrderEndDatePostponed: BuildEventDefinition<typeof onOrderEndDatePostponed$1>;
|
1553
|
+
declare const onOrderMarkedAsPaid: BuildEventDefinition<typeof onOrderMarkedAsPaid$1>;
|
1554
|
+
declare const onOrderPaused: BuildEventDefinition<typeof onOrderPaused$1>;
|
1555
|
+
declare const onOrderResumed: BuildEventDefinition<typeof onOrderResumed$1>;
|
1556
|
+
|
1557
|
+
declare const context$1_cancelOrder: typeof cancelOrder;
|
1558
|
+
declare const context$1_createOfflineOrder: typeof createOfflineOrder;
|
1559
|
+
declare const context$1_getOfflineOrderPreview: typeof getOfflineOrderPreview;
|
1560
|
+
declare const context$1_getPricePreview: typeof getPricePreview;
|
1561
|
+
declare const context$1_managementGetOrder: typeof managementGetOrder;
|
1562
|
+
declare const context$1_managementListOrders: typeof managementListOrders;
|
1563
|
+
declare const context$1_markAsPaid: typeof markAsPaid;
|
1564
|
+
declare const context$1_memberGetOrder: typeof memberGetOrder;
|
1565
|
+
declare const context$1_memberListOrders: typeof memberListOrders;
|
1566
|
+
declare const context$1_onOrderAutoRenewCanceled: typeof onOrderAutoRenewCanceled;
|
1567
|
+
declare const context$1_onOrderCanceled: typeof onOrderCanceled;
|
1568
|
+
declare const context$1_onOrderCreated: typeof onOrderCreated;
|
1569
|
+
declare const context$1_onOrderCycleStarted: typeof onOrderCycleStarted;
|
1570
|
+
declare const context$1_onOrderEndDatePostponed: typeof onOrderEndDatePostponed;
|
1571
|
+
declare const context$1_onOrderEnded: typeof onOrderEnded;
|
1572
|
+
declare const context$1_onOrderMarkedAsPaid: typeof onOrderMarkedAsPaid;
|
1573
|
+
declare const context$1_onOrderPaused: typeof onOrderPaused;
|
1574
|
+
declare const context$1_onOrderPurchased: typeof onOrderPurchased;
|
1575
|
+
declare const context$1_onOrderResumed: typeof onOrderResumed;
|
1576
|
+
declare const context$1_onOrderStartDateChanged: typeof onOrderStartDateChanged;
|
1577
|
+
declare const context$1_onOrderStarted: typeof onOrderStarted;
|
1578
|
+
declare const context$1_onOrderUpdated: typeof onOrderUpdated;
|
1579
|
+
declare const context$1_pauseOrder: typeof pauseOrder;
|
1580
|
+
declare const context$1_postponeEndDate: typeof postponeEndDate;
|
1581
|
+
declare const context$1_requestCancellation: typeof requestCancellation;
|
1582
|
+
declare const context$1_resumeOrder: typeof resumeOrder;
|
1583
|
+
declare namespace context$1 {
|
1584
|
+
export { context$1_cancelOrder as cancelOrder, context$1_createOfflineOrder as createOfflineOrder, context$1_getOfflineOrderPreview as getOfflineOrderPreview, context$1_getPricePreview as getPricePreview, context$1_managementGetOrder as managementGetOrder, context$1_managementListOrders as managementListOrders, context$1_markAsPaid as markAsPaid, context$1_memberGetOrder as memberGetOrder, context$1_memberListOrders as memberListOrders, context$1_onOrderAutoRenewCanceled as onOrderAutoRenewCanceled, context$1_onOrderCanceled as onOrderCanceled, context$1_onOrderCreated as onOrderCreated, context$1_onOrderCycleStarted as onOrderCycleStarted, context$1_onOrderEndDatePostponed as onOrderEndDatePostponed, context$1_onOrderEnded as onOrderEnded, context$1_onOrderMarkedAsPaid as onOrderMarkedAsPaid, context$1_onOrderPaused as onOrderPaused, context$1_onOrderPurchased as onOrderPurchased, context$1_onOrderResumed as onOrderResumed, context$1_onOrderStartDateChanged as onOrderStartDateChanged, context$1_onOrderStarted as onOrderStarted, context$1_onOrderUpdated as onOrderUpdated, context$1_pauseOrder as pauseOrder, context$1_postponeEndDate as postponeEndDate, context$1_requestCancellation as requestCancellation, context$1_resumeOrder as resumeOrder };
|
1585
|
+
}
|
1586
|
+
|
1587
|
+
/** Information about the pricing plan. */
|
1588
|
+
interface Plan {
|
1589
|
+
/**
|
1590
|
+
* Plan ID.
|
1591
|
+
* @readonly
|
1592
|
+
*/
|
1593
|
+
_id?: string;
|
1594
|
+
/** Plan name. */
|
1595
|
+
name?: string | null;
|
1596
|
+
/** Plan description. */
|
1597
|
+
description?: string | null;
|
1598
|
+
/**
|
1599
|
+
* List of text strings that promote what is included with this plan.
|
1600
|
+
*
|
1601
|
+
* For example, "Plenty of parking" or "Free gift on your birthday".
|
1602
|
+
*/
|
1603
|
+
perks?: StringList;
|
1604
|
+
/** Plan price, payment schedule, and expiration. */
|
1605
|
+
pricing?: Pricing;
|
1606
|
+
/** Whether the plan is public (visible to site visitors and members). */
|
1607
|
+
public?: boolean | null;
|
1608
|
+
/**
|
1609
|
+
* Whether the plan is archived. Archived plans are not visible and can't be purchased anymore, but existing purchases remain in effect.
|
1610
|
+
* @readonly
|
1611
|
+
*/
|
1612
|
+
archived?: boolean;
|
1613
|
+
/**
|
1614
|
+
* Whether the plan is marked as primary. If `true`, the plan is highlighted on the site with a custom ribbon.
|
1615
|
+
*
|
1616
|
+
* Default: `false`.
|
1617
|
+
* @readonly
|
1618
|
+
*/
|
1619
|
+
primary?: boolean;
|
1620
|
+
/**
|
1621
|
+
* Whether the plan has any orders (including pending and unpaid orders).
|
1622
|
+
* @readonly
|
1623
|
+
*/
|
1624
|
+
hasOrders?: boolean;
|
1625
|
+
/**
|
1626
|
+
* Date plan was created.
|
1627
|
+
* @readonly
|
1628
|
+
*/
|
1629
|
+
_createdDate?: Date;
|
1630
|
+
/**
|
1631
|
+
* Date plan was last updated.
|
1632
|
+
* @readonly
|
1633
|
+
*/
|
1634
|
+
_updatedDate?: Date;
|
1635
|
+
/**
|
1636
|
+
* URL-friendly version of plan name. Unique across all plans in the same site.
|
1637
|
+
* @readonly
|
1638
|
+
*/
|
1639
|
+
slug?: string | null;
|
1640
|
+
/**
|
1641
|
+
* Number of times the same buyer can purchase the plan. Currently limited to support:
|
1642
|
+
* - Empty value or a value of `0`, meaning no limitation.
|
1643
|
+
* - Value of `1`, meaning limited to one purchase per buyer.
|
1644
|
+
*/
|
1645
|
+
maxPurchasesPerBuyer?: number | null;
|
1646
|
+
/**
|
1647
|
+
* Whether the buyer can start the plan at a later date.
|
1648
|
+
*
|
1649
|
+
* Default: `false`.
|
1650
|
+
*
|
1651
|
+
*/
|
1652
|
+
allowFutureStartDate?: boolean | null;
|
1653
|
+
/**
|
1654
|
+
* Whether the buyer is allowed to cancel their plan. If `false`, calling the [`requestCancellation()`](https://www.wix.com/velo/reference/wix-pricing-plans-v2/orders/requestcancellation) function returns an error.
|
1655
|
+
*
|
1656
|
+
* Default: `true`.
|
1657
|
+
*
|
1658
|
+
*/
|
1659
|
+
buyerCanCancel?: boolean | null;
|
1660
|
+
/** Any terms and conditions that apply to the plan. This information will be displayed during checkout. */
|
1661
|
+
termsAndConditions?: string | null;
|
1662
|
+
/** ID of the form associated with the plan at checkout. */
|
1663
|
+
formId?: string | null;
|
1664
|
+
}
|
1665
|
+
/** This wrapper type exist in order to distinguish an empty string list from no list at all in update requests. */
|
1666
|
+
interface StringList {
|
1667
|
+
/** List of strings */
|
1668
|
+
values?: string[];
|
1669
|
+
}
|
1670
|
+
/** Plan pricing information. Includes the price of the plan and payment details. */
|
1671
|
+
interface Pricing extends PricingPricingModelOneOf {
|
1672
|
+
/**
|
1673
|
+
* Pricing model indicating that the plan has recurring payments.
|
1674
|
+
*
|
1675
|
+
* Note: This type of subscription is not a "Wix subscription," which encompasses various types of subscriptions, such as Wix Stores subscriptions, Wix invoice subscriptions, and *all* pricing plan models.
|
1676
|
+
*/
|
1677
|
+
subscription?: Recurrence;
|
1678
|
+
/** Pricing model indicating a single payment per cycle and the length of the cycle. The cycle is the duration of the plan, not a payment cycle. */
|
1679
|
+
singlePaymentForDuration?: Duration;
|
1680
|
+
/** Pricing model indicating the plan is paid in one single payment. The plan is valid until canceled. */
|
1681
|
+
singlePaymentUnlimited?: boolean | null;
|
1682
|
+
/** Amount for a single payment. For subscriptions, this is the amount to pay each payment cycle and it is required. For plans that are not recurring plans, it is the single payment amount for the whole subscription. */
|
1683
|
+
price?: Money;
|
1684
|
+
/** Free trial period for the plan in days. Available only for recurring plans, meaning plans whose pricing model is `subscription`. Set to `0` to remove the free trial. */
|
1685
|
+
freeTrialDays?: number | null;
|
1686
|
+
}
|
1687
|
+
/** @oneof */
|
1688
|
+
interface PricingPricingModelOneOf {
|
1689
|
+
/** Plan has recurring payments. */
|
1690
|
+
subscription?: Recurrence;
|
1691
|
+
/** One time payment, plan is valid for the specified duration. */
|
1692
|
+
singlePaymentForDuration?: Duration;
|
1693
|
+
/** One time payment, plan is valid until it is canceled. */
|
1694
|
+
singlePaymentUnlimited?: boolean | null;
|
1695
|
+
}
|
1696
|
+
/** An object specifying how often and for how long payments recur (may be forever). */
|
1697
|
+
interface Recurrence {
|
1698
|
+
/** Length of one payment cycle. For example, 1 month to have monthly payments. Multiply `cycleDuration`'s `count` by `cycleCount` to get the subscription duration. Currently, only a value of `1` is supported. */
|
1699
|
+
cycleDuration?: Duration;
|
1700
|
+
/**
|
1701
|
+
* Amount of payment cycles the subscription is valid for.
|
1702
|
+
*
|
1703
|
+
* `0` for unlimited plans or for plans that are valid until canceled.
|
1704
|
+
*/
|
1705
|
+
cycleCount?: number | null;
|
1706
|
+
}
|
1707
|
+
/** A duration expressed in number of time units. */
|
1708
|
+
interface Duration {
|
1709
|
+
/** Number of days days, months, weeks, or years in a single payment cycle. Currently limited to support only `1`. */
|
1710
|
+
count?: number | null;
|
1711
|
+
/** Unit of time for the cycle duration. */
|
1712
|
+
unit?: PeriodUnit;
|
1713
|
+
}
|
1714
|
+
declare enum PeriodUnit {
|
1715
|
+
UNDEFINED = "UNDEFINED",
|
1716
|
+
DAY = "DAY",
|
1717
|
+
WEEK = "WEEK",
|
1718
|
+
MONTH = "MONTH",
|
1719
|
+
YEAR = "YEAR"
|
1720
|
+
}
|
1721
|
+
interface Money {
|
1722
|
+
/** Monetary amount. Decimal string with a period as a decimal separator. For example, `'3.99'`. Cannot be a negative value. */
|
1723
|
+
value?: string;
|
1724
|
+
/**
|
1725
|
+
* Currency code. Three-letter currency code in
|
1726
|
+
* [ISO-4217 alphabetic](https://en.wikipedia.org/wiki/ISO_4217#Active_codes) format. For example, `'USD'`.
|
1727
|
+
*/
|
1728
|
+
currency?: string;
|
1729
|
+
}
|
1730
|
+
interface ListPublicPlansResponse {
|
1731
|
+
/** List of public pricing plans. */
|
1732
|
+
plans?: PublicPlan[];
|
1733
|
+
/** Details on the paged set of public pricing plans returned. */
|
1734
|
+
pagingMetadata?: PagingMetadataV2;
|
1735
|
+
}
|
1736
|
+
/** Public plan entity containing information about the pricing plan. Can be read by any site member or visitor. */
|
1737
|
+
interface PublicPlan {
|
1738
|
+
/** Plan ID. */
|
1739
|
+
_id?: string;
|
1740
|
+
/** Plan name. */
|
1741
|
+
name?: string | null;
|
1742
|
+
/** Plan description. */
|
1743
|
+
description?: string | null;
|
1744
|
+
/** What is included with this plan (e.g., 1 weekly entrance to a specific class). */
|
1745
|
+
perks?: StringList;
|
1746
|
+
/** Plan price, payment schedule, and expiration. */
|
1747
|
+
pricing?: Pricing;
|
1748
|
+
/** Whether the plan is marked as primary. */
|
1749
|
+
primary?: boolean;
|
1750
|
+
/** Date plan was created. */
|
1751
|
+
_createdDate?: Date;
|
1752
|
+
/** Date plan was last updated. */
|
1753
|
+
_updatedDate?: Date;
|
1754
|
+
/** URL-friendly version of plan name. Unique across all plans in the same site. */
|
1755
|
+
slug?: string | null;
|
1756
|
+
/** Number of times the same buyer can purchase the plan. An empty value or a value of zero means no limitation. */
|
1757
|
+
maxPurchasesPerBuyer?: number | null;
|
1758
|
+
/** Whether the buyer can start the plan at a later date. Defaults to false. */
|
1759
|
+
allowFutureStartDate?: boolean | null;
|
1760
|
+
/** Whether the buyer is allowed to cancel their plan. Defaults to false. */
|
1761
|
+
buyerCanCancel?: boolean | null;
|
1762
|
+
/** Any terms and conditions that apply to the plan. This information will be displayed during checkout. */
|
1763
|
+
termsAndConditions?: string | null;
|
1764
|
+
/** ID of the form associated with the plan at checkout. */
|
1765
|
+
formId?: string | null;
|
1766
|
+
}
|
1767
|
+
interface PagingMetadataV2 {
|
1768
|
+
/** Number of items returned in the response. */
|
1769
|
+
count?: number | null;
|
1770
|
+
/** Offset that was requested. */
|
1771
|
+
offset?: number | null;
|
1772
|
+
/** Total number of items that match the query. Returned if offset paging is used and the `tooManyToCount` flag is not set. */
|
1773
|
+
total?: number | null;
|
1774
|
+
/** Flag that indicates the server failed to calculate the `total` field. */
|
1775
|
+
tooManyToCount?: boolean | null;
|
1776
|
+
/** Cursors to navigate through the result pages using `next` and `prev`. Returned if cursor paging is used. */
|
1777
|
+
cursors?: Cursors;
|
1778
|
+
}
|
1779
|
+
interface Cursors {
|
1780
|
+
/** Cursor string pointing to the next page in the list of results. */
|
1781
|
+
next?: string | null;
|
1782
|
+
/** Cursor pointing to the previous page in the list of results. */
|
1783
|
+
prev?: string | null;
|
1784
|
+
}
|
1785
|
+
declare enum ArchivedFilter {
|
1786
|
+
/** Returns all plans that are active. */
|
1787
|
+
ACTIVE = "ACTIVE",
|
1788
|
+
/** Returns all plans that are archived. */
|
1789
|
+
ARCHIVED = "ARCHIVED",
|
1790
|
+
/** Returns all plans that are active and archived. */
|
1791
|
+
ARCHIVED_AND_ACTIVE = "ARCHIVED_AND_ACTIVE"
|
1792
|
+
}
|
1793
|
+
declare enum PublicFilter {
|
1794
|
+
/** Returns all public and hidden plans. */
|
1795
|
+
PUBLIC_AND_HIDDEN = "PUBLIC_AND_HIDDEN",
|
1796
|
+
/** Returns only public plans. */
|
1797
|
+
PUBLIC = "PUBLIC",
|
1798
|
+
/** Returns only hidden plans. */
|
1799
|
+
HIDDEN = "HIDDEN"
|
1800
|
+
}
|
1801
|
+
interface ListPlansResponse {
|
1802
|
+
/** List of all public and hidden pricing plans. */
|
1803
|
+
plans?: Plan[];
|
1804
|
+
/** Details on the paged set of pricing plans returned. */
|
1805
|
+
pagingMetadata?: PagingMetadataV2;
|
1806
|
+
}
|
1807
|
+
interface GetPlanStatsResponse {
|
1808
|
+
/** Total number of plans created, including active plans (both public and hidden) and archived plans. */
|
1809
|
+
totalPlans?: number;
|
1810
|
+
}
|
1811
|
+
interface BuyerCanCancelUpdated {
|
1812
|
+
plan?: Plan;
|
1813
|
+
}
|
1814
|
+
interface SetPlanVisibilityResponse {
|
1815
|
+
/** Plan info. */
|
1816
|
+
plan?: Plan;
|
1817
|
+
}
|
1818
|
+
interface MakePlanPrimaryResponse {
|
1819
|
+
/** Primary plan info. */
|
1820
|
+
plan?: Plan;
|
1821
|
+
}
|
1822
|
+
interface ArchivePlanResponse {
|
1823
|
+
/** Archived plan info. */
|
1824
|
+
plan?: Plan;
|
1825
|
+
}
|
1826
|
+
interface PlanArchived {
|
1827
|
+
plan?: Plan;
|
1828
|
+
}
|
1829
|
+
interface IdentificationData extends IdentificationDataIdOneOf {
|
1830
|
+
/** ID of a site visitor that has not logged in to the site. */
|
1831
|
+
anonymousVisitorId?: string;
|
1832
|
+
/** ID of a site visitor that has logged in to the site. */
|
1833
|
+
memberId?: string;
|
1834
|
+
/** ID of a Wix user (site owner, contributor, etc.). */
|
1835
|
+
wixUserId?: string;
|
1836
|
+
/** ID of an app. */
|
1837
|
+
appId?: string;
|
1838
|
+
/** @readonly */
|
1839
|
+
identityType?: WebhookIdentityType;
|
1840
|
+
}
|
1841
|
+
/** @oneof */
|
1842
|
+
interface IdentificationDataIdOneOf {
|
1843
|
+
/** ID of a site visitor that has not logged in to the site. */
|
1844
|
+
anonymousVisitorId?: string;
|
1845
|
+
/** ID of a site visitor that has logged in to the site. */
|
1846
|
+
memberId?: string;
|
1847
|
+
/** ID of a Wix user (site owner, contributor, etc.). */
|
1848
|
+
wixUserId?: string;
|
1849
|
+
/** ID of an app. */
|
1850
|
+
appId?: string;
|
1851
|
+
}
|
1852
|
+
declare enum WebhookIdentityType {
|
1853
|
+
UNKNOWN = "UNKNOWN",
|
1854
|
+
ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
|
1855
|
+
MEMBER = "MEMBER",
|
1856
|
+
WIX_USER = "WIX_USER",
|
1857
|
+
APP = "APP"
|
1858
|
+
}
|
1859
|
+
interface ListPublicPlansResponseNonNullableFields {
|
1860
|
+
plans: {
|
1861
|
+
_id: string;
|
1862
|
+
perks?: {
|
1863
|
+
values: string[];
|
1864
|
+
};
|
1865
|
+
pricing?: {
|
1866
|
+
subscription?: {
|
1867
|
+
cycleDuration?: {
|
1868
|
+
unit: PeriodUnit;
|
1869
|
+
};
|
1870
|
+
};
|
1871
|
+
singlePaymentForDuration?: {
|
1872
|
+
unit: PeriodUnit;
|
1873
|
+
};
|
1874
|
+
price?: {
|
1875
|
+
value: string;
|
1876
|
+
currency: string;
|
1877
|
+
};
|
1878
|
+
};
|
1879
|
+
primary: boolean;
|
1880
|
+
}[];
|
1881
|
+
}
|
1882
|
+
interface ListPlansResponseNonNullableFields {
|
1883
|
+
plans: {
|
1884
|
+
_id: string;
|
1885
|
+
perks?: {
|
1886
|
+
values: string[];
|
1887
|
+
};
|
1888
|
+
pricing?: {
|
1889
|
+
subscription?: {
|
1890
|
+
cycleDuration?: {
|
1891
|
+
unit: PeriodUnit;
|
1892
|
+
};
|
1893
|
+
};
|
1894
|
+
singlePaymentForDuration?: {
|
1895
|
+
unit: PeriodUnit;
|
1896
|
+
};
|
1897
|
+
price?: {
|
1898
|
+
value: string;
|
1899
|
+
currency: string;
|
1900
|
+
};
|
1901
|
+
};
|
1902
|
+
archived: boolean;
|
1903
|
+
primary: boolean;
|
1904
|
+
hasOrders: boolean;
|
1905
|
+
}[];
|
1906
|
+
}
|
1907
|
+
interface GetPlanStatsResponseNonNullableFields {
|
1908
|
+
totalPlans: number;
|
1909
|
+
}
|
1910
|
+
interface SetPlanVisibilityResponseNonNullableFields {
|
1911
|
+
plan?: {
|
1912
|
+
_id: string;
|
1913
|
+
perks?: {
|
1914
|
+
values: string[];
|
1915
|
+
};
|
1916
|
+
pricing?: {
|
1917
|
+
subscription?: {
|
1918
|
+
cycleDuration?: {
|
1919
|
+
unit: PeriodUnit;
|
1920
|
+
};
|
1921
|
+
};
|
1922
|
+
singlePaymentForDuration?: {
|
1923
|
+
unit: PeriodUnit;
|
1924
|
+
};
|
1925
|
+
price?: {
|
1926
|
+
value: string;
|
1927
|
+
currency: string;
|
1928
|
+
};
|
1929
|
+
};
|
1930
|
+
archived: boolean;
|
1931
|
+
primary: boolean;
|
1932
|
+
hasOrders: boolean;
|
1933
|
+
};
|
1934
|
+
}
|
1935
|
+
interface MakePlanPrimaryResponseNonNullableFields {
|
1936
|
+
plan?: {
|
1937
|
+
_id: string;
|
1938
|
+
perks?: {
|
1939
|
+
values: string[];
|
1940
|
+
};
|
1941
|
+
pricing?: {
|
1942
|
+
subscription?: {
|
1943
|
+
cycleDuration?: {
|
1944
|
+
unit: PeriodUnit;
|
1945
|
+
};
|
1946
|
+
};
|
1947
|
+
singlePaymentForDuration?: {
|
1948
|
+
unit: PeriodUnit;
|
1949
|
+
};
|
1950
|
+
price?: {
|
1951
|
+
value: string;
|
1952
|
+
currency: string;
|
1953
|
+
};
|
1954
|
+
};
|
1955
|
+
archived: boolean;
|
1956
|
+
primary: boolean;
|
1957
|
+
hasOrders: boolean;
|
1958
|
+
};
|
1959
|
+
}
|
1960
|
+
interface ArchivePlanResponseNonNullableFields {
|
1961
|
+
plan?: {
|
1962
|
+
_id: string;
|
1963
|
+
perks?: {
|
1964
|
+
values: string[];
|
1965
|
+
};
|
1966
|
+
pricing?: {
|
1967
|
+
subscription?: {
|
1968
|
+
cycleDuration?: {
|
1969
|
+
unit: PeriodUnit;
|
1970
|
+
};
|
1971
|
+
};
|
1972
|
+
singlePaymentForDuration?: {
|
1973
|
+
unit: PeriodUnit;
|
1974
|
+
};
|
1975
|
+
price?: {
|
1976
|
+
value: string;
|
1977
|
+
currency: string;
|
1978
|
+
};
|
1979
|
+
};
|
1980
|
+
archived: boolean;
|
1981
|
+
primary: boolean;
|
1982
|
+
hasOrders: boolean;
|
1983
|
+
};
|
1984
|
+
}
|
1985
|
+
interface BaseEventMetadata {
|
1986
|
+
/** App instance ID. */
|
1987
|
+
instanceId?: string | null;
|
1988
|
+
/** Event type. */
|
1989
|
+
eventType?: string;
|
1990
|
+
/** The identification type and identity data. */
|
1991
|
+
identity?: IdentificationData;
|
1992
|
+
}
|
1993
|
+
interface EventMetadata extends BaseEventMetadata {
|
1994
|
+
/**
|
1995
|
+
* Unique event ID.
|
1996
|
+
* Allows clients to ignore duplicate webhooks.
|
1997
|
+
*/
|
1998
|
+
_id?: string;
|
1999
|
+
/**
|
2000
|
+
* Assumes actions are also always typed to an entity_type
|
2001
|
+
* Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
|
2002
|
+
*/
|
2003
|
+
entityFqdn?: string;
|
2004
|
+
/**
|
2005
|
+
* This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug)
|
2006
|
+
* This is although the created/updated/deleted notion is duplication of the oneof types
|
2007
|
+
* Example: created/updated/deleted/started/completed/email_opened
|
2008
|
+
*/
|
2009
|
+
slug?: string;
|
2010
|
+
/** ID of the entity associated with the event. */
|
2011
|
+
entityId?: string;
|
2012
|
+
/** Event timestamp. */
|
2013
|
+
eventTime?: Date;
|
2014
|
+
/**
|
2015
|
+
* Whether the event was triggered as a result of a privacy regulation application
|
2016
|
+
* (for example, GDPR).
|
2017
|
+
*/
|
2018
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
2019
|
+
/** If present, indicates the action that triggered the event. */
|
2020
|
+
originatedFrom?: string | null;
|
2021
|
+
/**
|
2022
|
+
* A sequence number defining the order of updates to the underlying entity.
|
2023
|
+
* For example, given that some entity was updated at 16:00 and than again at 16:01,
|
2024
|
+
* it is guaranteed that the sequence number of the second update is strictly higher than the first.
|
2025
|
+
* As the consumer, you can use this value to ensure that you handle messages in the correct order.
|
2026
|
+
* To do so, you will need to persist this number on your end, and compare the sequence number from the
|
2027
|
+
* message against the one you have stored. Given that the stored number is higher, you should ignore the message.
|
2028
|
+
*/
|
2029
|
+
entityEventSequence?: string | null;
|
2030
|
+
}
|
2031
|
+
interface PlanUpdatedEnvelope {
|
2032
|
+
entity: Plan;
|
2033
|
+
metadata: EventMetadata;
|
2034
|
+
}
|
2035
|
+
interface PlanCreatedEnvelope {
|
2036
|
+
entity: Plan;
|
2037
|
+
metadata: EventMetadata;
|
2038
|
+
}
|
2039
|
+
interface PlanBuyerCanCancelUpdatedEnvelope {
|
2040
|
+
data: BuyerCanCancelUpdated;
|
2041
|
+
metadata: EventMetadata;
|
2042
|
+
}
|
2043
|
+
interface PlanArchivedEnvelope {
|
2044
|
+
data: PlanArchived;
|
2045
|
+
metadata: EventMetadata;
|
2046
|
+
}
|
2047
|
+
interface ListPublicPlansOptions {
|
2048
|
+
/**
|
2049
|
+
* Number of pricing plans to list.
|
2050
|
+
*
|
2051
|
+
* Default: `75`.
|
2052
|
+
*/
|
2053
|
+
limit?: number | null;
|
2054
|
+
/**
|
2055
|
+
* Number of pricing plans to skip.
|
2056
|
+
*
|
2057
|
+
* Default: `0`.
|
2058
|
+
*/
|
2059
|
+
offset?: number | null;
|
2060
|
+
/** IDs of public plans to list. If non-existent IDs are specified, they are ignored and don't cause errors. If no IDs are specified, all public are listed according to the [order](#arrangeplans) displayed in the Dashboard. You can pass a maximum of 100 IDs. */
|
2061
|
+
planIds?: string[];
|
2062
|
+
}
|
2063
|
+
interface QueryOffsetResult {
|
2064
|
+
currentPage: number | undefined;
|
2065
|
+
totalPages: number | undefined;
|
2066
|
+
totalCount: number | undefined;
|
2067
|
+
hasNext: () => boolean;
|
2068
|
+
hasPrev: () => boolean;
|
2069
|
+
length: number;
|
2070
|
+
pageSize: number;
|
2071
|
+
}
|
2072
|
+
interface PlansQueryResult extends QueryOffsetResult {
|
2073
|
+
items: PublicPlan[];
|
2074
|
+
query: PlansQueryBuilder;
|
2075
|
+
next: () => Promise<PlansQueryResult>;
|
2076
|
+
prev: () => Promise<PlansQueryResult>;
|
2077
|
+
}
|
2078
|
+
interface PlansQueryBuilder {
|
2079
|
+
/** @param propertyName - Property whose value is compared with `value`.
|
2080
|
+
* @param value - Value to compare against.
|
2081
|
+
*/
|
2082
|
+
eq: (propertyName: '_id' | 'primary' | '_createdDate' | '_updatedDate' | 'slug', value: any) => PlansQueryBuilder;
|
2083
|
+
/** @param propertyName - Property whose value is compared with `value`.
|
2084
|
+
* @param value - Value to compare against.
|
2085
|
+
*/
|
2086
|
+
ne: (propertyName: '_id' | 'primary' | '_createdDate' | '_updatedDate' | 'slug', value: any) => PlansQueryBuilder;
|
2087
|
+
/** @param propertyName - Property whose value is compared with `value`.
|
2088
|
+
* @param value - Value to compare against.
|
2089
|
+
*/
|
2090
|
+
ge: (propertyName: '_createdDate' | '_updatedDate', value: any) => PlansQueryBuilder;
|
2091
|
+
/** @param propertyName - Property whose value is compared with `value`.
|
2092
|
+
* @param value - Value to compare against.
|
2093
|
+
*/
|
2094
|
+
gt: (propertyName: '_createdDate' | '_updatedDate', value: any) => PlansQueryBuilder;
|
2095
|
+
/** @param propertyName - Property whose value is compared with `value`.
|
2096
|
+
* @param value - Value to compare against.
|
2097
|
+
*/
|
2098
|
+
le: (propertyName: '_createdDate' | '_updatedDate', value: any) => PlansQueryBuilder;
|
2099
|
+
/** @param propertyName - Property whose value is compared with `value`.
|
2100
|
+
* @param value - Value to compare against.
|
2101
|
+
*/
|
2102
|
+
lt: (propertyName: '_createdDate' | '_updatedDate', value: any) => PlansQueryBuilder;
|
2103
|
+
/** @param propertyName - Property whose value is compared with `string`.
|
2104
|
+
* @param string - String to compare against. Case-insensitive.
|
2105
|
+
*/
|
2106
|
+
startsWith: (propertyName: '_id' | 'slug', value: string) => PlansQueryBuilder;
|
2107
|
+
/** @param propertyName - Property whose value is compared with `values`.
|
2108
|
+
* @param values - List of values to compare against.
|
2109
|
+
*/
|
2110
|
+
hasSome: (propertyName: '_id' | 'primary' | '_createdDate' | '_updatedDate' | 'slug', value: any[]) => PlansQueryBuilder;
|
2111
|
+
in: (propertyName: '_id' | 'primary' | '_createdDate' | '_updatedDate' | 'slug', value: any) => PlansQueryBuilder;
|
2112
|
+
exists: (propertyName: '_id' | 'primary' | '_createdDate' | '_updatedDate' | 'slug', value: boolean) => PlansQueryBuilder;
|
2113
|
+
/** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments. */
|
2114
|
+
ascending: (...propertyNames: Array<'_id' | 'primary' | '_createdDate' | '_updatedDate' | 'slug'>) => PlansQueryBuilder;
|
2115
|
+
/** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments. */
|
2116
|
+
descending: (...propertyNames: Array<'_id' | 'primary' | '_createdDate' | '_updatedDate' | 'slug'>) => PlansQueryBuilder;
|
2117
|
+
/** @param limit - Number of items to return, which is also the `pageSize` of the results object. */
|
2118
|
+
limit: (limit: number) => PlansQueryBuilder;
|
2119
|
+
/** @param skip - Number of items to skip in the query results before returning the results. */
|
2120
|
+
skip: (skip: number) => PlansQueryBuilder;
|
2121
|
+
find: () => Promise<PlansQueryResult>;
|
2122
|
+
}
|
2123
|
+
interface ListPlansOptions {
|
2124
|
+
/**
|
2125
|
+
* Archived filter.
|
2126
|
+
*
|
2127
|
+
* Default: `ACTIVE` (not archived).
|
2128
|
+
*/
|
2129
|
+
archived?: ArchivedFilter;
|
2130
|
+
/**
|
2131
|
+
* Visibility filter.
|
2132
|
+
*
|
2133
|
+
* Default: `PUBLIC_AND_HIDDEN` (meaning, both public and hidden plans are listed).
|
2134
|
+
*
|
2135
|
+
*/
|
2136
|
+
public?: PublicFilter;
|
2137
|
+
/**
|
2138
|
+
* Number of pricing plans to list.
|
2139
|
+
*
|
2140
|
+
* Default: `75`.
|
2141
|
+
*/
|
2142
|
+
limit?: number | null;
|
2143
|
+
/**
|
2144
|
+
* Number of pricing plans to skip.
|
2145
|
+
*
|
2146
|
+
* Default: `0`.
|
2147
|
+
*/
|
2148
|
+
offset?: number | null;
|
2149
|
+
/** IDs of plans to list. If non-existent IDs are specified, they are ignored and don't cause errors. If no IDs are specified, all public and hidden plans (based on `options`) are listed according to the [order](#arrangeplans) displayed in the Dashboard. You can pass a maximum of 100 IDs. */
|
2150
|
+
planIds?: string[];
|
2151
|
+
}
|
2152
|
+
interface UpdatePlan {
|
2153
|
+
/**
|
2154
|
+
* Plan ID.
|
2155
|
+
* @readonly
|
2156
|
+
*/
|
2157
|
+
_id?: string;
|
2158
|
+
/** Plan name. */
|
2159
|
+
name?: string | null;
|
2160
|
+
/** Plan description. */
|
2161
|
+
description?: string | null;
|
2162
|
+
/**
|
2163
|
+
* List of text strings that promote what is included with this plan.
|
2164
|
+
*
|
2165
|
+
* For example, "Plenty of parking" or "Free gift on your birthday".
|
2166
|
+
*/
|
2167
|
+
perks?: StringList;
|
2168
|
+
/** Plan price, payment schedule, and expiration. */
|
2169
|
+
pricing?: Pricing;
|
2170
|
+
/** Whether the plan is public (visible to site visitors and members). */
|
2171
|
+
public?: boolean | null;
|
2172
|
+
/**
|
2173
|
+
* Whether the plan is archived. Archived plans are not visible and can't be purchased anymore, but existing purchases remain in effect.
|
2174
|
+
* @readonly
|
2175
|
+
*/
|
2176
|
+
archived?: boolean;
|
2177
|
+
/**
|
2178
|
+
* Whether the plan is marked as primary. If `true`, the plan is highlighted on the site with a custom ribbon.
|
2179
|
+
*
|
2180
|
+
* Default: `false`.
|
2181
|
+
* @readonly
|
2182
|
+
*/
|
2183
|
+
primary?: boolean;
|
2184
|
+
/**
|
2185
|
+
* Whether the plan has any orders (including pending and unpaid orders).
|
2186
|
+
* @readonly
|
2187
|
+
*/
|
2188
|
+
hasOrders?: boolean;
|
2189
|
+
/**
|
2190
|
+
* Date plan was created.
|
2191
|
+
* @readonly
|
2192
|
+
*/
|
2193
|
+
_createdDate?: Date;
|
2194
|
+
/**
|
2195
|
+
* Date plan was last updated.
|
2196
|
+
* @readonly
|
2197
|
+
*/
|
2198
|
+
_updatedDate?: Date;
|
2199
|
+
/**
|
2200
|
+
* URL-friendly version of plan name. Unique across all plans in the same site.
|
2201
|
+
* @readonly
|
2202
|
+
*/
|
2203
|
+
slug?: string | null;
|
2204
|
+
/**
|
2205
|
+
* Number of times the same buyer can purchase the plan. Currently limited to support:
|
2206
|
+
* - Empty value or a value of `0`, meaning no limitation.
|
2207
|
+
* - Value of `1`, meaning limited to one purchase per buyer.
|
2208
|
+
*/
|
2209
|
+
maxPurchasesPerBuyer?: number | null;
|
2210
|
+
/**
|
2211
|
+
* Whether the buyer can start the plan at a later date.
|
2212
|
+
*
|
2213
|
+
* Default: `false`.
|
2214
|
+
*
|
2215
|
+
*/
|
2216
|
+
allowFutureStartDate?: boolean | null;
|
2217
|
+
/**
|
2218
|
+
* Whether the buyer is allowed to cancel their plan. If `false`, calling the [`requestCancellation()`](https://www.wix.com/velo/reference/wix-pricing-plans-v2/orders/requestcancellation) function returns an error.
|
2219
|
+
*
|
2220
|
+
* Default: `true`.
|
2221
|
+
*
|
2222
|
+
*/
|
2223
|
+
buyerCanCancel?: boolean | null;
|
2224
|
+
/** Any terms and conditions that apply to the plan. This information will be displayed during checkout. */
|
2225
|
+
termsAndConditions?: string | null;
|
2226
|
+
/** ID of the form associated with the plan at checkout. */
|
2227
|
+
formId?: string | null;
|
2228
|
+
}
|
2229
|
+
|
2230
|
+
declare function listPublicPlans$1(httpClient: HttpClient): (options?: ListPublicPlansOptions) => Promise<ListPublicPlansResponse & ListPublicPlansResponseNonNullableFields>;
|
2231
|
+
declare function queryPublicPlans$1(httpClient: HttpClient): () => PlansQueryBuilder;
|
2232
|
+
declare function getPlan$1(httpClient: HttpClient): (_id: string) => Promise<Plan & {
|
2233
|
+
_id: string;
|
2234
|
+
perks?: {
|
2235
|
+
values: string[];
|
2236
|
+
} | undefined;
|
2237
|
+
pricing?: {
|
2238
|
+
subscription?: {
|
2239
|
+
cycleDuration?: {
|
2240
|
+
unit: PeriodUnit;
|
2241
|
+
} | undefined;
|
2242
|
+
} | undefined;
|
2243
|
+
singlePaymentForDuration?: {
|
2244
|
+
unit: PeriodUnit;
|
2245
|
+
} | undefined;
|
2246
|
+
price?: {
|
2247
|
+
value: string;
|
2248
|
+
currency: string;
|
2249
|
+
} | undefined;
|
2250
|
+
} | undefined;
|
2251
|
+
archived: boolean;
|
2252
|
+
primary: boolean;
|
2253
|
+
hasOrders: boolean;
|
2254
|
+
}>;
|
2255
|
+
declare function listPlans$1(httpClient: HttpClient): (options?: ListPlansOptions) => Promise<ListPlansResponse & ListPlansResponseNonNullableFields>;
|
2256
|
+
declare function getPlanStats$1(httpClient: HttpClient): () => Promise<GetPlanStatsResponse & GetPlanStatsResponseNonNullableFields>;
|
2257
|
+
declare function createPlan$1(httpClient: HttpClient): (plan: Plan) => Promise<Plan & {
|
2258
|
+
_id: string;
|
2259
|
+
perks?: {
|
2260
|
+
values: string[];
|
2261
|
+
} | undefined;
|
2262
|
+
pricing?: {
|
2263
|
+
subscription?: {
|
2264
|
+
cycleDuration?: {
|
2265
|
+
unit: PeriodUnit;
|
2266
|
+
} | undefined;
|
2267
|
+
} | undefined;
|
2268
|
+
singlePaymentForDuration?: {
|
2269
|
+
unit: PeriodUnit;
|
2270
|
+
} | undefined;
|
2271
|
+
price?: {
|
2272
|
+
value: string;
|
2273
|
+
currency: string;
|
2274
|
+
} | undefined;
|
2275
|
+
} | undefined;
|
2276
|
+
archived: boolean;
|
2277
|
+
primary: boolean;
|
2278
|
+
hasOrders: boolean;
|
2279
|
+
}>;
|
2280
|
+
declare function updatePlan$1(httpClient: HttpClient): (_id: string, plan: UpdatePlan) => Promise<Plan & {
|
2281
|
+
_id: string;
|
2282
|
+
perks?: {
|
2283
|
+
values: string[];
|
2284
|
+
} | undefined;
|
2285
|
+
pricing?: {
|
2286
|
+
subscription?: {
|
2287
|
+
cycleDuration?: {
|
2288
|
+
unit: PeriodUnit;
|
2289
|
+
} | undefined;
|
2290
|
+
} | undefined;
|
2291
|
+
singlePaymentForDuration?: {
|
2292
|
+
unit: PeriodUnit;
|
2293
|
+
} | undefined;
|
2294
|
+
price?: {
|
2295
|
+
value: string;
|
2296
|
+
currency: string;
|
2297
|
+
} | undefined;
|
2298
|
+
} | undefined;
|
2299
|
+
archived: boolean;
|
2300
|
+
primary: boolean;
|
2301
|
+
hasOrders: boolean;
|
2302
|
+
}>;
|
2303
|
+
declare function setPlanVisibility$1(httpClient: HttpClient): (_id: string, visible: boolean) => Promise<SetPlanVisibilityResponse & SetPlanVisibilityResponseNonNullableFields>;
|
2304
|
+
declare function makePlanPrimary$1(httpClient: HttpClient): (_id: string) => Promise<MakePlanPrimaryResponse & MakePlanPrimaryResponseNonNullableFields>;
|
2305
|
+
declare function clearPrimary$1(httpClient: HttpClient): () => Promise<void>;
|
2306
|
+
declare function archivePlan$1(httpClient: HttpClient): (_id: string) => Promise<ArchivePlanResponse & ArchivePlanResponseNonNullableFields>;
|
2307
|
+
declare function arrangePlans$1(httpClient: HttpClient): (ids: string[]) => Promise<void>;
|
2308
|
+
declare const onPlanUpdated$1: EventDefinition<PlanUpdatedEnvelope, "wix.pricing_plans.plan_updated">;
|
2309
|
+
declare const onPlanCreated$1: EventDefinition<PlanCreatedEnvelope, "wix.pricing_plans.plan_created">;
|
2310
|
+
declare const onPlanBuyerCanCancelUpdated$1: EventDefinition<PlanBuyerCanCancelUpdatedEnvelope, "wix.pricing_plans.plan_buyer_can_cancel_updated">;
|
2311
|
+
declare const onPlanArchived$1: EventDefinition<PlanArchivedEnvelope, "wix.pricing_plans.plan_plan_archived">;
|
2312
|
+
|
2313
|
+
declare const listPublicPlans: BuildRESTFunction<typeof listPublicPlans$1>;
|
2314
|
+
declare const queryPublicPlans: BuildRESTFunction<typeof queryPublicPlans$1>;
|
2315
|
+
declare const getPlan: BuildRESTFunction<typeof getPlan$1>;
|
2316
|
+
declare const listPlans: BuildRESTFunction<typeof listPlans$1>;
|
2317
|
+
declare const getPlanStats: BuildRESTFunction<typeof getPlanStats$1>;
|
2318
|
+
declare const createPlan: BuildRESTFunction<typeof createPlan$1>;
|
2319
|
+
declare const updatePlan: BuildRESTFunction<typeof updatePlan$1>;
|
2320
|
+
declare const setPlanVisibility: BuildRESTFunction<typeof setPlanVisibility$1>;
|
2321
|
+
declare const makePlanPrimary: BuildRESTFunction<typeof makePlanPrimary$1>;
|
2322
|
+
declare const clearPrimary: BuildRESTFunction<typeof clearPrimary$1>;
|
2323
|
+
declare const archivePlan: BuildRESTFunction<typeof archivePlan$1>;
|
2324
|
+
declare const arrangePlans: BuildRESTFunction<typeof arrangePlans$1>;
|
2325
|
+
declare const onPlanUpdated: BuildEventDefinition<typeof onPlanUpdated$1>;
|
2326
|
+
declare const onPlanCreated: BuildEventDefinition<typeof onPlanCreated$1>;
|
2327
|
+
declare const onPlanBuyerCanCancelUpdated: BuildEventDefinition<typeof onPlanBuyerCanCancelUpdated$1>;
|
2328
|
+
declare const onPlanArchived: BuildEventDefinition<typeof onPlanArchived$1>;
|
2329
|
+
|
2330
|
+
declare const context_archivePlan: typeof archivePlan;
|
2331
|
+
declare const context_arrangePlans: typeof arrangePlans;
|
2332
|
+
declare const context_clearPrimary: typeof clearPrimary;
|
2333
|
+
declare const context_createPlan: typeof createPlan;
|
2334
|
+
declare const context_getPlan: typeof getPlan;
|
2335
|
+
declare const context_getPlanStats: typeof getPlanStats;
|
2336
|
+
declare const context_listPlans: typeof listPlans;
|
2337
|
+
declare const context_listPublicPlans: typeof listPublicPlans;
|
2338
|
+
declare const context_makePlanPrimary: typeof makePlanPrimary;
|
2339
|
+
declare const context_onPlanArchived: typeof onPlanArchived;
|
2340
|
+
declare const context_onPlanBuyerCanCancelUpdated: typeof onPlanBuyerCanCancelUpdated;
|
2341
|
+
declare const context_onPlanCreated: typeof onPlanCreated;
|
2342
|
+
declare const context_onPlanUpdated: typeof onPlanUpdated;
|
2343
|
+
declare const context_queryPublicPlans: typeof queryPublicPlans;
|
2344
|
+
declare const context_setPlanVisibility: typeof setPlanVisibility;
|
2345
|
+
declare const context_updatePlan: typeof updatePlan;
|
2346
|
+
declare namespace context {
|
2347
|
+
export { context_archivePlan as archivePlan, context_arrangePlans as arrangePlans, context_clearPrimary as clearPrimary, context_createPlan as createPlan, context_getPlan as getPlan, context_getPlanStats as getPlanStats, context_listPlans as listPlans, context_listPublicPlans as listPublicPlans, context_makePlanPrimary as makePlanPrimary, context_onPlanArchived as onPlanArchived, context_onPlanBuyerCanCancelUpdated as onPlanBuyerCanCancelUpdated, context_onPlanCreated as onPlanCreated, context_onPlanUpdated as onPlanUpdated, context_queryPublicPlans as queryPublicPlans, context_setPlanVisibility as setPlanVisibility, context_updatePlan as updatePlan };
|
2348
|
+
}
|
2349
|
+
|
2350
|
+
export { context$1 as orders, context as plans };
|