@wix/auto_sdk_ecom_checkout 1.0.15 → 1.0.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (134) hide show
  1. package/build/{es/src/ecom-v1-checkout-checkout.types.d.ts → ecom-v1-checkout-checkout.universal-BV8QOlPP.d.mts} +670 -376
  2. package/build/{cjs/src/ecom-v1-checkout-checkout.types.d.ts → ecom-v1-checkout-checkout.universal-BV8QOlPP.d.ts} +670 -376
  3. package/build/index.d.mts +211 -0
  4. package/build/index.d.ts +211 -0
  5. package/build/index.js +2781 -0
  6. package/build/index.js.map +1 -0
  7. package/build/index.mjs +2707 -0
  8. package/build/index.mjs.map +1 -0
  9. package/build/internal/{cjs/src/ecom-v1-checkout-checkout.types.d.ts → ecom-v1-checkout-checkout.universal-DGEClxWR.d.mts} +879 -376
  10. package/build/internal/{es/src/ecom-v1-checkout-checkout.types.d.ts → ecom-v1-checkout-checkout.universal-DGEClxWR.d.ts} +879 -376
  11. package/build/internal/index.d.mts +252 -0
  12. package/build/internal/index.d.ts +252 -0
  13. package/build/internal/index.js +2781 -0
  14. package/build/internal/index.js.map +1 -0
  15. package/build/internal/index.mjs +2707 -0
  16. package/build/internal/index.mjs.map +1 -0
  17. package/build/internal/meta.d.mts +2345 -0
  18. package/build/internal/meta.d.ts +2345 -0
  19. package/build/internal/meta.js +1587 -0
  20. package/build/internal/meta.js.map +1 -0
  21. package/build/internal/meta.mjs +1544 -0
  22. package/build/internal/meta.mjs.map +1 -0
  23. package/build/meta.d.mts +2345 -0
  24. package/build/meta.d.ts +2345 -0
  25. package/build/meta.js +1587 -0
  26. package/build/meta.js.map +1 -0
  27. package/build/meta.mjs +1544 -0
  28. package/build/meta.mjs.map +1 -0
  29. package/package.json +13 -12
  30. package/build/cjs/index.d.ts +0 -1
  31. package/build/cjs/index.js +0 -18
  32. package/build/cjs/index.js.map +0 -1
  33. package/build/cjs/index.typings.d.ts +0 -1
  34. package/build/cjs/index.typings.js +0 -18
  35. package/build/cjs/index.typings.js.map +0 -1
  36. package/build/cjs/meta.d.ts +0 -1
  37. package/build/cjs/meta.js +0 -18
  38. package/build/cjs/meta.js.map +0 -1
  39. package/build/cjs/src/ecom-v1-checkout-checkout.context.d.ts +0 -34
  40. package/build/cjs/src/ecom-v1-checkout-checkout.context.js +0 -77
  41. package/build/cjs/src/ecom-v1-checkout-checkout.context.js.map +0 -1
  42. package/build/cjs/src/ecom-v1-checkout-checkout.http.d.ts +0 -122
  43. package/build/cjs/src/ecom-v1-checkout-checkout.http.js +0 -1338
  44. package/build/cjs/src/ecom-v1-checkout-checkout.http.js.map +0 -1
  45. package/build/cjs/src/ecom-v1-checkout-checkout.meta.d.ts +0 -59
  46. package/build/cjs/src/ecom-v1-checkout-checkout.meta.js +0 -351
  47. package/build/cjs/src/ecom-v1-checkout-checkout.meta.js.map +0 -1
  48. package/build/cjs/src/ecom-v1-checkout-checkout.public.d.ts +0 -186
  49. package/build/cjs/src/ecom-v1-checkout-checkout.public.js +0 -358
  50. package/build/cjs/src/ecom-v1-checkout-checkout.public.js.map +0 -1
  51. package/build/cjs/src/ecom-v1-checkout-checkout.types.js +0 -301
  52. package/build/cjs/src/ecom-v1-checkout-checkout.types.js.map +0 -1
  53. package/build/cjs/src/ecom-v1-checkout-checkout.universal.d.ts +0 -4211
  54. package/build/cjs/src/ecom-v1-checkout-checkout.universal.js +0 -1597
  55. package/build/cjs/src/ecom-v1-checkout-checkout.universal.js.map +0 -1
  56. package/build/es/index.d.ts +0 -1
  57. package/build/es/index.js +0 -2
  58. package/build/es/index.js.map +0 -1
  59. package/build/es/index.typings.d.ts +0 -1
  60. package/build/es/index.typings.js +0 -2
  61. package/build/es/index.typings.js.map +0 -1
  62. package/build/es/meta.d.ts +0 -1
  63. package/build/es/meta.js +0 -2
  64. package/build/es/meta.js.map +0 -1
  65. package/build/es/package.json +0 -3
  66. package/build/es/src/ecom-v1-checkout-checkout.context.d.ts +0 -34
  67. package/build/es/src/ecom-v1-checkout-checkout.context.js +0 -42
  68. package/build/es/src/ecom-v1-checkout-checkout.context.js.map +0 -1
  69. package/build/es/src/ecom-v1-checkout-checkout.http.d.ts +0 -122
  70. package/build/es/src/ecom-v1-checkout-checkout.http.js +0 -1318
  71. package/build/es/src/ecom-v1-checkout-checkout.http.js.map +0 -1
  72. package/build/es/src/ecom-v1-checkout-checkout.meta.d.ts +0 -59
  73. package/build/es/src/ecom-v1-checkout-checkout.meta.js +0 -308
  74. package/build/es/src/ecom-v1-checkout-checkout.meta.js.map +0 -1
  75. package/build/es/src/ecom-v1-checkout-checkout.public.d.ts +0 -186
  76. package/build/es/src/ecom-v1-checkout-checkout.public.js +0 -306
  77. package/build/es/src/ecom-v1-checkout-checkout.public.js.map +0 -1
  78. package/build/es/src/ecom-v1-checkout-checkout.types.js +0 -298
  79. package/build/es/src/ecom-v1-checkout-checkout.types.js.map +0 -1
  80. package/build/es/src/ecom-v1-checkout-checkout.universal.d.ts +0 -4211
  81. package/build/es/src/ecom-v1-checkout-checkout.universal.js +0 -1554
  82. package/build/es/src/ecom-v1-checkout-checkout.universal.js.map +0 -1
  83. package/build/internal/cjs/index.d.ts +0 -1
  84. package/build/internal/cjs/index.js +0 -18
  85. package/build/internal/cjs/index.js.map +0 -1
  86. package/build/internal/cjs/index.typings.d.ts +0 -1
  87. package/build/internal/cjs/index.typings.js +0 -18
  88. package/build/internal/cjs/index.typings.js.map +0 -1
  89. package/build/internal/cjs/meta.d.ts +0 -1
  90. package/build/internal/cjs/meta.js +0 -18
  91. package/build/internal/cjs/meta.js.map +0 -1
  92. package/build/internal/cjs/src/ecom-v1-checkout-checkout.context.d.ts +0 -42
  93. package/build/internal/cjs/src/ecom-v1-checkout-checkout.context.js +0 -77
  94. package/build/internal/cjs/src/ecom-v1-checkout-checkout.context.js.map +0 -1
  95. package/build/internal/cjs/src/ecom-v1-checkout-checkout.http.d.ts +0 -122
  96. package/build/internal/cjs/src/ecom-v1-checkout-checkout.http.js +0 -1338
  97. package/build/internal/cjs/src/ecom-v1-checkout-checkout.http.js.map +0 -1
  98. package/build/internal/cjs/src/ecom-v1-checkout-checkout.meta.d.ts +0 -59
  99. package/build/internal/cjs/src/ecom-v1-checkout-checkout.meta.js +0 -351
  100. package/build/internal/cjs/src/ecom-v1-checkout-checkout.meta.js.map +0 -1
  101. package/build/internal/cjs/src/ecom-v1-checkout-checkout.public.d.ts +0 -219
  102. package/build/internal/cjs/src/ecom-v1-checkout-checkout.public.js +0 -358
  103. package/build/internal/cjs/src/ecom-v1-checkout-checkout.public.js.map +0 -1
  104. package/build/internal/cjs/src/ecom-v1-checkout-checkout.types.js +0 -301
  105. package/build/internal/cjs/src/ecom-v1-checkout-checkout.types.js.map +0 -1
  106. package/build/internal/cjs/src/ecom-v1-checkout-checkout.universal.d.ts +0 -4500
  107. package/build/internal/cjs/src/ecom-v1-checkout-checkout.universal.js +0 -1597
  108. package/build/internal/cjs/src/ecom-v1-checkout-checkout.universal.js.map +0 -1
  109. package/build/internal/es/index.d.ts +0 -1
  110. package/build/internal/es/index.js +0 -2
  111. package/build/internal/es/index.js.map +0 -1
  112. package/build/internal/es/index.typings.d.ts +0 -1
  113. package/build/internal/es/index.typings.js +0 -2
  114. package/build/internal/es/index.typings.js.map +0 -1
  115. package/build/internal/es/meta.d.ts +0 -1
  116. package/build/internal/es/meta.js +0 -2
  117. package/build/internal/es/meta.js.map +0 -1
  118. package/build/internal/es/src/ecom-v1-checkout-checkout.context.d.ts +0 -42
  119. package/build/internal/es/src/ecom-v1-checkout-checkout.context.js +0 -42
  120. package/build/internal/es/src/ecom-v1-checkout-checkout.context.js.map +0 -1
  121. package/build/internal/es/src/ecom-v1-checkout-checkout.http.d.ts +0 -122
  122. package/build/internal/es/src/ecom-v1-checkout-checkout.http.js +0 -1318
  123. package/build/internal/es/src/ecom-v1-checkout-checkout.http.js.map +0 -1
  124. package/build/internal/es/src/ecom-v1-checkout-checkout.meta.d.ts +0 -59
  125. package/build/internal/es/src/ecom-v1-checkout-checkout.meta.js +0 -308
  126. package/build/internal/es/src/ecom-v1-checkout-checkout.meta.js.map +0 -1
  127. package/build/internal/es/src/ecom-v1-checkout-checkout.public.d.ts +0 -219
  128. package/build/internal/es/src/ecom-v1-checkout-checkout.public.js +0 -306
  129. package/build/internal/es/src/ecom-v1-checkout-checkout.public.js.map +0 -1
  130. package/build/internal/es/src/ecom-v1-checkout-checkout.types.js +0 -298
  131. package/build/internal/es/src/ecom-v1-checkout-checkout.types.js.map +0 -1
  132. package/build/internal/es/src/ecom-v1-checkout-checkout.universal.d.ts +0 -4500
  133. package/build/internal/es/src/ecom-v1-checkout-checkout.universal.js +0 -1554
  134. package/build/internal/es/src/ecom-v1-checkout-checkout.universal.js.map +0 -1
