@wix/auto_sdk_ecom_cart 1.0.2 → 1.0.4

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 (57) hide show
  1. package/build/cjs/src/ecom-v1-cart-cart.context.d.ts +2 -1
  2. package/build/cjs/src/ecom-v1-cart-cart.context.js +0 -1
  3. package/build/cjs/src/ecom-v1-cart-cart.context.js.map +1 -1
  4. package/build/cjs/src/ecom-v1-cart-cart.http.d.ts +7 -12
  5. package/build/cjs/src/ecom-v1-cart-cart.http.js +13 -12
  6. package/build/cjs/src/ecom-v1-cart-cart.http.js.map +1 -1
  7. package/build/cjs/src/ecom-v1-cart-cart.public.d.ts +16 -13
  8. package/build/cjs/src/ecom-v1-cart-cart.public.js +0 -1
  9. package/build/cjs/src/ecom-v1-cart-cart.public.js.map +1 -1
  10. package/build/cjs/src/ecom-v1-cart-cart.types.d.ts +669 -144
  11. package/build/cjs/src/ecom-v1-cart-cart.types.js.map +1 -1
  12. package/build/cjs/src/ecom-v1-cart-cart.universal.d.ts +797 -168
  13. package/build/cjs/src/ecom-v1-cart-cart.universal.js +35 -16
  14. package/build/cjs/src/ecom-v1-cart-cart.universal.js.map +1 -1
  15. package/build/es/src/ecom-v1-cart-cart.context.d.ts +2 -1
  16. package/build/es/src/ecom-v1-cart-cart.context.js +0 -1
  17. package/build/es/src/ecom-v1-cart-cart.context.js.map +1 -1
  18. package/build/es/src/ecom-v1-cart-cart.http.d.ts +7 -12
  19. package/build/es/src/ecom-v1-cart-cart.http.js +13 -12
  20. package/build/es/src/ecom-v1-cart-cart.http.js.map +1 -1
  21. package/build/es/src/ecom-v1-cart-cart.public.d.ts +16 -13
  22. package/build/es/src/ecom-v1-cart-cart.public.js +0 -1
  23. package/build/es/src/ecom-v1-cart-cart.public.js.map +1 -1
  24. package/build/es/src/ecom-v1-cart-cart.types.d.ts +669 -144
  25. package/build/es/src/ecom-v1-cart-cart.types.js.map +1 -1
  26. package/build/es/src/ecom-v1-cart-cart.universal.d.ts +797 -168
  27. package/build/es/src/ecom-v1-cart-cart.universal.js +35 -16
  28. package/build/es/src/ecom-v1-cart-cart.universal.js.map +1 -1
  29. package/build/internal/cjs/src/ecom-v1-cart-cart.context.d.ts +0 -1
  30. package/build/internal/cjs/src/ecom-v1-cart-cart.context.js +0 -1
  31. package/build/internal/cjs/src/ecom-v1-cart-cart.context.js.map +1 -1
  32. package/build/internal/cjs/src/ecom-v1-cart-cart.http.d.ts +7 -12
  33. package/build/internal/cjs/src/ecom-v1-cart-cart.http.js +13 -12
  34. package/build/internal/cjs/src/ecom-v1-cart-cart.http.js.map +1 -1
  35. package/build/internal/cjs/src/ecom-v1-cart-cart.public.d.ts +7 -13
  36. package/build/internal/cjs/src/ecom-v1-cart-cart.public.js +0 -1
  37. package/build/internal/cjs/src/ecom-v1-cart-cart.public.js.map +1 -1
  38. package/build/internal/cjs/src/ecom-v1-cart-cart.types.d.ts +669 -144
  39. package/build/internal/cjs/src/ecom-v1-cart-cart.types.js.map +1 -1
  40. package/build/internal/cjs/src/ecom-v1-cart-cart.universal.d.ts +770 -176
  41. package/build/internal/cjs/src/ecom-v1-cart-cart.universal.js +35 -16
  42. package/build/internal/cjs/src/ecom-v1-cart-cart.universal.js.map +1 -1
  43. package/build/internal/es/src/ecom-v1-cart-cart.context.d.ts +0 -1
  44. package/build/internal/es/src/ecom-v1-cart-cart.context.js +0 -1
  45. package/build/internal/es/src/ecom-v1-cart-cart.context.js.map +1 -1
  46. package/build/internal/es/src/ecom-v1-cart-cart.http.d.ts +7 -12
  47. package/build/internal/es/src/ecom-v1-cart-cart.http.js +13 -12
  48. package/build/internal/es/src/ecom-v1-cart-cart.http.js.map +1 -1
  49. package/build/internal/es/src/ecom-v1-cart-cart.public.d.ts +7 -13
  50. package/build/internal/es/src/ecom-v1-cart-cart.public.js +0 -1
  51. package/build/internal/es/src/ecom-v1-cart-cart.public.js.map +1 -1
  52. package/build/internal/es/src/ecom-v1-cart-cart.types.d.ts +669 -144
  53. package/build/internal/es/src/ecom-v1-cart-cart.types.js.map +1 -1
  54. package/build/internal/es/src/ecom-v1-cart-cart.universal.d.ts +770 -176
  55. package/build/internal/es/src/ecom-v1-cart-cart.universal.js +35 -16
  56. package/build/internal/es/src/ecom-v1-cart-cart.universal.js.map +1 -1
  57. package/package.json +2 -2
@@ -1,17 +1,26 @@
1
1
  export interface Cart {
2
- /** Cart ID. */
2
+ /**
3
+ * Cart ID.
4
+ * @format GUID
5
+ */
3
6
  _id?: string | null;
4
7
  /**
5
8
  * Line items.
9
+ * @minSize 1
10
+ * @maxSize 300
6
11
  * @readonly
7
12
  */
8
13
  lineItems?: LineItem[];
9
- /** [Buyer note](https://support.wix.com/en/article/wix-stores-viewing-buyer-notes) left by the customer. */
14
+ /**
15
+ * [Buyer note](https://support.wix.com/en/article/wix-stores-viewing-buyer-notes) left by the customer.
16
+ * @maxLength 1000
17
+ */
10
18
  buyerNote?: string | null;
11
19
  /** Buyer information. */
12
20
  buyerInfo?: BuyerInfo;
13
21
  /**
14
22
  * Currency used for pricing.
23
+ * @format CURRENCY
15
24
  * @readonly
16
25
  */
17
26
  currency?: string;
@@ -19,6 +28,7 @@ export interface Cart {
19
28
  * Currency code used for all the converted prices that are returned.
20
29
  * For a site that supports multiple currencies, this is the currency the buyer selected.
21
30
  * @readonly
31
+ * @format CURRENCY
22
32
  */
23
33
  conversionCurrency?: string;
24
34
  /**
@@ -45,6 +55,7 @@ export interface Cart {
45
55
  /**
46
56
  * ID of the checkout that originated from this cart.
47
57
  * @readonly
58
+ * @format GUID
48
59
  */
49
60
  checkoutId?: string | null;
50
61
  /**
@@ -68,10 +79,12 @@ export interface Cart {
68
79
  * `overrideCheckoutUrl` allows the flexibility to redirect customers to a customized checkout page.
69
80
  *
70
81
  * 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`.
82
+ * @maxLength 1000
71
83
  */
72
84
  overrideCheckoutUrl?: string | null;
73
85
  /**
74
86
  * Persistent ID that correlates between the various eCommerce elements: cart, checkout, and order.
87
+ * @format GUID
75
88
  * @readonly
76
89
  */
77
90
  purchaseFlowId?: string | null;
@@ -80,17 +93,22 @@ export interface Cart {
80
93
  /**
81
94
  * The business location ID associated with the cart.
82
95
  * Learn more about the [Locations API](https://dev.wix.com/docs/rest/business-management/locations/introduction).
83
- * @internal
96
+ * @format GUID
84
97
  */
85
98
  businessLocationId?: string | null;
86
99
  }
87
100
  export interface LineItem {
88
101
  /**
89
102
  * Line item ID.
103
+ * @format GUID
90
104
  * @readonly
91
105
  */
92
106
  _id?: string | null;
93
- /** Item quantity. */
107
+ /**
108
+ * Item quantity.
109
+ * @min 1
110
+ * @max 100000
111
+ */
94
112
  quantity?: number;
95
113
  /** 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. */
96
114
  catalogReference?: CatalogReference;
@@ -171,6 +189,8 @@ export interface LineItem {
171
189
  * + For example, for Wix Bookings, `catalogReference.catalogItemId` is the booking ID. Therefore this value is set to the service ID.
172
190
  * + in most cases, this field is the same as `catalogReference.catalogItemId`.
173
191
  * + Used in membership validation.
192
+ * @minLength 1
193
+ * @maxLength 36
174
194
  * @readonly
175
195
  */
176
196
  rootCatalogItemId?: string | null;
@@ -187,13 +207,14 @@ export interface LineItem {
187
207
  /** Selected membership to be used as payment for this item. Must be used with `lineItem.paymentOption` set to `MEMBERSHIP` or `MEMBERSHIP_OFFLINE`. This field can be empty when `lineItem.paymentOption` is set to `MEMBERSHIP_OFFLINE`. */
188
208
  selectedMembership?: SelectedMembership;
189
209
  /**
190
- * The Item's Delivery Profile Id
191
- * @internal
210
+ * Delivery profile ID.
211
+ * @format GUID
192
212
  * @readonly
193
213
  */
194
214
  deliveryProfileId?: string | null;
195
215
  /**
196
216
  * Tax group ID for this line item.
217
+ * @format GUID
197
218
  * @readonly
198
219
  */
199
220
  taxGroupId?: string | null;
@@ -204,6 +225,8 @@ export interface LineItem {
204
225
  customLineItem?: boolean;
205
226
  /**
206
227
  * Item payment policy that requires customer consent to complete purchase. The payment policy will be displayed on the checkout page.
228
+ * @minLength 1
229
+ * @maxLength 2500
207
230
  * @readonly
208
231
  */
209
232
  consentRequiredPaymentPolicy?: string | null;
@@ -234,7 +257,7 @@ export interface LineItem {
234
257
  */
235
258
  savePaymentMethod?: boolean;
236
259
  /**
237
- * Address to be used for tax calculation.
260
+ * Address to use for tax calculation purposes.
238
261
  * @internal
239
262
  */
240
263
  taxableAddress?: TaxableAddress;
@@ -249,11 +272,13 @@ export interface LineItem {
249
272
  * Policies to be displayed to the customer on the checkout page.
250
273
  * @internal
251
274
  * @readonly
275
+ * @maxSize 5
252
276
  */
253
277
  policies?: Policy[];
254
278
  /**
255
279
  * ID of the app managing the inventory.
256
280
  * @internal
281
+ * @format GUID
257
282
  */
258
283
  inventoryAppId?: string | null;
259
284
  /**
@@ -267,7 +292,11 @@ export interface LineItem {
267
292
  }
268
293
  /** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */
269
294
  export interface CatalogReference {
270
- /** ID of the item within the catalog it belongs to. */
295
+ /**
296
+ * ID of the item within the catalog it belongs to.
297
+ * @minLength 1
298
+ * @maxLength 36
299
+ */
271
300
  catalogItemId?: string;
272
301
  /**
273
302
  * ID of the app providing the catalog.
@@ -278,6 +307,7 @@ export interface CatalogReference {
278
307
  * + Wix Stores: `"215238eb-22a5-4c36-9e7b-e7c08025e04e"`
279
308
  * + Wix Bookings: `"13d21c63-b5ec-5912-8397-c3a5ddb27a97"`
280
309
  * + Wix Restaurants: `"9a5d83fd-8570-482e-81ab-cfa88942ee60"`
310
+ * @minLength 1
281
311
  */
282
312
  appId?: string;
283
313
  /**
@@ -290,17 +320,29 @@ export interface CatalogReference {
290
320
  options?: Record<string, any> | null;
291
321
  }
292
322
  export interface ProductName {
293
- /** **Required** - Original product name (in site's default language). */
323
+ /**
324
+ * **Required** - Original product name (in site's default language).
325
+ * @minLength 1
326
+ * @maxLength 200
327
+ */
294
328
  original?: string;
295
- /** Description product name translated into buyer's language. Defaults to `original` when not defined. */
329
+ /**
330
+ * Description product name translated into buyer's language. Defaults to `original` when not defined.
331
+ * @minLength 1
332
+ * @maxLength 400
333
+ */
296
334
  translated?: string | null;
297
335
  }
298
336
  export interface MultiCurrencyPrice {
299
- /** Amount. */
337
+ /**
338
+ * Amount.
339
+ * @decimalValue options { gte:0, lte:1000000000000000 }
340
+ */
300
341
  amount?: string;
301
342
  /**
302
343
  * Converted amount.
303
344
  * @readonly
345
+ * @decimalValue options { gte:0, lte:1000000000000000 }
304
346
  */
305
347
  convertedAmount?: string;
306
348
  /**
@@ -333,21 +375,39 @@ export interface DescriptionLineValueOneOf {
333
375
  export interface DescriptionLineDescriptionLineValueOneOf {
334
376
  }
335
377
  export interface DescriptionLineName {
336
- /** Description line name in site's default language. */
378
+ /**
379
+ * Description line name in site's default language.
380
+ * @maxLength 100
381
+ */
337
382
  original?: string;
338
- /** Description line name translated into buyer's language. Defaults to `original` when not defined. */
383
+ /**
384
+ * Description line name translated into buyer's language. Defaults to `original` when not defined.
385
+ * @maxLength 200
386
+ */
339
387
  translated?: string | null;
340
388
  }
341
389
  export interface PlainTextValue {
342
- /** Description line plain text value in site's default language. */
390
+ /**
391
+ * Description line plain text value in site's default language.
392
+ * @maxLength 600
393
+ */
343
394
  original?: string;
344
- /** Description line plain text value translated into buyer's language. Defaults to `original` when not defined. */
395
+ /**
396
+ * Description line plain text value translated into buyer's language. Defaults to `original` when not defined.
397
+ * @maxLength 600
398
+ */
345
399
  translated?: string | null;
346
400
  }
347
401
  export interface Color {
348
- /** Description line color name in site's default language. */
402
+ /**
403
+ * Description line color name in site's default language.
404
+ * @maxLength 500
405
+ */
349
406
  original?: string;
350
- /** Description line color name translated into buyer's language. Defaults to `original` when not defined. */
407
+ /**
408
+ * Description line color name translated into buyer's language. Defaults to `original` when not defined.
409
+ * @maxLength 500
410
+ */
351
411
  translated?: string | null;
352
412
  /**
353
413
  * HEX or RGB color code for display.
@@ -397,7 +457,10 @@ export declare enum ItemAvailabilityStatus {
397
457
  export interface PhysicalProperties {
398
458
  /** Line item weight. Measurement unit matches the weight unit specified in `weightUnit` in the request. */
399
459
  weight?: number | null;
400
- /** Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku). */
460
+ /**
461
+ * Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku).
462
+ * @maxLength 40
463
+ */
401
464
  sku?: string | null;
402
465
  /** Whether this line item is shippable. */
403
466
  shippable?: boolean;
@@ -450,11 +513,16 @@ export interface SubscriptionSettings {
450
513
  *
451
514
  * Default: `1`.
452
515
  * If SubscriptionFrequency is Day the minimum interval is 7
516
+ * @min 1
517
+ * @max 50
453
518
  */
454
519
  interval?: number | null;
455
520
  /** Whether subscription is renewed automatically at the end of each period. */
456
521
  autoRenewal?: boolean;
457
- /** Number of billing cycles before subscription ends. Ignored if `autoRenewal` is `true`. */
522
+ /**
523
+ * Number of billing cycles before subscription ends. Ignored if `autoRenewal` is `true`.
524
+ * @min 1
525
+ */
458
526
  billingCycles?: number | null;
459
527
  /**
460
528
  * Whether to allow the customer to cancel the subscription..
@@ -484,29 +552,53 @@ export declare enum SubscriptionFrequency {
484
552
  export interface FreeTrialPeriod {
485
553
  /** Frequency of priod. Values: DAY, WEEK, MONTH, YEAR */
486
554
  frequency?: SubscriptionFrequency;
487
- /** interval of period */
555
+ /**
556
+ * interval of period
557
+ * @min 1
558
+ * @max 50
559
+ */
488
560
  interval?: number;
489
561
  }
490
562
  export interface Title {
491
- /** 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). */
563
+ /**
564
+ * 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).
565
+ * @minLength 1
566
+ * @maxLength 150
567
+ */
492
568
  original?: string;
493
569
  /**
494
570
  * Subscription option name translated into the buyer's language.
495
571
  *
496
572
  * Default: Same as `original`.
573
+ * @minLength 1
574
+ * @maxLength 150
497
575
  */
498
576
  translated?: string | null;
499
577
  }
500
578
  export interface Description {
501
- /** Subscription option description. */
579
+ /**
580
+ * Subscription option description.
581
+ * @maxLength 500
582
+ */
502
583
  original?: string;
503
- /** Translated subscription option description. */
584
+ /**
585
+ * Translated subscription option description.
586
+ * @maxLength 500
587
+ */
504
588
  translated?: string | null;
505
589
  }
506
590
  export interface SecuredMedia {
507
- /** Media ID in Wix Media Manager. */
591
+ /**
592
+ * Media ID in Wix Media Manager.
593
+ * @minLength 1
594
+ * @maxLength 100
595
+ */
508
596
  _id?: string;
509
- /** Original filename. */
597
+ /**
598
+ * Original filename.
599
+ * @minLength 1
600
+ * @maxLength 1000
601
+ */
510
602
  fileName?: string;
511
603
  /** File type. */
512
604
  fileType?: FileType;
@@ -535,33 +627,59 @@ export declare enum PaymentOptionType {
535
627
  export interface ServiceProperties {
536
628
  /** The date and time for which the service is supposed to be provided. For example, the time of the class. */
537
629
  scheduledDate?: Date | null;
538
- /** The number of people participating in this service. For example, the number of people attending the class or the number of people per hotel room. */
630
+ /**
631
+ * The number of people participating in this service. For example, the number of people attending the class or the number of people per hotel room.
632
+ * @min 1
633
+ * @max 10000
634
+ */
539
635
  numberOfParticipants?: number | null;
540
636
  }
541
637
  export interface PriceDescription {
542
638
  /**
543
639
  * **Required** - Original price description (in site's default language).
544
640
  *
641
+ * @minLength 1
642
+ * @maxLength 100
545
643
  */
546
644
  original?: string;
547
- /** Product name translated into buyer's language. Defaults to `original` when not defined. */
645
+ /**
646
+ * Product name translated into buyer's language. Defaults to `original` when not defined.
647
+ * @minLength 1
648
+ * @maxLength 100
649
+ */
548
650
  translated?: string | null;
549
651
  }
550
652
  /** Selected Membership */
551
653
  export interface SelectedMembership {
552
- /** Membership ID. */
654
+ /**
655
+ * Membership ID.
656
+ * @minLength 1
657
+ * @maxLength 100
658
+ */
553
659
  _id?: string;
554
- /** ID of the app providing this payment option. */
660
+ /**
661
+ * ID of the app providing this payment option.
662
+ * @format GUID
663
+ */
555
664
  appId?: string;
556
665
  }
557
666
  export interface CatalogOverrideFields {
558
667
  /** Item name. */
559
668
  productName?: ProductName;
560
- /** Item price **after** discounts. */
669
+ /**
670
+ * Item price **after** discounts.
671
+ * @decimalValue options { gte:0, lte:999999999, maxScale:3 }
672
+ */
561
673
  price?: string | null;
562
- /** Item price **before** discounts. */
674
+ /**
675
+ * Item price **before** discounts.
676
+ * @decimalValue options { gte:0, lte:999999999, maxScale:3 }
677
+ */
563
678
  fullPrice?: string | null;
564
- /** Item description lines. Used when displaying the line item to customers. */
679
+ /**
680
+ * Item description lines. Used when displaying the line item to customers.
681
+ * @maxSize 20
682
+ */
565
683
  descriptionLines?: DescriptionLine[];
566
684
  /** Physical properties of the item. */
567
685
  physicalProperties?: PhysicalProperties;
@@ -569,7 +687,11 @@ export interface CatalogOverrideFields {
569
687
  image?: string;
570
688
  /** Payment method selected for the item. */
571
689
  paymentOption?: PaymentOption;
572
- /** Only eligible for catalog items with `lineItem.paymentOption.value` type of `DEPOSIT_ONLINE`. */
690
+ /**
691
+ * Only eligible for catalog items with `lineItem.paymentOption.value` type of `DEPOSIT_ONLINE`.
692
+ * @format DECIMAL_VALUE
693
+ * @decimalValue options { gt:0, lte:999999999, maxScale:3 }
694
+ */
573
695
  depositAmount?: string | null;
574
696
  /**
575
697
  * Whether to save the payment method on the order.
@@ -580,11 +702,9 @@ export interface CatalogOverrideFields {
580
702
  }
581
703
  export interface PaymentOption {
582
704
  /**
583
- * + `FULL_PAYMENT_ONLINE`: The entire payment for this item happens as part of the checkout.
584
- * + `FULL_PAYMENT_OFFLINE`: The entire payment for this item happens after the checkout. For example, when using cash, check, or other offline payment methods.
585
- * + `MEMBERSHIP`: Payment for this item is done by charging a membership. When selected, `price` is `0`.
586
- * + `DEPOSIT_ONLINE`: Partial payment to be paid upfront during the checkout. Initial amount to be paid for each line item is specified in `depositAmount`.
587
- * + `MEMBERSHIP_OFFLINE`: 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`.
705
+ * Type of selected payment option for current item.
706
+ *
707
+ * Default: `FULL_PAYMENT_ONLINE`
588
708
  */
589
709
  value?: PaymentOptionType;
590
710
  }
@@ -615,47 +735,67 @@ export interface ExtendedFields {
615
735
  namespaces?: Record<string, Record<string, any>>;
616
736
  }
617
737
  export interface Policy {
618
- /** Policy title - should be translated */
738
+ /**
739
+ * Policy title - should be translated
740
+ * @minLength 1
741
+ * @maxLength 29
742
+ */
619
743
  title?: string | null;
620
- /** Policy content - should be translated */
744
+ /**
745
+ * Policy content - should be translated
746
+ * @minLength 1
747
+ * @maxLength 3000
748
+ */
621
749
  content?: string;
622
750
  }
623
751
  /** Buyer Info */
624
752
  export interface BuyerInfo extends BuyerInfoIdOneOf {
625
753
  /**
626
754
  * Visitor ID - if the buyer is **not** a site member.
755
+ * @format GUID
627
756
  * @readonly
628
757
  */
629
758
  visitorId?: string;
630
759
  /**
631
760
  * Member ID - if the buyer is a site member.
761
+ * @format GUID
632
762
  * @readonly
633
763
  */
634
764
  memberId?: string;
635
765
  /**
636
766
  * User ID - if the cart owner is a Wix user.
767
+ * @format GUID
637
768
  * @readonly
638
769
  */
639
770
  userId?: string;
640
- /** Contact ID. For more information, see the Contacts API. */
771
+ /**
772
+ * Contact ID. For more information, see the Contacts API.
773
+ * @format GUID
774
+ */
641
775
  contactId?: string | null;
642
- /** Buyer email address. */
776
+ /**
777
+ * Buyer email address.
778
+ * @format EMAIL
779
+ */
643
780
  email?: string | null;
644
781
  }
645
782
  /** @oneof */
646
783
  export interface BuyerInfoIdOneOf {
647
784
  /**
648
785
  * Visitor ID - if the buyer is **not** a site member.
786
+ * @format GUID
649
787
  * @readonly
650
788
  */
651
789
  visitorId?: string;
652
790
  /**
653
791
  * Member ID - if the buyer is a site member.
792
+ * @format GUID
654
793
  * @readonly
655
794
  */
656
795
  memberId?: string;
657
796
  /**
658
797
  * User ID - if the cart owner is a Wix user.
798
+ * @format GUID
659
799
  * @readonly
660
800
  */
661
801
  userId?: string;
@@ -712,7 +852,10 @@ export interface MerchantDiscount {
712
852
  amount?: MultiCurrencyPrice;
713
853
  }
714
854
  export interface DiscountRule {
715
- /** Discount rule ID */
855
+ /**
856
+ * Discount rule ID
857
+ * @format GUID
858
+ */
716
859
  _id?: string;
717
860
  /** Discount rule name */
718
861
  name?: DiscountRuleName;
@@ -720,9 +863,17 @@ export interface DiscountRule {
720
863
  amount?: MultiCurrencyPrice;
721
864
  }
722
865
  export interface DiscountRuleName {
723
- /** Original discount rule name (in site's default language). */
866
+ /**
867
+ * Original discount rule name (in site's default language).
868
+ * @minLength 1
869
+ * @maxLength 256
870
+ */
724
871
  original?: string;
725
- /** Discount rule name translated into buyer's language. Defaults to `original` when not defined. */
872
+ /**
873
+ * Discount rule name translated into buyer's language. Defaults to `original` when not defined.
874
+ * @minLength 1
875
+ * @maxLength 500
876
+ */
726
877
  translated?: string | null;
727
878
  }
728
879
  export declare enum DiscountType {
@@ -742,19 +893,37 @@ export interface AddressWithContact {
742
893
  }
743
894
  /** Physical address */
744
895
  export interface Address {
745
- /** Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format. */
896
+ /**
897
+ * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format.
898
+ * @format COUNTRY
899
+ */
746
900
  country?: string | null;
747
- /** Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format. */
901
+ /**
902
+ * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format.
903
+ * @maxLength 50
904
+ */
748
905
  subdivision?: string | null;
749
- /** City name. */
906
+ /**
907
+ * City name.
908
+ * @maxLength 50
909
+ */
750
910
  city?: string | null;
751
- /** Postal or zip code. */
911
+ /**
912
+ * Postal or zip code.
913
+ * @maxLength 50
914
+ */
752
915
  postalCode?: string | null;
753
916
  /** Street address. */
754
917
  streetAddress?: StreetAddress;
755
- /** Main address line (usually street name and number). */
918
+ /**
919
+ * Main address line (usually street name and number).
920
+ * @maxLength 150
921
+ */
756
922
  addressLine1?: string | null;
757
- /** Free text providing more detailed address info. Usually contains apt, suite, floor. */
923
+ /**
924
+ * Free text providing more detailed address info. Usually contains apt, suite, floor.
925
+ * @maxLength 100
926
+ */
758
927
  addressLine2?: string | null;
759
928
  /**
760
929
  * Country's full name.
@@ -781,13 +950,25 @@ export interface AddressLocation {
781
950
  }
782
951
  /** Full contact details for an address */
783
952
  export interface FullAddressContactDetails {
784
- /** First name. */
953
+ /**
954
+ * First name.
955
+ * @maxLength 100
956
+ */
785
957
  firstName?: string | null;
786
- /** Last name. */
958
+ /**
959
+ * Last name.
960
+ * @maxLength 100
961
+ */
787
962
  lastName?: string | null;
788
- /** Phone number. */
963
+ /**
964
+ * Phone number.
965
+ * @format PHONE
966
+ */
789
967
  phone?: string | null;
790
- /** Company name. */
968
+ /**
969
+ * Company name.
970
+ * @maxLength 1000
971
+ */
791
972
  company?: string | null;
792
973
  /** Tax information (for Brazil only). If ID is provided, `vatId.type` must also be set, `UNSPECIFIED` is not allowed. */
793
974
  vatId?: VatId;
@@ -813,9 +994,16 @@ export declare enum VatType {
813
994
  CNPJ = "CNPJ"
814
995
  }
815
996
  export interface SelectedShippingOption {
816
- /** Carrier ID. */
997
+ /**
998
+ * Carrier ID.
999
+ * @format GUID
1000
+ */
817
1001
  carrierId?: string | null;
818
- /** Selected shipping option code. For example, "usps_std_overnight". */
1002
+ /**
1003
+ * Selected shipping option code. For example, "usps_std_overnight".
1004
+ * @minLength 1
1005
+ * @maxLength 100
1006
+ */
819
1007
  code?: string;
820
1008
  }
821
1009
  export interface GetCurrentCartRequest {
@@ -829,22 +1017,36 @@ export interface UpdateCartRequest {
829
1017
  cartInfo?: Cart;
830
1018
  /** The code of an existing coupon to apply to the cart. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */
831
1019
  couponCode?: string | null;
832
- /** Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will be applied to the whole cart. */
1020
+ /**
1021
+ * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will be applied to the whole cart.
1022
+ * @maxSize 100
1023
+ */
833
1024
  merchantDiscounts?: MerchantDiscountInput[];
834
- /** Catalog line items. */
1025
+ /**
1026
+ * Catalog line items.
1027
+ * @maxSize 300
1028
+ */
835
1029
  lineItems?: LineItem[];
836
1030
  /**
837
1031
  * Custom line items. Custom line items don't trigger the Catalog service plugin.
838
1032
  *
839
1033
  * To access and manage custom line items, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
840
1034
  * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
1035
+ * @maxSize 300
841
1036
  */
842
1037
  customLineItems?: CustomLineItem[];
843
1038
  }
844
1039
  export interface MerchantDiscountInput {
845
- /** Discount amount. */
1040
+ /**
1041
+ * Discount amount.
1042
+ * @decimalValue options { gte:0 }
1043
+ */
846
1044
  amount?: string;
847
- /** IDs of the line items the discount applies to. */
1045
+ /**
1046
+ * IDs of the line items the discount applies to.
1047
+ * @format GUID
1048
+ * @maxSize 300
1049
+ */
848
1050
  lineItemIds?: string[];
849
1051
  }
850
1052
  export interface CustomLineItem {
@@ -853,17 +1055,24 @@ export interface CustomLineItem {
853
1055
  *
854
1056
  * Min: `1`
855
1057
  * Max: `100000`
1058
+ * @min 1
1059
+ * @max 100000
856
1060
  */
857
1061
  quantity?: number;
858
1062
  /**
859
1063
  * Custom line item price.
860
1064
  *
861
1065
  * Must be a number or a decimal without symbols.
1066
+ * @format DECIMAL_VALUE
1067
+ * @decimalValue options { gte:0, lte:1000000000000000 }
862
1068
  */
863
1069
  price?: string;
864
1070
  /** Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67". */
865
1071
  priceDescription?: PriceDescription;
866
- /** Custom line item description lines. Used for displaying the cart, checkout and order. */
1072
+ /**
1073
+ * Custom line item description lines. Used for displaying the cart, checkout and order.
1074
+ * @maxSize 10
1075
+ */
867
1076
  descriptionLines?: DescriptionLine[];
868
1077
  /**
869
1078
  * Custom line item media. Supported formats:
@@ -875,9 +1084,13 @@ export interface CustomLineItem {
875
1084
  * Custom line item ID. If passed, `id` must be unique.
876
1085
  *
877
1086
  * Default: auto-generated ID
1087
+ * @format GUID
878
1088
  */
879
1089
  _id?: string | null;
880
- /** Tax group ID for this custom line item. */
1090
+ /**
1091
+ * Tax group ID for this custom line item.
1092
+ * @format GUID
1093
+ */
881
1094
  taxGroupId?: string | null;
882
1095
  /** Name of the item or product. */
883
1096
  productName?: ProductName;
@@ -885,11 +1098,15 @@ export interface CustomLineItem {
885
1098
  url?: string;
886
1099
  /** Item type. Either a preset type or custom. */
887
1100
  itemType?: ItemType;
888
- /** Item price **before** catalog-defined discount. Defaults to `price` when not provided. */
1101
+ /**
1102
+ * Item price **before** catalog-defined discount. Defaults to `price` when not provided.
1103
+ * @format DECIMAL_VALUE
1104
+ */
889
1105
  fullPrice?: string | null;
890
1106
  /**
891
1107
  * Item quantity available for purchase. Only return this if inventory is managed.
892
1108
  * Not returning this field means that the buyer can "infinitely" tick up the number of items in the cart.
1109
+ * @max 100000
893
1110
  */
894
1111
  quantityAvailable?: number | null;
895
1112
  /** Physical properties of the item. */
@@ -914,6 +1131,8 @@ export interface CustomLineItem {
914
1131
  * + For example, for Wix Bookings, `catalogReference.catalogItemId` is the booking ID. Therefore this value is set to the service ID.
915
1132
  * + In most cases, this field is the same as `catalogReference.catalogItemId`.
916
1133
  * + Used in membership validation.
1134
+ * @minLength 1
1135
+ * @maxLength 36
917
1136
  */
918
1137
  rootCatalogItemId?: string | null;
919
1138
  /**
@@ -921,8 +1140,14 @@ export interface CustomLineItem {
921
1140
  *
922
1141
  * Eligible for catalog items with type `DEPOSIT_ONLINE`.
923
1142
  * When omitted, the item's price will not be split and is expected to be paid in a single installment.
1143
+ * @format DECIMAL_VALUE
924
1144
  */
925
1145
  depositAmount?: string | null;
1146
+ /**
1147
+ * Delivery profile ID.
1148
+ * @format GUID
1149
+ */
1150
+ deliveryProfileId?: string | null;
926
1151
  /** 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. */
927
1152
  catalogReference?: CatalogReference;
928
1153
  /**
@@ -941,6 +1166,8 @@ export interface CustomLineItem {
941
1166
  fixedQuantity?: boolean;
942
1167
  /**
943
1168
  * Item payment policy that requires customer consent to complete purchase. The payment policy will be displayed on the checkout page.
1169
+ * @minLength 1
1170
+ * @maxLength 1000
944
1171
  * @readonly
945
1172
  */
946
1173
  consentRequiredPaymentPolicy?: string | null;
@@ -954,11 +1181,13 @@ export interface CustomLineItem {
954
1181
  /**
955
1182
  * Policies to be displayed to the customer on the checkout page.
956
1183
  * @internal
1184
+ * @maxSize 5
957
1185
  */
958
1186
  policies?: Policy[];
959
1187
  /**
960
1188
  * ID of the app managing the inventory.
961
1189
  * @internal
1190
+ * @format GUID
962
1191
  */
963
1192
  inventoryAppId?: string | null;
964
1193
  /**
@@ -968,26 +1197,35 @@ export interface CustomLineItem {
968
1197
  * @internal
969
1198
  */
970
1199
  membersOnly?: boolean;
1200
+ /**
1201
+ * Address to use for tax calculation purposes.
1202
+ * @internal
1203
+ */
1204
+ taxableAddress?: TaxableAddress;
971
1205
  }
972
1206
  export interface UpdateCartResponse {
973
1207
  /** Updated Cart. */
974
1208
  cart?: Cart;
975
1209
  }
976
1210
  export interface AddToCurrentCartRequest {
977
- /** Catalog line items. */
1211
+ /**
1212
+ * Catalog line items.
1213
+ * @maxSize 100
1214
+ */
978
1215
  lineItems?: LineItem[];
979
1216
  /**
980
1217
  * Custom line items. Custom line items don't trigger the Catalog service plugin.
981
1218
  *
982
1219
  * To access and manage custom line items, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
983
1220
  * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
1221
+ * @maxSize 100
984
1222
  */
985
1223
  customLineItems?: CustomLineItem[];
986
1224
  /**
987
1225
  * Business location ID.
988
1226
  * To update a cart's business location ID, use the UpdateCart method.
989
1227
  * Learn more about the [Locations API](https://dev.wix.com/docs/rest/business-management/locations/introduction).
990
- * @internal
1228
+ * @format GUID
991
1229
  */
992
1230
  businessLocationId?: string | null;
993
1231
  }
@@ -996,13 +1234,17 @@ export interface AddToCartResponse {
996
1234
  cart?: Cart;
997
1235
  }
998
1236
  export interface AddToCurrentCartAndEstimateTotalsRequest {
999
- /** Catalog line items. */
1237
+ /**
1238
+ * Catalog line items.
1239
+ * @maxSize 100
1240
+ */
1000
1241
  lineItems?: LineItem[];
1001
1242
  /**
1002
1243
  * Custom line items. Custom line items don't trigger the Catalog service plugin.
1003
1244
  *
1004
1245
  * To access and manage custom line items, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
1005
1246
  * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
1247
+ * @maxSize 100
1006
1248
  */
1007
1249
  customLineItems?: CustomLineItem[];
1008
1250
  /** Selected shipping option. */
@@ -1027,15 +1269,31 @@ export interface AddToCurrentCartAndEstimateTotalsRequest {
1027
1269
  calculateShipping?: boolean | null;
1028
1270
  }
1029
1271
  export interface SelectedMemberships {
1030
- /** Selected memberships. */
1272
+ /**
1273
+ * Selected memberships.
1274
+ * @maxSize 300
1275
+ */
1031
1276
  memberships?: HostSelectedMembership[];
1032
1277
  }
1033
1278
  export interface HostSelectedMembership {
1034
- /** Membership ID. */
1279
+ /**
1280
+ * Membership ID.
1281
+ * @minLength 1
1282
+ * @maxLength 100
1283
+ */
1035
1284
  _id?: string;
1036
- /** ID of the app providing this payment option. */
1285
+ /**
1286
+ * ID of the app providing this payment option.
1287
+ * @format GUID
1288
+ */
1037
1289
  appId?: string;
1038
- /** IDs of the line items this membership applies to. */
1290
+ /**
1291
+ * IDs of the line items this membership applies to.
1292
+ * @minSize 1
1293
+ * @maxSize 300
1294
+ * @minLength 1
1295
+ * @maxLength 100
1296
+ */
1039
1297
  lineItemIds?: string[];
1040
1298
  }
1041
1299
  export interface EstimateTotalsResponse {
@@ -1057,7 +1315,10 @@ export interface EstimateTotalsResponse {
1057
1315
  calculationErrors?: CalculationErrors;
1058
1316
  /** Weight measurement unit - defaults to site's weight unit. */
1059
1317
  weightUnit?: WeightUnit;
1060
- /** Currency used for pricing in this store. */
1318
+ /**
1319
+ * Currency used for pricing in this store.
1320
+ * @format CURRENCY
1321
+ */
1061
1322
  currency?: string;
1062
1323
  /**
1063
1324
  * Minimal amount to pay in order to place the order.
@@ -1071,7 +1332,10 @@ export interface EstimateTotalsResponse {
1071
1332
  payLater?: PriceSummary;
1072
1333
  /** Information about valid and invalid memberships, and which ones are selected for usage. */
1073
1334
  membershipOptions?: MembershipOptions;
1074
- /** Additional fees */
1335
+ /**
1336
+ * Additional fees
1337
+ * @maxSize 100
1338
+ */
1075
1339
  additionalFees?: AdditionalFee[];
1076
1340
  /**
1077
1341
  * List of validation violations raised by the [Validations Custom Extension SPI](https://www.wix.com/velo/reference/spis/wix-ecom/ecom-validations/introduction).
@@ -1118,7 +1382,10 @@ export interface LineItemPricesData {
1118
1382
  export interface ItemTaxFullDetails {
1119
1383
  /** Amount for which tax is calculated. */
1120
1384
  taxableAmount?: MultiCurrencyPrice;
1121
- /** Tax rate %, as a decimal point between 0 and 1. */
1385
+ /**
1386
+ * Tax rate %, as a decimal point between 0 and 1.
1387
+ * @decimalValue options { gte:0, lte:1, maxScale:6 }
1388
+ */
1122
1389
  taxRate?: string;
1123
1390
  /** Calculated tax, based on `taxable_amount` and `tax_rate`. */
1124
1391
  totalTax?: MultiCurrencyPrice;
@@ -1130,9 +1397,15 @@ export interface ItemTaxFullDetails {
1130
1397
  rateBreakdown?: TaxRateBreakdown[];
1131
1398
  }
1132
1399
  export interface TaxRateBreakdown {
1133
- /** Name of tax against which the calculation was performed. */
1400
+ /**
1401
+ * Name of tax against which the calculation was performed.
1402
+ * @maxLength 100
1403
+ */
1134
1404
  name?: string;
1135
- /** Rate at which this tax detail was calculated. */
1405
+ /**
1406
+ * Rate at which this tax detail was calculated.
1407
+ * @decimalValue options { gte:0, lte:1, maxScale:6 }
1408
+ */
1136
1409
  rate?: string;
1137
1410
  /** Amount of tax for this tax detail. */
1138
1411
  tax?: MultiCurrencyPrice;
@@ -1142,21 +1415,31 @@ export interface TaxRateBreakdown {
1142
1415
  * It holds the tax amount and the tax rate for each tax authority that apply on the line item.
1143
1416
  */
1144
1417
  export interface TaxBreakdown {
1145
- /** The name of the jurisdiction to which this tax detail applies. For example, "New York" or "Quebec". */
1418
+ /**
1419
+ * The name of the jurisdiction to which this tax detail applies. For example, "New York" or "Quebec".
1420
+ * @maxLength 200
1421
+ */
1146
1422
  jurisdiction?: string | null;
1147
1423
  /** The amount of this line item price that was considered nontaxable. (Decimal value) */
1148
1424
  nonTaxableAmount?: MultiCurrencyPrice;
1149
- /** The rate at which this tax detail was calculated, e.g 0.1000 signifies 10% tax and 2.0000 signifies 200% tax. (Decimal value) */
1425
+ /**
1426
+ * The rate at which this tax detail was calculated, e.g 0.1000 signifies 10% tax and 2.0000 signifies 200% tax. (Decimal value)
1427
+ * @decimalValue options { gte:0, maxScale:6 }
1428
+ */
1150
1429
  rate?: string | null;
1151
1430
  /** The amount of tax estimated for this line item. (Decimal value) */
1152
1431
  taxAmount?: MultiCurrencyPrice;
1153
1432
  /** The taxable amount of this line item. */
1154
1433
  taxableAmount?: MultiCurrencyPrice;
1155
- /** The type of tax that was calculated. Depends on the jurisdiction's tax laws. For example, "Sales Tax", "Income Tax", "Value Added Tax", etc. */
1434
+ /**
1435
+ * The type of tax that was calculated. Depends on the jurisdiction's tax laws. For example, "Sales Tax", "Income Tax", "Value Added Tax", etc.
1436
+ * @maxLength 200
1437
+ */
1156
1438
  taxType?: string | null;
1157
1439
  /**
1158
1440
  * The name of the tax against which this tax amount was calculated. For example, "NY State Sales Tax", "Quebec GST", etc.
1159
1441
  * This name should be explicit enough to allow the merchant to understand what tax was calculated.
1442
+ * @maxLength 200
1160
1443
  */
1161
1444
  taxName?: string | null;
1162
1445
  /** The type of the jurisdiction in which this tax detail applies. */
@@ -1195,11 +1478,16 @@ export interface GiftCard {
1195
1478
  obfuscatedCode?: string;
1196
1479
  /** Gift card value. */
1197
1480
  amount?: MultiCurrencyPrice;
1198
- /** App ID of the gift card provider. */
1481
+ /**
1482
+ * App ID of the gift card provider.
1483
+ * @format GUID
1484
+ */
1199
1485
  appId?: string;
1200
1486
  /**
1201
1487
  * External ID in the gift card provider's system.
1202
1488
  * Used for integration and tracking across different platforms.
1489
+ * @minLength 1
1490
+ * @maxLength 50
1203
1491
  */
1204
1492
  externalId?: string | null;
1205
1493
  }
@@ -1286,15 +1574,27 @@ export interface ApplicationError {
1286
1574
  * Tax breakdown is the tax amount split to the tax authorities that applied on the line item.
1287
1575
  */
1288
1576
  export interface AggregatedTaxBreakdown {
1289
- /** The name of the tax against which this tax amount was calculated. */
1577
+ /**
1578
+ * The name of the tax against which this tax amount was calculated.
1579
+ * @maxLength 200
1580
+ */
1290
1581
  taxName?: string;
1291
- /** The type of tax that was calculated. Depends on the company's nexus settings as well as the jurisdiction's tax laws. */
1582
+ /**
1583
+ * The type of tax that was calculated. Depends on the company's nexus settings as well as the jurisdiction's tax laws.
1584
+ * @maxLength 200
1585
+ */
1292
1586
  taxType?: string;
1293
- /** The name of the jurisdiction in which this tax detail applies. */
1587
+ /**
1588
+ * The name of the jurisdiction in which this tax detail applies.
1589
+ * @maxLength 200
1590
+ */
1294
1591
  jurisdiction?: string;
1295
1592
  /** The type of the jurisdiction in which this tax detail applies (e.g. Country,State,County,City,Special). */
1296
1593
  jurisdictionTypeEnum?: JurisdictionType;
1297
- /** The rate at which this tax detail was calculated, e.g 0.1000 signifies 10% tax and 2.000 signifies 200% tax. (Decimal value) */
1594
+ /**
1595
+ * The rate at which this tax detail was calculated, e.g 0.1000 signifies 10% tax and 2.000 signifies 200% tax. (Decimal value)
1596
+ * @decimalValue options { gte:0, maxScale:6 }
1597
+ */
1298
1598
  rate?: string;
1299
1599
  /** The sum of all the tax from line items that calculated by the tax identifiers. */
1300
1600
  aggregatedTaxAmount?: MultiCurrencyPrice;
@@ -1310,18 +1610,26 @@ export interface ShippingInformation {
1310
1610
  export interface ShippingRegion {
1311
1611
  /**
1312
1612
  * Shipping region ID.
1613
+ * @format GUID
1313
1614
  * @readonly
1314
1615
  */
1315
1616
  _id?: string;
1316
- /** Shipping region name. */
1617
+ /**
1618
+ * Shipping region name.
1619
+ * @maxLength 100
1620
+ */
1317
1621
  name?: string;
1318
1622
  }
1319
1623
  export interface SelectedCarrierServiceOption {
1320
- /** Unique identifier of selected option. For example, "usps_std_overnight". */
1624
+ /**
1625
+ * Unique identifier of selected option. For example, "usps_std_overnight".
1626
+ * @maxLength 100
1627
+ */
1321
1628
  code?: string;
1322
1629
  /**
1323
1630
  * Title of the option, such as USPS Standard Overnight Delivery (in the requested locale).
1324
1631
  * For example, "Standard" or "First-Class Package International".
1632
+ * @maxLength 250
1325
1633
  * @readonly
1326
1634
  */
1327
1635
  title?: string;
@@ -1342,17 +1650,29 @@ export interface SelectedCarrierServiceOption {
1342
1650
  requestedShippingOption?: boolean;
1343
1651
  /** Other charges */
1344
1652
  otherCharges?: SelectedCarrierServiceOptionOtherCharge[];
1345
- /** This carrier's unique ID */
1653
+ /**
1654
+ * This carrier's unique ID
1655
+ * @format GUID
1656
+ */
1346
1657
  carrierId?: string | null;
1347
- /** Delivery solution allocations to different delivery carriers and delivery regions */
1658
+ /**
1659
+ * Delivery solution allocations to different delivery carriers and delivery regions
1660
+ * @maxSize 300
1661
+ */
1348
1662
  deliveryAllocations?: DeliveryAllocation[];
1349
1663
  /** If the delivery solution is a partial and doesn't apply to all items. */
1350
1664
  partial?: boolean | null;
1351
1665
  }
1352
1666
  export interface DeliveryLogistics {
1353
- /** Expected delivery time, in free text. For example, "3-5 business days". */
1667
+ /**
1668
+ * Expected delivery time, in free text. For example, "3-5 business days".
1669
+ * @maxLength 500
1670
+ */
1354
1671
  deliveryTime?: string | null;
1355
- /** Instructions for caller, e.g for pickup: "Please deliver during opening hours, and please don't park in disabled parking spot". */
1672
+ /**
1673
+ * Instructions for caller, e.g for pickup: "Please deliver during opening hours, and please don't park in disabled parking spot".
1674
+ * @maxLength 1000
1675
+ */
1356
1676
  instructions?: string | null;
1357
1677
  /** Pickup details. */
1358
1678
  pickupDetails?: PickupDetails;
@@ -1394,7 +1714,10 @@ export interface SelectedCarrierServiceOptionPrices {
1394
1714
  export interface SelectedCarrierServiceOptionOtherCharge {
1395
1715
  /** Type of additional cost. */
1396
1716
  type?: ChargeType;
1397
- /** Details of the charge, such as 'Full Coverage Insurance of up to 80% of value of shipment'. */
1717
+ /**
1718
+ * Details of the charge, such as 'Full Coverage Insurance of up to 80% of value of shipment'.
1719
+ * @maxLength 200
1720
+ */
1398
1721
  details?: string | null;
1399
1722
  /** Price of added charge. */
1400
1723
  cost?: SelectedCarrierServiceOptionPrices;
@@ -1412,23 +1735,43 @@ export interface DeliveryAllocation {
1412
1735
  applicableLineItems?: ApplicableLineItems;
1413
1736
  }
1414
1737
  export interface Carrier {
1415
- /** The carrier app id */
1738
+ /**
1739
+ * The carrier app id
1740
+ * @format GUID
1741
+ */
1416
1742
  appId?: string | null;
1417
- /** Unique code that acts as an ID for a shipping rate. For example, `"usps_std_overnight"`. */
1743
+ /**
1744
+ * Unique code that acts as an ID for a shipping rate. For example, `"usps_std_overnight"`.
1745
+ * @maxLength 250
1746
+ */
1418
1747
  code?: string;
1419
1748
  }
1420
1749
  export interface Region {
1421
- /** The delivery region id. */
1750
+ /**
1751
+ * The delivery region id.
1752
+ * @format GUID
1753
+ */
1422
1754
  _id?: string | null;
1423
- /** The delivery region name. */
1755
+ /**
1756
+ * The delivery region name.
1757
+ * @maxLength 100
1758
+ */
1424
1759
  name?: string | null;
1425
1760
  }
1426
1761
  export interface ApplicableLineItems {
1427
- /** Line items that the delivery solution is for. */
1762
+ /**
1763
+ * Line items that the delivery solution is for.
1764
+ * @maxSize 300
1765
+ * @minLength 1
1766
+ * @maxLength 100
1767
+ */
1428
1768
  lineItemIds?: string[];
1429
1769
  }
1430
1770
  export interface CarrierServiceOption {
1431
- /** Carrier ID. */
1771
+ /**
1772
+ * Carrier ID.
1773
+ * @format GUID
1774
+ */
1432
1775
  carrierId?: string;
1433
1776
  /** Shipping options offered by this carrier for this request. */
1434
1777
  shippingOptions?: ShippingOption[];
@@ -1437,18 +1780,23 @@ export interface ShippingOption {
1437
1780
  /**
1438
1781
  * Unique code of provided shipping option like "usps_std_overnight".
1439
1782
  * For legacy calculators this would be the UUID of the option.
1783
+ * @maxLength 100
1440
1784
  */
1441
1785
  code?: string;
1442
1786
  /**
1443
1787
  * Title of the option, such as USPS Standard Overnight Delivery (in the requested locale).
1444
1788
  * For example, "Standard" or "First-Class Package International".
1789
+ * @maxLength 250
1445
1790
  */
1446
1791
  title?: string;
1447
1792
  /** Delivery logistics. */
1448
1793
  logistics?: DeliveryLogistics;
1449
1794
  /** Sipping price information. */
1450
1795
  cost?: ShippingPrice;
1451
- /** Delivery solution allocations to different delivery carriers and delivery regions */
1796
+ /**
1797
+ * Delivery solution allocations to different delivery carriers and delivery regions
1798
+ * @maxSize 300
1799
+ */
1452
1800
  deliveryAllocations?: DeliveryAllocation[];
1453
1801
  /** If the delivery solution is a partial and doesn't apply to all items. */
1454
1802
  partial?: boolean | null;
@@ -1476,6 +1824,7 @@ export interface AppliedDiscount extends AppliedDiscountDiscountSourceOneOf {
1476
1824
  discountType?: AppliedDiscountDiscountType;
1477
1825
  /**
1478
1826
  * IDs of the line items the discount applies to.
1827
+ * @format GUID
1479
1828
  * @deprecated IDs of line items the discount applies to.
1480
1829
  * @replacedBy line_items_discounts
1481
1830
  * @targetRemovalDate 2024-06-01
@@ -1485,6 +1834,8 @@ export interface AppliedDiscount extends AppliedDiscountDiscountSourceOneOf {
1485
1834
  * Number of subscription cycle this discount applies to
1486
1835
  * default None - all billing cycle
1487
1836
  * @internal
1837
+ * @min 1
1838
+ * @max 999
1488
1839
  */
1489
1840
  subscriptionCycles?: number | null;
1490
1841
  }
@@ -1516,11 +1867,18 @@ export interface V1Coupon {
1516
1867
  export interface V1MerchantDiscount {
1517
1868
  /** Discount value. */
1518
1869
  amount?: MultiCurrencyPrice;
1519
- /** Discount Percentage. Will be calculated from items price before other discounts. */
1870
+ /**
1871
+ * Discount Percentage. Will be calculated from items price before other discounts.
1872
+ * @min 1
1873
+ * @max 100
1874
+ */
1520
1875
  percentage?: number | null;
1521
1876
  }
1522
1877
  export interface V1DiscountRule {
1523
- /** Discount rule ID */
1878
+ /**
1879
+ * Discount rule ID
1880
+ * @format GUID
1881
+ */
1524
1882
  _id?: string;
1525
1883
  /** Discount rule name */
1526
1884
  name?: V1DiscountRuleName;
@@ -1528,13 +1886,24 @@ export interface V1DiscountRule {
1528
1886
  amount?: MultiCurrencyPrice;
1529
1887
  }
1530
1888
  export interface V1DiscountRuleName {
1531
- /** Original discount rule name (in site's default language). */
1889
+ /**
1890
+ * Original discount rule name (in site's default language).
1891
+ * @minLength 1
1892
+ * @maxLength 256
1893
+ */
1532
1894
  original?: string;
1533
- /** Translated discount rule name according to buyer language. Defaults to `original` when not provided. */
1895
+ /**
1896
+ * Translated discount rule name according to buyer language. Defaults to `original` when not provided.
1897
+ * @minLength 1
1898
+ * @maxLength 500
1899
+ */
1534
1900
  translated?: string | null;
1535
1901
  }
1536
1902
  export interface LineItemDiscount {
1537
- /** ID of line item the discount applies to. */
1903
+ /**
1904
+ * ID of line item the discount applies to.
1905
+ * @format GUID
1906
+ */
1538
1907
  _id?: string;
1539
1908
  /** Discount value. */
1540
1909
  totalDiscountAmount?: MultiCurrencyPrice;
@@ -1664,21 +2033,43 @@ export interface CarrierError {
1664
2033
  error?: Details;
1665
2034
  }
1666
2035
  export interface MembershipOptions {
1667
- /** List of payment options that can be used. */
2036
+ /**
2037
+ * List of payment options that can be used.
2038
+ * @maxSize 300
2039
+ */
1668
2040
  eligibleMemberships?: Membership[];
1669
- /** List of payment options that are owned by the member, but cannot be used due to reason provided. */
2041
+ /**
2042
+ * List of payment options that are owned by the member, but cannot be used due to reason provided.
2043
+ * @maxSize 300
2044
+ */
1670
2045
  invalidMemberships?: InvalidMembership[];
1671
- /** The selected membership payment options and which line items they apply to. */
2046
+ /**
2047
+ * The selected membership payment options and which line items they apply to.
2048
+ * @maxSize 300
2049
+ */
1672
2050
  selectedMemberships?: HostSelectedMembership[];
1673
2051
  }
1674
2052
  export interface Membership {
1675
- /** Membership ID. */
2053
+ /**
2054
+ * Membership ID.
2055
+ * @minLength 1
2056
+ * @maxLength 100
2057
+ */
1676
2058
  _id?: string;
1677
- /** ID of the application providing this payment option. */
2059
+ /**
2060
+ * ID of the application providing this payment option.
2061
+ * @format GUID
2062
+ */
1678
2063
  appId?: string;
1679
2064
  /** The name of this membership. */
1680
2065
  name?: MembershipName;
1681
- /** Line item IDs which are "paid" for by this membership. */
2066
+ /**
2067
+ * Line item IDs which are "paid" for by this membership.
2068
+ * @minSize 1
2069
+ * @maxSize 300
2070
+ * @minLength 1
2071
+ * @maxLength 100
2072
+ */
1682
2073
  lineItemIds?: string[];
1683
2074
  /** Optional - For a membership that has limited credits, information about credit usage. */
1684
2075
  credits?: MembershipPaymentCredits;
@@ -1688,13 +2079,22 @@ export interface Membership {
1688
2079
  additionalData?: Record<string, any> | null;
1689
2080
  }
1690
2081
  export interface MembershipName {
1691
- /** Membership name. */
2082
+ /**
2083
+ * Membership name.
2084
+ * @maxLength 100
2085
+ */
1692
2086
  original?: string;
1693
- /** Membership name translated into buyer's language. Defaults to `original` when not defined. */
2087
+ /**
2088
+ * Membership name translated into buyer's language. Defaults to `original` when not defined.
2089
+ * @maxLength 100
2090
+ */
1694
2091
  translated?: string | null;
1695
2092
  }
1696
2093
  export interface MembershipPaymentCredits {
1697
- /** Membership's total amount of credits. */
2094
+ /**
2095
+ * Membership's total amount of credits.
2096
+ * @min 1
2097
+ */
1698
2098
  total?: number;
1699
2099
  /** Membership's remaining amount of credits. */
1700
2100
  remaining?: number;
@@ -1702,19 +2102,35 @@ export interface MembershipPaymentCredits {
1702
2102
  export interface InvalidMembership {
1703
2103
  /** Membership details. */
1704
2104
  membership?: Membership;
1705
- /** Reason why this membership is invalid and cannot be used. */
2105
+ /**
2106
+ * Reason why this membership is invalid and cannot be used.
2107
+ * @minLength 1
2108
+ * @maxLength 100
2109
+ */
1706
2110
  reason?: string;
1707
2111
  }
1708
2112
  export interface AdditionalFee {
1709
- /** Additional fee's unique code (or ID) for future processing. */
2113
+ /**
2114
+ * Additional fee's unique code (or ID) for future processing.
2115
+ * @minLength 1
2116
+ * @maxLength 100
2117
+ */
1710
2118
  code?: string | null;
1711
- /** Translated additional fee's name. */
2119
+ /**
2120
+ * Translated additional fee's name.
2121
+ * @minLength 1
2122
+ * @maxLength 50
2123
+ */
1712
2124
  name?: string;
1713
2125
  /** Additional fee's price. */
1714
2126
  price?: MultiCurrencyPrice;
1715
2127
  /** Tax details. */
1716
2128
  taxDetails?: ItemTaxFullDetails;
1717
- /** Provider's app id. */
2129
+ /**
2130
+ * Provider's app id.
2131
+ * @minLength 1
2132
+ * @maxLength 100
2133
+ */
1718
2134
  providerAppId?: string | null;
1719
2135
  /** Additional fee's price before tax. */
1720
2136
  priceBeforeTax?: MultiCurrencyPrice;
@@ -1723,12 +2139,15 @@ export interface AdditionalFee {
1723
2139
  /**
1724
2140
  * Optional - Line items associated with this additional fee.
1725
2141
  * If no `lineItemIds` are provided, the fee will be associated with the whole cart/checkout/order.
2142
+ * @format GUID
1726
2143
  */
1727
2144
  lineItemIds?: string[];
1728
2145
  /**
1729
2146
  * Number of subscription cycle this fee applies to
1730
2147
  * default None - all billing cycle
1731
2148
  * @internal
2149
+ * @min 1
2150
+ * @max 999
1732
2151
  */
1733
2152
  subscriptionCycles?: number | null;
1734
2153
  /** the source the additional fee was added from */
@@ -1748,7 +2167,11 @@ export interface Violation {
1748
2167
  severity?: Severity;
1749
2168
  /** Target location on a checkout or cart page where the violation will be displayed. */
1750
2169
  target?: Target;
1751
- /** Violation description. Can include rich text. Only HTTP or HTTPS links in the following format are allowed: `<a href="https://www.wix.com">Click me</a>`. */
2170
+ /**
2171
+ * Violation description. Can include rich text. Only HTTP or HTTPS links in the following format are allowed: `<a href="https://www.wix.com">Click me</a>`.
2172
+ * @minLength 1
2173
+ * @maxLength 1000
2174
+ */
1752
2175
  description?: string | null;
1753
2176
  }
1754
2177
  export declare enum Severity {
@@ -1807,7 +2230,12 @@ export interface TargetLineItem {
1807
2230
  suggestedFix?: SuggestedFix;
1808
2231
  }
1809
2232
  export interface RemoveLineItemsFromCurrentCartRequest {
1810
- /** IDs of the line items to remove from the cart. */
2233
+ /**
2234
+ * IDs of the line items to remove from the cart.
2235
+ * @format GUID
2236
+ * @minSize 1
2237
+ * @maxSize 100
2238
+ */
1811
2239
  lineItemIds?: string[];
1812
2240
  }
1813
2241
  export interface RemoveLineItemsResponse {
@@ -1823,7 +2251,10 @@ export interface CreateCheckoutFromCurrentCartRequest {
1823
2251
  billingAddress?: Address;
1824
2252
  /** Selected shipping option. */
1825
2253
  selectedShippingOption?: SelectedShippingOption;
1826
- /** Mandatory when setting a billing or shipping address if the site visitor isn't logged in. */
2254
+ /**
2255
+ * Mandatory when setting a billing or shipping address if the site visitor isn't logged in.
2256
+ * @format EMAIL
2257
+ */
1827
2258
  email?: string | null;
1828
2259
  }
1829
2260
  export declare enum ChannelType {
@@ -1871,13 +2302,24 @@ export interface RemoveCouponResponse {
1871
2302
  cart?: Cart;
1872
2303
  }
1873
2304
  export interface UpdateCurrentCartLineItemQuantityRequest {
1874
- /** Line item IDs and their new quantity. */
2305
+ /**
2306
+ * Line item IDs and their new quantity.
2307
+ * @minSize 1
2308
+ * @maxSize 100
2309
+ */
1875
2310
  lineItems?: LineItemQuantityUpdate[];
1876
2311
  }
1877
2312
  export interface LineItemQuantityUpdate {
1878
- /** Line item ID. Required. */
2313
+ /**
2314
+ * Line item ID. Required.
2315
+ * @format GUID
2316
+ */
1879
2317
  _id?: string;
1880
- /** New quantity. Number must be 1 or higher. Required. */
2318
+ /**
2319
+ * New quantity. Number must be 1 or higher. Required.
2320
+ * @min 1
2321
+ * @max 100000
2322
+ */
1881
2323
  quantity?: number;
1882
2324
  }
1883
2325
  export interface UpdateLineItemsQuantityResponse {
@@ -1981,9 +2423,15 @@ export interface ActionEvent {
1981
2423
  body?: string;
1982
2424
  }
1983
2425
  export interface MessageEnvelope {
1984
- /** App instance ID. */
2426
+ /**
2427
+ * App instance ID.
2428
+ * @format GUID
2429
+ */
1985
2430
  instanceId?: string | null;
1986
- /** Event type. */
2431
+ /**
2432
+ * Event type.
2433
+ * @maxLength 150
2434
+ */
1987
2435
  eventType?: string;
1988
2436
  /** The identification type and identity data. */
1989
2437
  identity?: IdentificationData;
@@ -1991,26 +2439,50 @@ export interface MessageEnvelope {
1991
2439
  data?: string;
1992
2440
  }
1993
2441
  export interface IdentificationData extends IdentificationDataIdOneOf {
1994
- /** ID of a site visitor that has not logged in to the site. */
2442
+ /**
2443
+ * ID of a site visitor that has not logged in to the site.
2444
+ * @format GUID
2445
+ */
1995
2446
  anonymousVisitorId?: string;
1996
- /** ID of a site visitor that has logged in to the site. */
2447
+ /**
2448
+ * ID of a site visitor that has logged in to the site.
2449
+ * @format GUID
2450
+ */
1997
2451
  memberId?: string;
1998
- /** ID of a Wix user (site owner, contributor, etc.). */
2452
+ /**
2453
+ * ID of a Wix user (site owner, contributor, etc.).
2454
+ * @format GUID
2455
+ */
1999
2456
  wixUserId?: string;
2000
- /** ID of an app. */
2457
+ /**
2458
+ * ID of an app.
2459
+ * @format GUID
2460
+ */
2001
2461
  appId?: string;
2002
2462
  /** @readonly */
2003
2463
  identityType?: WebhookIdentityType;
2004
2464
  }
2005
2465
  /** @oneof */
2006
2466
  export interface IdentificationDataIdOneOf {
2007
- /** ID of a site visitor that has not logged in to the site. */
2467
+ /**
2468
+ * ID of a site visitor that has not logged in to the site.
2469
+ * @format GUID
2470
+ */
2008
2471
  anonymousVisitorId?: string;
2009
- /** ID of a site visitor that has logged in to the site. */
2472
+ /**
2473
+ * ID of a site visitor that has logged in to the site.
2474
+ * @format GUID
2475
+ */
2010
2476
  memberId?: string;
2011
- /** ID of a Wix user (site owner, contributor, etc.). */
2477
+ /**
2478
+ * ID of a Wix user (site owner, contributor, etc.).
2479
+ * @format GUID
2480
+ */
2012
2481
  wixUserId?: string;
2013
- /** ID of an app. */
2482
+ /**
2483
+ * ID of an app.
2484
+ * @format GUID
2485
+ */
2014
2486
  appId?: string;
2015
2487
  }
2016
2488
  export declare enum WebhookIdentityType {
@@ -2025,15 +2497,22 @@ export interface CreateCartRequest {
2025
2497
  cartInfo?: Cart;
2026
2498
  /** The code of an existing coupon to apply to the cart. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */
2027
2499
  couponCode?: string | null;
2028
- /** Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will apply to the whole cart. */
2500
+ /**
2501
+ * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will apply to the whole cart.
2502
+ * @maxSize 100
2503
+ */
2029
2504
  merchantDiscounts?: MerchantDiscountInput[];
2030
- /** Catalog line items. */
2505
+ /**
2506
+ * Catalog line items.
2507
+ * @maxSize 300
2508
+ */
2031
2509
  lineItems?: LineItem[];
2032
2510
  /**
2033
2511
  * Custom line items. Custom line items don't trigger the Catalog service plugin.
2034
2512
  *
2035
2513
  * To access and manage custom line items, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
2036
2514
  * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
2515
+ * @maxSize 300
2037
2516
  */
2038
2517
  customLineItems?: CustomLineItem[];
2039
2518
  }
@@ -2042,7 +2521,10 @@ export interface CreateCartResponse {
2042
2521
  cart?: Cart;
2043
2522
  }
2044
2523
  export interface GetCartRequest {
2045
- /** ID of the cart to retrieve. */
2524
+ /**
2525
+ * ID of the cart to retrieve.
2526
+ * @format GUID
2527
+ */
2046
2528
  _id: string;
2047
2529
  }
2048
2530
  export interface GetCartResponse {
@@ -2050,7 +2532,10 @@ export interface GetCartResponse {
2050
2532
  cart?: Cart;
2051
2533
  }
2052
2534
  export interface GetCartByCheckoutIdRequest {
2053
- /** Checkout ID. */
2535
+ /**
2536
+ * Checkout ID.
2537
+ * @format GUID
2538
+ */
2054
2539
  _id: string;
2055
2540
  }
2056
2541
  export interface GetCartByCheckoutIdResponse {
@@ -2058,33 +2543,51 @@ export interface GetCartByCheckoutIdResponse {
2058
2543
  cart?: Cart;
2059
2544
  }
2060
2545
  export interface AddToCartRequest {
2061
- /** Cart ID. */
2546
+ /**
2547
+ * Cart ID.
2548
+ * @format GUID
2549
+ */
2062
2550
  _id: string;
2063
- /** Catalog line items. */
2551
+ /**
2552
+ * Catalog line items.
2553
+ * @maxSize 100
2554
+ */
2064
2555
  lineItems?: LineItem[];
2065
2556
  /**
2066
2557
  * Custom line items. Custom line items don't trigger the Catalog service plugin.
2067
2558
  *
2068
2559
  * To access and manage custom line items, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
2069
2560
  * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
2561
+ * @maxSize 100
2070
2562
  */
2071
2563
  customLineItems?: CustomLineItem[];
2072
2564
  /**
2073
2565
  * The business location ID associated with the cart.
2074
2566
  * The `businessLocationId` field cannot be passed if one already exists on the cart. To update a cart's business location ID, use the UpdateCart method.
2075
2567
  * Learn more about the [Locations API](https://dev.wix.com/docs/rest/business-management/locations/introduction).
2076
- * @internal
2568
+ * @format GUID
2077
2569
  */
2078
2570
  businessLocationId?: string | null;
2079
2571
  }
2080
2572
  export interface RemoveLineItemsRequest {
2081
- /** Cart ID. */
2573
+ /**
2574
+ * Cart ID.
2575
+ * @format GUID
2576
+ */
2082
2577
  _id: string;
2083
- /** IDs of the line items to remove from the cart. */
2578
+ /**
2579
+ * IDs of the line items to remove from the cart.
2580
+ * @format GUID
2581
+ * @minSize 1
2582
+ * @maxSize 100
2583
+ */
2084
2584
  lineItemIds: string[];
2085
2585
  }
2086
2586
  export interface CreateCheckoutRequest {
2087
- /** Cart ID. */
2587
+ /**
2588
+ * Cart ID.
2589
+ * @format GUID
2590
+ */
2088
2591
  _id: string;
2089
2592
  /** **Required**. Sales channel type. */
2090
2593
  channelType?: ChannelType;
@@ -2094,21 +2597,37 @@ export interface CreateCheckoutRequest {
2094
2597
  billingAddress?: Address;
2095
2598
  /** Selected shipping option. */
2096
2599
  selectedShippingOption?: SelectedShippingOption;
2097
- /** Mandatory when setting a billing or shipping address if the site visitor isn't logged in. */
2600
+ /**
2601
+ * Mandatory when setting a billing or shipping address if the site visitor isn't logged in.
2602
+ * @format EMAIL
2603
+ */
2098
2604
  email?: string | null;
2099
2605
  }
2100
2606
  export interface RemoveCouponRequest {
2101
- /** Cart ID. */
2607
+ /**
2608
+ * Cart ID.
2609
+ * @format GUID
2610
+ */
2102
2611
  _id: string;
2103
2612
  }
2104
2613
  export interface UpdateLineItemsQuantityRequest {
2105
- /** Cart ID. */
2614
+ /**
2615
+ * Cart ID.
2616
+ * @format GUID
2617
+ */
2106
2618
  _id: string;
2107
- /** Line item IDs and their new quantity. */
2619
+ /**
2620
+ * Line item IDs and their new quantity.
2621
+ * @minSize 1
2622
+ * @maxSize 100
2623
+ */
2108
2624
  lineItems: LineItemQuantityUpdate[];
2109
2625
  }
2110
2626
  export interface EstimateTotalsRequest {
2111
- /** Cart ID. */
2627
+ /**
2628
+ * Cart ID.
2629
+ * @format GUID
2630
+ */
2112
2631
  _id: string;
2113
2632
  /** Selected shipping option. */
2114
2633
  selectedShippingOption?: SelectedShippingOption;
@@ -2132,13 +2651,19 @@ export interface EstimateTotalsRequest {
2132
2651
  calculateShipping?: boolean | null;
2133
2652
  }
2134
2653
  export interface DeleteCartRequest {
2135
- /** ID of the cart to delete. */
2654
+ /**
2655
+ * ID of the cart to delete.
2656
+ * @format GUID
2657
+ */
2136
2658
  _id: string;
2137
2659
  }
2138
2660
  export interface Empty {
2139
2661
  }
2140
2662
  export interface RemoveBusinessLocationRequest {
2141
- /** Cart ID. */
2663
+ /**
2664
+ * Cart ID.
2665
+ * @format GUID
2666
+ */
2142
2667
  _id: string;
2143
2668
  }
2144
2669
  export interface RemoveBusinessLocationResponse {
@@ -2658,9 +3183,15 @@ export interface RemoveBusinessLocationResponseNonNullableFields {
2658
3183
  cart?: CartNonNullableFields;
2659
3184
  }
2660
3185
  export interface BaseEventMetadata {
2661
- /** App instance ID. */
3186
+ /**
3187
+ * App instance ID.
3188
+ * @format GUID
3189
+ */
2662
3190
  instanceId?: string | null;
2663
- /** Event type. */
3191
+ /**
3192
+ * Event type.
3193
+ * @maxLength 150
3194
+ */
2664
3195
  eventType?: string;
2665
3196
  /** The identification type and identity data. */
2666
3197
  identity?: IdentificationData;
@@ -2725,6 +3256,8 @@ export interface CartDeletedEnvelope {
2725
3256
  * @permissionId ECOM.READ_CARTS
2726
3257
  * @webhook
2727
3258
  * @eventType wix.ecom.v1.cart_deleted
3259
+ * @serviceIdentifier com.wix.ecom.cart.api.v1.CurrentCartService
3260
+ * @slug deleted
2728
3261
  */
2729
3262
  export declare function onCartDeleted(handler: (event: CartDeletedEnvelope) => void | Promise<void>): void;
2730
3263
  export interface CartUpdatedEnvelope {
@@ -2748,6 +3281,7 @@ export interface CartUpdatedEnvelope {
2748
3281
  * @permissionId ECOM.READ_CARTS
2749
3282
  * @webhook
2750
3283
  * @eventType wix.ecom.v1.cart_updated
3284
+ * @slug updated
2751
3285
  */
2752
3286
  export declare function onCartUpdated(handler: (event: CartUpdatedEnvelope) => void | Promise<void>): void;
2753
3287
  export interface CartCreatedEnvelope {
@@ -2773,6 +3307,8 @@ export interface CartCreatedEnvelope {
2773
3307
  * @permissionId ECOM.READ_CARTS
2774
3308
  * @webhook
2775
3309
  * @eventType wix.ecom.v1.cart_created
3310
+ * @serviceIdentifier com.wix.ecom.cart.api.v1.CartService
3311
+ * @slug created
2776
3312
  */
2777
3313
  export declare function onCartCreated(handler: (event: CartCreatedEnvelope) => void | Promise<void>): void;
2778
3314
  /**
@@ -2783,8 +3319,8 @@ export declare function onCartCreated(handler: (event: CartCreatedEnvelope) => v
2783
3319
  *
2784
3320
  * > **Note:** When adding catalog items, `options.lineItems.catalogReference` is required.
2785
3321
  * @public
2786
- * @requiredField options.customLineItems.descriptionLines
2787
3322
  * @requiredField options.customLineItems.descriptionLines.name
3323
+ * @requiredField options.customLineItems.descriptionLines.value
2788
3324
  * @requiredField options.customLineItems.itemType
2789
3325
  * @requiredField options.customLineItems.price
2790
3326
  * @requiredField options.customLineItems.productName
@@ -2798,12 +3334,16 @@ export declare function onCartCreated(handler: (event: CartCreatedEnvelope) => v
2798
3334
  * @permissionId ECOM.ADMIN_MODIFY_CARTS
2799
3335
  * @permissionScope Manage Stores - all permissions
2800
3336
  * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
3337
+ * @permissionScope Manage Restaurants - all permissions
3338
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2801
3339
  * @permissionScope Manage eCommerce - all permissions
2802
3340
  * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
2803
3341
  * @permissionScope Manage Stores - all permissions
2804
3342
  * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
2805
3343
  * @permissionScope Manage eCommerce - Admin Permissions
2806
3344
  * @permissionScopeId SCOPE.ECOM.MANAGE-ADMIN
3345
+ * @permissionScope Manage Restaurants - all permissions
3346
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2807
3347
  * @permissionScope Manage eCommerce - all permissions
2808
3348
  * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
2809
3349
  * @applicableIdentity APP
@@ -2817,29 +3357,35 @@ export interface CreateCartOptions {
2817
3357
  cartInfo?: Cart;
2818
3358
  /** The code of an existing coupon to apply to the cart. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */
2819
3359
  couponCode?: string | null;
2820
- /** Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will apply to the whole cart. */
3360
+ /**
3361
+ * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will apply to the whole cart.
3362
+ * @maxSize 100
3363
+ */
2821
3364
  merchantDiscounts?: MerchantDiscountInput[];
2822
- /** Catalog line items. */
3365
+ /**
3366
+ * Catalog line items.
3367
+ * @maxSize 300
3368
+ */
2823
3369
  lineItems?: LineItem[];
2824
3370
  /**
2825
3371
  * Custom line items. Custom line items don't trigger the Catalog service plugin.
2826
3372
  *
2827
3373
  * To access and manage custom line items, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
2828
3374
  * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
3375
+ * @maxSize 300
2829
3376
  */
2830
3377
  customLineItems?: CustomLineItem[];
2831
3378
  }
2832
3379
  /**
2833
3380
  * Updates a specified cart's properties.
2834
3381
  *
2835
- *
2836
- * The `updateCart()` function returns a Promise that resolves when the specified cart's properties are updated.
3382
+ * After a cart is updated, call `refreshCart()` to update the cart's UI elements and trigger the `onCartChange()` event.
2837
3383
  *
2838
3384
  * > **Note:** When updating catalog items, `options.lineItems.catalogReference` is required.
2839
3385
  * @public
2840
3386
  * @requiredField _id
2841
- * @requiredField options.customLineItems.descriptionLines
2842
3387
  * @requiredField options.customLineItems.descriptionLines.name
3388
+ * @requiredField options.customLineItems.descriptionLines.value
2843
3389
  * @requiredField options.customLineItems.itemType
2844
3390
  * @requiredField options.customLineItems.productName
2845
3391
  * @requiredField options.lineItems.catalogReference
@@ -2849,12 +3395,16 @@ export interface CreateCartOptions {
2849
3395
  * @permissionId ECOM.ADMIN_MODIFY_CARTS
2850
3396
  * @permissionScope Manage Stores - all permissions
2851
3397
  * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
3398
+ * @permissionScope Manage Restaurants - all permissions
3399
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2852
3400
  * @permissionScope Manage eCommerce - all permissions
2853
3401
  * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
2854
3402
  * @permissionScope Manage Stores - all permissions
2855
3403
  * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
2856
3404
  * @permissionScope Manage eCommerce - Admin Permissions
2857
3405
  * @permissionScopeId SCOPE.ECOM.MANAGE-ADMIN
3406
+ * @permissionScope Manage Restaurants - all permissions
3407
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2858
3408
  * @permissionScope Manage eCommerce - all permissions
2859
3409
  * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
2860
3410
  * @applicableIdentity APP
@@ -2866,19 +3416,28 @@ export declare function updateCart(_id: string | null, options?: UpdateCartOptio
2866
3416
  export interface UpdateCartOptions {
2867
3417
  /** The information for the cart being updated. */
2868
3418
  cartInfo: {
2869
- /** ID of the cart to be updated. */
3419
+ /**
3420
+ * ID of the cart to be updated.
3421
+ * @format GUID
3422
+ */
2870
3423
  _id?: string | null;
2871
3424
  /**
2872
3425
  * Line items.
3426
+ * @minSize 1
3427
+ * @maxSize 300
2873
3428
  * @readonly
2874
3429
  */
2875
3430
  lineItems?: LineItem[];
2876
- /** [Buyer note](https://support.wix.com/en/article/wix-stores-viewing-buyer-notes) left by the customer. */
3431
+ /**
3432
+ * [Buyer note](https://support.wix.com/en/article/wix-stores-viewing-buyer-notes) left by the customer.
3433
+ * @maxLength 1000
3434
+ */
2877
3435
  buyerNote?: string | null;
2878
3436
  /** Buyer information. */
2879
3437
  buyerInfo?: BuyerInfo;
2880
3438
  /**
2881
3439
  * Currency used for pricing.
3440
+ * @format CURRENCY
2882
3441
  * @readonly
2883
3442
  */
2884
3443
  currency?: string;
@@ -2886,6 +3445,7 @@ export interface UpdateCartOptions {
2886
3445
  * Currency code used for all the converted prices that are returned.
2887
3446
  * For a site that supports multiple currencies, this is the currency the buyer selected.
2888
3447
  * @readonly
3448
+ * @format CURRENCY
2889
3449
  */
2890
3450
  conversionCurrency?: string;
2891
3451
  /**
@@ -2912,6 +3472,7 @@ export interface UpdateCartOptions {
2912
3472
  /**
2913
3473
  * ID of the checkout that originated from this cart.
2914
3474
  * @readonly
3475
+ * @format GUID
2915
3476
  */
2916
3477
  checkoutId?: string | null;
2917
3478
  /**
@@ -2935,10 +3496,12 @@ export interface UpdateCartOptions {
2935
3496
  * `overrideCheckoutUrl` allows the flexibility to redirect customers to a customized checkout page.
2936
3497
  *
2937
3498
  * 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`.
3499
+ * @maxLength 1000
2938
3500
  */
2939
3501
  overrideCheckoutUrl?: string | null;
2940
3502
  /**
2941
3503
  * Persistent ID that correlates between the various eCommerce elements: cart, checkout, and order.
3504
+ * @format GUID
2942
3505
  * @readonly
2943
3506
  */
2944
3507
  purchaseFlowId?: string | null;
@@ -2947,21 +3510,28 @@ export interface UpdateCartOptions {
2947
3510
  /**
2948
3511
  * The business location ID associated with the cart.
2949
3512
  * Learn more about the [Locations API](https://dev.wix.com/docs/rest/business-management/locations/introduction).
2950
- * @internal
3513
+ * @format GUID
2951
3514
  */
2952
3515
  businessLocationId?: string | null;
2953
3516
  };
2954
3517
  /** The code of an existing coupon to apply to the cart. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */
2955
3518
  couponCode?: string | null;
2956
- /** Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will be applied to the whole cart. */
3519
+ /**
3520
+ * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will be applied to the whole cart.
3521
+ * @maxSize 100
3522
+ */
2957
3523
  merchantDiscounts?: MerchantDiscountInput[];
2958
- /** Catalog line items. */
3524
+ /**
3525
+ * Catalog line items.
3526
+ * @maxSize 300
3527
+ */
2959
3528
  lineItems?: LineItem[];
2960
3529
  /**
2961
3530
  * Custom line items. Custom line items don't trigger the Catalog service plugin.
2962
3531
  *
2963
3532
  * To access and manage custom line items, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
2964
3533
  * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
3534
+ * @maxSize 300
2965
3535
  */
2966
3536
  customLineItems?: CustomLineItem[];
2967
3537
  }
@@ -3023,15 +3593,14 @@ export declare function getCartByCheckoutId(_id: string): Promise<GetCartByCheck
3023
3593
  /**
3024
3594
  * Adds catalog line items to a cart.
3025
3595
  *
3026
- *
3027
- * The `addToCart()` function returns a Promise that resolves to the updated cart when the specified items have been added.
3596
+ * After a cart is updated, call `refreshCart()` to update the cart's UI elements and trigger the `onCartChange()` event.
3028
3597
  *
3029
3598
  * > **Note:** When adding catalog items, `options.lineItems.catalogReference` is required.
3030
3599
  * @param _id - Cart ID.
3031
3600
  * @public
3032
3601
  * @requiredField _id
3033
- * @requiredField options.customLineItems.descriptionLines
3034
3602
  * @requiredField options.customLineItems.descriptionLines.name
3603
+ * @requiredField options.customLineItems.descriptionLines.value
3035
3604
  * @requiredField options.customLineItems.itemType
3036
3605
  * @requiredField options.customLineItems.price
3037
3606
  * @requiredField options.customLineItems.productName
@@ -3044,12 +3613,16 @@ export declare function getCartByCheckoutId(_id: string): Promise<GetCartByCheck
3044
3613
  * @permissionId ECOM.ADMIN_MODIFY_CARTS
3045
3614
  * @permissionScope Manage Stores - all permissions
3046
3615
  * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
3616
+ * @permissionScope Manage Restaurants - all permissions
3617
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
3047
3618
  * @permissionScope Manage eCommerce - all permissions
3048
3619
  * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
3049
3620
  * @permissionScope Manage Stores - all permissions
3050
3621
  * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
3051
3622
  * @permissionScope Manage eCommerce - Admin Permissions
3052
3623
  * @permissionScopeId SCOPE.ECOM.MANAGE-ADMIN
3624
+ * @permissionScope Manage Restaurants - all permissions
3625
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
3053
3626
  * @permissionScope Manage eCommerce - all permissions
3054
3627
  * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
3055
3628
  * @applicableIdentity APP
@@ -3059,21 +3632,31 @@ export declare function getCartByCheckoutId(_id: string): Promise<GetCartByCheck
3059
3632
  */
3060
3633
  export declare function addToCart(_id: string, options?: AddToCartOptions): Promise<AddToCartResponse & AddToCartResponseNonNullableFields>;
3061
3634
  export interface AddToCartOptions {
3062
- /** Catalog line items. */
3635
+ /**
3636
+ * Catalog line items.
3637
+ * @maxSize 100
3638
+ */
3063
3639
  lineItems?: LineItem[];
3064
3640
  /**
3065
3641
  * Custom line items. Custom line items don't trigger the Catalog service plugin.
3066
3642
  *
3067
3643
  * To access and manage custom line items, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
3068
3644
  * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
3645
+ * @maxSize 100
3069
3646
  */
3070
3647
  customLineItems?: CustomLineItem[];
3648
+ /**
3649
+ * The business location ID associated with the cart.
3650
+ * The `businessLocationId` field cannot be passed if one already exists on the cart. To update a cart's business location ID, use the UpdateCart method.
3651
+ * Learn more about the [Locations API](https://dev.wix.com/docs/rest/business-management/locations/introduction).
3652
+ * @format GUID
3653
+ */
3654
+ businessLocationId?: string | null;
3071
3655
  }
3072
3656
  /**
3073
3657
  * Removes line items from the specified cart.
3074
3658
  *
3075
- *
3076
- * The `removeLineItems()` function returns a Promise that resolves to the updated cart when the line items are removed from the specified cart.
3659
+ * After a cart is updated, call `refreshCart()` to update the cart's UI elements and trigger the `onCartChange()` event.
3077
3660
  * @public
3078
3661
  * @requiredField _id
3079
3662
  * @requiredField lineItemIds
@@ -3082,6 +3665,8 @@ export interface AddToCartOptions {
3082
3665
  * @permissionId ECOM.MODIFY_CARTS
3083
3666
  * @permissionScope Manage Stores - all permissions
3084
3667
  * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
3668
+ * @permissionScope Manage Restaurants - all permissions
3669
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
3085
3670
  * @permissionScope Manage eCommerce - all permissions
3086
3671
  * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
3087
3672
  * @applicableIdentity APP
@@ -3128,20 +3713,24 @@ export interface CreateCheckoutOptions {
3128
3713
  billingAddress?: Address;
3129
3714
  /** Selected shipping option. */
3130
3715
  selectedShippingOption?: SelectedShippingOption;
3131
- /** Mandatory when setting a billing or shipping address if the site visitor isn't logged in. */
3716
+ /**
3717
+ * Mandatory when setting a billing or shipping address if the site visitor isn't logged in.
3718
+ * @format EMAIL
3719
+ */
3132
3720
  email?: string | null;
3133
3721
  }
3134
3722
  /**
3135
3723
  * Removes the coupon from a specified cart.
3136
3724
  *
3137
- *
3138
- * The `removeCoupon()` function returns a Promise that resolves to the updated cart when the coupon is removed from the specified cart.
3725
+ * After a cart is updated, call `refreshCart()` to update the cart's UI elements and trigger the `onCartChange()` event.
3139
3726
  * @param _id - Cart ID.
3140
3727
  * @public
3141
3728
  * @requiredField _id
3142
3729
  * @permissionId ECOM.MODIFY_CARTS
3143
3730
  * @permissionScope Manage Stores - all permissions
3144
3731
  * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
3732
+ * @permissionScope Manage Restaurants - all permissions
3733
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
3145
3734
  * @permissionScope Manage eCommerce - all permissions
3146
3735
  * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
3147
3736
  * @applicableIdentity APP
@@ -3153,12 +3742,11 @@ export declare function removeCoupon(_id: string): Promise<RemoveCouponResponse
3153
3742
  /**
3154
3743
  * Updates the quantity of one or more line items in a specified cart.
3155
3744
  *
3745
+ * After a cart is updated, call `refreshCart()` to update the cart's UI elements and trigger the `onCartChange()` event.
3156
3746
  *
3157
- * The `updateLineItemsQuantity()` function returns a Promise that resolves when the quantities of the specified cart's line items are updated.
3158
- *
3159
- * This endpoint is only for updating the quantity of line items. To entirely remove a line item from the cart, use [`removeLineItems()`](#removelineitems). To add a new line item to the cart, use [`addToCart()`](#addtocart).
3747
+ * This method is only for updating the quantity of line items. To entirely remove a line item from the cart, use `removeLineItems()`. To add a new line item to the cart, use `addToCart()`.
3160
3748
  *
3161
- * This endpoint checks the amount of stock remaining for this line item. If the specified `quantity` is greater than the remaining stock, then the `quantity` returned in the response is the total amount of remaining stock.
3749
+ * This method checks the amount of stock remaining for this line item. If the specified `quantity` is greater than the remaining stock, then the `quantity` returned in the response is the total amount of remaining stock.
3162
3750
  * @param _id - Cart ID.
3163
3751
  * @param lineItems - Line item IDs and their new quantity.
3164
3752
  * @public
@@ -3167,6 +3755,8 @@ export declare function removeCoupon(_id: string): Promise<RemoveCouponResponse
3167
3755
  * @permissionId ECOM.MODIFY_CARTS
3168
3756
  * @permissionScope Manage Stores - all permissions
3169
3757
  * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
3758
+ * @permissionScope Manage Restaurants - all permissions
3759
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
3170
3760
  * @permissionScope Manage eCommerce - all permissions
3171
3761
  * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
3172
3762
  * @applicableIdentity APP
@@ -3240,6 +3830,8 @@ export interface EstimateTotalsOptions {
3240
3830
  * @permissionId ECOM.MODIFY_CARTS
3241
3831
  * @permissionScope Manage Stores - all permissions
3242
3832
  * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
3833
+ * @permissionScope Manage Restaurants - all permissions
3834
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
3243
3835
  * @permissionScope Manage eCommerce - all permissions
3244
3836
  * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
3245
3837
  * @applicableIdentity APP
@@ -3251,12 +3843,14 @@ export declare function deleteCart(_id: string): Promise<void>;
3251
3843
  /**
3252
3844
  * Removes the location associated with a cart.
3253
3845
  * @param _id - Cart ID.
3254
- * @internal
3846
+ * @public
3255
3847
  * @documentationMaturity preview
3256
3848
  * @requiredField _id
3257
3849
  * @permissionId ECOM.MODIFY_CARTS
3258
3850
  * @permissionScope Manage Stores - all permissions
3259
3851
  * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
3852
+ * @permissionScope Manage Restaurants - all permissions
3853
+ * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
3260
3854
  * @permissionScope Manage eCommerce - all permissions
3261
3855
  * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
3262
3856
  * @applicableIdentity APP