@@ -1,10 +1,10 @@
1
- export interface Checkout {
1
+ interface Checkout {
2
2
  /**
3
3
  * Checkout ID.
4
4
  * @format GUID
5
5
  * @readonly
6
6
  */
7
- id?: string | null;
7
+ _id?: string | null;
8
8
  /**
9
9
  * Line items.
10
10
  *
@@ -19,7 +19,7 @@ export interface Checkout {
19
19
  /** Shipping information. */
20
20
  shippingInfo?: ShippingInfo;
21
21
  /**
22
- * [Buyer note](https://support.wix.com/en/article/collecting-and-viewing-buyer-notes) left by the customer.
22
+ * [Buyer note](https://support.wix.com/en/article/wix-stores-viewing-buyer-notes) left by the customer.
23
23
  * @maxLength 1000
24
24
  */
25
25
  buyerNote?: string | null;
@@ -107,12 +107,12 @@ export interface Checkout {
107
107
  * Date and time the checkout was created.
108
108
  * @readonly
109
109
  */
110
- createdDate?: Date | null;
110
+ _createdDate?: Date | null;
111
111
  /**
112
112
  * Date and time the checkout was updated.
113
113
  * @readonly
114
114
  */
115
- updatedDate?: Date | null;
115
+ _updatedDate?: Date | null;
116
116
  /**
117
117
  * Minimal amount to pay in order to place the order.
118
118
  * @readonly
@@ -136,7 +136,7 @@ export interface Checkout {
136
136
  */
137
137
  cartId?: string | null;
138
138
  /**
139
- * List of validation violations raised by the Validations service plugin ([SDK](https://dev.wix.com/docs/sdk/backend-modules/ecom/service-plugins/validations/introduction) | [REST](https://dev.wix.com/docs/rest/business-solutions/e-commerce/service-plugins/validations-integration-service-plugin/introduction)).
139
+ * List of validation violations raised by the [Validations Custom Extension SPI](https://www.wix.com/velo/reference/spis/wix-ecom/ecom-validations/introduction).
140
140
  * @readonly
141
141
  */
142
142
  violations?: Violation[];
@@ -155,9 +155,7 @@ export interface Checkout {
155
155
  /**
156
156
  * Additional settings for customization of the checkout process.
157
157
  *
158
- * > **Notes:**
159
- * > * Custom settings can only be set when creating a checkout.
160
- * > * To access and manage custom checkout page content, your app must have the permission scope named "Manage eCommerce - Admin Permissions". Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
158
+ * Custom settings can only be defined when [creating a checkout](https://www.wix.com/velo/reference/wix-ecom-backend/checkout/createcheckout).
161
159
  * @immutable
162
160
  */
163
161
  customSettings?: CustomSettings;
@@ -168,6 +166,27 @@ export interface Checkout {
168
166
  * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
169
167
  */
170
168
  customContentReference?: CustomContentReference;
169
+ /**
170
+ * References to an external app and resource associated with this checkout.
171
+ * Used for integration and tracking across different platforms.
172
+ * @immutable
173
+ */
174
+ externalReference?: ExternalReference;
175
+ /**
176
+ * Order ID.
177
+ *
178
+ * This field is empty until the checkout completes and becomes an order.
179
+ * @internal
180
+ * @format GUID
181
+ * @readonly
182
+ */
183
+ orderId?: string | null;
184
+ /**
185
+ * Payment for subscriptions after free trial period.
186
+ * @internal
187
+ * @readonly
188
+ */
189
+ payAfterFreeTrial?: PriceSummary;
171
190
  /**
172
191
  * The business location ID associated with the checkout.
173
192
  *
@@ -175,14 +194,31 @@ export interface Checkout {
175
194
  * @format GUID
176
195
  */
177
196
  businessLocationId?: string | null;
197
+ /**
198
+ * Whether payment is required to create an order.
199
+ *
200
+ * Payment is required if any of the following conditions are met:
201
+ * 1. At least one item requires a payment method. This can be because the item has the `savePaymentMethod` field set to `true`, or the item is a subscription with a price greater than zero.
202
+ * 2. The calculated total amount due for immediate payment is greater than zero - `checkout.payNow > 0`.
203
+ * @internal
204
+ * @readonly
205
+ */
206
+ paymentRequired?: boolean;
207
+ /**
208
+ * Charges information for each subscription in the checkout.
209
+ * @internal
210
+ * @readonly
211
+ * @maxSize 100
212
+ */
213
+ subscriptionCharges?: SubscriptionCharges[];
178
214
  }
179
- export interface LineItem {
215
+ interface LineItem {
180
216
  /**
181
217
  * Line item ID.
182
218
  * @format GUID
183
219
  * @readonly
184
220
  */
185
- id?: string | null;
221
+ _id?: string | null;
186
222
  /**
187
223
  * Item quantity.
188
224
  *
@@ -192,7 +228,7 @@ export interface LineItem {
192
228
  * @max 100000
193
229
  */
194
230
  quantity?: number;
195
- /** Catalog and item reference. Includes IDs for the item and the catalog it came from, as well as further optional info. Optional for custom line items, which don't trigger the Catalog service plugin. */
231
+ /** Catalog and item reference. Holds IDs for the item and the catalog it came from, as well as further optional info. Optional for custom line items, which don't trigger the Catalog service plugin. */
196
232
  catalogReference?: CatalogReference;
197
233
  /**
198
234
  * Item name.
@@ -206,7 +242,7 @@ export interface LineItem {
206
242
  * URL to the item's page on the site.
207
243
  * @readonly
208
244
  */
209
- url?: PageUrlV2;
245
+ url?: string;
210
246
  /**
211
247
  * Item price **after** catalog-defined discount and line item discounts.
212
248
  * @readonly
@@ -248,7 +284,7 @@ export interface LineItem {
248
284
  */
249
285
  discount?: MultiCurrencyPrice;
250
286
  /**
251
- * Line item description lines. Used for display purposes for the cart, checkout and order.
287
+ * Line item description lines. Used for displaying the cart, checkout and order.
252
288
  * @readonly
253
289
  */
254
290
  descriptionLines?: DescriptionLine[];
@@ -256,7 +292,7 @@ export interface LineItem {
256
292
  * Line item image details.
257
293
  * @readonly
258
294
  */
259
- media?: CommonImage;
295
+ media?: string;
260
296
  /**
261
297
  * Item availability details.
262
298
  * @readonly
@@ -278,9 +314,11 @@ export interface LineItem {
278
314
  */
279
315
  subscriptionOptionInfo?: SubscriptionOptionInfo;
280
316
  /**
281
- * Type of selected payment option for current item.
282
- *
283
- * Default: `FULL_PAYMENT_ONLINE`
317
+ * Type of selected payment option for current item. Defaults to `"FULL_PAYMENT_ONLINE"`.
318
+ * + `"FULL_PAYMENT_ONLINE"`: The entire payment for this item happens as part of the checkout.
319
+ * + `"FULL_PAYMENT_OFFLINE"`: The entire payment for this item happens after the checkout. For example, when using cash, check, or other offline payment methods.
320
+ * + `"MEMBERSHIP"`: Payment for this item is done by charging a membership. When this option is used, `lineItem.price.amount` is 0.
321
+ * + `"DEPOSIT_ONLINE"`: Partial payment for the given item to be paid upfront during the checkout. Amount to be paid is defined by deposit_amount field.
284
322
  * @readonly
285
323
  */
286
324
  paymentOption?: PaymentOptionType;
@@ -334,6 +372,18 @@ export interface LineItem {
334
372
  * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
335
373
  */
336
374
  catalogOverrideFields?: CatalogOverrideFields;
375
+ /**
376
+ * Whether the price is not yet defined, and will be updated after the order is created.
377
+ * @internal
378
+ * @readonly
379
+ */
380
+ priceUndetermined?: boolean;
381
+ /**
382
+ * Whether the line item quantity is fixed and cannot be changed.
383
+ * @internal
384
+ * @readonly
385
+ */
386
+ fixedQuantity?: boolean;
337
387
  /**
338
388
  * Whether to save the payment method on the order.
339
389
  *
@@ -341,9 +391,55 @@ export interface LineItem {
341
391
  * @readonly
342
392
  */
343
393
  savePaymentMethod?: boolean;
394
+ /**
395
+ * Address to use for tax calculation purposes.
396
+ * @internal
397
+ */
398
+ taxableAddress?: TaxableAddress;
399
+ /**
400
+ * Custom extended fields for the line item object.
401
+ *
402
+ * [Extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields) must be configured in the app dashboard before they can be accessed with API calls.
403
+ * @internal
404
+ */
405
+ extendedFields?: ExtendedFields;
406
+ /**
407
+ * Policies to be displayed to the customer on the checkout page.
408
+ * @internal
409
+ * @readonly
410
+ * @maxSize 5
411
+ */
412
+ policies?: Policy[];
413
+ /**
414
+ * ID of the app managing the inventory.
415
+ * @internal
416
+ * @format GUID
417
+ */
418
+ inventoryAppId?: string | null;
419
+ /**
420
+ * Whether the item can only be purchased by site members.
421
+ *
422
+ * Default: `false`
423
+ * @internal
424
+ * @readonly
425
+ */
426
+ membersOnly?: boolean;
427
+ /**
428
+ * Modifier groups that were added to the item.
429
+ * @internal
430
+ * @readonly
431
+ * @maxSize 10
432
+ */
433
+ modifierGroups?: ModifierGroup[];
434
+ /**
435
+ * Total price of all item modifiers. Included in the item price.
436
+ * @internal
437
+ * @readonly
438
+ */
439
+ modifiersTotalPrice?: MultiCurrencyPrice;
344
440
  }
345
441
  /** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */
346
- export interface CatalogReference {
442
+ interface CatalogReference {
347
443
  /**
348
444
  * ID of the item within the catalog it belongs to.
349
445
  * @minLength 1
@@ -363,13 +459,15 @@ export interface CatalogReference {
363
459
  */
364
460
  appId?: string;
365
461
  /**
366
- * Additional item details in key:value pairs. Use this optional field to provide more specificity with item selection. The `options` field values differ depending on which catalog is providing the items.
462
+ * Additional item details in key:value pairs.
463
+ *
464
+ * Use this optional field to provide more specificity with item selection. The `options` field values differ depending on which catalog is providing the items.
367
465
  *
368
- * For products and variants from a Wix Stores catalog, learn more about eCommerce integration ([SDK](https://dev.wix.com/docs/sdk/backend-modules/stores/catalog-v3/e-commerce-integration) | [REST](https://dev.wix.com/docs/rest/business-solutions/stores/catalog/e-commerce-integration)).
466
+ * For products and variants from your Wix Stores catalog, learn more about [eCommerce integration](https://www.wix.com/velo/reference/wix-stores-backend/ecommerce-integration).
369
467
  */
370
468
  options?: Record<string, any> | null;
371
469
  }
372
- export interface ProductName {
470
+ interface ProductName {
373
471
  /**
374
472
  * __Required.__ Item name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).
375
473
  *
@@ -390,13 +488,7 @@ export interface ProductName {
390
488
  */
391
489
  translated?: string | null;
392
490
  }
393
- export interface PageUrlV2 {
394
- /** The relative path for the page within the site. For example, `/product-page/a-product`. */
395
- relativePath?: string;
396
- /** The page's full URL. For example, `https://mysite.com/product-page/a-product`. */
397
- url?: string | null;
398
- }
399
- export interface MultiCurrencyPrice {
491
+ interface MultiCurrencyPrice {
400
492
  /**
401
493
  * Amount.
402
494
  * @decimalValue options { gte:0, lte:1000000000000000 }
@@ -419,7 +511,7 @@ export interface MultiCurrencyPrice {
419
511
  */
420
512
  formattedConvertedAmount?: string;
421
513
  }
422
- export interface ItemTaxFullDetails {
514
+ interface ItemTaxFullDetails {
423
515
  /** Amount for which tax is calculated. */
424
516
  taxableAmount?: MultiCurrencyPrice;
425
517
  /**
@@ -436,7 +528,7 @@ export interface ItemTaxFullDetails {
436
528
  */
437
529
  rateBreakdown?: TaxRateBreakdown[];
438
530
  }
439
- export interface TaxRateBreakdown {
531
+ interface TaxRateBreakdown {
440
532
  /**
441
533
  * Name of tax against which the calculation was performed.
442
534
  * @maxLength 100
@@ -454,7 +546,7 @@ export interface TaxRateBreakdown {
454
546
  * TaxBreakdown represents tax information for a line item.
455
547
  * It holds the tax amount and the tax rate for each tax authority that apply on the line item.
456
548
  */
457
- export interface TaxBreakdown {
549
+ interface TaxBreakdown {
458
550
  /**
459
551
  * The name of the jurisdiction to which this tax detail applies. For example, "New York" or "Quebec".
460
552
  * @maxLength 200
@@ -486,7 +578,7 @@ export interface TaxBreakdown {
486
578
  jurisdictionType?: JurisdictionType;
487
579
  }
488
580
  /** JurisdictionType represents the type of the jurisdiction in which this tax detail applies (e.g. Country,State,County,City,Special). */
489
- export declare enum JurisdictionType {
581
+ declare enum JurisdictionType {
490
582
  UNDEFINED = "UNDEFINED",
491
583
  COUNTRY = "COUNTRY",
492
584
  STATE = "STATE",
@@ -494,7 +586,7 @@ export declare enum JurisdictionType {
494
586
  CITY = "CITY",
495
587
  SPECIAL = "SPECIAL"
496
588
  }
497
- export interface DescriptionLine extends DescriptionLineValueOneOf, DescriptionLineDescriptionLineValueOneOf {
589
+ interface DescriptionLine extends DescriptionLineValueOneOf, DescriptionLineDescriptionLineValueOneOf {
498
590
  /** Description line plain text value. */
499
591
  plainText?: PlainTextValue;
500
592
  /** Description line color value. */
@@ -503,16 +595,16 @@ export interface DescriptionLine extends DescriptionLineValueOneOf, DescriptionL
503
595
  name?: DescriptionLineName;
504
596
  }
505
597
  /** @oneof */
506
- export interface DescriptionLineValueOneOf {
598
+ interface DescriptionLineValueOneOf {
507
599
  /** Description line plain text value. */
508
600
  plainText?: PlainTextValue;
509
601
  /** Description line color value. */
510
602
  colorInfo?: Color;
511
603
  }
512
604
  /** @oneof */
513
- export interface DescriptionLineDescriptionLineValueOneOf {
605
+ interface DescriptionLineDescriptionLineValueOneOf {
514
606
  }
515
- export interface DescriptionLineName {
607
+ interface DescriptionLineName {
516
608
  /**
517
609
  * Description line name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).
518
610
  * @maxLength 100
@@ -526,7 +618,7 @@ export interface DescriptionLineName {
526
618
  */
527
619
  translated?: string | null;
528
620
  }
529
- export interface PlainTextValue {
621
+ interface PlainTextValue {
530
622
  /**
531
623
  * Description line plain text value in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).
532
624
  * @maxLength 600
@@ -540,7 +632,7 @@ export interface PlainTextValue {
540
632
  */
541
633
  translated?: string | null;
542
634
  }
543
- export interface Color {
635
+ interface Color {
544
636
  /**
545
637
  * Description line color name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).
546
638
  * @maxLength 500
@@ -556,7 +648,7 @@ export interface Color {
556
648
  /** HEX or RGB color code for display. */
557
649
  code?: string | null;
558
650
  }
559
- export declare enum DescriptionLineType {
651
+ declare enum DescriptionLineType {
560
652
  /** Unrecognized type. */
561
653
  UNRECOGNISED = "UNRECOGNISED",
562
654
  /** Plain text type. */
@@ -564,30 +656,7 @@ export declare enum DescriptionLineType {
564
656
  /** Color type. */
565
657
  COLOR = "COLOR"
566
658
  }
567
- export interface CommonImage {
568
- /** WixMedia image ID. */
569
- id?: string;
570
- /** Image URL. */
571
- url?: string;
572
- /**
573
- * Original image height.
574
- * @readonly
575
- */
576
- height?: number;
577
- /**
578
- * Original image width.
579
- * @readonly
580
- */
581
- width?: number;
582
- /** Image alt text. */
583
- altText?: string | null;
584
- /**
585
- * Image filename.
586
- * @readonly
587
- */
588
- filename?: string | null;
589
- }
590
- export interface FocalPoint {
659
+ interface FocalPoint {
591
660
  /** X-coordinate of the focal point. */
592
661
  x?: number;
593
662
  /** Y-coordinate of the focal point. */
@@ -597,13 +666,13 @@ export interface FocalPoint {
597
666
  /** crop by width */
598
667
  width?: number | null;
599
668
  }
600
- export interface ItemAvailabilityInfo {
669
+ interface ItemAvailabilityInfo {
601
670
  /** Item availability status. */
602
671
  status?: ItemAvailabilityStatus;
603
672
  /** Quantity available. */
604
673
  quantityAvailable?: number | null;
605
674
  }
606
- export declare enum ItemAvailabilityStatus {
675
+ declare enum ItemAvailabilityStatus {
607
676
  AVAILABLE = "AVAILABLE",
608
677
  /** Item does not exist. */
609
678
  NOT_FOUND = "NOT_FOUND",
@@ -612,8 +681,8 @@ export declare enum ItemAvailabilityStatus {
612
681
  /** Available quantity is less than requested. */
613
682
  PARTIALLY_AVAILABLE = "PARTIALLY_AVAILABLE"
614
683
  }
615
- export interface PhysicalProperties {
616
- /** Line item weight. Measurement unit matches the weight unit specified in `weightUnit` in the request. */
684
+ interface PhysicalProperties {
685
+ /** Line item weight. Measurement unit (`"KG"` or `"LB"`) is taken from `order.weightUnit`. */
617
686
  weight?: number | null;
618
687
  /**
619
688
  * Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku).
@@ -623,39 +692,39 @@ export interface PhysicalProperties {
623
692
  /** Whether this line item is shippable. */
624
693
  shippable?: boolean;
625
694
  }
626
- export interface Scope {
695
+ interface Scope {
627
696
  /** Scope namespace (Wix Stores, Wix Bookings, Wix Events, Wix Pricing Plans) */
628
697
  namespace?: string;
629
698
  /** Coupon scope's applied group (e.g., event or ticket in Wix Events) */
630
699
  group?: Group;
631
700
  }
632
- export interface Group {
701
+ interface Group {
633
702
  /** Coupon scope's group (e.g., product or collection in Wix Stores). See [valid scope values](https://dev.wix.com/api/rest/coupons/coupons/valid-scope-values). */
634
703
  name?: string;
635
704
  /** Item ID (when the coupon scope is limited to just one item). */
636
705
  entityId?: string | null;
637
706
  }
638
- export interface ItemType extends ItemTypeItemTypeDataOneOf {
707
+ interface ItemType extends ItemTypeItemTypeDataOneOf {
639
708
  /** Preset item type. */
640
709
  preset?: ItemTypeItemType;
641
710
  /** Custom item type. When none of the preset types are suitable, specifies the custom type. */
642
711
  custom?: string;
643
712
  }
644
713
  /** @oneof */
645
- export interface ItemTypeItemTypeDataOneOf {
714
+ interface ItemTypeItemTypeDataOneOf {
646
715
  /** Preset item type. */
647
716
  preset?: ItemTypeItemType;
648
717
  /** Custom item type. When none of the preset types are suitable, specifies the custom type. */
649
718
  custom?: string;
650
719
  }
651
- export declare enum ItemTypeItemType {
720
+ declare enum ItemTypeItemType {
652
721
  UNRECOGNISED = "UNRECOGNISED",
653
722
  PHYSICAL = "PHYSICAL",
654
723
  DIGITAL = "DIGITAL",
655
724
  GIFT_CARD = "GIFT_CARD",
656
725
  SERVICE = "SERVICE"
657
726
  }
658
- export interface SubscriptionOptionInfo {
727
+ interface SubscriptionOptionInfo {
659
728
  /** Subscription option settings. */
660
729
  subscriptionSettings?: SubscriptionSettings;
661
730
  /** Subscription option title. */
@@ -663,7 +732,7 @@ export interface SubscriptionOptionInfo {
663
732
  /** Subscription option description. */
664
733
  description?: Description;
665
734
  }
666
- export interface SubscriptionSettings {
735
+ interface SubscriptionSettings {
667
736
  /** Frequency of recurring payment. */
668
737
  frequency?: SubscriptionFrequency;
669
738
  /**
@@ -682,16 +751,32 @@ export interface SubscriptionSettings {
682
751
  * @min 1
683
752
  */
684
753
  billingCycles?: number | null;
754
+ /**
755
+ * Whether to allow the customer to cancel the subscription..
756
+ * @internal
757
+ */
758
+ enableCustomerCancellation?: boolean;
759
+ /**
760
+ * Period until first cycle starts. If applied payNow will be 0
761
+ * If None => no free trial
762
+ * @internal
763
+ */
764
+ freeTrialPeriod?: FreeTrialPeriod;
765
+ /**
766
+ * The date the subscription will start. The subscription will be charged either now or according to freeTrialDays.
767
+ * @internal
768
+ */
769
+ startDate?: Date | null;
685
770
  }
686
771
  /** Frequency unit of recurring payment */
687
- export declare enum SubscriptionFrequency {
772
+ declare enum SubscriptionFrequency {
688
773
  UNDEFINED = "UNDEFINED",
689
774
  DAY = "DAY",
690
775
  WEEK = "WEEK",
691
776
  MONTH = "MONTH",
692
777
  YEAR = "YEAR"
693
778
  }
694
- export interface FreeTrialPeriod {
779
+ interface FreeTrialPeriod {
695
780
  /** Frequency of period. Values: DAY, WEEK, MONTH, YEAR */
696
781
  frequency?: SubscriptionFrequency;
697
782
  /**
@@ -701,7 +786,7 @@ export interface FreeTrialPeriod {
701
786
  */
702
787
  interval?: number;
703
788
  }
704
- export interface Title {
789
+ interface Title {
705
790
  /**
706
791
  * Subscription option name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).
707
792
  * @minLength 1
@@ -717,7 +802,7 @@ export interface Title {
717
802
  */
718
803
  translated?: string | null;
719
804
  }
720
- export interface Description {
805
+ interface Description {
721
806
  /**
722
807
  * Subscription option description.
723
808
  * @maxLength 500
@@ -729,13 +814,13 @@ export interface Description {
729
814
  */
730
815
  translated?: string | null;
731
816
  }
732
- export interface SecuredMedia {
817
+ interface SecuredMedia {
733
818
  /**
734
819
  * Media ID in Wix Media Manager.
735
820
  * @minLength 1
736
821
  * @maxLength 100
737
822
  */
738
- id?: string;
823
+ _id?: string;
739
824
  /**
740
825
  * Original filename.
741
826
  * @minLength 1
@@ -745,7 +830,7 @@ export interface SecuredMedia {
745
830
  /** File type. */
746
831
  fileType?: FileType;
747
832
  }
748
- export declare enum FileType {
833
+ declare enum FileType {
749
834
  UNSPECIFIED = "UNSPECIFIED",
750
835
  SECURE_PICTURE = "SECURE_PICTURE",
751
836
  SECURE_VIDEO = "SECURE_VIDEO",
@@ -754,7 +839,7 @@ export declare enum FileType {
754
839
  SECURE_ARCHIVE = "SECURE_ARCHIVE"
755
840
  }
756
841
  /** Type of selected payment option for catalog item */
757
- export declare enum PaymentOptionType {
842
+ declare enum PaymentOptionType {
758
843
  /** The entire payment for this item happens as part of the checkout. */
759
844
  FULL_PAYMENT_ONLINE = "FULL_PAYMENT_ONLINE",
760
845
  /** The entire payment for this item happens after checkout. For example, when using cash, check, or other offline payment methods. */
@@ -766,7 +851,7 @@ export declare enum PaymentOptionType {
766
851
  /** Payment for this item can only be done by charging a membership and must be manually redeemed in the dashboard by the site admin. When selected, `price` is `0`. */
767
852
  MEMBERSHIP_OFFLINE = "MEMBERSHIP_OFFLINE"
768
853
  }
769
- export interface ServiceProperties {
854
+ interface ServiceProperties {
770
855
  /**
771
856
  * Date and time the service is to be provided, in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format.
772
857
  * For example, the start time of a class.
@@ -779,7 +864,7 @@ export interface ServiceProperties {
779
864
  */
780
865
  numberOfParticipants?: number | null;
781
866
  }
782
- export interface PriceDescription {
867
+ interface PriceDescription {
783
868
  /**
784
869
  * __Required.__ Price description in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).
785
870
  * @minLength 1
@@ -795,7 +880,7 @@ export interface PriceDescription {
795
880
  */
796
881
  translated?: string | null;
797
882
  }
798
- export interface CatalogOverrideFields {
883
+ interface CatalogOverrideFields {
799
884
  /** Item name. */
800
885
  productName?: ProductName;
801
886
  /**
@@ -816,7 +901,7 @@ export interface CatalogOverrideFields {
816
901
  /** Physical properties of the item. */
817
902
  physicalProperties?: PhysicalProperties;
818
903
  /** Item image. */
819
- image?: Image;
904
+ image?: string;
820
905
  /** Payment method selected for the item. */
821
906
  paymentOption?: PaymentOption;
822
907
  /**
@@ -832,19 +917,7 @@ export interface CatalogOverrideFields {
832
917
  */
833
918
  savePaymentMethod?: boolean | null;
834
919
  }
835
- export interface Image {
836
- /** WixMedia image ID. */
837
- id?: string;
838
- /** Original image height. */
839
- height?: number;
840
- /** Original image width. */
841
- width?: number;
842
- /** Image alt text. Optional. */
843
- altText?: string | null;
844
- /** Image filename. Optional. */
845
- filename?: string | null;
846
- }
847
- export interface PaymentOption {
920
+ interface PaymentOption {
848
921
  /**
849
922
  * Type of selected payment option for current item.
850
923
  *
@@ -852,22 +925,22 @@ export interface PaymentOption {
852
925
  */
853
926
  value?: PaymentOptionType;
854
927
  }
855
- export interface TaxableAddress extends TaxableAddressTaxableAddressDataOneOf {
928
+ interface TaxableAddress extends TaxableAddressTaxableAddressDataOneOf {
856
929
  /** taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. */
857
930
  addressType?: TaxableAddressType;
858
931
  }
859
932
  /** @oneof */
860
- export interface TaxableAddressTaxableAddressDataOneOf {
933
+ interface TaxableAddressTaxableAddressDataOneOf {
861
934
  /** taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. */
862
935
  addressType?: TaxableAddressType;
863
936
  }
864
- export declare enum TaxableAddressType {
937
+ declare enum TaxableAddressType {
865
938
  UNKNOWN_TAXABLE_ADDRESS = "UNKNOWN_TAXABLE_ADDRESS",
866
939
  BUSINESS = "BUSINESS",
867
940
  BILLING = "BILLING",
868
941
  SHIPPING = "SHIPPING"
869
942
  }
870
- export interface ExtendedFields {
943
+ interface ExtendedFields {
871
944
  /**
872
945
  * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.
873
946
  * The value of each key is structured according to the schema defined when the extended fields were configured.
@@ -878,7 +951,7 @@ export interface ExtendedFields {
878
951
  */
879
952
  namespaces?: Record<string, Record<string, any>>;
880
953
  }
881
- export interface Policy {
954
+ interface Policy {
882
955
  /**
883
956
  * Policy title - should be translated
884
957
  * @minLength 1
@@ -892,13 +965,13 @@ export interface Policy {
892
965
  */
893
966
  content?: string;
894
967
  }
895
- export interface ModifierGroup {
968
+ interface ModifierGroup {
896
969
  /**
897
970
  * Modifier group id.
898
971
  * @minLength 1
899
972
  * @maxLength 36
900
973
  */
901
- id?: string;
974
+ _id?: string;
902
975
  /** Modifier group name. */
903
976
  name?: TranslatableString;
904
977
  /**
@@ -908,7 +981,7 @@ export interface ModifierGroup {
908
981
  */
909
982
  modifiers?: ItemModifier[];
910
983
  }
911
- export interface TranslatableString {
984
+ interface TranslatableString {
912
985
  /**
913
986
  * __Required.__ String in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).
914
987
  *
@@ -929,13 +1002,13 @@ export interface TranslatableString {
929
1002
  */
930
1003
  translated?: string | null;
931
1004
  }
932
- export interface ItemModifier {
1005
+ interface ItemModifier {
933
1006
  /**
934
1007
  * Modifier ID.
935
1008
  * @minLength 1
936
1009
  * @maxLength 36
937
1010
  */
938
- id?: string;
1011
+ _id?: string;
939
1012
  /**
940
1013
  * The quantity of this modifier.
941
1014
  * @min 1
@@ -950,14 +1023,14 @@ export interface ItemModifier {
950
1023
  price?: MultiCurrencyPrice;
951
1024
  }
952
1025
  /** Billing Info and shipping details */
953
- export interface AddressWithContact {
1026
+ interface AddressWithContact {
954
1027
  /** Address. */
955
1028
  address?: ApiAddress;
956
1029
  /** Contact details. */
957
1030
  contactDetails?: FullAddressContactDetails;
958
1031
  }
959
1032
  /** Physical address */
960
- export interface ApiAddress {
1033
+ interface ApiAddress {
961
1034
  /**
962
1035
  * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format.
963
1036
  * @format COUNTRY
@@ -984,7 +1057,7 @@ export interface ApiAddress {
984
1057
  * Main address line (usually street name and number).
985
1058
  * @maxLength 150
986
1059
  */
987
- addressLine?: string | null;
1060
+ addressLine1?: string | null;
988
1061
  /**
989
1062
  * Free text providing more detailed address info. Usually contains apt, suite, floor.
990
1063
  * @maxLength 100
@@ -1001,20 +1074,20 @@ export interface ApiAddress {
1001
1074
  */
1002
1075
  subdivisionFullname?: string | null;
1003
1076
  }
1004
- export interface StreetAddress {
1077
+ interface StreetAddress {
1005
1078
  /** Street number. */
1006
1079
  number?: string;
1007
1080
  /** Street name. */
1008
1081
  name?: string;
1009
1082
  }
1010
- export interface AddressLocation {
1083
+ interface AddressLocation {
1011
1084
  /** Address latitude. */
1012
1085
  latitude?: number | null;
1013
1086
  /** Address longitude. */
1014
1087
  longitude?: number | null;
1015
1088
  }
1016
1089
  /** Full contact details for an address */
1017
- export interface FullAddressContactDetails {
1090
+ interface FullAddressContactDetails {
1018
1091
  /**
1019
1092
  * First name.
1020
1093
  * @maxLength 100
@@ -1038,9 +1111,9 @@ export interface FullAddressContactDetails {
1038
1111
  /** Tax information (for Brazil only). If ID is provided, `vatId.type` must also be set, `UNSPECIFIED` is not allowed. */
1039
1112
  vatId?: CommonVatId;
1040
1113
  }
1041
- export interface CommonVatId {
1114
+ interface CommonVatId {
1042
1115
  /** Customer's tax ID. */
1043
- id?: string;
1116
+ _id?: string;
1044
1117
  /**
1045
1118
  * Tax type.
1046
1119
  *
@@ -1051,14 +1124,14 @@ export interface CommonVatId {
1051
1124
  type?: CommonVatType;
1052
1125
  }
1053
1126
  /** tax info types */
1054
- export declare enum CommonVatType {
1127
+ declare enum CommonVatType {
1055
1128
  UNSPECIFIED = "UNSPECIFIED",
1056
1129
  /** CPF - for individual tax payers. */
1057
1130
  CPF = "CPF",
1058
1131
  /** CNPJ - for corporations */
1059
1132
  CNPJ = "CNPJ"
1060
1133
  }
1061
- export interface ShippingInfo {
1134
+ interface ShippingInfo {
1062
1135
  /** Shipping address and contact details. */
1063
1136
  shippingDestination?: AddressWithContact;
1064
1137
  /** Selected option out of the options allowed for the `region`. */
@@ -1074,7 +1147,7 @@ export interface ShippingInfo {
1074
1147
  */
1075
1148
  carrierServiceOptions?: CarrierServiceOption[];
1076
1149
  }
1077
- export interface SelectedCarrierServiceOption {
1150
+ interface SelectedCarrierServiceOption {
1078
1151
  /**
1079
1152
  * Unique identifier of selected option. For example, "usps_std_overnight".
1080
1153
  * @maxLength 100
@@ -1117,7 +1190,7 @@ export interface SelectedCarrierServiceOption {
1117
1190
  /** If the delivery solution is a partial and doesn't apply to all items. */
1118
1191
  partial?: boolean | null;
1119
1192
  }
1120
- export interface DeliveryLogistics {
1193
+ interface DeliveryLogistics {
1121
1194
  /**
1122
1195
  * Expected delivery time, in free text. For example, "3-5 business days".
1123
1196
  * @maxLength 500
@@ -1131,7 +1204,7 @@ export interface DeliveryLogistics {
1131
1204
  /** Pickup details. */
1132
1205
  pickupDetails?: PickupDetails;
1133
1206
  }
1134
- export interface PickupDetails {
1207
+ interface PickupDetails {
1135
1208
  /** Pickup address. */
1136
1209
  address?: ApiAddress;
1137
1210
  /**
@@ -1142,18 +1215,18 @@ export interface PickupDetails {
1142
1215
  /** Pickup method */
1143
1216
  pickupMethod?: PickupMethod;
1144
1217
  }
1145
- export declare enum PickupMethod {
1218
+ declare enum PickupMethod {
1146
1219
  UNKNOWN_METHOD = "UNKNOWN_METHOD",
1147
1220
  STORE_PICKUP = "STORE_PICKUP",
1148
1221
  PICKUP_POINT = "PICKUP_POINT"
1149
1222
  }
1150
- export interface DeliveryTimeSlot {
1223
+ interface DeliveryTimeSlot {
1151
1224
  /** starting time of the delivery time slot */
1152
1225
  from?: Date | null;
1153
1226
  /** ending time of the delivery time slot */
1154
1227
  to?: Date | null;
1155
1228
  }
1156
- export interface SelectedCarrierServiceOptionPrices {
1229
+ interface SelectedCarrierServiceOptionPrices {
1157
1230
  /** Total shipping price, after discount and after tax. */
1158
1231
  totalPriceAfterTax?: MultiCurrencyPrice;
1159
1232
  /** Total price of shipping after discounts (when relevant), and before tax. */
@@ -1165,7 +1238,7 @@ export interface SelectedCarrierServiceOptionPrices {
1165
1238
  /** Shipping price before discount and before tax. */
1166
1239
  price?: MultiCurrencyPrice;
1167
1240
  }
1168
- export interface SelectedCarrierServiceOptionOtherCharge {
1241
+ interface SelectedCarrierServiceOptionOtherCharge {
1169
1242
  /** Type of additional cost. */
1170
1243
  type?: ChargeType;
1171
1244
  /**
@@ -1176,11 +1249,11 @@ export interface SelectedCarrierServiceOptionOtherCharge {
1176
1249
  /** Price of added charge. */
1177
1250
  cost?: SelectedCarrierServiceOptionPrices;
1178
1251
  }
1179
- export declare enum ChargeType {
1252
+ declare enum ChargeType {
1180
1253
  HANDLING_FEE = "HANDLING_FEE",
1181
1254
  INSURANCE = "INSURANCE"
1182
1255
  }
1183
- export interface DeliveryAllocation {
1256
+ interface DeliveryAllocation {
1184
1257
  /** The delivery option's carrier details, could be multiple if the delivery option is a combination of multiple carriers */
1185
1258
  deliveryCarrier?: Carrier;
1186
1259
  /** The delivery region that are relevant for this delivery solution. */
@@ -1188,7 +1261,7 @@ export interface DeliveryAllocation {
1188
1261
  /** Populated if the delivery solution is a partially supplied by this carrier. */
1189
1262
  applicableLineItems?: ApplicableLineItems;
1190
1263
  }
1191
- export interface Carrier {
1264
+ interface Carrier {
1192
1265
  /**
1193
1266
  * The carrier app id
1194
1267
  * @format GUID
@@ -1200,19 +1273,19 @@ export interface Carrier {
1200
1273
  */
1201
1274
  code?: string;
1202
1275
  }
1203
- export interface Region {
1276
+ interface Region {
1204
1277
  /**
1205
1278
  * The delivery region id.
1206
1279
  * @format GUID
1207
1280
  */
1208
- id?: string | null;
1281
+ _id?: string | null;
1209
1282
  /**
1210
1283
  * The delivery region name.
1211
1284
  * @maxLength 100
1212
1285
  */
1213
1286
  name?: string | null;
1214
1287
  }
1215
- export interface ApplicableLineItems {
1288
+ interface ApplicableLineItems {
1216
1289
  /**
1217
1290
  * Line items that the delivery solution is for.
1218
1291
  * @maxSize 300
@@ -1221,20 +1294,20 @@ export interface ApplicableLineItems {
1221
1294
  */
1222
1295
  lineItemIds?: string[];
1223
1296
  }
1224
- export interface ShippingRegion {
1297
+ interface ShippingRegion {
1225
1298
  /**
1226
1299
  * Shipping region ID.
1227
1300
  * @format GUID
1228
1301
  * @readonly
1229
1302
  */
1230
- id?: string;
1303
+ _id?: string;
1231
1304
  /**
1232
1305
  * Shipping region name.
1233
1306
  * @maxLength 100
1234
1307
  */
1235
1308
  name?: string;
1236
1309
  }
1237
- export interface CarrierServiceOption {
1310
+ interface CarrierServiceOption {
1238
1311
  /**
1239
1312
  * Carrier ID.
1240
1313
  * @format GUID
@@ -1243,7 +1316,7 @@ export interface CarrierServiceOption {
1243
1316
  /** Shipping options offered by this carrier for this request. */
1244
1317
  shippingOptions?: ShippingOption[];
1245
1318
  }
1246
- export interface ShippingOption {
1319
+ interface ShippingOption {
1247
1320
  /**
1248
1321
  * Unique code of provided shipping option like "usps_std_overnight".
1249
1322
  * For legacy calculators this would be the UUID of the option.
@@ -1268,33 +1341,33 @@ export interface ShippingOption {
1268
1341
  /** If the delivery solution is a partial and doesn't apply to all items. */
1269
1342
  partial?: boolean | null;
1270
1343
  }
1271
- export interface ShippingPrice {
1344
+ interface ShippingPrice {
1272
1345
  /** Shipping price. */
1273
1346
  price?: MultiCurrencyPrice;
1274
1347
  /** Other costs such as insurance, handling & packaging for fragile items, etc. */
1275
1348
  otherCharges?: OtherCharge[];
1276
1349
  }
1277
- export interface OtherCharge {
1350
+ interface OtherCharge {
1278
1351
  /** Type of additional cost. */
1279
1352
  type?: ChargeType;
1280
1353
  /** Price of added cost. */
1281
1354
  price?: MultiCurrencyPrice;
1282
1355
  }
1283
- export interface BuyerInfo extends BuyerInfoIdOneOf {
1356
+ interface BuyerInfo extends BuyerInfoIdOneOf {
1284
1357
  /**
1285
- * Visitor ID (if site visitor is **not** a member).
1358
+ * Visitor ID - if the buyer is **not** a site member.
1286
1359
  * @format GUID
1287
1360
  * @readonly
1288
1361
  */
1289
1362
  visitorId?: string;
1290
1363
  /**
1291
- * Member ID (if site visitor is a site member).
1364
+ * Member ID - If the buyer is a site member.
1292
1365
  * @format GUID
1293
1366
  * @readonly
1294
1367
  */
1295
1368
  memberId?: string;
1296
1369
  /**
1297
- * Contact ID. Auto-created if one does not yet exist. For more information, see the Contacts API.
1370
+ * Contact ID. For more information, see the Contacts API.
1298
1371
  * @format GUID
1299
1372
  * @readonly
1300
1373
  */
@@ -1306,21 +1379,21 @@ export interface BuyerInfo extends BuyerInfoIdOneOf {
1306
1379
  email?: string | null;
1307
1380
  }
1308
1381
  /** @oneof */
1309
- export interface BuyerInfoIdOneOf {
1382
+ interface BuyerInfoIdOneOf {
1310
1383
  /**
1311
- * Visitor ID (if site visitor is **not** a member).
1384
+ * Visitor ID - if the buyer is **not** a site member.
1312
1385
  * @format GUID
1313
1386
  * @readonly
1314
1387
  */
1315
1388
  visitorId?: string;
1316
1389
  /**
1317
- * Member ID (if site visitor is a site member).
1390
+ * Member ID - If the buyer is a site member.
1318
1391
  * @format GUID
1319
1392
  * @readonly
1320
1393
  */
1321
1394
  memberId?: string;
1322
1395
  }
1323
- export interface PriceSummary {
1396
+ interface PriceSummary {
1324
1397
  /** Subtotal of all line items, before discounts and before tax. */
1325
1398
  subtotal?: MultiCurrencyPrice;
1326
1399
  /** Total shipping price, before discounts and before tax. */
@@ -1334,7 +1407,7 @@ export interface PriceSummary {
1334
1407
  /** Total additional fees price before tax. */
1335
1408
  additionalFees?: MultiCurrencyPrice;
1336
1409
  }
1337
- export interface CalculationErrors extends CalculationErrorsShippingCalculationErrorOneOf {
1410
+ interface CalculationErrors extends CalculationErrorsShippingCalculationErrorOneOf {
1338
1411
  /** General shipping calculation error. */
1339
1412
  generalShippingCalculationError?: Details;
1340
1413
  /** Carrier errors. */
@@ -1356,13 +1429,13 @@ export interface CalculationErrors extends CalculationErrorsShippingCalculationE
1356
1429
  discountsCalculationError?: Details;
1357
1430
  }
1358
1431
  /** @oneof */
1359
- export interface CalculationErrorsShippingCalculationErrorOneOf {
1432
+ interface CalculationErrorsShippingCalculationErrorOneOf {
1360
1433
  /** General shipping calculation error. */
1361
1434
  generalShippingCalculationError?: Details;
1362
1435
  /** Carrier errors. */
1363
1436
  carrierErrors?: CarrierErrors;
1364
1437
  }
1365
- export interface Details extends DetailsKindOneOf {
1438
+ interface Details extends DetailsKindOneOf {
1366
1439
  applicationError?: ApplicationError;
1367
1440
  validationError?: ValidationError;
1368
1441
  systemError?: SystemError;
@@ -1373,12 +1446,12 @@ export interface Details extends DetailsKindOneOf {
1373
1446
  tracing?: Record<string, string>;
1374
1447
  }
1375
1448
  /** @oneof */
1376
- export interface DetailsKindOneOf {
1449
+ interface DetailsKindOneOf {
1377
1450
  applicationError?: ApplicationError;
1378
1451
  validationError?: ValidationError;
1379
1452
  systemError?: SystemError;
1380
1453
  }
1381
- export interface ApplicationError {
1454
+ interface ApplicationError {
1382
1455
  /** Error code. */
1383
1456
  code?: string;
1384
1457
  /** Description of the error. */
@@ -1418,10 +1491,10 @@ export interface ApplicationError {
1418
1491
  * ]
1419
1492
  * }
1420
1493
  */
1421
- export interface ValidationError {
1494
+ interface ValidationError {
1422
1495
  fieldViolations?: FieldViolation[];
1423
1496
  }
1424
- export declare enum RuleType {
1497
+ declare enum RuleType {
1425
1498
  VALIDATION = "VALIDATION",
1426
1499
  OTHER = "OTHER",
1427
1500
  MAX = "MAX",
@@ -1444,7 +1517,7 @@ export declare enum RuleType {
1444
1517
  EXACT_SIZE = "EXACT_SIZE",
1445
1518
  REQUIRED_ONE_OF_FIELD = "REQUIRED_ONE_OF_FIELD"
1446
1519
  }
1447
- export interface FieldViolation {
1520
+ interface FieldViolation {
1448
1521
  field?: string;
1449
1522
  description?: string;
1450
1523
  violatedRule?: RuleType;
@@ -1452,26 +1525,26 @@ export interface FieldViolation {
1452
1525
  ruleName?: string | null;
1453
1526
  data?: Record<string, any> | null;
1454
1527
  }
1455
- export interface SystemError {
1528
+ interface SystemError {
1456
1529
  /** Error code. */
1457
1530
  errorCode?: string | null;
1458
1531
  }
1459
- export interface CarrierErrors {
1532
+ interface CarrierErrors {
1460
1533
  /** Carrier errors. */
1461
1534
  errors?: CarrierError[];
1462
1535
  }
1463
- export interface CarrierError {
1536
+ interface CarrierError {
1464
1537
  /** Carrier ID. */
1465
1538
  carrierId?: string;
1466
1539
  /** Error details. */
1467
1540
  error?: Details;
1468
1541
  }
1469
- export interface GiftCard {
1542
+ interface GiftCard {
1470
1543
  /**
1471
1544
  * Gift Card ID.
1472
1545
  * @deprecated
1473
1546
  */
1474
- id?: string;
1547
+ _id?: string;
1475
1548
  /** Gift card obfuscated code. */
1476
1549
  obfuscatedCode?: string;
1477
1550
  /** Gift card value. */
@@ -1489,7 +1562,7 @@ export interface GiftCard {
1489
1562
  */
1490
1563
  externalId?: string | null;
1491
1564
  }
1492
- export interface AppliedDiscount extends AppliedDiscountDiscountSourceOneOf {
1565
+ interface AppliedDiscount extends AppliedDiscountDiscountSourceOneOf {
1493
1566
  /** Coupon details. */
1494
1567
  coupon?: Coupon;
1495
1568
  /** Merchant discount. */
@@ -1499,16 +1572,24 @@ export interface AppliedDiscount extends AppliedDiscountDiscountSourceOneOf {
1499
1572
  /** Discount type. */
1500
1573
  discountType?: DiscountType;
1501
1574
  /**
1502
- * IDs of line items the discount applies to.
1575
+ * IDs of the line items the discount applies to.
1503
1576
  * @format GUID
1504
1577
  * @deprecated IDs of line items the discount applies to.
1505
1578
  * @replacedBy line_items_discounts
1506
1579
  * @targetRemovalDate 2024-06-01
1507
1580
  */
1508
1581
  lineItemIds?: string[];
1582
+ /**
1583
+ * Number of subscription cycle this discount applies to
1584
+ * default None - all billing cycle
1585
+ * @internal
1586
+ * @min 1
1587
+ * @max 999
1588
+ */
1589
+ subscriptionCycles?: number | null;
1509
1590
  }
1510
1591
  /** @oneof */
1511
- export interface AppliedDiscountDiscountSourceOneOf {
1592
+ interface AppliedDiscountDiscountSourceOneOf {
1512
1593
  /** Coupon details. */
1513
1594
  coupon?: Coupon;
1514
1595
  /** Merchant discount. */
@@ -1516,15 +1597,15 @@ export interface AppliedDiscountDiscountSourceOneOf {
1516
1597
  /** Discount rule */
1517
1598
  discountRule?: DiscountRule;
1518
1599
  }
1519
- export declare enum DiscountType {
1600
+ declare enum DiscountType {
1520
1601
  GLOBAL = "GLOBAL",
1521
1602
  SPECIFIC_ITEMS = "SPECIFIC_ITEMS",
1522
1603
  SHIPPING = "SHIPPING"
1523
1604
  }
1524
1605
  /** Coupon */
1525
- export interface Coupon {
1606
+ interface Coupon {
1526
1607
  /** Coupon ID. */
1527
- id?: string;
1608
+ _id?: string;
1528
1609
  /** Coupon code. */
1529
1610
  code?: string;
1530
1611
  /** Coupon value. */
@@ -1532,7 +1613,7 @@ export interface Coupon {
1532
1613
  /** Coupon name. */
1533
1614
  name?: string;
1534
1615
  }
1535
- export interface MerchantDiscount {
1616
+ interface MerchantDiscount {
1536
1617
  /** Discount value. */
1537
1618
  amount?: MultiCurrencyPrice;
1538
1619
  /**
@@ -1542,18 +1623,18 @@ export interface MerchantDiscount {
1542
1623
  */
1543
1624
  percentage?: number | null;
1544
1625
  }
1545
- export interface DiscountRule {
1626
+ interface DiscountRule {
1546
1627
  /**
1547
1628
  * Discount rule ID
1548
1629
  * @format GUID
1549
1630
  */
1550
- id?: string;
1631
+ _id?: string;
1551
1632
  /** Discount rule name */
1552
1633
  name?: DiscountRuleName;
1553
1634
  /** Discount value. */
1554
1635
  amount?: MultiCurrencyPrice;
1555
1636
  }
1556
- export interface DiscountRuleName {
1637
+ interface DiscountRuleName {
1557
1638
  /**
1558
1639
  * Original discount rule name (in site's default language).
1559
1640
  * @minLength 1
@@ -1567,16 +1648,16 @@ export interface DiscountRuleName {
1567
1648
  */
1568
1649
  translated?: string | null;
1569
1650
  }
1570
- export interface LineItemDiscount {
1651
+ interface LineItemDiscount {
1571
1652
  /**
1572
1653
  * ID of line item the discount applies to.
1573
1654
  * @format GUID
1574
1655
  */
1575
- id?: string;
1656
+ _id?: string;
1576
1657
  /** Discount value. */
1577
1658
  totalDiscountAmount?: MultiCurrencyPrice;
1578
1659
  }
1579
- export interface CustomField {
1660
+ interface CustomField {
1580
1661
  /** Custom field value. */
1581
1662
  value?: any;
1582
1663
  /**
@@ -1592,7 +1673,7 @@ export interface CustomField {
1592
1673
  */
1593
1674
  translatedTitle?: string | null;
1594
1675
  }
1595
- export declare enum WeightUnit {
1676
+ declare enum WeightUnit {
1596
1677
  /** Weight unit can't be classified due to an error. */
1597
1678
  UNSPECIFIED_WEIGHT_UNIT = "UNSPECIFIED_WEIGHT_UNIT",
1598
1679
  /** Kilograms. */
@@ -1600,7 +1681,7 @@ export declare enum WeightUnit {
1600
1681
  /** Pounds. */
1601
1682
  LB = "LB"
1602
1683
  }
1603
- export interface TaxSummary {
1684
+ interface TaxSummary {
1604
1685
  /**
1605
1686
  * Amount for which tax is calculated, added from line items.
1606
1687
  * @readonly
@@ -1617,7 +1698,7 @@ export interface TaxSummary {
1617
1698
  */
1618
1699
  calculationDetails?: TaxCalculationDetails;
1619
1700
  }
1620
- export interface TaxCalculationDetails extends TaxCalculationDetailsCalculationDetailsOneOf {
1701
+ interface TaxCalculationDetails extends TaxCalculationDetailsCalculationDetailsOneOf {
1621
1702
  /** Reason the manual calculation was used. */
1622
1703
  manualRateReason?: ManualCalculationReason;
1623
1704
  /** Details of the fallback rate calculation. */
@@ -1626,13 +1707,13 @@ export interface TaxCalculationDetails extends TaxCalculationDetailsCalculationD
1626
1707
  rateType?: RateType;
1627
1708
  }
1628
1709
  /** @oneof */
1629
- export interface TaxCalculationDetailsCalculationDetailsOneOf {
1710
+ interface TaxCalculationDetailsCalculationDetailsOneOf {
1630
1711
  /** Reason the manual calculation was used. */
1631
1712
  manualRateReason?: ManualCalculationReason;
1632
1713
  /** Details of the fallback rate calculation. */
1633
1714
  autoTaxFallbackDetails?: AutoTaxFallbackCalculationDetails;
1634
1715
  }
1635
- export declare enum RateType {
1716
+ declare enum RateType {
1636
1717
  /** no tax being collected for this request due to location of purchase */
1637
1718
  NO_TAX_COLLECTED = "NO_TAX_COLLECTED",
1638
1719
  /** manual rate used for calculation */
@@ -1642,19 +1723,19 @@ export declare enum RateType {
1642
1723
  /** fallback rate used for calculation */
1643
1724
  FALLBACK_RATE = "FALLBACK_RATE"
1644
1725
  }
1645
- export declare enum ManualCalculationReason {
1726
+ declare enum ManualCalculationReason {
1646
1727
  /** user set calculator in Business Manager to be Manual */
1647
1728
  GLOBAL_SETTING_TO_MANUAL = "GLOBAL_SETTING_TO_MANUAL",
1648
1729
  /** specific region is on manual even though Global setting is Auto-tax */
1649
1730
  REGION_SETTING_TO_MANUAL = "REGION_SETTING_TO_MANUAL"
1650
1731
  }
1651
- export interface AutoTaxFallbackCalculationDetails {
1732
+ interface AutoTaxFallbackCalculationDetails {
1652
1733
  /** reason for fallback */
1653
1734
  fallbackReason?: FallbackReason;
1654
1735
  /** invalid request (i.e. address), timeout, internal error, license error, and others will be encoded here */
1655
1736
  error?: ApplicationError;
1656
1737
  }
1657
- export declare enum FallbackReason {
1738
+ declare enum FallbackReason {
1658
1739
  /** auto-tax failed to be calculated */
1659
1740
  AUTO_TAX_FAILED = "AUTO_TAX_FAILED",
1660
1741
  /** auto-tax was temporarily deactivated on a system-level */
@@ -1664,7 +1745,7 @@ export declare enum FallbackReason {
1664
1745
  * The summary of the tax breakdown for all the line items. It will hold for each tax name, the aggregated tax amount paid for it and the tax rate.
1665
1746
  * Tax breakdown is the tax amount split to the tax authorities that applied on the line item.
1666
1747
  */
1667
- export interface AggregatedTaxBreakdown {
1748
+ interface AggregatedTaxBreakdown {
1668
1749
  /**
1669
1750
  * The name of the tax against which this tax amount was calculated.
1670
1751
  * @maxLength 200
@@ -1690,7 +1771,7 @@ export interface AggregatedTaxBreakdown {
1690
1771
  /** The sum of all the tax from line items that calculated by the tax identifiers. */
1691
1772
  aggregatedTaxAmount?: MultiCurrencyPrice;
1692
1773
  }
1693
- export declare enum ChannelType {
1774
+ declare enum ChannelType {
1694
1775
  /** Unspecified sales channel. This value is not supported. */
1695
1776
  UNSPECIFIED = "UNSPECIFIED",
1696
1777
  /** A web client. */
@@ -1724,7 +1805,7 @@ export declare enum ChannelType {
1724
1805
  /** [Faire marketplace integration](https://support.wix.com/en/article/wix-stores-creating-a-faire-store-using-the-faire-integration-app). */
1725
1806
  FAIRE_COM = "FAIRE_COM"
1726
1807
  }
1727
- export interface CreatedBy extends CreatedByIdOneOf {
1808
+ interface CreatedBy extends CreatedByIdOneOf {
1728
1809
  /**
1729
1810
  * User ID. When the order was created by a Wix user on behalf of a buyer.
1730
1811
  * For example, via POS (point of service).
@@ -1748,7 +1829,7 @@ export interface CreatedBy extends CreatedByIdOneOf {
1748
1829
  appId?: string;
1749
1830
  }
1750
1831
  /** @oneof */
1751
- export interface CreatedByIdOneOf {
1832
+ interface CreatedByIdOneOf {
1752
1833
  /**
1753
1834
  * User ID. When the order was created by a Wix user on behalf of a buyer.
1754
1835
  * For example, via POS (point of service).
@@ -1772,7 +1853,7 @@ export interface CreatedByIdOneOf {
1772
1853
  appId?: string;
1773
1854
  }
1774
1855
  /** Reserved for internal use. */
1775
- export interface MembershipOptions {
1856
+ interface MembershipOptions {
1776
1857
  /**
1777
1858
  * Reserved for internal use.
1778
1859
  * @readonly
@@ -1788,13 +1869,13 @@ export interface MembershipOptions {
1788
1869
  /** Selected membership to apply to this checkout. */
1789
1870
  selectedMemberships?: SelectedMemberships;
1790
1871
  }
1791
- export interface Membership {
1872
+ interface Membership {
1792
1873
  /**
1793
1874
  * Membership ID.
1794
1875
  * @minLength 1
1795
1876
  * @maxLength 100
1796
1877
  */
1797
- id?: string;
1878
+ _id?: string;
1798
1879
  /**
1799
1880
  * ID of the application providing this payment option.
1800
1881
  * @format GUID
@@ -1803,7 +1884,7 @@ export interface Membership {
1803
1884
  /** The name of this membership. */
1804
1885
  name?: MembershipName;
1805
1886
  /**
1806
- * Line item IDs which are "paid" for by this membership.
1887
+ * Line item IDs which are "paid for" by this membership.
1807
1888
  * @minSize 1
1808
1889
  * @maxSize 300
1809
1890
  * @minLength 1
@@ -1817,7 +1898,7 @@ export interface Membership {
1817
1898
  /** Additional data about this membership. */
1818
1899
  additionalData?: Record<string, any> | null;
1819
1900
  }
1820
- export interface MembershipName {
1901
+ interface MembershipName {
1821
1902
  /**
1822
1903
  * Membership name.
1823
1904
  * @maxLength 100
@@ -1829,7 +1910,7 @@ export interface MembershipName {
1829
1910
  */
1830
1911
  translated?: string | null;
1831
1912
  }
1832
- export interface MembershipPaymentCredits {
1913
+ interface MembershipPaymentCredits {
1833
1914
  /**
1834
1915
  * Membership's total amount of credits.
1835
1916
  * @min 1
@@ -1838,7 +1919,7 @@ export interface MembershipPaymentCredits {
1838
1919
  /** Membership's remaining amount of credits. */
1839
1920
  remaining?: number;
1840
1921
  }
1841
- export interface InvalidMembership {
1922
+ interface InvalidMembership {
1842
1923
  /** Membership details. */
1843
1924
  membership?: Membership;
1844
1925
  /**
@@ -1848,20 +1929,20 @@ export interface InvalidMembership {
1848
1929
  */
1849
1930
  reason?: string;
1850
1931
  }
1851
- export interface SelectedMemberships {
1932
+ interface SelectedMemberships {
1852
1933
  /**
1853
1934
  * Selected memberships.
1854
1935
  * @maxSize 300
1855
1936
  */
1856
1937
  memberships?: SelectedMembership[];
1857
1938
  }
1858
- export interface SelectedMembership {
1939
+ interface SelectedMembership {
1859
1940
  /**
1860
1941
  * Membership ID.
1861
1942
  * @minLength 1
1862
1943
  * @maxLength 100
1863
1944
  */
1864
- id?: string;
1945
+ _id?: string;
1865
1946
  /**
1866
1947
  * ID of the app providing this payment option.
1867
1948
  * @format GUID
@@ -1876,7 +1957,7 @@ export interface SelectedMembership {
1876
1957
  */
1877
1958
  lineItemIds?: string[];
1878
1959
  }
1879
- export interface AdditionalFee {
1960
+ interface AdditionalFee {
1880
1961
  /**
1881
1962
  * Additional fee's unique code (or ID) for future processing.
1882
1963
  * @minLength 1
@@ -1909,10 +1990,18 @@ export interface AdditionalFee {
1909
1990
  * @format GUID
1910
1991
  */
1911
1992
  lineItemIds?: string[];
1993
+ /**
1994
+ * Number of subscription cycle this fee applies to
1995
+ * default None - all billing cycle
1996
+ * @internal
1997
+ * @min 1
1998
+ * @max 999
1999
+ */
2000
+ subscriptionCycles?: number | null;
1912
2001
  /** the source the additional fee was added from */
1913
2002
  source?: AdditionalFeeSource;
1914
2003
  }
1915
- export declare enum AdditionalFeeSource {
2004
+ declare enum AdditionalFeeSource {
1916
2005
  UNKNOWN_ADDITIONAL_FEE_SOURCE = "UNKNOWN_ADDITIONAL_FEE_SOURCE",
1917
2006
  /** The additional fee was added by an additional fee service plugin */
1918
2007
  SERVICE_PLUGIN = "SERVICE_PLUGIN",
@@ -1921,7 +2010,7 @@ export declare enum AdditionalFeeSource {
1921
2010
  /** The additional fee was added manually on the request */
1922
2011
  MANUAL = "MANUAL"
1923
2012
  }
1924
- export interface ConversionInfo {
2013
+ interface ConversionInfo {
1925
2014
  /**
1926
2015
  * The site currency.
1927
2016
  * @readonly
@@ -1935,7 +2024,7 @@ export interface ConversionInfo {
1935
2024
  */
1936
2025
  conversionRate?: string;
1937
2026
  }
1938
- export interface Violation {
2027
+ interface Violation {
1939
2028
  /** Severity of the violation. The violations are shown on the cart and checkout pages. A warning is displayed as yellow, and allows a site visitor to proceed with caution. An error is displayed as red, and doesn't allow a site visitor to proceed with the eCommerce flow. */
1940
2029
  severity?: Severity;
1941
2030
  /** Target location on a checkout or cart page where the violation will be displayed. */
@@ -1947,7 +2036,7 @@ export interface Violation {
1947
2036
  */
1948
2037
  description?: string | null;
1949
2038
  }
1950
- export declare enum Severity {
2039
+ declare enum Severity {
1951
2040
  /** The user is allowed to move forward in the flow. */
1952
2041
  WARNING = "WARNING",
1953
2042
  /**
@@ -1956,48 +2045,53 @@ export declare enum Severity {
1956
2045
  */
1957
2046
  ERROR = "ERROR"
1958
2047
  }
1959
- export interface Target extends TargetTargetTypeOneOf {
2048
+ interface Target extends TargetTargetTypeOneOf {
1960
2049
  /** General (other) violation. */
1961
2050
  other?: Other;
1962
2051
  /** Specific line item violation. */
1963
2052
  lineItem?: TargetLineItem;
1964
2053
  }
1965
2054
  /** @oneof */
1966
- export interface TargetTargetTypeOneOf {
2055
+ interface TargetTargetTypeOneOf {
1967
2056
  /** General (other) violation. */
1968
2057
  other?: Other;
1969
2058
  /** Specific line item violation. */
1970
2059
  lineItem?: TargetLineItem;
1971
2060
  }
1972
2061
  /** Available locations on the webpage */
1973
- export declare enum NameInOther {
2062
+ declare enum NameInOther {
1974
2063
  /** Default location, in case no specific location is specified. */
1975
2064
  OTHER_DEFAULT = "OTHER_DEFAULT"
1976
2065
  }
1977
2066
  /** Available locations on the line item */
1978
- export declare enum NameInLineItem {
2067
+ declare enum NameInLineItem {
1979
2068
  /** Default location, in case no specific location is specified. */
1980
2069
  LINE_ITEM_DEFAULT = "LINE_ITEM_DEFAULT"
1981
2070
  }
1982
- export declare enum SuggestedFix {
2071
+ declare enum SuggestedFix {
1983
2072
  /** No suggested fix is specified. The user should refer to the violation description to resolve the issue. */
1984
2073
  UNKNOWN_SUGGESTED_FIX = "UNKNOWN_SUGGESTED_FIX",
1985
2074
  /** The line item should be removed from the cart or checkout to resolve the violation. */
1986
2075
  REMOVE_LINE_ITEM = "REMOVE_LINE_ITEM"
1987
2076
  }
1988
2077
  /** General (other) violation. */
1989
- export interface Other {
2078
+ interface Other {
1990
2079
  /** Location on a checkout or a cart page where a general (other) violation will be displayed. */
1991
2080
  name?: NameInOther;
1992
2081
  }
1993
2082
  /** Specific line item violation. */
1994
- export interface TargetLineItem {
2083
+ interface TargetLineItem {
1995
2084
  /** Location on a checkout or a cart page where the specific line item violation will be displayed. */
1996
2085
  name?: NameInLineItem;
1997
2086
  /** ID of the line item containing the violation. */
1998
- id?: string | null;
2087
+ _id?: string | null;
2088
+ /**
2089
+ * Suggested fix for resolving the line item violation.
2090
+ * @internal
2091
+ */
2092
+ suggestedFix?: SuggestedFix;
1999
2093
  }
2000
- export interface CustomSettings {
2094
+ interface CustomSettings {
2001
2095
  /**
2002
2096
  * Whether to restrict the option to add or remove a gift card on the checkout page.
2003
2097
  *
@@ -2023,7 +2117,7 @@ export interface CustomSettings {
2023
2117
  */
2024
2118
  disabledManualPayment?: boolean;
2025
2119
  }
2026
- export interface CustomContentReference {
2120
+ interface CustomContentReference {
2027
2121
  /**
2028
2122
  * ID of the app providing the content.
2029
2123
  *
@@ -2039,7 +2133,7 @@ export interface CustomContentReference {
2039
2133
  */
2040
2134
  componentId?: string;
2041
2135
  }
2042
- export interface ExternalReference {
2136
+ interface ExternalReference {
2043
2137
  /**
2044
2138
  * ID of the app associated with the purchase flow.
2045
2139
  * For example, the Wix Pay Links app ID.
@@ -2056,7 +2150,7 @@ export interface ExternalReference {
2056
2150
  */
2057
2151
  resourceId?: string | null;
2058
2152
  }
2059
- export interface SubscriptionCharges {
2153
+ interface SubscriptionCharges {
2060
2154
  /**
2061
2155
  * ids of the items the subscription is defined on
2062
2156
  * @format GUID
@@ -2076,7 +2170,7 @@ export interface SubscriptionCharges {
2076
2170
  */
2077
2171
  charges?: Charge[];
2078
2172
  }
2079
- export interface Charge {
2173
+ interface Charge {
2080
2174
  /** The cycle number from which the charge starts. */
2081
2175
  cycleFrom?: number;
2082
2176
  /** The number of cycles for which the charge is applicable. */
@@ -2086,16 +2180,16 @@ export interface Charge {
2086
2180
  /** The billing date from which the charge starts. */
2087
2181
  cycleBillingDate?: Date | null;
2088
2182
  }
2089
- export interface UpdatedCheckoutMessage {
2183
+ interface UpdatedCheckoutMessage {
2090
2184
  /** Previous checkout. */
2091
2185
  oldCheckout?: Checkout;
2092
2186
  /** Updated checkout. */
2093
2187
  updatedCheckout?: Checkout;
2094
2188
  }
2095
- export interface CreateCheckoutRequest {
2189
+ interface CreateCheckoutRequest {
2096
2190
  /** Checkout information. */
2097
2191
  checkoutInfo?: Checkout;
2098
- /** Coupon code. */
2192
+ /** The code of an existing coupon to apply to checkout. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */
2099
2193
  couponCode?: string | null;
2100
2194
  /**
2101
2195
  * Catalog line items to add to the checkout.
@@ -2123,14 +2217,12 @@ export interface CreateCheckoutRequest {
2123
2217
  /**
2124
2218
  * `overrideCheckoutUrl` allows the flexibility to redirect customers to a customized checkout page.
2125
2219
  *
2126
- * This field overrides the `checkoutUrl` in a cart or checkout. `checkoutUrl` is used in the Abandoned Checkout API
2127
- * to send customers back to their checkouts. By default, a `checkoutUrl` generates for a checkout and directs to a
2128
- * standard Wix checkout page. When `overrideCheckoutUrl` has a value, it will replace and set the value of `checkoutUrl`.
2220
+ * This field overrides the `checkoutUrl` in a cart or checkout. `checkoutUrl` is used to send customers back to their checkouts. By default, a `checkoutUrl` generates for a checkout and directs to a standard Wix checkout page. When `overrideCheckoutUrl` has a value, it will replace and set the value of `checkoutUrl`.
2129
2221
  * @maxLength 1000
2130
2222
  */
2131
2223
  overrideCheckoutUrl?: string | null;
2132
2224
  }
2133
- export interface CustomLineItem {
2225
+ interface CustomLineItem {
2134
2226
  /**
2135
2227
  * Custom line item quantity.
2136
2228
  *
@@ -2141,9 +2233,7 @@ export interface CustomLineItem {
2141
2233
  */
2142
2234
  quantity?: number;
2143
2235
  /**
2144
- * Custom line item price.
2145
- *
2146
- * Must be a number or a decimal without symbols.
2236
+ * Custom line item price. For security reasons, the `price` field should come from backend Velo code, and not be passed from the frontend.
2147
2237
  * @format DECIMAL_VALUE
2148
2238
  * @decimalValue options { gte:0, lte:1000000000000000 }
2149
2239
  */
@@ -2151,19 +2241,23 @@ export interface CustomLineItem {
2151
2241
  /** Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67". */
2152
2242
  priceDescription?: PriceDescription;
2153
2243
  /**
2154
- * Custom line item description lines. Used for display purposes for the cart, checkout and order.
2244
+ * Custom line item description lines. Used for displaying the cart, checkout and order.
2155
2245
  * @maxSize 10
2156
2246
  */
2157
2247
  descriptionLines?: DescriptionLine[];
2158
- /** Custom line item's media. */
2159
- media?: Image;
2248
+ /**
2249
+ * Custom line item media.
2250
+ * + Link to an image/video from the [Wix Media Manager](https://support.wix.com/en/article/wix-media-about-the-media-manager) - `"wix:image://v1/3c76e2_c53...4ea4~mv2.jpg#originWidth=1000&originHeight=1000"`.
2251
+ * + An image from the web - `"http(s)://<image url>"`.
2252
+ */
2253
+ media?: string;
2160
2254
  /**
2161
2255
  * Custom line item ID. If passed, `id` must be unique.
2162
2256
  *
2163
2257
  * Default: auto-generated ID
2164
2258
  * @format GUID
2165
2259
  */
2166
- id?: string | null;
2260
+ _id?: string | null;
2167
2261
  /**
2168
2262
  * Tax group ID for this custom line item.
2169
2263
  * @format GUID
@@ -2172,7 +2266,7 @@ export interface CustomLineItem {
2172
2266
  /** Name of the item or product. */
2173
2267
  productName?: ProductName;
2174
2268
  /** URL to the item's page on the site. When not provided, the link back from the cart page to the relevant product page will not work. */
2175
- url?: PageUrlV2;
2269
+ url?: string;
2176
2270
  /** Item type. Either a preset type or custom. */
2177
2271
  itemType?: ItemType;
2178
2272
  /**
@@ -2227,6 +2321,20 @@ export interface CustomLineItem {
2227
2321
  deliveryProfileId?: string | null;
2228
2322
  /** Catalog and item reference. Includes IDs for the item and the catalog it came from, as well as further optional info. Optional for custom line items, which don't trigger the Catalog service plugin. */
2229
2323
  catalogReference?: CatalogReference;
2324
+ /**
2325
+ * Whether the price is not yet defined, and will be updated after the order is created.
2326
+ *
2327
+ * Default: `false`
2328
+ * @internal
2329
+ */
2330
+ priceUndetermined?: boolean;
2331
+ /**
2332
+ * Whether the line item quantity is fixed and cannot be changed.
2333
+ *
2334
+ * Default: `false`
2335
+ * @internal
2336
+ */
2337
+ fixedQuantity?: boolean;
2230
2338
  /**
2231
2339
  * Item payment policy that requires customer consent to complete purchase. The payment policy will be displayed on the checkout page.
2232
2340
  * @minLength 1
@@ -2241,105 +2349,123 @@ export interface CustomLineItem {
2241
2349
  * @readonly
2242
2350
  */
2243
2351
  savePaymentMethod?: boolean;
2352
+ /**
2353
+ * Policies to be displayed to the customer on the checkout page.
2354
+ * @internal
2355
+ * @maxSize 5
2356
+ */
2357
+ policies?: Policy[];
2358
+ /**
2359
+ * ID of the app managing the inventory.
2360
+ * @internal
2361
+ * @format GUID
2362
+ */
2363
+ inventoryAppId?: string | null;
2364
+ /**
2365
+ * Whether the item can only be purchased by site members.
2366
+ *
2367
+ * Default: `false`
2368
+ * @internal
2369
+ */
2370
+ membersOnly?: boolean;
2371
+ /**
2372
+ * Address to use for tax calculation purposes.
2373
+ * @internal
2374
+ */
2375
+ taxableAddress?: TaxableAddress;
2244
2376
  }
2245
- export interface MerchantDiscountInput {
2377
+ interface MerchantDiscountInput {
2246
2378
  /**
2247
2379
  * Discount amount.
2248
2380
  * @decimalValue options { gte:0 }
2249
2381
  */
2250
2382
  amount?: string;
2251
2383
  /**
2252
- * IDs of line items the discount applies to.
2384
+ * IDs of the line items the discount applies to.
2253
2385
  * @format GUID
2254
2386
  * @maxSize 300
2255
2387
  */
2256
2388
  lineItemIds?: string[];
2257
2389
  }
2258
- export interface CreateCheckoutResponse {
2390
+ interface CreateCheckoutResponse {
2259
2391
  /** Newly created checkout. */
2260
2392
  checkout?: Checkout;
2261
2393
  }
2262
- export interface ShippingCalculationErrorData extends ShippingCalculationErrorDataShippingCalculationErrorOneOf {
2394
+ interface ShippingCalculationErrorData extends ShippingCalculationErrorDataShippingCalculationErrorOneOf {
2263
2395
  generalShippingCalculationError?: Details;
2264
2396
  carrierErrors?: CarrierErrors;
2265
2397
  }
2266
2398
  /** @oneof */
2267
- export interface ShippingCalculationErrorDataShippingCalculationErrorOneOf {
2399
+ interface ShippingCalculationErrorDataShippingCalculationErrorOneOf {
2268
2400
  generalShippingCalculationError?: Details;
2269
2401
  carrierErrors?: CarrierErrors;
2270
2402
  }
2271
- export interface GetCheckoutRequest {
2403
+ interface GetCheckoutRequest {
2272
2404
  /**
2273
2405
  * Checkout ID.
2274
2406
  * @format GUID
2275
2407
  */
2276
- id: string;
2408
+ _id: string;
2277
2409
  }
2278
- export interface GetCheckoutResponse {
2410
+ interface GetCheckoutResponse {
2279
2411
  /** Retrieved checkout. */
2280
2412
  checkout?: Checkout;
2281
2413
  }
2282
- export interface GetCheckoutWithAllExtendedFieldsRequest {
2414
+ interface GetCheckoutWithAllExtendedFieldsRequest {
2283
2415
  /**
2284
2416
  * Checkout ID.
2285
2417
  * @format GUID
2286
2418
  */
2287
- id?: string;
2419
+ _id?: string;
2288
2420
  }
2289
- export interface GetCheckoutWithAllExtendedFieldsResponse {
2421
+ interface GetCheckoutWithAllExtendedFieldsResponse {
2290
2422
  /** Retrieved checkout. */
2291
2423
  checkout?: Checkout;
2292
2424
  }
2293
- export interface GetCheckoutByCartIdRequest {
2425
+ interface GetCheckoutByCartIdRequest {
2294
2426
  /**
2295
2427
  * Cart ID.
2296
2428
  * @format GUID
2297
2429
  */
2298
- id: string;
2430
+ _id: string;
2299
2431
  }
2300
- export interface GetCheckoutByCartIdResponse {
2432
+ interface GetCheckoutByCartIdResponse {
2301
2433
  /** Retrieved checkout. */
2302
2434
  checkout?: Checkout;
2303
2435
  }
2304
- export interface GetWixCheckoutURLRequest {
2436
+ interface GetWixCheckoutURLRequest {
2305
2437
  /**
2306
2438
  * Checkout ID.
2307
2439
  * @format GUID
2308
2440
  */
2309
- id: string;
2441
+ _id: string;
2310
2442
  }
2311
- export interface GetWixCheckoutURLResponse {
2443
+ interface GetWixCheckoutURLResponse {
2312
2444
  /** Checkout URL. */
2313
2445
  checkoutUrl?: string;
2314
2446
  }
2315
- export interface GetCheckoutURLRequest {
2447
+ interface GetCheckoutURLRequest {
2316
2448
  /**
2317
2449
  * Checkout ID.
2318
2450
  * @format GUID
2319
2451
  */
2320
- id: string;
2452
+ _id: string;
2321
2453
  }
2322
- export interface GetCheckoutURLResponse {
2454
+ interface GetCheckoutURLResponse {
2323
2455
  /** Checkout URL. */
2324
2456
  checkoutUrl?: string;
2325
2457
  }
2326
- export interface UpdateCheckoutRequest {
2458
+ interface UpdateCheckoutRequest {
2327
2459
  /** Checkout information. */
2328
2460
  checkout: Checkout;
2329
- /**
2330
- * Coupon code.
2331
- *
2332
- * The checkout can only hold 1 `couponCode` at a time. If an additional `couponCode` is added, it will override the existing `couponCode`.
2333
- */
2461
+ /** The code of an existing coupon to apply to checkout. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */
2334
2462
  couponCode?: string | null;
2335
2463
  /** Gift card code. */
2336
2464
  giftCardCode?: string | null;
2337
2465
  /**
2338
2466
  * `overrideCheckoutUrl` allows the flexibility to redirect customers to a customized checkout page.
2339
2467
  *
2340
- * This field overrides the `checkoutUrl` in a cart or checkout. `checkoutUrl` is used in the Abandoned Checkout API
2341
- * to send customers back to their checkouts. By default, a `checkoutUrl` generates for a checkout and directs to a
2342
- * standard Wix checkout page. When `overrideCheckoutUrl` has a value, it will replace and set the value of `checkoutUrl`.
2468
+ * This field overrides the `checkoutUrl` in a cart or checkout. `checkoutUrl` is used to send customers back to their checkouts. By default, a `checkoutUrl` generates for a checkout and directs to a standard Wix checkout page. When `overrideCheckoutUrl` has a value, it will replace and set the value of `checkoutUrl`.
2343
2469
  * @maxLength 1000
2344
2470
  */
2345
2471
  overrideCheckoutUrl?: string | null;
@@ -2357,49 +2483,49 @@ export interface UpdateCheckoutRequest {
2357
2483
  */
2358
2484
  customLineItems?: CustomLineItem[];
2359
2485
  }
2360
- export interface UpdateCheckoutResponse {
2486
+ interface UpdateCheckoutResponse {
2361
2487
  /** Updated checkout. */
2362
2488
  checkout?: Checkout;
2363
2489
  }
2364
- export interface RemoveCouponRequest {
2490
+ interface RemoveCouponRequest {
2365
2491
  /**
2366
2492
  * ID of the checkout to remove the coupon from.
2367
2493
  * @format GUID
2368
2494
  */
2369
- id: string;
2495
+ _id: string;
2370
2496
  }
2371
- export interface RemoveCouponResponse {
2497
+ interface RemoveCouponResponse {
2372
2498
  /** Updated checkout after removal of coupon. */
2373
2499
  checkout?: Checkout;
2374
2500
  }
2375
- export interface RemoveGiftCardRequest {
2501
+ interface RemoveGiftCardRequest {
2376
2502
  /**
2377
2503
  * ID of the checkout to remove the gift card from.
2378
2504
  * @format GUID
2379
2505
  */
2380
- id: string;
2506
+ _id: string;
2381
2507
  }
2382
- export interface RemoveGiftCardResponse {
2508
+ interface RemoveGiftCardResponse {
2383
2509
  /** Updated checkout after removal of gift card. */
2384
2510
  checkout?: Checkout;
2385
2511
  }
2386
- export interface RemoveOverrideCheckoutUrlRequest {
2512
+ interface RemoveOverrideCheckoutUrlRequest {
2387
2513
  /**
2388
2514
  * ID of the checkout to remove the override checkout url from.
2389
2515
  * @format GUID
2390
2516
  */
2391
- id: string;
2517
+ _id: string;
2392
2518
  }
2393
- export interface RemoveOverrideCheckoutUrlResponse {
2519
+ interface RemoveOverrideCheckoutUrlResponse {
2394
2520
  /** Updated checkout after removal of override checkout url. */
2395
2521
  checkout?: Checkout;
2396
2522
  }
2397
- export interface AddToCheckoutRequest {
2523
+ interface AddToCheckoutRequest {
2398
2524
  /**
2399
2525
  * Checkout ID.
2400
2526
  * @format GUID
2401
2527
  */
2402
- id: string;
2528
+ _id: string;
2403
2529
  /**
2404
2530
  * Catalog line items.
2405
2531
  * @maxSize 100
@@ -2414,46 +2540,42 @@ export interface AddToCheckoutRequest {
2414
2540
  */
2415
2541
  customLineItems?: CustomLineItem[];
2416
2542
  }
2417
- export interface AddToCheckoutResponse {
2543
+ interface AddToCheckoutResponse {
2418
2544
  /** Updated checkout. */
2419
2545
  checkout?: Checkout;
2420
2546
  }
2421
- export interface RemoveLineItemsRequest {
2547
+ interface RemoveLineItemsRequest {
2422
2548
  /**
2423
2549
  * ID of the checkout to remove line items from.
2424
2550
  * @format GUID
2425
2551
  */
2426
- id: string;
2552
+ _id: string;
2427
2553
  /**
2428
2554
  * IDs of the line items to remove from the checkout.
2429
- *
2430
- * To find the IDs of the checkout line items you'd like to remove,
2431
- * pass the checkout ID to Get Checkout and look for the IDs under
2432
- * `lineItems`.
2433
2555
  * @format GUID
2434
2556
  * @minSize 1
2435
2557
  * @maxSize 300
2436
2558
  */
2437
2559
  lineItemIds: string[];
2438
2560
  }
2439
- export interface RemoveLineItemsResponse {
2561
+ interface RemoveLineItemsResponse {
2440
2562
  /** Updated checkout after removal of line items. */
2441
2563
  checkout?: Checkout;
2442
2564
  }
2443
- export interface CreateOrderRequest {
2565
+ interface CreateOrderRequest {
2444
2566
  /**
2445
2567
  * Checkout ID.
2446
2568
  * @format GUID
2447
2569
  */
2448
- id: string;
2570
+ _id: string;
2449
2571
  /** Whether the payment method should be saved on the order. */
2450
2572
  savePaymentMethod?: boolean;
2451
2573
  /** Whether to authorize the payment and delay the capture. */
2452
2574
  delayCapture?: boolean;
2453
2575
  }
2454
- export interface CreateOrderResponse extends CreateOrderResponseIdOneOf {
2576
+ interface CreateOrderResponse extends CreateOrderResponseIdOneOf {
2455
2577
  /**
2456
- * ID of newly created order.
2578
+ * ID of the newly created order.
2457
2579
  * @format GUID
2458
2580
  */
2459
2581
  orderId?: string;
@@ -2466,16 +2588,15 @@ export interface CreateOrderResponse extends CreateOrderResponseIdOneOf {
2466
2588
  * Payment gateway order ID.
2467
2589
  *
2468
2590
  * For online orders, pass this value as the `paymentId` parameter to the Wix Pay [`startPayment()`](https://www.wix.com/velo/reference/wix-pay-frontend/startpayment) function so your customer can pay for the order.
2469
- * `paymentGatewayOrderId` will be returned if money needs to be charged.
2470
2591
  *
2471
- * In some cases, money cannot be charged:
2472
- * + When the total price (the `priceSummary.total.amount` field in the checkout/order objects) is `0`. For example, in the case of a free item or an item with a 100% discount.
2473
- * + If the total price is not `0`, but the payment is covered by alternative payment methods, such as a gift card.
2592
+ * This field will be returned if money needs to be charged. In some cases, money cannot be charged:
2593
+ * + When the total price (the `priceSummary.total.amount` field in the checkout/order objects) is 0. For example, in the case of a free item or an item with a 100% discount.
2594
+ * + If the total price is not 0, but the payment is covered by alternative payment methods, such as a gift card.
2474
2595
  */
2475
2596
  paymentGatewayOrderId?: string | null;
2476
2597
  }
2477
2598
  /** @oneof */
2478
- export interface CreateOrderResponseIdOneOf {
2599
+ interface CreateOrderResponseIdOneOf {
2479
2600
  /**
2480
2601
  * ID of newly created order.
2481
2602
  * @format GUID
@@ -2487,37 +2608,37 @@ export interface CreateOrderResponseIdOneOf {
2487
2608
  */
2488
2609
  subscriptionId?: string;
2489
2610
  }
2490
- export interface PaymentErrorResponseData {
2611
+ interface PaymentErrorResponseData {
2491
2612
  paymentResponseToken?: string | null;
2492
2613
  transactionStatus?: string;
2493
2614
  failureDetails?: string | null;
2494
2615
  }
2495
- export interface DoublePaymentErrorData extends DoublePaymentErrorDataIdOneOf {
2616
+ interface DoublePaymentErrorData extends DoublePaymentErrorDataIdOneOf {
2496
2617
  /** @format GUID */
2497
2618
  orderId?: string;
2498
2619
  /** @format GUID */
2499
2620
  subscriptionId?: string;
2500
2621
  }
2501
2622
  /** @oneof */
2502
- export interface DoublePaymentErrorDataIdOneOf {
2623
+ interface DoublePaymentErrorDataIdOneOf {
2503
2624
  /** @format GUID */
2504
2625
  orderId?: string;
2505
2626
  /** @format GUID */
2506
2627
  subscriptionId?: string;
2507
2628
  }
2508
- export interface RedeemErrorData {
2629
+ interface RedeemErrorData {
2509
2630
  reason?: string;
2510
2631
  }
2511
- export interface ViolationsList {
2632
+ interface ViolationsList {
2512
2633
  /** Violations risen by ValidationsSPI implementers. */
2513
2634
  violations?: Violation[];
2514
2635
  }
2515
- export interface CreateOrderAndChargeRequest {
2636
+ interface CreateOrderAndChargeRequest {
2516
2637
  /**
2517
2638
  * Checkout ID.
2518
2639
  * @format GUID
2519
2640
  */
2520
- id: string;
2641
+ _id: string;
2521
2642
  /** Payment token. */
2522
2643
  paymentToken?: string | null;
2523
2644
  /** Whether the payment method should be saved on the order. */
@@ -2525,7 +2646,7 @@ export interface CreateOrderAndChargeRequest {
2525
2646
  /** Whether to authorize the payment and delay the capture. */
2526
2647
  delayCapture?: boolean;
2527
2648
  }
2528
- export interface CreateOrderAndChargeResponse extends CreateOrderAndChargeResponseIdOneOf {
2649
+ interface CreateOrderAndChargeResponse extends CreateOrderAndChargeResponseIdOneOf {
2529
2650
  /**
2530
2651
  * ID of newly created order.
2531
2652
  * @format GUID
@@ -2539,16 +2660,23 @@ export interface CreateOrderAndChargeResponse extends CreateOrderAndChargeRespon
2539
2660
  /** Payment response token. */
2540
2661
  paymentResponseToken?: string | null;
2541
2662
  /**
2542
- * The payment gateway is cashier.
2543
- * payment_gateway_order_id will be returned given that money was charged.
2544
- * In some cases, money will not be charged:
2545
- * If the total price is 0 - For example, could be a free item or a an item with 100% discount
2546
- * If the total price is not 0, but the payment is covered by alternative payment methods such as gift card
2663
+ * For online orders, send this value as a parameter to the Wix Pay [`startPayment()`](https://www.wix.com/velo/reference/wix-pay/startpayment) function to enable your buyer to pay for the order.
2664
+ * `paymentGatewayOrderId` will be returned if money needs to be charged.
2665
+ *
2666
+ * In some cases, money should not be charged:
2667
+ * + If the total price is 0. For example, in the case of a free item or an item with 100% discount.
2668
+ * + If the total price is not 0, but the payment is covered by alternative payment methods, such as a gift card.
2547
2669
  */
2548
2670
  paymentGatewayOrderId?: string | null;
2671
+ /**
2672
+ * Whether an order was successfully created from this checkout and the payment transaction was completed
2673
+ * @internal
2674
+ * @readonly
2675
+ */
2676
+ checkoutCompleted?: boolean;
2549
2677
  }
2550
2678
  /** @oneof */
2551
- export interface CreateOrderAndChargeResponseIdOneOf {
2679
+ interface CreateOrderAndChargeResponseIdOneOf {
2552
2680
  /**
2553
2681
  * ID of newly created order.
2554
2682
  * @format GUID
@@ -2560,41 +2688,47 @@ export interface CreateOrderAndChargeResponseIdOneOf {
2560
2688
  */
2561
2689
  subscriptionId?: string;
2562
2690
  }
2563
- export interface MarkCheckoutAsCompletedAndRedirectToUrlRequest {
2691
+ interface MarkCheckoutAsCompletedAndRedirectToUrlRequest {
2564
2692
  /**
2565
2693
  * Server-signed JWT token with required information to complete checkout
2566
2694
  * @maxLength 4096
2567
2695
  */
2568
2696
  token: string;
2569
2697
  }
2570
- export interface RawHttpResponse {
2698
+ interface RawHttpResponse {
2571
2699
  body?: Uint8Array;
2572
2700
  statusCode?: number | null;
2573
2701
  headers?: HeadersEntry[];
2574
2702
  }
2575
- export interface HeadersEntry {
2703
+ interface HeadersEntry {
2576
2704
  key?: string;
2577
2705
  value?: string;
2578
2706
  }
2579
- export interface MarkCheckoutAsCompletedRequest {
2707
+ interface MarkCheckoutAsCompletedRequest {
2580
2708
  /**
2581
2709
  * Checkout ID.
2582
2710
  * @format GUID
2583
2711
  */
2584
- id: string;
2712
+ _id: string;
2713
+ /**
2714
+ * Order ID.
2715
+ * @internal
2716
+ * @format GUID
2717
+ */
2718
+ orderId?: string | null;
2585
2719
  }
2586
- export interface MarkCheckoutAsCompletedResponse {
2720
+ interface MarkCheckoutAsCompletedResponse {
2587
2721
  }
2588
2722
  /** Triggered when an order created from this checkout is successfully paid for or when a checkout is marked as completed. */
2589
- export interface CheckoutMarkedAsCompleted {
2723
+ interface CheckoutMarkedAsCompleted {
2590
2724
  checkout?: Checkout;
2591
2725
  }
2592
- export interface UpdateLineItemsQuantityRequest {
2726
+ interface UpdateLineItemsQuantityRequest {
2593
2727
  /**
2594
2728
  * Checkout ID.
2595
2729
  * @format GUID
2596
2730
  */
2597
- id: string;
2731
+ _id: string;
2598
2732
  /**
2599
2733
  * Line item info to update.
2600
2734
  * @minSize 1
@@ -2602,12 +2736,12 @@ export interface UpdateLineItemsQuantityRequest {
2602
2736
  */
2603
2737
  lineItems: LineItemQuantityUpdate[];
2604
2738
  }
2605
- export interface LineItemQuantityUpdate {
2739
+ interface LineItemQuantityUpdate {
2606
2740
  /**
2607
2741
  * ID of the line item to update.
2608
2742
  * @format GUID
2609
2743
  */
2610
- id?: string;
2744
+ _id?: string;
2611
2745
  /**
2612
2746
  * New total amount of the line item,
2613
2747
  * not the amount to add to the current `quantity`.
@@ -2620,42 +2754,42 @@ export interface LineItemQuantityUpdate {
2620
2754
  */
2621
2755
  quantity?: number;
2622
2756
  }
2623
- export interface UpdateLineItemsQuantityResponse {
2757
+ interface UpdateLineItemsQuantityResponse {
2624
2758
  /** Updated checkout. */
2625
2759
  checkout?: Checkout;
2626
2760
  }
2627
- export interface GetCheckoutPaymentSettingsRequest {
2761
+ interface GetCheckoutPaymentSettingsRequest {
2628
2762
  /**
2629
2763
  * Checkout ID.
2630
2764
  * @format GUID
2631
2765
  */
2632
- id: string;
2766
+ _id: string;
2633
2767
  }
2634
- export interface GetCheckoutPaymentSettingsResponse {
2768
+ interface GetCheckoutPaymentSettingsResponse {
2635
2769
  blockedPaymentOptions?: GetCheckoutPaymentSettingsResponsePaymentOption[];
2636
2770
  }
2637
- export declare enum GetCheckoutPaymentSettingsResponsePaymentOption {
2771
+ declare enum GetCheckoutPaymentSettingsResponsePaymentOption {
2638
2772
  UNKNOWN_PAYMENT_OPTION = "UNKNOWN_PAYMENT_OPTION",
2639
2773
  MANUAL = "MANUAL"
2640
2774
  }
2641
- export interface DeleteCheckoutRequest {
2775
+ interface DeleteCheckoutRequest {
2642
2776
  /**
2643
2777
  * ID of the checkout to delete.
2644
2778
  * @format GUID
2645
2779
  */
2646
- id?: string;
2780
+ _id?: string;
2647
2781
  }
2648
- export interface DeleteCheckoutResponse {
2782
+ interface DeleteCheckoutResponse {
2649
2783
  }
2650
- export interface SubscriptionCreated {
2784
+ interface SubscriptionCreated {
2651
2785
  subscription?: Subscription;
2652
2786
  }
2653
- export interface Subscription {
2787
+ interface Subscription {
2654
2788
  /**
2655
2789
  * Subscription id (auto-generated upon subscription creation)
2656
2790
  * @readonly
2657
2791
  */
2658
- id?: string;
2792
+ _id?: string;
2659
2793
  /**
2660
2794
  * id of subscription in external system
2661
2795
  * @format GUID
@@ -2714,23 +2848,23 @@ export interface Subscription {
2714
2848
  billingInfo?: BillingInfo;
2715
2849
  }
2716
2850
  /** Buyer Info */
2717
- export interface V1BuyerInfo {
2851
+ interface V1BuyerInfo {
2718
2852
  /**
2719
2853
  * Wix customer ID
2720
2854
  * @format GUID
2721
2855
  */
2722
- id?: string;
2856
+ _id?: string;
2723
2857
  /** Customer type */
2724
2858
  identityType?: IdentityType;
2725
2859
  }
2726
- export declare enum IdentityType {
2860
+ declare enum IdentityType {
2727
2861
  UNSPECIFIED_IDENTITY_TYPE = "UNSPECIFIED_IDENTITY_TYPE",
2728
2862
  /** Site member */
2729
2863
  MEMBER = "MEMBER",
2730
2864
  /** Contact */
2731
2865
  CONTACT = "CONTACT"
2732
2866
  }
2733
- export interface V1LineItem {
2867
+ interface V1LineItem {
2734
2868
  /** Line item ID (auto-generated) */
2735
2869
  index?: number;
2736
2870
  /**
@@ -2759,7 +2893,7 @@ export interface V1LineItem {
2759
2893
  /** Product details */
2760
2894
  productDetails?: ProductDetails;
2761
2895
  }
2762
- export interface OptionSelection {
2896
+ interface OptionSelection {
2763
2897
  /**
2764
2898
  * Option name
2765
2899
  * @maxLength 200
@@ -2771,7 +2905,7 @@ export interface OptionSelection {
2771
2905
  */
2772
2906
  selection?: string;
2773
2907
  }
2774
- export interface CustomTextFieldSelection {
2908
+ interface CustomTextFieldSelection {
2775
2909
  /**
2776
2910
  * Custom text field name
2777
2911
  * @maxLength 100
@@ -2783,7 +2917,7 @@ export interface CustomTextFieldSelection {
2783
2917
  */
2784
2918
  value?: string;
2785
2919
  }
2786
- export interface ChargeDetails {
2920
+ interface ChargeDetails {
2787
2921
  /**
2788
2922
  * price of line item (depends on subscription option)
2789
2923
  * @max 999999999.99
@@ -2812,7 +2946,7 @@ export interface ChargeDetails {
2812
2946
  */
2813
2947
  taxRate?: string | null;
2814
2948
  }
2815
- export interface ProductDetails {
2949
+ interface ProductDetails {
2816
2950
  /**
2817
2951
  * Line item product ID (optional for POS orders)
2818
2952
  * @minLength 1
@@ -2865,7 +2999,7 @@ export interface ProductDetails {
2865
2999
  */
2866
3000
  appId?: string | null;
2867
3001
  }
2868
- export declare enum LineItemType {
3002
+ declare enum LineItemType {
2869
3003
  /** Line item type can't be classified, due to an error */
2870
3004
  UNSPECIFIED_LINE_ITEM_TYPE = "UNSPECIFIED_LINE_ITEM_TYPE",
2871
3005
  /** Physical item type */
@@ -2875,7 +3009,7 @@ export declare enum LineItemType {
2875
3009
  /** Custom item price */
2876
3010
  CUSTOM_AMOUNT_ITEM = "CUSTOM_AMOUNT_ITEM"
2877
3011
  }
2878
- export interface MediaItem {
3012
+ interface MediaItem {
2879
3013
  /**
2880
3014
  * Media type
2881
3015
  * @readonly
@@ -2900,7 +3034,7 @@ export interface MediaItem {
2900
3034
  */
2901
3035
  height?: number;
2902
3036
  /** Media ID (for media items previously saved in Wix Media) */
2903
- id?: string | null;
3037
+ _id?: string | null;
2904
3038
  /** Media external URL */
2905
3039
  externalImageUrl?: string | null;
2906
3040
  /**
@@ -2909,13 +3043,13 @@ export interface MediaItem {
2909
3043
  */
2910
3044
  altText?: string | null;
2911
3045
  }
2912
- export declare enum MediaItemType {
3046
+ declare enum MediaItemType {
2913
3047
  /** Media item type can't be classified, due to an error */
2914
3048
  UNSPECIFIED_MEDIA_TYPE_ITEM = "UNSPECIFIED_MEDIA_TYPE_ITEM",
2915
3049
  /** Image item type */
2916
3050
  IMAGE = "IMAGE"
2917
3051
  }
2918
- export interface Totals {
3052
+ interface Totals {
2919
3053
  /**
2920
3054
  * Subtotal of all line items, before tax
2921
3055
  * @max 999999999.99
@@ -2952,7 +3086,7 @@ export interface Totals {
2952
3086
  */
2953
3087
  quantity?: number;
2954
3088
  }
2955
- export interface StoreSettings {
3089
+ interface StoreSettings {
2956
3090
  /**
2957
3091
  * Currency used for pricing in this store
2958
3092
  * @maxLength 3
@@ -2970,7 +3104,7 @@ export interface StoreSettings {
2970
3104
  */
2971
3105
  buyerLanguage?: string | null;
2972
3106
  }
2973
- export interface Address extends AddressAddressLine1OptionsOneOf {
3107
+ interface Address extends AddressAddressLine1OptionsOneOf {
2974
3108
  /**
2975
3109
  * Address line 1 (free text)
2976
3110
  * @maxLength 1000
@@ -3024,7 +3158,7 @@ export interface Address extends AddressAddressLine1OptionsOneOf {
3024
3158
  vatId?: VatId;
3025
3159
  }
3026
3160
  /** @oneof */
3027
- export interface AddressAddressLine1OptionsOneOf {
3161
+ interface AddressAddressLine1OptionsOneOf {
3028
3162
  /**
3029
3163
  * Address line 1 (free text)
3030
3164
  * @maxLength 1000
@@ -3033,7 +3167,7 @@ export interface AddressAddressLine1OptionsOneOf {
3033
3167
  /** Address line 1 (street) */
3034
3168
  street?: Street;
3035
3169
  }
3036
- export interface FullName {
3170
+ interface FullName {
3037
3171
  /**
3038
3172
  * Customer's first name
3039
3173
  * @maxLength 1000
@@ -3045,7 +3179,7 @@ export interface FullName {
3045
3179
  */
3046
3180
  lastName?: string;
3047
3181
  }
3048
- export interface Street {
3182
+ interface Street {
3049
3183
  /**
3050
3184
  * Street number
3051
3185
  * @maxLength 500
@@ -3057,7 +3191,7 @@ export interface Street {
3057
3191
  */
3058
3192
  name?: string;
3059
3193
  }
3060
- export interface VatId {
3194
+ interface VatId {
3061
3195
  /**
3062
3196
  * Customer's tax ID.
3063
3197
  * @maxLength 50
@@ -3071,7 +3205,7 @@ export interface VatId {
3071
3205
  type?: VatType;
3072
3206
  }
3073
3207
  /** Brazilian tax info types */
3074
- export declare enum VatType {
3208
+ declare enum VatType {
3075
3209
  /** When the tax info type can't be classified, due to an error */
3076
3210
  UNSPECIFIED_TAX_TYPE = "UNSPECIFIED_TAX_TYPE",
3077
3211
  /** CPF - for individual tax payers */
@@ -3079,7 +3213,7 @@ export declare enum VatType {
3079
3213
  /** CNPJ - for corporations */
3080
3214
  CNPJ = "CNPJ"
3081
3215
  }
3082
- export interface V1ShippingInfo extends V1ShippingInfoDetailsOneOf {
3216
+ interface V1ShippingInfo extends V1ShippingInfoDetailsOneOf {
3083
3217
  /** Shipment details (when this object describes shipment) */
3084
3218
  shipmentDetails?: ShipmentDetails;
3085
3219
  /** Pickup details (when this object describes pickup) */
@@ -3096,13 +3230,13 @@ export interface V1ShippingInfo extends V1ShippingInfoDetailsOneOf {
3096
3230
  estimatedDeliveryTime?: string | null;
3097
3231
  }
3098
3232
  /** @oneof */
3099
- export interface V1ShippingInfoDetailsOneOf {
3233
+ interface V1ShippingInfoDetailsOneOf {
3100
3234
  /** Shipment details (when this object describes shipment) */
3101
3235
  shipmentDetails?: ShipmentDetails;
3102
3236
  /** Pickup details (when this object describes pickup) */
3103
3237
  pickupDetails?: V1PickupDetails;
3104
3238
  }
3105
- export interface ShipmentDetails {
3239
+ interface ShipmentDetails {
3106
3240
  /** Shipping destination address */
3107
3241
  address?: Address;
3108
3242
  /**
@@ -3123,7 +3257,7 @@ export interface ShipmentDetails {
3123
3257
  */
3124
3258
  taxRate?: string | null;
3125
3259
  }
3126
- export interface V1PickupDetails {
3260
+ interface V1PickupDetails {
3127
3261
  /** Pickup address */
3128
3262
  address?: PickupAddress;
3129
3263
  /**
@@ -3132,7 +3266,7 @@ export interface V1PickupDetails {
3132
3266
  */
3133
3267
  pickupInstructions?: string | null;
3134
3268
  }
3135
- export interface PickupAddress {
3269
+ interface PickupAddress {
3136
3270
  /**
3137
3271
  * Country code (2 letters)
3138
3272
  * @format COUNTRY
@@ -3159,7 +3293,7 @@ export interface PickupAddress {
3159
3293
  */
3160
3294
  zipCode?: string;
3161
3295
  }
3162
- export interface AppliedCoupon {
3296
+ interface AppliedCoupon {
3163
3297
  /** Coupon ID */
3164
3298
  couponId?: string;
3165
3299
  /**
@@ -3174,7 +3308,7 @@ export interface AppliedCoupon {
3174
3308
  code?: string;
3175
3309
  }
3176
3310
  /** Custom field */
3177
- export interface V1CustomField {
3311
+ interface V1CustomField {
3178
3312
  /**
3179
3313
  * Free text that the customer entered in the custom field during the checkout process
3180
3314
  * @maxLength 250
@@ -3191,9 +3325,9 @@ export interface V1CustomField {
3191
3325
  */
3192
3326
  translatedTitle?: string;
3193
3327
  }
3194
- export interface V1SubscriptionOptionInfo {
3328
+ interface V1SubscriptionOptionInfo {
3195
3329
  /** @format GUID */
3196
- id?: string | null;
3330
+ _id?: string | null;
3197
3331
  /**
3198
3332
  * @minLength 1
3199
3333
  * @maxLength 20
@@ -3203,29 +3337,29 @@ export interface V1SubscriptionOptionInfo {
3203
3337
  description?: string | null;
3204
3338
  discount?: Discount;
3205
3339
  }
3206
- export interface Discount {
3340
+ interface Discount {
3207
3341
  /** Discount type. */
3208
3342
  type?: DiscountDiscountType;
3209
3343
  /** Discount value. */
3210
3344
  value?: number;
3211
3345
  }
3212
- export declare enum DiscountDiscountType {
3346
+ declare enum DiscountDiscountType {
3213
3347
  UNDEFINED = "UNDEFINED",
3214
3348
  /** No discount */
3215
3349
  AMOUNT = "AMOUNT",
3216
3350
  PERCENT = "PERCENT"
3217
3351
  }
3218
- export interface ChannelInfo {
3352
+ interface ChannelInfo {
3219
3353
  /** Sales channel that submitted the subscription */
3220
3354
  type?: ChannelInfoChannelType;
3221
3355
  }
3222
- export declare enum ChannelInfoChannelType {
3356
+ declare enum ChannelInfoChannelType {
3223
3357
  UNSPECIFIED = "UNSPECIFIED",
3224
3358
  WEB = "WEB",
3225
3359
  OTHER_PLATFORM = "OTHER_PLATFORM",
3226
3360
  WIX_APP_STORE = "WIX_APP_STORE"
3227
3361
  }
3228
- export interface V1SubscriptionSettings {
3362
+ interface V1SubscriptionSettings {
3229
3363
  /** Frequency of recurring payment. */
3230
3364
  frequency?: SubscriptionFrequency;
3231
3365
  /** Whether subscription is renewed automatically at the end of each period. */
@@ -3237,7 +3371,7 @@ export interface V1SubscriptionSettings {
3237
3371
  */
3238
3372
  billingCycles?: number | null;
3239
3373
  }
3240
- export interface BillingInfo {
3374
+ interface BillingInfo {
3241
3375
  /**
3242
3376
  * Payment method used for this order
3243
3377
  * @maxLength 50
@@ -3254,9 +3388,9 @@ export interface BillingInfo {
3254
3388
  */
3255
3389
  paymentGatewayOrderId?: string | null;
3256
3390
  }
3257
- export interface Empty {
3391
+ interface Empty {
3258
3392
  }
3259
- export interface DomainEvent extends DomainEventBodyOneOf {
3393
+ interface DomainEvent extends DomainEventBodyOneOf {
3260
3394
  createdEvent?: EntityCreatedEvent;
3261
3395
  updatedEvent?: EntityUpdatedEvent;
3262
3396
  deletedEvent?: EntityDeletedEvent;
@@ -3265,7 +3399,7 @@ export interface DomainEvent extends DomainEventBodyOneOf {
3265
3399
  * Unique event ID.
3266
3400
  * Allows clients to ignore duplicate webhooks.
3267
3401
  */
3268
- id?: string;
3402
+ _id?: string;
3269
3403
  /**
3270
3404
  * Assumes actions are also always typed to an entity_type
3271
3405
  * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
@@ -3299,36 +3433,34 @@ export interface DomainEvent extends DomainEventBodyOneOf {
3299
3433
  entityEventSequence?: string | null;
3300
3434
  }
3301
3435
  /** @oneof */
3302
- export interface DomainEventBodyOneOf {
3436
+ interface DomainEventBodyOneOf {
3303
3437
  createdEvent?: EntityCreatedEvent;
3304
3438
  updatedEvent?: EntityUpdatedEvent;
3305
3439
  deletedEvent?: EntityDeletedEvent;
3306
3440
  actionEvent?: ActionEvent;
3307
3441
  }
3308
- export interface EntityCreatedEvent {
3309
- entityAsJson?: string;
3310
- /** Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity */
3311
- restoreInfo?: RestoreInfo;
3442
+ interface EntityCreatedEvent {
3443
+ entity?: string;
3312
3444
  }
3313
- export interface RestoreInfo {
3445
+ interface RestoreInfo {
3314
3446
  deletedDate?: Date | null;
3315
3447
  }
3316
- export interface EntityUpdatedEvent {
3448
+ interface EntityUpdatedEvent {
3317
3449
  /**
3318
3450
  * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
3319
3451
  * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
3320
3452
  * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
3321
3453
  */
3322
- currentEntityAsJson?: string;
3454
+ currentEntity?: string;
3323
3455
  }
3324
- export interface EntityDeletedEvent {
3456
+ interface EntityDeletedEvent {
3325
3457
  /** Entity that was deleted */
3326
- deletedEntityAsJson?: string | null;
3458
+ deletedEntity?: string | null;
3327
3459
  }
3328
- export interface ActionEvent {
3329
- bodyAsJson?: string;
3460
+ interface ActionEvent {
3461
+ body?: string;
3330
3462
  }
3331
- export interface MessageEnvelope {
3463
+ interface MessageEnvelope {
3332
3464
  /**
3333
3465
  * App instance ID.
3334
3466
  * @format GUID
@@ -3344,7 +3476,7 @@ export interface MessageEnvelope {
3344
3476
  /** Stringify payload. */
3345
3477
  data?: string;
3346
3478
  }
3347
- export interface IdentificationData extends IdentificationDataIdOneOf {
3479
+ interface IdentificationData extends IdentificationDataIdOneOf {
3348
3480
  /**
3349
3481
  * ID of a site visitor that has not logged in to the site.
3350
3482
  * @format GUID
@@ -3369,7 +3501,7 @@ export interface IdentificationData extends IdentificationDataIdOneOf {
3369
3501
  identityType?: WebhookIdentityType;
3370
3502
  }
3371
3503
  /** @oneof */
3372
- export interface IdentificationDataIdOneOf {
3504
+ interface IdentificationDataIdOneOf {
3373
3505
  /**
3374
3506
  * ID of a site visitor that has not logged in to the site.
3375
3507
  * @format GUID
@@ -3391,10 +3523,381 @@ export interface IdentificationDataIdOneOf {
3391
3523
  */
3392
3524
  appId?: string;
3393
3525
  }
3394
- export declare enum WebhookIdentityType {
3526
+ declare enum WebhookIdentityType {
3395
3527
  UNKNOWN = "UNKNOWN",
3396
3528
  ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
3397
3529
  MEMBER = "MEMBER",
3398
3530
  WIX_USER = "WIX_USER",
3399
3531
  APP = "APP"
3400
3532
  }
3533
+ interface BaseEventMetadata {
3534
+ /**
3535
+ * App instance ID.
3536
+ * @format GUID
3537
+ */
3538
+ instanceId?: string | null;
3539
+ /**
3540
+ * Event type.
3541
+ * @maxLength 150
3542
+ */
3543
+ eventType?: string;
3544
+ /** The identification type and identity data. */
3545
+ identity?: IdentificationData;
3546
+ }
3547
+ interface EventMetadata extends BaseEventMetadata {
3548
+ /**
3549
+ * Unique event ID.
3550
+ * Allows clients to ignore duplicate webhooks.
3551
+ */
3552
+ _id?: string;
3553
+ /**
3554
+ * Assumes actions are also always typed to an entity_type
3555
+ * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
3556
+ */
3557
+ entityFqdn?: string;
3558
+ /**
3559
+ * This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug)
3560
+ * This is although the created/updated/deleted notion is duplication of the oneof types
3561
+ * Example: created/updated/deleted/started/completed/email_opened
3562
+ */
3563
+ slug?: string;
3564
+ /** ID of the entity associated with the event. */
3565
+ entityId?: string;
3566
+ /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example: 2020-04-26T13:57:50.699Z */
3567
+ eventTime?: Date | null;
3568
+ /**
3569
+ * Whether the event was triggered as a result of a privacy regulation application
3570
+ * (for example, GDPR).
3571
+ */
3572
+ triggeredByAnonymizeRequest?: boolean | null;
3573
+ /** If present, indicates the action that triggered the event. */
3574
+ originatedFrom?: string | null;
3575
+ /**
3576
+ * A sequence number defining the order of updates to the underlying entity.
3577
+ * For example, given that some entity was updated at 16:00 and than again at 16:01,
3578
+ * it is guaranteed that the sequence number of the second update is strictly higher than the first.
3579
+ * As the consumer, you can use this value to ensure that you handle messages in the correct order.
3580
+ * To do so, you will need to persist this number on your end, and compare the sequence number from the
3581
+ * message against the one you have stored. Given that the stored number is higher, you should ignore the message.
3582
+ */
3583
+ entityEventSequence?: string | null;
3584
+ }
3585
+ interface CheckoutCompletedEnvelope {
3586
+ data: CheckoutMarkedAsCompleted;
3587
+ metadata: EventMetadata;
3588
+ }
3589
+ interface CheckoutCreatedEnvelope {
3590
+ entity: Checkout;
3591
+ metadata: EventMetadata;
3592
+ }
3593
+ interface CheckoutUpdatedEnvelope {
3594
+ entity: Checkout;
3595
+ metadata: EventMetadata;
3596
+ }
3597
+ interface CreateCheckoutOptions {
3598
+ /** Checkout information. */
3599
+ checkoutInfo?: Checkout;
3600
+ /** The code of an existing coupon to apply to checkout. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */
3601
+ couponCode?: string | null;
3602
+ /**
3603
+ * Catalog line items to add to the checkout.
3604
+ * @maxSize 300
3605
+ */
3606
+ lineItems?: LineItem[];
3607
+ /**
3608
+ * Custom line items to add to the checkout. Custom line items don't trigger the Catalog service plugin.
3609
+ *
3610
+ * To access and manage custom line items, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
3611
+ * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
3612
+ * @maxSize 300
3613
+ */
3614
+ customLineItems?: CustomLineItem[];
3615
+ /** Sales channel that submitted the order. */
3616
+ channelType: ChannelType;
3617
+ /**
3618
+ * Gift card code.
3619
+ *
3620
+ * The checkout can only hold 1 `giftCardCode` at a time. If an additional `giftCardCode` is added, it will override the existing `giftCardCode`.
3621
+ *
3622
+ * >**Note:** Gift cards are supported through the Wix UI, though the service plugin is not currently available. Learn more about [Wix Gift Cards](https://support.wix.com/en/article/setting-up-wix-gift-cards-9451439).
3623
+ */
3624
+ giftCardCode?: string | null;
3625
+ /**
3626
+ * `overrideCheckoutUrl` allows the flexibility to redirect customers to a customized checkout page.
3627
+ *
3628
+ * This field overrides the `checkoutUrl` in a cart or checkout. `checkoutUrl` is used to send customers back to their checkouts. By default, a `checkoutUrl` generates for a checkout and directs to a standard Wix checkout page. When `overrideCheckoutUrl` has a value, it will replace and set the value of `checkoutUrl`.
3629
+ * @maxLength 1000
3630
+ */
3631
+ overrideCheckoutUrl?: string | null;
3632
+ }
3633
+ interface UpdateCheckout {
3634
+ /**
3635
+ * Checkout ID.
3636
+ * @format GUID
3637
+ * @readonly
3638
+ */
3639
+ _id?: string | null;
3640
+ /**
3641
+ * Line items.
3642
+ *
3643
+ * Max: 300 items
3644
+ * @minSize 1
3645
+ * @maxSize 300
3646
+ * @readonly
3647
+ */
3648
+ lineItems?: LineItem[];
3649
+ /** Billing information. */
3650
+ billingInfo?: AddressWithContact;
3651
+ /** Shipping information. */
3652
+ shippingInfo?: ShippingInfo;
3653
+ /**
3654
+ * [Buyer note](https://support.wix.com/en/article/wix-stores-viewing-buyer-notes) left by the customer.
3655
+ * @maxLength 1000
3656
+ */
3657
+ buyerNote?: string | null;
3658
+ /** Buyer information. */
3659
+ buyerInfo?: BuyerInfo;
3660
+ /**
3661
+ * All converted prices are displayed in this currency in three-letter [ISO-4217 alphabetic](https://en.wikipedia.org/wiki/ISO_4217#Active_codes) format.
3662
+ * @readonly
3663
+ * @format CURRENCY
3664
+ */
3665
+ conversionCurrency?: string;
3666
+ /**
3667
+ * Calculated price summary for the checkout.
3668
+ * @readonly
3669
+ */
3670
+ priceSummary?: PriceSummary;
3671
+ /**
3672
+ * Errors when calculating totals.
3673
+ * @readonly
3674
+ */
3675
+ calculationErrors?: CalculationErrors;
3676
+ /**
3677
+ * Applied gift card details.
3678
+ *
3679
+ * >**Note:** Gift cards are supported through the Wix UI, though the service plugin is not currently available. Learn more about [Wix Gift Cards](https://support.wix.com/en/article/setting-up-wix-gift-cards-9451439).
3680
+ * @readonly
3681
+ */
3682
+ giftCard?: GiftCard;
3683
+ /**
3684
+ * Applied discounts.
3685
+ * @readonly
3686
+ */
3687
+ appliedDiscounts?: AppliedDiscount[];
3688
+ /** Custom fields. */
3689
+ customFields?: CustomField[];
3690
+ /**
3691
+ * Weight measurement unit. Defaults to a site's weight unit.
3692
+ * @readonly
3693
+ */
3694
+ weightUnit?: WeightUnit;
3695
+ /**
3696
+ * Tax summary.
3697
+ * @readonly
3698
+ */
3699
+ taxSummary?: TaxSummary;
3700
+ /**
3701
+ * The currency used when submitting the order.
3702
+ * @format CURRENCY
3703
+ * @readonly
3704
+ */
3705
+ currency?: string;
3706
+ /**
3707
+ * Sales channel that submitted the order.
3708
+ * @readonly
3709
+ */
3710
+ channelType?: ChannelType;
3711
+ /**
3712
+ * Site language in which original values are shown.
3713
+ * @readonly
3714
+ */
3715
+ siteLanguage?: string;
3716
+ /**
3717
+ * Language for communication with the buyer. Defaults to the site language.
3718
+ * For a site that supports multiple languages, this is the language the buyer selected.
3719
+ * @readonly
3720
+ */
3721
+ buyerLanguage?: string;
3722
+ /**
3723
+ * Whether an order was successfully created from this checkout.
3724
+ * For an order to be successful, it must be successfully paid for (unless the total is 0).
3725
+ * @readonly
3726
+ */
3727
+ completed?: boolean;
3728
+ /**
3729
+ * Whether tax is included in line item prices.
3730
+ * @readonly
3731
+ */
3732
+ taxIncludedInPrice?: boolean;
3733
+ /**
3734
+ * ID of the checkout's initiator.
3735
+ * @readonly
3736
+ */
3737
+ createdBy?: CreatedBy;
3738
+ /**
3739
+ * Date and time the checkout was created.
3740
+ * @readonly
3741
+ */
3742
+ _createdDate?: Date | null;
3743
+ /**
3744
+ * Date and time the checkout was updated.
3745
+ * @readonly
3746
+ */
3747
+ _updatedDate?: Date | null;
3748
+ /**
3749
+ * Minimal amount to pay in order to place the order.
3750
+ * @readonly
3751
+ */
3752
+ payNow?: PriceSummary;
3753
+ /**
3754
+ * Remaining amount for the order to be fully paid.
3755
+ * @readonly
3756
+ */
3757
+ payLater?: PriceSummary;
3758
+ /** Memberships to apply when creating the order. */
3759
+ membershipOptions?: MembershipOptions;
3760
+ /**
3761
+ * Additional Fees.
3762
+ * @maxSize 100
3763
+ */
3764
+ additionalFees?: AdditionalFee[];
3765
+ /**
3766
+ * Cart ID that this checkout was created from. Empty if this checkout wasn't created from a cart.
3767
+ * @format GUID
3768
+ */
3769
+ cartId?: string | null;
3770
+ /**
3771
+ * List of validation violations raised by the [Validations Custom Extension SPI](https://www.wix.com/velo/reference/spis/wix-ecom/ecom-validations/introduction).
3772
+ * @readonly
3773
+ */
3774
+ violations?: Violation[];
3775
+ /**
3776
+ * Custom field data for the checkout object.
3777
+ *
3778
+ * [Extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields) must be configured in the app dashboard before they can be accessed with API calls.
3779
+ */
3780
+ extendedFields?: ExtendedFields;
3781
+ /**
3782
+ * Persistent ID that correlates between the various eCommerce elements: cart, checkout, and order.
3783
+ * @format GUID
3784
+ * @readonly
3785
+ */
3786
+ purchaseFlowId?: string | null;
3787
+ /**
3788
+ * Additional settings for customization of the checkout process.
3789
+ *
3790
+ * Custom settings can only be defined when [creating a checkout](https://www.wix.com/velo/reference/wix-ecom-backend/checkout/createcheckout).
3791
+ * @immutable
3792
+ */
3793
+ customSettings?: CustomSettings;
3794
+ /**
3795
+ * Reference IDs for the app and component providing custom checkout page content.
3796
+ *
3797
+ * To access and manage custom checkout page content, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
3798
+ * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
3799
+ */
3800
+ customContentReference?: CustomContentReference;
3801
+ /**
3802
+ * References to an external app and resource associated with this checkout.
3803
+ * Used for integration and tracking across different platforms.
3804
+ * @immutable
3805
+ */
3806
+ externalReference?: ExternalReference;
3807
+ /**
3808
+ * Order ID.
3809
+ *
3810
+ * This field is empty until the checkout completes and becomes an order.
3811
+ * @internal
3812
+ * @format GUID
3813
+ * @readonly
3814
+ */
3815
+ orderId?: string | null;
3816
+ /**
3817
+ * Payment for subscriptions after free trial period.
3818
+ * @internal
3819
+ * @readonly
3820
+ */
3821
+ payAfterFreeTrial?: PriceSummary;
3822
+ /**
3823
+ * The business location ID associated with the checkout.
3824
+ *
3825
+ * To learn more, see the Locations API.
3826
+ * @format GUID
3827
+ */
3828
+ businessLocationId?: string | null;
3829
+ /**
3830
+ * Whether payment is required to create an order.
3831
+ *
3832
+ * Payment is required if any of the following conditions are met:
3833
+ * 1. At least one item requires a payment method. This can be because the item has the `savePaymentMethod` field set to `true`, or the item is a subscription with a price greater than zero.
3834
+ * 2. The calculated total amount due for immediate payment is greater than zero - `checkout.payNow > 0`.
3835
+ * @internal
3836
+ * @readonly
3837
+ */
3838
+ paymentRequired?: boolean;
3839
+ /**
3840
+ * Charges information for each subscription in the checkout.
3841
+ * @internal
3842
+ * @readonly
3843
+ * @maxSize 100
3844
+ */
3845
+ subscriptionCharges?: SubscriptionCharges[];
3846
+ }
3847
+ interface UpdateCheckoutOptions {
3848
+ /** The code of an existing coupon to apply to checkout. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */
3849
+ couponCode?: string | null;
3850
+ /** Gift card code. */
3851
+ giftCardCode?: string | null;
3852
+ /**
3853
+ * `overrideCheckoutUrl` allows the flexibility to redirect customers to a customized checkout page.
3854
+ *
3855
+ * This field overrides the `checkoutUrl` in a cart or checkout. `checkoutUrl` is used to send customers back to their checkouts. By default, a `checkoutUrl` generates for a checkout and directs to a standard Wix checkout page. When `overrideCheckoutUrl` has a value, it will replace and set the value of `checkoutUrl`.
3856
+ * @maxLength 1000
3857
+ */
3858
+ overrideCheckoutUrl?: string | null;
3859
+ /**
3860
+ * Catalog line items.
3861
+ * @maxSize 300
3862
+ */
3863
+ lineItems?: LineItem[];
3864
+ /**
3865
+ * Custom line items. Custom line items don't trigger the Catalog service plugin.
3866
+ *
3867
+ * To access and manage custom line items, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
3868
+ * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
3869
+ * @maxSize 300
3870
+ */
3871
+ customLineItems?: CustomLineItem[];
3872
+ }
3873
+ interface AddToCheckoutOptions {
3874
+ /**
3875
+ * Catalog line items.
3876
+ * @maxSize 100
3877
+ */
3878
+ lineItems?: LineItem[];
3879
+ /**
3880
+ * Custom line items. Custom line items don't trigger the Catalog service plugin.
3881
+ *
3882
+ * To access and manage custom line items, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
3883
+ * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
3884
+ * @maxSize 100
3885
+ */
3886
+ customLineItems?: CustomLineItem[];
3887
+ }
3888
+ interface CreateOrderOptions {
3889
+ /** Whether the payment method should be saved on the order. */
3890
+ savePaymentMethod?: boolean;
3891
+ /** Whether to authorize the payment and delay the capture. */
3892
+ delayCapture?: boolean;
3893
+ }
3894
+ interface CreateOrderAndChargeOptions {
3895
+ /** Payment token. */
3896
+ paymentToken?: string | null;
3897
+ /** Whether the payment method should be saved on the order. */
3898
+ savePaymentMethod?: boolean;
3899
+ /** Whether to authorize the payment and delay the capture. */
3900
+ delayCapture?: boolean;
3901
+ }
3902
+
3903
+ export { type CatalogReference as $, type AddToCheckoutOptions as A, NameInLineItem as B, type CreateCheckoutOptions as C, DescriptionLineType as D, SuggestedFix as E, FileType as F, type GetCheckoutByCartIdResponse as G, GetCheckoutPaymentSettingsResponsePaymentOption as H, ItemAvailabilityStatus as I, JurisdictionType as J, IdentityType as K, type LineItemQuantityUpdate as L, ManualCalculationReason as M, NameInOther as N, LineItemType as O, PaymentOptionType as P, MediaItemType as Q, type RemoveCouponResponse as R, SubscriptionFrequency as S, TaxableAddressType as T, type UpdateCheckout as U, VatType as V, WeightUnit as W, DiscountDiscountType as X, ChannelInfoChannelType as Y, WebhookIdentityType as Z, type LineItem as _, type Checkout as a, type DetailsKindOneOf as a$, type ProductName as a0, type MultiCurrencyPrice as a1, type ItemTaxFullDetails as a2, type TaxRateBreakdown as a3, type TaxBreakdown as a4, type DescriptionLine as a5, type DescriptionLineValueOneOf as a6, type DescriptionLineDescriptionLineValueOneOf as a7, type DescriptionLineName as a8, type PlainTextValue as a9, type ApiAddress as aA, type StreetAddress as aB, type AddressLocation as aC, type FullAddressContactDetails as aD, type CommonVatId as aE, type ShippingInfo as aF, type SelectedCarrierServiceOption as aG, type DeliveryLogistics as aH, type PickupDetails as aI, type DeliveryTimeSlot as aJ, type SelectedCarrierServiceOptionPrices as aK, type SelectedCarrierServiceOptionOtherCharge as aL, type DeliveryAllocation as aM, type Carrier as aN, type Region as aO, type ApplicableLineItems as aP, type ShippingRegion as aQ, type CarrierServiceOption as aR, type ShippingOption as aS, type ShippingPrice as aT, type OtherCharge as aU, type BuyerInfo as aV, type BuyerInfoIdOneOf as aW, type PriceSummary as aX, type CalculationErrors as aY, type CalculationErrorsShippingCalculationErrorOneOf as aZ, type Details as a_, type Color as aa, type FocalPoint as ab, type ItemAvailabilityInfo as ac, type PhysicalProperties as ad, type Scope as ae, type Group as af, type ItemType as ag, type ItemTypeItemTypeDataOneOf as ah, type SubscriptionOptionInfo as ai, type SubscriptionSettings as aj, type FreeTrialPeriod as ak, type Title as al, type Description as am, type SecuredMedia as an, type ServiceProperties as ao, type PriceDescription as ap, type CatalogOverrideFields as aq, type PaymentOption as ar, type TaxableAddress as as, type TaxableAddressTaxableAddressDataOneOf as at, type ExtendedFields as au, type Policy as av, type ModifierGroup as aw, type TranslatableString as ax, type ItemModifier as ay, type AddressWithContact as az, type GetWixCheckoutURLResponse as b, type CreateOrderResponseIdOneOf as b$, type ApplicationError as b0, type ValidationError as b1, type FieldViolation as b2, type SystemError as b3, type CarrierErrors as b4, type CarrierError as b5, type GiftCard as b6, type AppliedDiscount as b7, type AppliedDiscountDiscountSourceOneOf as b8, type Coupon as b9, type CustomSettings as bA, type CustomContentReference as bB, type ExternalReference as bC, type SubscriptionCharges as bD, type Charge as bE, type UpdatedCheckoutMessage as bF, type CreateCheckoutRequest as bG, type CustomLineItem as bH, type MerchantDiscountInput as bI, type CreateCheckoutResponse as bJ, type ShippingCalculationErrorData as bK, type ShippingCalculationErrorDataShippingCalculationErrorOneOf as bL, type GetCheckoutRequest as bM, type GetCheckoutResponse as bN, type GetCheckoutWithAllExtendedFieldsRequest as bO, type GetCheckoutWithAllExtendedFieldsResponse as bP, type GetCheckoutByCartIdRequest as bQ, type GetWixCheckoutURLRequest as bR, type GetCheckoutURLRequest as bS, type UpdateCheckoutRequest as bT, type UpdateCheckoutResponse as bU, type RemoveCouponRequest as bV, type RemoveGiftCardRequest as bW, type RemoveOverrideCheckoutUrlRequest as bX, type AddToCheckoutRequest as bY, type RemoveLineItemsRequest as bZ, type CreateOrderRequest as b_, type MerchantDiscount as ba, type DiscountRule as bb, type DiscountRuleName as bc, type LineItemDiscount as bd, type CustomField as be, type TaxSummary as bf, type TaxCalculationDetails as bg, type TaxCalculationDetailsCalculationDetailsOneOf as bh, type AutoTaxFallbackCalculationDetails as bi, type AggregatedTaxBreakdown as bj, type CreatedBy as bk, type CreatedByIdOneOf as bl, type MembershipOptions as bm, type Membership as bn, type MembershipName as bo, type MembershipPaymentCredits as bp, type InvalidMembership as bq, type SelectedMemberships as br, type SelectedMembership as bs, type AdditionalFee as bt, type ConversionInfo as bu, type Violation as bv, type Target as bw, type TargetTargetTypeOneOf as bx, type Other as by, type TargetLineItem as bz, type GetCheckoutURLResponse as c, type PaymentErrorResponseData as c0, type DoublePaymentErrorData as c1, type DoublePaymentErrorDataIdOneOf as c2, type RedeemErrorData as c3, type ViolationsList as c4, type CreateOrderAndChargeRequest as c5, type CreateOrderAndChargeResponseIdOneOf as c6, type MarkCheckoutAsCompletedAndRedirectToUrlRequest as c7, type HeadersEntry as c8, type MarkCheckoutAsCompletedRequest as c9, type PickupAddress as cA, type AppliedCoupon as cB, type V1CustomField as cC, type V1SubscriptionOptionInfo as cD, type Discount as cE, type ChannelInfo as cF, type V1SubscriptionSettings as cG, type BillingInfo as cH, type Empty as cI, type DomainEvent as cJ, type DomainEventBodyOneOf as cK, type EntityCreatedEvent as cL, type RestoreInfo as cM, type EntityUpdatedEvent as cN, type EntityDeletedEvent as cO, type ActionEvent as cP, type MessageEnvelope as cQ, type IdentificationData as cR, type IdentificationDataIdOneOf as cS, type BaseEventMetadata as cT, type EventMetadata as cU, type CheckoutCompletedEnvelope as cV, type CheckoutCreatedEnvelope as cW, type CheckoutUpdatedEnvelope as cX, type MarkCheckoutAsCompletedResponse as ca, type CheckoutMarkedAsCompleted as cb, type UpdateLineItemsQuantityRequest as cc, type GetCheckoutPaymentSettingsRequest as cd, type DeleteCheckoutRequest as ce, type DeleteCheckoutResponse as cf, type SubscriptionCreated as cg, type Subscription as ch, type V1BuyerInfo as ci, type V1LineItem as cj, type OptionSelection as ck, type CustomTextFieldSelection as cl, type ChargeDetails as cm, type ProductDetails as cn, type MediaItem as co, type Totals as cp, type StoreSettings as cq, type Address as cr, type AddressAddressLine1OptionsOneOf as cs, type FullName as ct, type Street as cu, type VatId as cv, type V1ShippingInfo as cw, type V1ShippingInfoDetailsOneOf as cx, type ShipmentDetails as cy, type V1PickupDetails as cz, type UpdateCheckoutOptions as d, type RemoveGiftCardResponse as e, type RemoveOverrideCheckoutUrlResponse as f, type AddToCheckoutResponse as g, type RemoveLineItemsResponse as h, type CreateOrderOptions as i, type CreateOrderResponse as j, type CreateOrderAndChargeOptions as k, type CreateOrderAndChargeResponse as l, type RawHttpResponse as m, type UpdateLineItemsQuantityResponse as n, type GetCheckoutPaymentSettingsResponse as o, ItemTypeItemType as p, CommonVatType as q, PickupMethod as r, ChargeType as s, RuleType as t, DiscountType as u, RateType as v, FallbackReason as w, ChannelType as x, AdditionalFeeSource as y, Severity as z };