@wix/auto_sdk_ecom_checkout 1.0.36 → 1.0.37

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-DEDRvPML.d.mts} +674 -365
  2. package/build/{cjs/src/ecom-v1-checkout-checkout.types.d.ts → ecom-v1-checkout-checkout.universal-DEDRvPML.d.ts} +674 -365
  3. package/build/index.d.mts +210 -0
  4. package/build/index.d.ts +210 -0
  5. package/build/index.js +2782 -0
  6. package/build/index.js.map +1 -0
  7. package/build/index.mjs +2708 -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-CirtPjnM.d.mts} +803 -364
  10. package/build/internal/{es/src/ecom-v1-checkout-checkout.types.d.ts → ecom-v1-checkout-checkout.universal-CirtPjnM.d.ts} +803 -364
  11. package/build/internal/index.d.mts +240 -0
  12. package/build/internal/index.d.ts +240 -0
  13. package/build/internal/index.js +2782 -0
  14. package/build/internal/index.js.map +1 -0
  15. package/build/internal/index.mjs +2708 -0
  16. package/build/internal/index.mjs.map +1 -0
  17. package/build/internal/meta.d.mts +2606 -0
  18. package/build/internal/meta.d.ts +2606 -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 +2606 -0
  24. package/build/meta.d.ts +2606 -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 +12 -11
  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 -35
  40. package/build/cjs/src/ecom-v1-checkout-checkout.context.js +0 -76
  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 -101
  43. package/build/cjs/src/ecom-v1-checkout-checkout.http.js +0 -1317
  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 -182
  49. package/build/cjs/src/ecom-v1-checkout-checkout.public.js +0 -357
  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 -303
  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 -4437
  54. package/build/cjs/src/ecom-v1-checkout-checkout.universal.js +0 -1587
  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 -35
  67. package/build/es/src/ecom-v1-checkout-checkout.context.js +0 -41
  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 -101
  70. package/build/es/src/ecom-v1-checkout-checkout.http.js +0 -1297
  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 -182
  76. package/build/es/src/ecom-v1-checkout-checkout.public.js +0 -305
  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 -300
  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 -4437
  81. package/build/es/src/ecom-v1-checkout-checkout.universal.js +0 -1544
  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 -41
  93. package/build/internal/cjs/src/ecom-v1-checkout-checkout.context.js +0 -76
  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 -101
  96. package/build/internal/cjs/src/ecom-v1-checkout-checkout.http.js +0 -1317
  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 -206
  102. package/build/internal/cjs/src/ecom-v1-checkout-checkout.public.js +0 -357
  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 -303
  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 -4623
  107. package/build/internal/cjs/src/ecom-v1-checkout-checkout.universal.js +0 -1587
  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 -41
  119. package/build/internal/es/src/ecom-v1-checkout-checkout.context.js +0 -41
  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 -101
  122. package/build/internal/es/src/ecom-v1-checkout-checkout.http.js +0 -1297
  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 -206
  128. package/build/internal/es/src/ecom-v1-checkout-checkout.public.js +0 -305
  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 -300
  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 -4623
  133. package/build/internal/es/src/ecom-v1-checkout-checkout.universal.js +0 -1544
  134. package/build/internal/es/src/ecom-v1-checkout-checkout.universal.js.map +0 -1
@@ -0,0 +1,2606 @@
1
+ import { bF as CreateCheckoutRequest$1, bK as CreateCheckoutResponse$1, bN as GetCheckoutRequest$1, bO as GetCheckoutResponse$1, bR as GetCheckoutByCartIdRequest$1, G as GetCheckoutByCartIdResponse$1, bS as GetWixCheckoutURLRequest$1, bT as GetWixCheckoutURLResponse$1, bU as GetCheckoutURLRequest$1, b as GetCheckoutURLResponse$1, bV as UpdateCheckoutRequest$1, bW as UpdateCheckoutResponse$1, bX as RemoveCouponRequest$1, R as RemoveCouponResponse$1, bY as RemoveGiftCardRequest$1, d as RemoveGiftCardResponse$1, bZ as RemoveOverrideCheckoutUrlRequest$1, e as RemoveOverrideCheckoutUrlResponse$1, b_ as AddToCheckoutRequest$1, f as AddToCheckoutResponse$1, b$ as RemoveLineItemsRequest$1, g as RemoveLineItemsResponse$1, c0 as CreateOrderRequest$1, i as CreateOrderResponse$1, c7 as CreateOrderAndChargeRequest$1, c8 as CreateOrderAndChargeResponse$1, ca as MarkCheckoutAsCompletedAndRedirectToUrlRequest$1, j as RawHttpResponse$1, cc as MarkCheckoutAsCompletedRequest$1, cd as MarkCheckoutAsCompletedResponse$1, cf as UpdateLineItemsQuantityRequest$1, k as UpdateLineItemsQuantityResponse$1, cg as GetCheckoutPaymentSettingsRequest$1, ch as GetCheckoutPaymentSettingsResponse$1 } from './ecom-v1-checkout-checkout.universal-DEDRvPML.js';
2
+
3
+ interface Checkout {
4
+ /**
5
+ * Checkout ID.
6
+ * @format GUID
7
+ * @readonly
8
+ */
9
+ id?: string | null;
10
+ /**
11
+ * Line items.
12
+ *
13
+ * Max: 300 items
14
+ * @minSize 1
15
+ * @maxSize 300
16
+ * @readonly
17
+ */
18
+ lineItems?: LineItem[];
19
+ /** Billing information. */
20
+ billingInfo?: AddressWithContact;
21
+ /** Shipping information. */
22
+ shippingInfo?: ShippingInfo;
23
+ /**
24
+ * [Buyer note](https://support.wix.com/en/article/collecting-and-viewing-buyer-notes) left by the customer.
25
+ * @maxLength 1000
26
+ */
27
+ buyerNote?: string | null;
28
+ /** Buyer information. */
29
+ buyerInfo?: BuyerInfo;
30
+ /**
31
+ * The currency selected by the buyer during the purchase flow, in three-letter [ISO-4217 alphabetic](https://en.wikipedia.org/wiki/ISO_4217#Active_codes) format.
32
+ * @readonly
33
+ * @format CURRENCY
34
+ */
35
+ conversionCurrency?: string;
36
+ /**
37
+ * Calculated price summary for the checkout.
38
+ * @readonly
39
+ */
40
+ priceSummary?: PriceSummary;
41
+ /**
42
+ * Errors when calculating totals.
43
+ * @readonly
44
+ */
45
+ calculationErrors?: CalculationErrors;
46
+ /**
47
+ * Applied gift card details.
48
+ *
49
+ * >**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).
50
+ * @readonly
51
+ */
52
+ giftCard?: GiftCard;
53
+ /**
54
+ * Applied discounts.
55
+ * @readonly
56
+ */
57
+ appliedDiscounts?: AppliedDiscount[];
58
+ /** Custom fields. */
59
+ customFields?: CustomField[];
60
+ /**
61
+ * Weight measurement unit. Defaults to a site's weight unit.
62
+ * @readonly
63
+ */
64
+ weightUnit?: WeightUnitWithLiterals;
65
+ /**
66
+ * Tax summary.
67
+ * @readonly
68
+ */
69
+ taxSummary?: TaxSummary;
70
+ /**
71
+ * The site's default currency, in three-letter [ISO-4217 alphabetic](https://en.wikipedia.org/wiki/ISO_4217#Active_codes) format.
72
+ * @format CURRENCY
73
+ * @readonly
74
+ */
75
+ currency?: string;
76
+ /**
77
+ * Sales channel that submitted the order.
78
+ * @readonly
79
+ */
80
+ channelType?: ChannelTypeWithLiterals;
81
+ /**
82
+ * Site language in which original values are shown.
83
+ * @readonly
84
+ */
85
+ siteLanguage?: string;
86
+ /**
87
+ * Language for communication with the buyer. Defaults to the site language.
88
+ *
89
+ * For a site that supports multiple languages, this is the language the buyer selected.
90
+ * @readonly
91
+ */
92
+ buyerLanguage?: string;
93
+ /**
94
+ * Whether an order was successfully created from this checkout.
95
+ *
96
+ * For an order to be successful, it must be successfully paid for (unless the total is 0).
97
+ * @readonly
98
+ */
99
+ completed?: boolean;
100
+ /**
101
+ * Whether tax is included in line item prices.
102
+ * @readonly
103
+ */
104
+ taxIncludedInPrice?: boolean;
105
+ /**
106
+ * ID of the checkout's initiator.
107
+ * @readonly
108
+ */
109
+ createdBy?: CreatedBy;
110
+ /**
111
+ * Date and time the checkout was created.
112
+ * @readonly
113
+ */
114
+ createdDate?: Date | null;
115
+ /**
116
+ * Date and time the checkout was updated.
117
+ * @readonly
118
+ */
119
+ updatedDate?: Date | null;
120
+ /**
121
+ * Minimal amount to pay in order to place the order.
122
+ * @readonly
123
+ */
124
+ payNow?: PriceSummary;
125
+ /**
126
+ * Remaining amount for the order to be fully paid.
127
+ * @readonly
128
+ */
129
+ payLater?: PriceSummary;
130
+ /** Memberships to apply when creating the order. */
131
+ membershipOptions?: MembershipOptions;
132
+ /**
133
+ * Additional Fees.
134
+ * @maxSize 100
135
+ */
136
+ additionalFees?: AdditionalFee[];
137
+ /**
138
+ * Cart ID that this checkout was created from. Empty if this checkout wasn't created from a cart.
139
+ * @format GUID
140
+ */
141
+ cartId?: string | null;
142
+ /**
143
+ * 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)).
144
+ * @readonly
145
+ */
146
+ violations?: Violation[];
147
+ /**
148
+ * Custom field data for the checkout object.
149
+ *
150
+ * [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.
151
+ */
152
+ extendedFields?: ExtendedFields;
153
+ /**
154
+ * Persistent ID that correlates between the various eCommerce elements: cart, checkout, and order.
155
+ * @format GUID
156
+ * @readonly
157
+ */
158
+ purchaseFlowId?: string | null;
159
+ /**
160
+ * Additional settings for customization of the checkout process.
161
+ *
162
+ * > **Notes:**
163
+ * > * Custom settings can only be set when creating a checkout.
164
+ * > * 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).
165
+ * @immutable
166
+ */
167
+ customSettings?: CustomSettings;
168
+ /**
169
+ * Reference IDs for the app and component providing custom checkout page content.
170
+ *
171
+ * To access and manage custom checkout page content, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
172
+ * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
173
+ */
174
+ customContentReference?: CustomContentReference;
175
+ /**
176
+ * References to an external app and resource associated with this checkout.
177
+ * Used for integration and tracking across different platforms.
178
+ * @immutable
179
+ */
180
+ externalReference?: ExternalReference;
181
+ /**
182
+ * Payment for subscriptions after free trial period.
183
+ * @readonly
184
+ */
185
+ payAfterFreeTrial?: PriceSummary;
186
+ /**
187
+ * The business location ID associated with the checkout.
188
+ *
189
+ * To learn more, see the Locations API.
190
+ * @format GUID
191
+ */
192
+ businessLocationId?: string | null;
193
+ /**
194
+ * Currency used for payment, in three-letter [ISO-4217 alphabetic](https://en.wikipedia.org/wiki/ISO_4217#Active_codes) format.
195
+ * @readonly
196
+ * @format CURRENCY
197
+ */
198
+ paymentCurrency?: string;
199
+ }
200
+ interface LineItem {
201
+ /**
202
+ * Line item ID.
203
+ * @format GUID
204
+ * @readonly
205
+ */
206
+ id?: string | null;
207
+ /**
208
+ * Item quantity.
209
+ *
210
+ * Min: `"1"`
211
+ * Max: `"100000"`
212
+ * @min 1
213
+ * @max 100000
214
+ */
215
+ quantity?: number;
216
+ /** 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. */
217
+ catalogReference?: CatalogReference;
218
+ /**
219
+ * Item name.
220
+ * + Stores - `product.name`
221
+ * + Bookings - `service.info.name`
222
+ * + Events - `ticket.name`
223
+ * @readonly
224
+ */
225
+ productName?: ProductName;
226
+ /**
227
+ * URL to the item's page on the site.
228
+ * @readonly
229
+ */
230
+ url?: PageUrlV2;
231
+ /**
232
+ * Item price **after** catalog-defined discount and line item discounts.
233
+ * @readonly
234
+ */
235
+ price?: MultiCurrencyPrice;
236
+ /**
237
+ * Total line item price **after** catalog-defined discount and line item discounts.
238
+ * @readonly
239
+ */
240
+ lineItemPrice?: MultiCurrencyPrice;
241
+ /**
242
+ * Item price **before** catalog-defined discount. Defaults to `price` when not provided.
243
+ * @readonly
244
+ */
245
+ fullPrice?: MultiCurrencyPrice;
246
+ /**
247
+ * Item price **before** line item discounts and **after** catalog-defined discount. Defaults to `price` when not provided.
248
+ * @readonly
249
+ */
250
+ priceBeforeDiscounts?: MultiCurrencyPrice;
251
+ /**
252
+ * Total price after all discounts and tax.
253
+ * @readonly
254
+ */
255
+ totalPriceAfterTax?: MultiCurrencyPrice;
256
+ /**
257
+ * Total price after discounts, and before tax.
258
+ * @readonly
259
+ */
260
+ totalPriceBeforeTax?: MultiCurrencyPrice;
261
+ /**
262
+ * Tax details for this line item.
263
+ * @readonly
264
+ */
265
+ taxDetails?: ItemTaxFullDetails;
266
+ /**
267
+ * Discount for this line item's entire quantity.
268
+ * @readonly
269
+ */
270
+ discount?: MultiCurrencyPrice;
271
+ /**
272
+ * Line item description lines. Used for display purposes for the cart, checkout and order.
273
+ * @readonly
274
+ */
275
+ descriptionLines?: DescriptionLine[];
276
+ /**
277
+ * Line item image details.
278
+ * @readonly
279
+ */
280
+ media?: CommonImage;
281
+ /**
282
+ * Item availability details.
283
+ * @readonly
284
+ */
285
+ availability?: ItemAvailabilityInfo;
286
+ /**
287
+ * Physical properties of the item. When relevant, contains information such as SKU, item weight, and shippability.
288
+ * @readonly
289
+ */
290
+ physicalProperties?: PhysicalProperties;
291
+ /**
292
+ * Item type. Either a preset type or custom.
293
+ * @readonly
294
+ */
295
+ itemType?: ItemType;
296
+ /**
297
+ * Subscription option information.
298
+ * @readonly
299
+ */
300
+ subscriptionOptionInfo?: SubscriptionOptionInfo;
301
+ /**
302
+ * Type of selected payment option for current item.
303
+ *
304
+ * Default: `FULL_PAYMENT_ONLINE`
305
+ * @readonly
306
+ */
307
+ paymentOption?: PaymentOptionTypeWithLiterals;
308
+ /**
309
+ * Service properties. When relevant, this contains information such as date and number of participants.
310
+ * @readonly
311
+ */
312
+ serviceProperties?: ServiceProperties;
313
+ /**
314
+ * In cases where `catalogReference.catalogItemId` is NOT the actual catalog item ID, this field will return the true item's ID.
315
+ * + For example, for Wix Bookings, `catalogReference.catalogItemId` is the booking ID. Therefore this value is set to the service ID.
316
+ * + In most cases, this field has the same value as `catalogReference.catalogItemId`.
317
+ * + Used in membership validation.
318
+ * @minLength 1
319
+ * @maxLength 36
320
+ * @readonly
321
+ */
322
+ rootCatalogItemId?: string | null;
323
+ /**
324
+ * Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67".
325
+ * @readonly
326
+ */
327
+ priceDescription?: PriceDescription;
328
+ /**
329
+ * Partial payment to be paid upfront during the checkout. Eligible for catalog items with `lineItem.paymentOption` type `DEPOSIT_ONLINE` only.
330
+ * @readonly
331
+ */
332
+ depositAmount?: MultiCurrencyPrice;
333
+ /**
334
+ * Delivery profile ID.
335
+ * @format GUID
336
+ * @readonly
337
+ */
338
+ deliveryProfileId?: string | null;
339
+ /**
340
+ * Whether the line item is a custom line item. Custom line items don't trigger the Catalog service plugin.
341
+ * @readonly
342
+ */
343
+ customLineItem?: boolean;
344
+ /**
345
+ * Item payment policy that requires customer consent to complete purchase. The payment policy will be displayed on the checkout page.
346
+ * @minLength 1
347
+ * @maxLength 2500
348
+ * @readonly
349
+ */
350
+ consentRequiredPaymentPolicy?: string | null;
351
+ /**
352
+ * Overriding values for catalog item properties.
353
+ *
354
+ * To override catalog fields, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
355
+ * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
356
+ */
357
+ catalogOverrideFields?: CatalogOverrideFields;
358
+ /**
359
+ * Whether the price is not yet defined, and will be updated after the order is created.
360
+ * @readonly
361
+ */
362
+ priceUndetermined?: boolean;
363
+ /**
364
+ * Whether the line item quantity is fixed and cannot be changed.
365
+ * @readonly
366
+ */
367
+ fixedQuantity?: boolean;
368
+ /**
369
+ * Whether to save the payment method on the order.
370
+ *
371
+ * Default: `false`
372
+ * @readonly
373
+ */
374
+ savePaymentMethod?: boolean;
375
+ /** Address to use for tax calculation purposes. */
376
+ taxableAddress?: TaxableAddress;
377
+ /**
378
+ * Policies to be displayed to the customer on the checkout page.
379
+ * @readonly
380
+ * @maxSize 5
381
+ */
382
+ policies?: Policy[];
383
+ /**
384
+ * Whether the item can only be purchased by site members.
385
+ *
386
+ * Default: `false`
387
+ * @readonly
388
+ */
389
+ membersOnly?: boolean;
390
+ /**
391
+ * Modifier groups that were added to the item.
392
+ * @readonly
393
+ * @maxSize 25
394
+ */
395
+ modifierGroups?: ModifierGroup[];
396
+ /**
397
+ * Total price of all item modifiers. Included in the item price.
398
+ * @readonly
399
+ */
400
+ modifiersTotalPrice?: MultiCurrencyPrice;
401
+ }
402
+ /** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */
403
+ interface CatalogReference {
404
+ /**
405
+ * ID of the item within the catalog it belongs to.
406
+ * @minLength 1
407
+ * @maxLength 36
408
+ */
409
+ catalogItemId?: string;
410
+ /**
411
+ * ID of the app providing the catalog.
412
+ *
413
+ * You can get your app's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).
414
+ *
415
+ * For items from Wix catalogs, the following values always apply:
416
+ * + Wix Stores: `"215238eb-22a5-4c36-9e7b-e7c08025e04e"`
417
+ * + Wix Bookings: `"13d21c63-b5ec-5912-8397-c3a5ddb27a97"`
418
+ * + Wix Restaurants: `"9a5d83fd-8570-482e-81ab-cfa88942ee60"`
419
+ * @minLength 1
420
+ */
421
+ appId?: string;
422
+ /**
423
+ * 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.
424
+ *
425
+ * 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)).
426
+ */
427
+ options?: Record<string, any> | null;
428
+ }
429
+ interface ProductName {
430
+ /**
431
+ * __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).
432
+ *
433
+ * Min: 1 character.
434
+ * Max: 200 characters.
435
+ * @minLength 1
436
+ * @maxLength 200
437
+ */
438
+ original?: string;
439
+ /**
440
+ * Item name translated into the buyer's language.
441
+ *
442
+ * Min: 1 character.
443
+ * Max: 400 characters.
444
+ * Default: Same as `original`.
445
+ * @minLength 1
446
+ * @maxLength 400
447
+ */
448
+ translated?: string | null;
449
+ }
450
+ interface PageUrlV2 {
451
+ /** The relative path for the page within the site. For example, `/product-page/a-product`. */
452
+ relativePath?: string;
453
+ /** The page's full URL. For example, `https://mysite.com/product-page/a-product`. */
454
+ url?: string | null;
455
+ }
456
+ interface MultiCurrencyPrice {
457
+ /**
458
+ * Amount.
459
+ * @decimalValue options { gte:0, lte:1000000000000000 }
460
+ */
461
+ amount?: string;
462
+ /**
463
+ * Converted amount.
464
+ * @readonly
465
+ * @decimalValue options { gte:0, lte:1000000000000000 }
466
+ */
467
+ convertedAmount?: string;
468
+ /**
469
+ * Amount formatted with currency symbol.
470
+ * @readonly
471
+ */
472
+ formattedAmount?: string;
473
+ /**
474
+ * Converted amount formatted with currency symbol.
475
+ * @readonly
476
+ */
477
+ formattedConvertedAmount?: string;
478
+ }
479
+ interface ItemTaxFullDetails {
480
+ /** Amount for which tax is calculated. */
481
+ taxableAmount?: MultiCurrencyPrice;
482
+ /**
483
+ * Tax rate %, as a decimal point between 0 and 1.
484
+ * @decimalValue options { gte:0, lte:1, maxScale:6 }
485
+ */
486
+ taxRate?: string;
487
+ /** Calculated tax, based on `taxable_amount` and `tax_rate`. */
488
+ totalTax?: MultiCurrencyPrice;
489
+ /**
490
+ * If breakdown exists, the sum of rates in the breakdown must equal `tax_rate`. Deprecated - use 'tax_breakdown' instead.
491
+ * @readonly
492
+ * @deprecated
493
+ */
494
+ rateBreakdown?: TaxRateBreakdown[];
495
+ }
496
+ interface TaxRateBreakdown {
497
+ /**
498
+ * Name of tax against which the calculation was performed.
499
+ * @maxLength 100
500
+ */
501
+ name?: string;
502
+ /**
503
+ * Rate at which this tax detail was calculated.
504
+ * @decimalValue options { gte:0, lte:1, maxScale:6 }
505
+ */
506
+ rate?: string;
507
+ /** Amount of tax for this tax detail. */
508
+ tax?: MultiCurrencyPrice;
509
+ }
510
+ interface DescriptionLine extends DescriptionLineValueOneOf, DescriptionLineDescriptionLineValueOneOf {
511
+ /** Description line plain text value. */
512
+ plainText?: PlainTextValue;
513
+ /** Description line color value. */
514
+ colorInfo?: Color;
515
+ /** Description line name. */
516
+ name?: DescriptionLineName;
517
+ }
518
+ /** @oneof */
519
+ interface DescriptionLineValueOneOf {
520
+ /** Description line plain text value. */
521
+ plainText?: PlainTextValue;
522
+ /** Description line color value. */
523
+ colorInfo?: Color;
524
+ }
525
+ /** @oneof */
526
+ interface DescriptionLineDescriptionLineValueOneOf {
527
+ }
528
+ interface DescriptionLineName {
529
+ /**
530
+ * 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).
531
+ * @maxLength 100
532
+ */
533
+ original?: string;
534
+ /**
535
+ * Description line name translated into the buyer's language.
536
+ *
537
+ * Default: Same as `original`.
538
+ * @maxLength 200
539
+ */
540
+ translated?: string | null;
541
+ }
542
+ interface PlainTextValue {
543
+ /**
544
+ * 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).
545
+ * @maxLength 600
546
+ */
547
+ original?: string;
548
+ /**
549
+ * Description line plain text value translated into the buyer's language.
550
+ *
551
+ * Default: Same as `original`.
552
+ * @maxLength 600
553
+ */
554
+ translated?: string | null;
555
+ }
556
+ interface Color {
557
+ /**
558
+ * 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).
559
+ * @maxLength 500
560
+ */
561
+ original?: string;
562
+ /**
563
+ * Description line color name translated into the buyer's language.
564
+ *
565
+ * Default: Same as `original`.
566
+ * @maxLength 500
567
+ */
568
+ translated?: string | null;
569
+ /** HEX or RGB color code for display. */
570
+ code?: string | null;
571
+ }
572
+ interface CommonImage {
573
+ /** WixMedia image ID. */
574
+ id?: string;
575
+ /** Image URL. */
576
+ url?: string;
577
+ /**
578
+ * Original image height.
579
+ * @readonly
580
+ */
581
+ height?: number;
582
+ /**
583
+ * Original image width.
584
+ * @readonly
585
+ */
586
+ width?: number;
587
+ /** Image alt text. */
588
+ altText?: string | null;
589
+ /**
590
+ * Image filename.
591
+ * @readonly
592
+ */
593
+ filename?: string | null;
594
+ }
595
+ interface ItemAvailabilityInfo {
596
+ /** Item availability status. */
597
+ status?: ItemAvailabilityStatusWithLiterals;
598
+ /** Quantity available. */
599
+ quantityAvailable?: number | null;
600
+ }
601
+ declare enum ItemAvailabilityStatus {
602
+ AVAILABLE = "AVAILABLE",
603
+ /** Item does not exist. */
604
+ NOT_FOUND = "NOT_FOUND",
605
+ /** Item is not in stock. */
606
+ NOT_AVAILABLE = "NOT_AVAILABLE",
607
+ /** Available quantity is less than requested. */
608
+ PARTIALLY_AVAILABLE = "PARTIALLY_AVAILABLE"
609
+ }
610
+ /** @enumType */
611
+ type ItemAvailabilityStatusWithLiterals = ItemAvailabilityStatus | 'AVAILABLE' | 'NOT_FOUND' | 'NOT_AVAILABLE' | 'PARTIALLY_AVAILABLE';
612
+ interface PhysicalProperties {
613
+ /** Line item weight. Measurement unit matches the weight unit specified in `weightUnit` in the request. */
614
+ weight?: number | null;
615
+ /**
616
+ * Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku).
617
+ * @maxLength 40
618
+ */
619
+ sku?: string | null;
620
+ /** Whether this line item is shippable. */
621
+ shippable?: boolean;
622
+ }
623
+ interface ItemType extends ItemTypeItemTypeDataOneOf {
624
+ /** Preset item type. */
625
+ preset?: ItemTypeItemTypeWithLiterals;
626
+ /** Custom item type. When none of the preset types are suitable, specifies the custom type. */
627
+ custom?: string;
628
+ }
629
+ /** @oneof */
630
+ interface ItemTypeItemTypeDataOneOf {
631
+ /** Preset item type. */
632
+ preset?: ItemTypeItemTypeWithLiterals;
633
+ /** Custom item type. When none of the preset types are suitable, specifies the custom type. */
634
+ custom?: string;
635
+ }
636
+ declare enum ItemTypeItemType {
637
+ UNRECOGNISED = "UNRECOGNISED",
638
+ PHYSICAL = "PHYSICAL",
639
+ DIGITAL = "DIGITAL",
640
+ GIFT_CARD = "GIFT_CARD",
641
+ SERVICE = "SERVICE"
642
+ }
643
+ /** @enumType */
644
+ type ItemTypeItemTypeWithLiterals = ItemTypeItemType | 'UNRECOGNISED' | 'PHYSICAL' | 'DIGITAL' | 'GIFT_CARD' | 'SERVICE';
645
+ interface SubscriptionOptionInfo {
646
+ /** Subscription option settings. */
647
+ subscriptionSettings?: SubscriptionSettings;
648
+ /** Subscription option title. */
649
+ title?: Title;
650
+ /** Subscription option description. */
651
+ description?: Description;
652
+ }
653
+ interface SubscriptionSettings {
654
+ /** Frequency of recurring payment. */
655
+ frequency?: SubscriptionFrequencyWithLiterals;
656
+ /**
657
+ * Interval of recurring payment.
658
+ *
659
+ * Default: `1`.
660
+ * If SubscriptionFrequency is Day the minimum interval is 7
661
+ * @min 1
662
+ * @max 50
663
+ */
664
+ interval?: number | null;
665
+ /** Whether subscription is renewed automatically at the end of each period. */
666
+ autoRenewal?: boolean;
667
+ /**
668
+ * Number of billing cycles before subscription ends. Ignored if `autoRenewal` is `true`.
669
+ * @min 1
670
+ */
671
+ billingCycles?: number | null;
672
+ /** Whether to allow the customer to cancel the subscription.. */
673
+ enableCustomerCancellation?: boolean;
674
+ /**
675
+ * Period until first cycle starts. If applied payNow will be 0
676
+ * If None => no free trial
677
+ */
678
+ freeTrialPeriod?: FreeTrialPeriod;
679
+ }
680
+ /** Frequency unit of recurring payment */
681
+ declare enum SubscriptionFrequency {
682
+ UNDEFINED = "UNDEFINED",
683
+ DAY = "DAY",
684
+ WEEK = "WEEK",
685
+ MONTH = "MONTH",
686
+ YEAR = "YEAR"
687
+ }
688
+ /** @enumType */
689
+ type SubscriptionFrequencyWithLiterals = SubscriptionFrequency | 'UNDEFINED' | 'DAY' | 'WEEK' | 'MONTH' | 'YEAR';
690
+ interface FreeTrialPeriod {
691
+ /** Frequency of period. Values: DAY, WEEK, MONTH, YEAR */
692
+ frequency?: SubscriptionFrequencyWithLiterals;
693
+ /**
694
+ * interval of period
695
+ * @min 1
696
+ * @max 999
697
+ */
698
+ interval?: number;
699
+ }
700
+ interface Title {
701
+ /**
702
+ * 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).
703
+ * @minLength 1
704
+ * @maxLength 150
705
+ */
706
+ original?: string;
707
+ /**
708
+ * Subscription option name translated into the buyer's language.
709
+ *
710
+ * Default: Same as `original`.
711
+ * @minLength 1
712
+ * @maxLength 150
713
+ */
714
+ translated?: string | null;
715
+ }
716
+ interface Description {
717
+ /**
718
+ * Subscription option description.
719
+ * @maxLength 500
720
+ */
721
+ original?: string;
722
+ /**
723
+ * Translated subscription option description.
724
+ * @maxLength 500
725
+ */
726
+ translated?: string | null;
727
+ }
728
+ /** Type of selected payment option for catalog item */
729
+ declare enum PaymentOptionType {
730
+ /** The entire payment for this item happens as part of the checkout. */
731
+ FULL_PAYMENT_ONLINE = "FULL_PAYMENT_ONLINE",
732
+ /** The entire payment for this item happens after checkout. For example, when using cash, check, or other offline payment methods. */
733
+ FULL_PAYMENT_OFFLINE = "FULL_PAYMENT_OFFLINE",
734
+ /** Payment for this item is done by charging a membership. When selected, `price` is `0`. */
735
+ MEMBERSHIP = "MEMBERSHIP",
736
+ /** Partial payment to be paid upfront during checkout. The initial amount to be paid for each line item is specified in `depositAmount`. */
737
+ DEPOSIT_ONLINE = "DEPOSIT_ONLINE",
738
+ /** 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`. */
739
+ MEMBERSHIP_OFFLINE = "MEMBERSHIP_OFFLINE"
740
+ }
741
+ /** @enumType */
742
+ type PaymentOptionTypeWithLiterals = PaymentOptionType | 'FULL_PAYMENT_ONLINE' | 'FULL_PAYMENT_OFFLINE' | 'MEMBERSHIP' | 'DEPOSIT_ONLINE' | 'MEMBERSHIP_OFFLINE';
743
+ interface ServiceProperties {
744
+ /**
745
+ * 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.
746
+ * For example, the start time of a class.
747
+ */
748
+ scheduledDate?: Date | null;
749
+ /**
750
+ * The number of people participating in the service. For example, the number of people attending a class or the number of people per hotel room.
751
+ * @min 1
752
+ * @max 10000
753
+ */
754
+ numberOfParticipants?: number | null;
755
+ }
756
+ interface PriceDescription {
757
+ /**
758
+ * __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).
759
+ * @minLength 1
760
+ * @maxLength 100
761
+ */
762
+ original?: string;
763
+ /**
764
+ * Price description translated into the buyer's language.
765
+ *
766
+ * Default: Same as `original`.
767
+ * @minLength 1
768
+ * @maxLength 100
769
+ */
770
+ translated?: string | null;
771
+ }
772
+ interface CatalogOverrideFields {
773
+ /** Item name. */
774
+ productName?: ProductName;
775
+ /**
776
+ * Item price **after** discounts.
777
+ * @decimalValue options { gte:0, lte:999999999, maxScale:3 }
778
+ */
779
+ price?: string | null;
780
+ /**
781
+ * Item price **before** discounts.
782
+ * @decimalValue options { gte:0, lte:999999999, maxScale:3 }
783
+ */
784
+ fullPrice?: string | null;
785
+ /**
786
+ * Item description lines. Used when displaying the line item to customers.
787
+ * @maxSize 20
788
+ */
789
+ descriptionLines?: DescriptionLine[];
790
+ /** Physical properties of the item. */
791
+ physicalProperties?: PhysicalProperties;
792
+ /** Item image. */
793
+ image?: Image;
794
+ /** Payment method selected for the item. */
795
+ paymentOption?: PaymentOption;
796
+ /**
797
+ * Only eligible for catalog items with `lineItem.paymentOption.value` type of `DEPOSIT_ONLINE`.
798
+ * @format DECIMAL_VALUE
799
+ * @decimalValue options { gt:0, lte:999999999, maxScale:3 }
800
+ */
801
+ depositAmount?: string | null;
802
+ /**
803
+ * Whether to save the payment method on the order.
804
+ *
805
+ * Default: `false`
806
+ */
807
+ savePaymentMethod?: boolean | null;
808
+ }
809
+ interface Image {
810
+ /** WixMedia image ID. */
811
+ id?: string;
812
+ /** Original image height. */
813
+ height?: number;
814
+ /** Original image width. */
815
+ width?: number;
816
+ /** Image alt text. Optional. */
817
+ altText?: string | null;
818
+ /** Image filename. Optional. */
819
+ filename?: string | null;
820
+ }
821
+ interface PaymentOption {
822
+ /**
823
+ * Type of selected payment option for current item.
824
+ *
825
+ * Default: `FULL_PAYMENT_ONLINE`
826
+ */
827
+ value?: PaymentOptionTypeWithLiterals;
828
+ }
829
+ interface TaxableAddress extends TaxableAddressTaxableAddressDataOneOf {
830
+ /** taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. */
831
+ addressType?: TaxableAddressTypeWithLiterals;
832
+ }
833
+ /** @oneof */
834
+ interface TaxableAddressTaxableAddressDataOneOf {
835
+ /** taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. */
836
+ addressType?: TaxableAddressTypeWithLiterals;
837
+ }
838
+ declare enum TaxableAddressType {
839
+ UNKNOWN_TAXABLE_ADDRESS = "UNKNOWN_TAXABLE_ADDRESS",
840
+ BUSINESS = "BUSINESS",
841
+ BILLING = "BILLING",
842
+ SHIPPING = "SHIPPING"
843
+ }
844
+ /** @enumType */
845
+ type TaxableAddressTypeWithLiterals = TaxableAddressType | 'UNKNOWN_TAXABLE_ADDRESS' | 'BUSINESS' | 'BILLING' | 'SHIPPING';
846
+ interface ExtendedFields {
847
+ /**
848
+ * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.
849
+ * The value of each key is structured according to the schema defined when the extended fields were configured.
850
+ *
851
+ * You can only access fields for which you have the appropriate permissions.
852
+ *
853
+ * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).
854
+ */
855
+ namespaces?: Record<string, Record<string, any>>;
856
+ }
857
+ interface Policy {
858
+ /**
859
+ * Policy title - should be translated
860
+ * @minLength 1
861
+ * @maxLength 29
862
+ */
863
+ title?: string | null;
864
+ /**
865
+ * Policy content - should be translated
866
+ * @minLength 1
867
+ * @maxLength 3000
868
+ */
869
+ content?: string;
870
+ }
871
+ interface ModifierGroup {
872
+ /**
873
+ * Modifier group id.
874
+ * @minLength 1
875
+ * @maxLength 36
876
+ */
877
+ id?: string;
878
+ /** Modifier group name. */
879
+ name?: TranslatableString;
880
+ /**
881
+ * List of modifiers in this group.
882
+ * @minSize 1
883
+ * @maxSize 25
884
+ */
885
+ modifiers?: ItemModifier[];
886
+ }
887
+ interface TranslatableString {
888
+ /**
889
+ * __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).
890
+ *
891
+ * Min: 1 character.
892
+ * Max: 200 characters.
893
+ * @minLength 1
894
+ * @maxLength 200
895
+ */
896
+ original?: string;
897
+ /**
898
+ * String translated into the buyer's language.
899
+ *
900
+ * Min: 1 character.
901
+ * Max: 400 characters.
902
+ * Default: Same as `original`.
903
+ * @minLength 1
904
+ * @maxLength 400
905
+ */
906
+ translated?: string | null;
907
+ }
908
+ interface ItemModifier {
909
+ /**
910
+ * Modifier ID.
911
+ * @minLength 1
912
+ * @maxLength 36
913
+ */
914
+ id?: string;
915
+ /**
916
+ * The quantity of this modifier.
917
+ * @min 1
918
+ * @max 100000
919
+ */
920
+ quantity?: number | null;
921
+ /** Primary display label for the modifier. */
922
+ label?: TranslatableString;
923
+ /** Optional additional details or clarification for the modifier. */
924
+ details?: TranslatableString;
925
+ /** The price of the modifier. */
926
+ price?: MultiCurrencyPrice;
927
+ }
928
+ /** Billing Info and shipping details */
929
+ interface AddressWithContact {
930
+ /** Address. */
931
+ address?: ApiAddress;
932
+ /** Contact details. */
933
+ contactDetails?: FullAddressContactDetails;
934
+ }
935
+ /** Physical address */
936
+ interface ApiAddress {
937
+ /**
938
+ * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format.
939
+ * @format COUNTRY
940
+ */
941
+ country?: string | null;
942
+ /**
943
+ * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format.
944
+ * @maxLength 50
945
+ */
946
+ subdivision?: string | null;
947
+ /**
948
+ * City name.
949
+ * @maxLength 50
950
+ */
951
+ city?: string | null;
952
+ /**
953
+ * Postal or zip code.
954
+ * @maxLength 50
955
+ */
956
+ postalCode?: string | null;
957
+ /** Street address. */
958
+ streetAddress?: StreetAddress;
959
+ /**
960
+ * Main address line (usually street name and number).
961
+ * @maxLength 150
962
+ */
963
+ addressLine?: string | null;
964
+ /**
965
+ * Free text providing more detailed address info. Usually contains apt, suite, floor.
966
+ * @maxLength 100
967
+ */
968
+ addressLine2?: string | null;
969
+ /**
970
+ * Country's full name.
971
+ * @readonly
972
+ */
973
+ countryFullname?: string | null;
974
+ /**
975
+ * Subdivision full-name.
976
+ * @readonly
977
+ */
978
+ subdivisionFullname?: string | null;
979
+ }
980
+ interface StreetAddress {
981
+ /** Street number. */
982
+ number?: string;
983
+ /** Street name. */
984
+ name?: string;
985
+ }
986
+ /** Full contact details for an address */
987
+ interface FullAddressContactDetails {
988
+ /**
989
+ * First name.
990
+ * @maxLength 100
991
+ */
992
+ firstName?: string | null;
993
+ /**
994
+ * Last name.
995
+ * @maxLength 100
996
+ */
997
+ lastName?: string | null;
998
+ /**
999
+ * Phone number.
1000
+ * @format PHONE
1001
+ */
1002
+ phone?: string | null;
1003
+ /**
1004
+ * Company name.
1005
+ * @maxLength 1000
1006
+ */
1007
+ company?: string | null;
1008
+ /** Tax information (for Brazil only). If ID is provided, `vatId.type` must also be set, `UNSPECIFIED` is not allowed. */
1009
+ vatId?: CommonVatId;
1010
+ }
1011
+ interface CommonVatId {
1012
+ /** Customer's tax ID. */
1013
+ id?: string;
1014
+ /**
1015
+ * Tax type.
1016
+ *
1017
+ * Supported values:
1018
+ * + `CPF`: for individual tax payers
1019
+ * + `CNPJ`: for corporations
1020
+ */
1021
+ type?: CommonVatTypeWithLiterals;
1022
+ }
1023
+ /** tax info types */
1024
+ declare enum CommonVatType {
1025
+ UNSPECIFIED = "UNSPECIFIED",
1026
+ /** CPF - for individual tax payers. */
1027
+ CPF = "CPF",
1028
+ /** CNPJ - for corporations */
1029
+ CNPJ = "CNPJ"
1030
+ }
1031
+ /** @enumType */
1032
+ type CommonVatTypeWithLiterals = CommonVatType | 'UNSPECIFIED' | 'CPF' | 'CNPJ';
1033
+ interface ShippingInfo {
1034
+ /** Shipping address and contact details. */
1035
+ shippingDestination?: AddressWithContact;
1036
+ /** Selected option out of the options allowed for the `region`. */
1037
+ selectedCarrierServiceOption?: SelectedCarrierServiceOption;
1038
+ /**
1039
+ * Shipping region. Based on the address provided.
1040
+ * @readonly
1041
+ */
1042
+ region?: ShippingRegion;
1043
+ /**
1044
+ * All carrier options for this shipping rule.
1045
+ * @readonly
1046
+ */
1047
+ carrierServiceOptions?: CarrierServiceOption[];
1048
+ }
1049
+ interface SelectedCarrierServiceOption {
1050
+ /**
1051
+ * Unique identifier of selected option. For example, "usps_std_overnight".
1052
+ * @maxLength 100
1053
+ */
1054
+ code?: string;
1055
+ /**
1056
+ * Title of the option, such as USPS Standard Overnight Delivery (in the requested locale).
1057
+ * For example, "Standard" or "First-Class Package International".
1058
+ * @maxLength 250
1059
+ * @readonly
1060
+ */
1061
+ title?: string;
1062
+ /**
1063
+ * Delivery logistics.
1064
+ * @readonly
1065
+ */
1066
+ logistics?: DeliveryLogistics;
1067
+ /**
1068
+ * Shipping costs.
1069
+ * @readonly
1070
+ */
1071
+ cost?: SelectedCarrierServiceOptionPrices;
1072
+ /**
1073
+ * Were we able to find the requested shipping option, or otherwise we fallback to the default one (the first)
1074
+ * @readonly
1075
+ */
1076
+ requestedShippingOption?: boolean;
1077
+ /**
1078
+ * Other charges
1079
+ * @deprecated Other charges
1080
+ * @replacedBy additional_fees
1081
+ * @targetRemovalDate 2025-10-01
1082
+ */
1083
+ otherCharges?: SelectedCarrierServiceOptionOtherCharge[];
1084
+ /**
1085
+ * This carrier's unique ID
1086
+ * @format GUID
1087
+ */
1088
+ carrierId?: string | null;
1089
+ /**
1090
+ * Delivery solution allocations to different delivery carriers and delivery regions
1091
+ * @maxSize 300
1092
+ */
1093
+ deliveryAllocations?: DeliveryAllocation[];
1094
+ /** If the delivery solution is a partial and doesn't apply to all items. */
1095
+ partial?: boolean | null;
1096
+ }
1097
+ interface DeliveryLogistics {
1098
+ /**
1099
+ * Expected delivery time, in free text. For example, "3-5 business days".
1100
+ * @maxLength 500
1101
+ */
1102
+ deliveryTime?: string | null;
1103
+ /**
1104
+ * Instructions for caller, e.g for pickup: "Please deliver during opening hours, and please don't park in disabled parking spot".
1105
+ * @maxLength 1000
1106
+ */
1107
+ instructions?: string | null;
1108
+ /** Pickup details. */
1109
+ pickupDetails?: PickupDetails;
1110
+ }
1111
+ interface PickupDetails {
1112
+ /** Pickup address. */
1113
+ address?: ApiAddress;
1114
+ /**
1115
+ * Whether the pickup address is that of a business - this may effect tax calculation.
1116
+ * @deprecated
1117
+ */
1118
+ businessLocation?: boolean;
1119
+ /** Pickup method */
1120
+ pickupMethod?: PickupMethodWithLiterals;
1121
+ }
1122
+ declare enum PickupMethod {
1123
+ UNKNOWN_METHOD = "UNKNOWN_METHOD",
1124
+ STORE_PICKUP = "STORE_PICKUP",
1125
+ PICKUP_POINT = "PICKUP_POINT"
1126
+ }
1127
+ /** @enumType */
1128
+ type PickupMethodWithLiterals = PickupMethod | 'UNKNOWN_METHOD' | 'STORE_PICKUP' | 'PICKUP_POINT';
1129
+ interface SelectedCarrierServiceOptionPrices {
1130
+ /** Total shipping price, after discount and after tax. */
1131
+ totalPriceAfterTax?: MultiCurrencyPrice;
1132
+ /** Total price of shipping after discounts (when relevant), and before tax. */
1133
+ totalPriceBeforeTax?: MultiCurrencyPrice;
1134
+ /** Tax details. */
1135
+ taxDetails?: ItemTaxFullDetails;
1136
+ /** Shipping discount before tax. */
1137
+ totalDiscount?: MultiCurrencyPrice;
1138
+ /** Shipping price before discount and before tax. */
1139
+ price?: MultiCurrencyPrice;
1140
+ }
1141
+ interface SelectedCarrierServiceOptionOtherCharge {
1142
+ /** Type of additional cost. */
1143
+ type?: ChargeTypeWithLiterals;
1144
+ /**
1145
+ * Details of the charge, such as 'Full Coverage Insurance of up to 80% of value of shipment'.
1146
+ * @maxLength 200
1147
+ */
1148
+ details?: string | null;
1149
+ /** Price of added charge. */
1150
+ cost?: SelectedCarrierServiceOptionPrices;
1151
+ }
1152
+ declare enum ChargeType {
1153
+ HANDLING_FEE = "HANDLING_FEE",
1154
+ INSURANCE = "INSURANCE"
1155
+ }
1156
+ /** @enumType */
1157
+ type ChargeTypeWithLiterals = ChargeType | 'HANDLING_FEE' | 'INSURANCE';
1158
+ interface DeliveryAllocation {
1159
+ /** The delivery option's carrier details, could be multiple if the delivery option is a combination of multiple carriers */
1160
+ deliveryCarrier?: Carrier;
1161
+ /** The delivery region that are relevant for this delivery solution. */
1162
+ deliveryRegion?: Region;
1163
+ /** Populated if the delivery solution is a partially supplied by this carrier. */
1164
+ applicableLineItems?: ApplicableLineItems;
1165
+ }
1166
+ interface Carrier {
1167
+ /**
1168
+ * The carrier app id
1169
+ * @format GUID
1170
+ */
1171
+ appId?: string | null;
1172
+ /**
1173
+ * Unique code that acts as an ID for a shipping rate. For example, `"usps_std_overnight"`.
1174
+ * @maxLength 250
1175
+ */
1176
+ code?: string;
1177
+ }
1178
+ interface Region {
1179
+ /**
1180
+ * The delivery region id.
1181
+ * @format GUID
1182
+ */
1183
+ id?: string | null;
1184
+ /**
1185
+ * The delivery region name.
1186
+ * @maxLength 100
1187
+ */
1188
+ name?: string | null;
1189
+ }
1190
+ interface ApplicableLineItems {
1191
+ /**
1192
+ * Line items that the delivery solution is for.
1193
+ * @maxSize 300
1194
+ * @minLength 1
1195
+ * @maxLength 100
1196
+ */
1197
+ lineItemIds?: string[];
1198
+ }
1199
+ interface ShippingRegion {
1200
+ /**
1201
+ * Shipping region ID.
1202
+ * @format GUID
1203
+ * @readonly
1204
+ */
1205
+ id?: string;
1206
+ /**
1207
+ * Shipping region name.
1208
+ * @maxLength 100
1209
+ */
1210
+ name?: string;
1211
+ }
1212
+ interface CarrierServiceOption {
1213
+ /**
1214
+ * Carrier ID.
1215
+ * @format GUID
1216
+ */
1217
+ carrierId?: string;
1218
+ /** Shipping options offered by this carrier for this request. */
1219
+ shippingOptions?: ShippingOption[];
1220
+ }
1221
+ interface ShippingOption {
1222
+ /**
1223
+ * Unique code of provided shipping option like "usps_std_overnight".
1224
+ * For legacy calculators this would be the UUID of the option.
1225
+ * @maxLength 100
1226
+ */
1227
+ code?: string;
1228
+ /**
1229
+ * Title of the option, such as USPS Standard Overnight Delivery (in the requested locale).
1230
+ * For example, "Standard" or "First-Class Package International".
1231
+ * @maxLength 250
1232
+ */
1233
+ title?: string;
1234
+ /** Delivery logistics. */
1235
+ logistics?: DeliveryLogistics;
1236
+ /** Sipping price information. */
1237
+ cost?: ShippingPrice;
1238
+ /**
1239
+ * Delivery solution allocations to different delivery carriers and delivery regions
1240
+ * @maxSize 300
1241
+ */
1242
+ deliveryAllocations?: DeliveryAllocation[];
1243
+ /** If the delivery solution is a partial and doesn't apply to all items. */
1244
+ partial?: boolean | null;
1245
+ }
1246
+ interface ShippingPrice {
1247
+ /** Shipping price. */
1248
+ price?: MultiCurrencyPrice;
1249
+ /** Other costs such as insurance, handling & packaging for fragile items, etc. */
1250
+ otherCharges?: OtherCharge[];
1251
+ }
1252
+ interface OtherCharge {
1253
+ /** Type of additional cost. */
1254
+ type?: ChargeTypeWithLiterals;
1255
+ /** Price of added cost. */
1256
+ price?: MultiCurrencyPrice;
1257
+ /**
1258
+ * Description of the additional charge. For example, `"Handling fee of $5 applied for gift wrapping"`.
1259
+ * @maxLength 250
1260
+ */
1261
+ details?: string | null;
1262
+ }
1263
+ interface BuyerInfo extends BuyerInfoIdOneOf {
1264
+ /**
1265
+ * Visitor ID (if site visitor is **not** a member).
1266
+ * @format GUID
1267
+ * @readonly
1268
+ */
1269
+ visitorId?: string;
1270
+ /**
1271
+ * Member ID (if site visitor is a site member).
1272
+ * @format GUID
1273
+ * @readonly
1274
+ */
1275
+ memberId?: string;
1276
+ /**
1277
+ * Contact ID. Auto-created if one does not yet exist. For more information, see the Contacts API.
1278
+ * @format GUID
1279
+ * @readonly
1280
+ */
1281
+ contactId?: string | null;
1282
+ /**
1283
+ * Buyer email address.
1284
+ * @format EMAIL
1285
+ */
1286
+ email?: string | null;
1287
+ }
1288
+ /** @oneof */
1289
+ interface BuyerInfoIdOneOf {
1290
+ /**
1291
+ * Visitor ID (if site visitor is **not** a member).
1292
+ * @format GUID
1293
+ * @readonly
1294
+ */
1295
+ visitorId?: string;
1296
+ /**
1297
+ * Member ID (if site visitor is a site member).
1298
+ * @format GUID
1299
+ * @readonly
1300
+ */
1301
+ memberId?: string;
1302
+ }
1303
+ interface PriceSummary {
1304
+ /** Subtotal of all line items, before discounts and before tax. */
1305
+ subtotal?: MultiCurrencyPrice;
1306
+ /** Total shipping price, before discounts and before tax. */
1307
+ shipping?: MultiCurrencyPrice;
1308
+ /** Total tax. */
1309
+ tax?: MultiCurrencyPrice;
1310
+ /** Total calculated discount value. */
1311
+ discount?: MultiCurrencyPrice;
1312
+ /** Total price after discounts, gift cards, and tax. */
1313
+ total?: MultiCurrencyPrice;
1314
+ /** Total additional fees price before tax. */
1315
+ additionalFees?: MultiCurrencyPrice;
1316
+ }
1317
+ interface CalculationErrors extends CalculationErrorsShippingCalculationErrorOneOf {
1318
+ /** General shipping calculation error. */
1319
+ generalShippingCalculationError?: Details;
1320
+ /** Carrier errors. */
1321
+ carrierErrors?: CarrierErrors;
1322
+ /** Tax calculation error. */
1323
+ taxCalculationError?: Details;
1324
+ /** Coupon calculation error. */
1325
+ couponCalculationError?: Details;
1326
+ /** Gift card calculation error. */
1327
+ giftCardCalculationError?: Details;
1328
+ /** Order validation errors. */
1329
+ orderValidationErrors?: ApplicationError[];
1330
+ /**
1331
+ * Membership payment methods calculation errors
1332
+ * For example, will indicate that a line item that must be paid with membership payment doesn't have one or selected memberships are invalid
1333
+ */
1334
+ membershipError?: Details;
1335
+ /** Discount Rule calculation error. */
1336
+ discountsCalculationError?: Details;
1337
+ }
1338
+ /** @oneof */
1339
+ interface CalculationErrorsShippingCalculationErrorOneOf {
1340
+ /** General shipping calculation error. */
1341
+ generalShippingCalculationError?: Details;
1342
+ /** Carrier errors. */
1343
+ carrierErrors?: CarrierErrors;
1344
+ }
1345
+ interface Details extends DetailsKindOneOf {
1346
+ applicationError?: ApplicationError;
1347
+ validationError?: ValidationError;
1348
+ systemError?: SystemError;
1349
+ /**
1350
+ * deprecated in API's - to enable migration from rendering arbitrary tracing to rest response
1351
+ * @deprecated
1352
+ */
1353
+ tracing?: Record<string, string>;
1354
+ }
1355
+ /** @oneof */
1356
+ interface DetailsKindOneOf {
1357
+ applicationError?: ApplicationError;
1358
+ validationError?: ValidationError;
1359
+ systemError?: SystemError;
1360
+ }
1361
+ interface ApplicationError {
1362
+ /** Error code. */
1363
+ code?: string;
1364
+ /** Description of the error. */
1365
+ description?: string;
1366
+ /** Data related to the error. */
1367
+ data?: Record<string, any> | null;
1368
+ }
1369
+ /**
1370
+ * example result:
1371
+ * {
1372
+ * "fieldViolations": [
1373
+ * {
1374
+ * "field": "fieldA",
1375
+ * "description": "invalid music note. supported notes: [do,re,mi,fa,sol,la,ti]",
1376
+ * "violatedRule": "OTHER",
1377
+ * "ruleName": "INVALID_NOTE",
1378
+ * "data": {
1379
+ * "value": "FI"
1380
+ * }
1381
+ * },
1382
+ * {
1383
+ * "field": "fieldB",
1384
+ * "description": "field value out of range. supported range: [0-20]",
1385
+ * "violatedRule": "MAX",
1386
+ * "data": {
1387
+ * "threshold": 20
1388
+ * }
1389
+ * },
1390
+ * {
1391
+ * "field": "fieldC",
1392
+ * "description": "invalid phone number. provide a valid phone number of size: [7-12], supported characters: [0-9, +, -, (, )]",
1393
+ * "violatedRule": "FORMAT",
1394
+ * "data": {
1395
+ * "type": "PHONE"
1396
+ * }
1397
+ * }
1398
+ * ]
1399
+ * }
1400
+ */
1401
+ interface ValidationError {
1402
+ fieldViolations?: FieldViolation[];
1403
+ }
1404
+ declare enum RuleType {
1405
+ VALIDATION = "VALIDATION",
1406
+ OTHER = "OTHER",
1407
+ MAX = "MAX",
1408
+ MIN = "MIN",
1409
+ MAX_LENGTH = "MAX_LENGTH",
1410
+ MIN_LENGTH = "MIN_LENGTH",
1411
+ MAX_SIZE = "MAX_SIZE",
1412
+ MIN_SIZE = "MIN_SIZE",
1413
+ FORMAT = "FORMAT",
1414
+ DECIMAL_LTE = "DECIMAL_LTE",
1415
+ DECIMAL_GTE = "DECIMAL_GTE",
1416
+ DECIMAL_LT = "DECIMAL_LT",
1417
+ DECIMAL_GT = "DECIMAL_GT",
1418
+ DECIMAL_MAX_SCALE = "DECIMAL_MAX_SCALE",
1419
+ INVALID_ENUM_VALUE = "INVALID_ENUM_VALUE",
1420
+ REQUIRED_FIELD = "REQUIRED_FIELD",
1421
+ FIELD_NOT_ALLOWED = "FIELD_NOT_ALLOWED",
1422
+ ONE_OF_ALIGNMENT = "ONE_OF_ALIGNMENT",
1423
+ EXACT_LENGTH = "EXACT_LENGTH",
1424
+ EXACT_SIZE = "EXACT_SIZE",
1425
+ REQUIRED_ONE_OF_FIELD = "REQUIRED_ONE_OF_FIELD"
1426
+ }
1427
+ /** @enumType */
1428
+ type RuleTypeWithLiterals = RuleType | 'VALIDATION' | 'OTHER' | 'MAX' | 'MIN' | 'MAX_LENGTH' | 'MIN_LENGTH' | 'MAX_SIZE' | 'MIN_SIZE' | 'FORMAT' | 'DECIMAL_LTE' | 'DECIMAL_GTE' | 'DECIMAL_LT' | 'DECIMAL_GT' | 'DECIMAL_MAX_SCALE' | 'INVALID_ENUM_VALUE' | 'REQUIRED_FIELD' | 'FIELD_NOT_ALLOWED' | 'ONE_OF_ALIGNMENT' | 'EXACT_LENGTH' | 'EXACT_SIZE' | 'REQUIRED_ONE_OF_FIELD';
1429
+ interface FieldViolation {
1430
+ field?: string;
1431
+ description?: string;
1432
+ violatedRule?: RuleTypeWithLiterals;
1433
+ /** applicable when violated_rule=OTHER */
1434
+ ruleName?: string | null;
1435
+ data?: Record<string, any> | null;
1436
+ }
1437
+ interface SystemError {
1438
+ /** Error code. */
1439
+ errorCode?: string | null;
1440
+ }
1441
+ interface CarrierErrors {
1442
+ /** Carrier errors. */
1443
+ errors?: CarrierError[];
1444
+ }
1445
+ interface CarrierError {
1446
+ /** Carrier ID. */
1447
+ carrierId?: string;
1448
+ /** Error details. */
1449
+ error?: Details;
1450
+ }
1451
+ interface GiftCard {
1452
+ /**
1453
+ * Gift Card ID.
1454
+ * @deprecated
1455
+ */
1456
+ id?: string;
1457
+ /** Gift card obfuscated code. */
1458
+ obfuscatedCode?: string;
1459
+ /** Gift card value. */
1460
+ amount?: MultiCurrencyPrice;
1461
+ /**
1462
+ * App ID of the gift card provider.
1463
+ * @format GUID
1464
+ */
1465
+ appId?: string;
1466
+ /**
1467
+ * External ID in the gift card provider's system.
1468
+ * Used for integration and tracking across different platforms.
1469
+ * @minLength 1
1470
+ * @maxLength 50
1471
+ */
1472
+ externalId?: string | null;
1473
+ }
1474
+ interface AppliedDiscount extends AppliedDiscountDiscountSourceOneOf {
1475
+ /** Coupon details. */
1476
+ coupon?: Coupon;
1477
+ /** Merchant discount. */
1478
+ merchantDiscount?: MerchantDiscount;
1479
+ /** Discount rule */
1480
+ discountRule?: DiscountRule;
1481
+ /** Discount type. */
1482
+ discountType?: DiscountTypeWithLiterals;
1483
+ /**
1484
+ * IDs of line items the discount applies to.
1485
+ * @format GUID
1486
+ * @deprecated IDs of line items the discount applies to.
1487
+ * @replacedBy line_items_discounts
1488
+ * @targetRemovalDate 2024-06-01
1489
+ */
1490
+ lineItemIds?: string[];
1491
+ }
1492
+ /** @oneof */
1493
+ interface AppliedDiscountDiscountSourceOneOf {
1494
+ /** Coupon details. */
1495
+ coupon?: Coupon;
1496
+ /** Merchant discount. */
1497
+ merchantDiscount?: MerchantDiscount;
1498
+ /** Discount rule */
1499
+ discountRule?: DiscountRule;
1500
+ }
1501
+ declare enum DiscountType {
1502
+ GLOBAL = "GLOBAL",
1503
+ SPECIFIC_ITEMS = "SPECIFIC_ITEMS",
1504
+ SHIPPING = "SHIPPING"
1505
+ }
1506
+ /** @enumType */
1507
+ type DiscountTypeWithLiterals = DiscountType | 'GLOBAL' | 'SPECIFIC_ITEMS' | 'SHIPPING';
1508
+ /** Coupon */
1509
+ interface Coupon {
1510
+ /** Coupon ID. */
1511
+ id?: string;
1512
+ /** Coupon code. */
1513
+ code?: string;
1514
+ /** Coupon value. */
1515
+ amount?: MultiCurrencyPrice;
1516
+ /** Coupon name. */
1517
+ name?: string;
1518
+ }
1519
+ interface MerchantDiscount {
1520
+ /** Discount value. */
1521
+ amount?: MultiCurrencyPrice;
1522
+ /**
1523
+ * Discount Percentage. Will be calculated from items price before other discounts.
1524
+ * @min 1
1525
+ * @max 100
1526
+ */
1527
+ percentage?: number | null;
1528
+ }
1529
+ interface DiscountRule {
1530
+ /**
1531
+ * Discount rule ID
1532
+ * @format GUID
1533
+ */
1534
+ id?: string;
1535
+ /** Discount rule name */
1536
+ name?: DiscountRuleName;
1537
+ /** Discount value. */
1538
+ amount?: MultiCurrencyPrice;
1539
+ }
1540
+ interface DiscountRuleName {
1541
+ /**
1542
+ * Original discount rule name (in site's default language).
1543
+ * @minLength 1
1544
+ * @maxLength 256
1545
+ */
1546
+ original?: string;
1547
+ /**
1548
+ * Translated discount rule name according to buyer language. Defaults to `original` when not provided.
1549
+ * @minLength 1
1550
+ * @maxLength 500
1551
+ */
1552
+ translated?: string | null;
1553
+ }
1554
+ interface CustomField {
1555
+ /** Custom field value. */
1556
+ value?: any;
1557
+ /**
1558
+ * Custom field title.
1559
+ * @minLength 1
1560
+ * @maxLength 500
1561
+ */
1562
+ title?: string;
1563
+ /**
1564
+ * Translated custom field title.
1565
+ * @minLength 1
1566
+ * @maxLength 500
1567
+ */
1568
+ translatedTitle?: string | null;
1569
+ }
1570
+ declare enum WeightUnit {
1571
+ /** Weight unit can't be classified due to an error. */
1572
+ UNSPECIFIED_WEIGHT_UNIT = "UNSPECIFIED_WEIGHT_UNIT",
1573
+ /** Kilograms. */
1574
+ KG = "KG",
1575
+ /** Pounds. */
1576
+ LB = "LB"
1577
+ }
1578
+ /** @enumType */
1579
+ type WeightUnitWithLiterals = WeightUnit | 'UNSPECIFIED_WEIGHT_UNIT' | 'KG' | 'LB';
1580
+ interface TaxSummary {
1581
+ /**
1582
+ * Amount for which tax is calculated, added from line items.
1583
+ * @readonly
1584
+ */
1585
+ taxableAmount?: MultiCurrencyPrice;
1586
+ /**
1587
+ * Calculated tax, added from line items.
1588
+ * @readonly
1589
+ */
1590
+ totalTax?: MultiCurrencyPrice;
1591
+ /**
1592
+ * Tax calculator that was active when the order was created.
1593
+ * @deprecated
1594
+ */
1595
+ calculationDetails?: TaxCalculationDetails;
1596
+ }
1597
+ interface TaxCalculationDetails extends TaxCalculationDetailsCalculationDetailsOneOf {
1598
+ /** Reason the manual calculation was used. */
1599
+ manualRateReason?: ManualCalculationReasonWithLiterals;
1600
+ /** Details of the fallback rate calculation. */
1601
+ autoTaxFallbackDetails?: AutoTaxFallbackCalculationDetails;
1602
+ /** Rate calculation type. */
1603
+ rateType?: RateTypeWithLiterals;
1604
+ }
1605
+ /** @oneof */
1606
+ interface TaxCalculationDetailsCalculationDetailsOneOf {
1607
+ /** Reason the manual calculation was used. */
1608
+ manualRateReason?: ManualCalculationReasonWithLiterals;
1609
+ /** Details of the fallback rate calculation. */
1610
+ autoTaxFallbackDetails?: AutoTaxFallbackCalculationDetails;
1611
+ }
1612
+ declare enum RateType {
1613
+ /** no tax being collected for this request due to location of purchase */
1614
+ NO_TAX_COLLECTED = "NO_TAX_COLLECTED",
1615
+ /** manual rate used for calculation */
1616
+ MANUAL_RATE = "MANUAL_RATE",
1617
+ /** autotax rate used for calculation */
1618
+ AUTO_RATE = "AUTO_RATE",
1619
+ /** fallback rate used for calculation */
1620
+ FALLBACK_RATE = "FALLBACK_RATE"
1621
+ }
1622
+ /** @enumType */
1623
+ type RateTypeWithLiterals = RateType | 'NO_TAX_COLLECTED' | 'MANUAL_RATE' | 'AUTO_RATE' | 'FALLBACK_RATE';
1624
+ declare enum ManualCalculationReason {
1625
+ /** user set calculator in Business Manager to be Manual */
1626
+ GLOBAL_SETTING_TO_MANUAL = "GLOBAL_SETTING_TO_MANUAL",
1627
+ /** specific region is on manual even though Global setting is Auto-tax */
1628
+ REGION_SETTING_TO_MANUAL = "REGION_SETTING_TO_MANUAL"
1629
+ }
1630
+ /** @enumType */
1631
+ type ManualCalculationReasonWithLiterals = ManualCalculationReason | 'GLOBAL_SETTING_TO_MANUAL' | 'REGION_SETTING_TO_MANUAL';
1632
+ interface AutoTaxFallbackCalculationDetails {
1633
+ /** reason for fallback */
1634
+ fallbackReason?: FallbackReasonWithLiterals;
1635
+ /** invalid request (i.e. address), timeout, internal error, license error, and others will be encoded here */
1636
+ error?: ApplicationError;
1637
+ }
1638
+ declare enum FallbackReason {
1639
+ /** auto-tax failed to be calculated */
1640
+ AUTO_TAX_FAILED = "AUTO_TAX_FAILED",
1641
+ /** auto-tax was temporarily deactivated on a system-level */
1642
+ AUTO_TAX_DEACTIVATED = "AUTO_TAX_DEACTIVATED"
1643
+ }
1644
+ /** @enumType */
1645
+ type FallbackReasonWithLiterals = FallbackReason | 'AUTO_TAX_FAILED' | 'AUTO_TAX_DEACTIVATED';
1646
+ declare enum ChannelType {
1647
+ /** Unspecified sales channel. This value is not supported. */
1648
+ UNSPECIFIED = "UNSPECIFIED",
1649
+ /** A web client. */
1650
+ WEB = "WEB",
1651
+ /** [Point of sale solutions](https://support.wix.com/en/wix-mobile-pos-2196395). */
1652
+ POS = "POS",
1653
+ /** [eBay shop](https://support.wix.com/en/article/wix-stores-connecting-and-setting-up-an-ebay-shop). */
1654
+ EBAY = "EBAY",
1655
+ /** [Amazon shop](https://support.wix.com/en/article/wix-stores-connecting-and-setting-up-an-amazon-shop). */
1656
+ AMAZON = "AMAZON",
1657
+ /** Other sales platform. */
1658
+ OTHER_PLATFORM = "OTHER_PLATFORM",
1659
+ /** [Wix Owner app](https://support.wix.com/article/wix-owner-app-an-overview). */
1660
+ WIX_APP_STORE = "WIX_APP_STORE",
1661
+ /** Wix Invoices app in [your dashboard](https://www.wix.com/my-account/site-selector/?buttonText=Select%20Site&title=Select%20a%20Site&autoSelectOnSingleSite=true&actionUrl=https:%2F%2Fwww.wix.com%2Fdashboard%2F%7B%7BmetaSiteId%7D%7D%2Finvoices/settings/general-settings) */
1662
+ WIX_INVOICES = "WIX_INVOICES",
1663
+ /** Wix merchant backoffice. */
1664
+ BACKOFFICE_MERCHANT = "BACKOFFICE_MERCHANT",
1665
+ /** Wish sales channel. */
1666
+ WISH = "WISH",
1667
+ /** [ClassPass sales channel](https://support.wix.com/en/article/wix-bookings-letting-clients-book-your-services-with-classpass). */
1668
+ CLASS_PASS = "CLASS_PASS",
1669
+ /** Global-E sales channel. */
1670
+ GLOBAL_E = "GLOBAL_E",
1671
+ /** [Facebook shop](https://support.wix.com/en/article/wix-stores-changes-to-facebook-shops). */
1672
+ FACEBOOK = "FACEBOOK",
1673
+ /** [Etsy sales channel](https://support.wix.com/en/article/wix-stores-request-adding-etsy-as-a-sales-channel). */
1674
+ ETSY = "ETSY",
1675
+ /** [TikTok sales channel](https://support.wix.com/en/article/wix-stores-request-adding-tiktok-as-a-sales-channel). */
1676
+ TIKTOK = "TIKTOK",
1677
+ /** [Faire marketplace integration](https://support.wix.com/en/article/wix-stores-creating-a-faire-store-using-the-faire-integration-app). */
1678
+ FAIRE_COM = "FAIRE_COM"
1679
+ }
1680
+ /** @enumType */
1681
+ type ChannelTypeWithLiterals = ChannelType | 'UNSPECIFIED' | 'WEB' | 'POS' | 'EBAY' | 'AMAZON' | 'OTHER_PLATFORM' | 'WIX_APP_STORE' | 'WIX_INVOICES' | 'BACKOFFICE_MERCHANT' | 'WISH' | 'CLASS_PASS' | 'GLOBAL_E' | 'FACEBOOK' | 'ETSY' | 'TIKTOK' | 'FAIRE_COM';
1682
+ interface CreatedBy extends CreatedByIdOneOf {
1683
+ /**
1684
+ * User ID. When the order was created by a Wix user on behalf of a buyer.
1685
+ * For example, via POS (point of service).
1686
+ * @format GUID
1687
+ */
1688
+ userId?: string;
1689
+ /**
1690
+ * Member ID. When the order was created by a **logged in** site visitor.
1691
+ * @format GUID
1692
+ */
1693
+ memberId?: string;
1694
+ /**
1695
+ * Visitor ID. When the order was created by a site visitor that was **not** logged in.
1696
+ * @format GUID
1697
+ */
1698
+ visitorId?: string;
1699
+ /**
1700
+ * App ID. When the order was created by an external application or Wix service.
1701
+ * @format GUID
1702
+ */
1703
+ appId?: string;
1704
+ }
1705
+ /** @oneof */
1706
+ interface CreatedByIdOneOf {
1707
+ /**
1708
+ * User ID. When the order was created by a Wix user on behalf of a buyer.
1709
+ * For example, via POS (point of service).
1710
+ * @format GUID
1711
+ */
1712
+ userId?: string;
1713
+ /**
1714
+ * Member ID. When the order was created by a **logged in** site visitor.
1715
+ * @format GUID
1716
+ */
1717
+ memberId?: string;
1718
+ /**
1719
+ * Visitor ID. When the order was created by a site visitor that was **not** logged in.
1720
+ * @format GUID
1721
+ */
1722
+ visitorId?: string;
1723
+ /**
1724
+ * App ID. When the order was created by an external application or Wix service.
1725
+ * @format GUID
1726
+ */
1727
+ appId?: string;
1728
+ }
1729
+ /** Reserved for internal use. */
1730
+ interface MembershipOptions {
1731
+ /**
1732
+ * Reserved for internal use.
1733
+ * @readonly
1734
+ * @maxSize 300
1735
+ */
1736
+ eligibleMemberships?: Membership[];
1737
+ /**
1738
+ * Reserved for internal use.
1739
+ * @readonly
1740
+ * @maxSize 300
1741
+ */
1742
+ invalidMemberships?: InvalidMembership[];
1743
+ /** Selected membership to apply to this checkout. */
1744
+ selectedMemberships?: SelectedMemberships;
1745
+ }
1746
+ interface Membership {
1747
+ /**
1748
+ * Membership ID.
1749
+ * @minLength 1
1750
+ * @maxLength 100
1751
+ */
1752
+ id?: string;
1753
+ /**
1754
+ * ID of the application providing this payment option.
1755
+ * @format GUID
1756
+ */
1757
+ appId?: string;
1758
+ /** The name of this membership. */
1759
+ name?: MembershipName;
1760
+ /**
1761
+ * Line item IDs which are "paid" for by this membership.
1762
+ * @minSize 1
1763
+ * @maxSize 300
1764
+ * @minLength 1
1765
+ * @maxLength 100
1766
+ */
1767
+ lineItemIds?: string[];
1768
+ /** Optional - For a membership that has limited credits, information about credit usage. */
1769
+ credits?: MembershipPaymentCredits;
1770
+ /** Optional - TMembership expiry date. */
1771
+ expirationDate?: Date | null;
1772
+ /** Additional data about this membership. */
1773
+ additionalData?: Record<string, any> | null;
1774
+ }
1775
+ interface MembershipName {
1776
+ /**
1777
+ * Membership name.
1778
+ * @maxLength 100
1779
+ */
1780
+ original?: string;
1781
+ /**
1782
+ * Translated membership name. Defaults to `original` when not provided.
1783
+ * @maxLength 100
1784
+ */
1785
+ translated?: string | null;
1786
+ }
1787
+ interface MembershipPaymentCredits {
1788
+ /**
1789
+ * Membership's total amount of credits.
1790
+ * @min 1
1791
+ */
1792
+ total?: number;
1793
+ /** Membership's remaining amount of credits. */
1794
+ remaining?: number;
1795
+ }
1796
+ interface InvalidMembership {
1797
+ /** Membership details. */
1798
+ membership?: Membership;
1799
+ /**
1800
+ * Reason why this membership is invalid and cannot be used.
1801
+ * @minLength 1
1802
+ * @maxLength 100
1803
+ */
1804
+ reason?: string;
1805
+ }
1806
+ interface SelectedMemberships {
1807
+ /**
1808
+ * Selected memberships.
1809
+ * @maxSize 300
1810
+ */
1811
+ memberships?: SelectedMembership[];
1812
+ }
1813
+ interface SelectedMembership {
1814
+ /**
1815
+ * Membership ID.
1816
+ * @minLength 1
1817
+ * @maxLength 100
1818
+ */
1819
+ id?: string;
1820
+ /**
1821
+ * ID of the app providing this payment option.
1822
+ * @format GUID
1823
+ */
1824
+ appId?: string;
1825
+ /**
1826
+ * IDs of the line items this membership applies to.
1827
+ * @minSize 1
1828
+ * @maxSize 300
1829
+ * @minLength 1
1830
+ * @maxLength 100
1831
+ */
1832
+ lineItemIds?: string[];
1833
+ }
1834
+ interface AdditionalFee {
1835
+ /**
1836
+ * Additional fee's unique code (or ID) for future processing.
1837
+ * @minLength 1
1838
+ * @maxLength 100
1839
+ */
1840
+ code?: string | null;
1841
+ /**
1842
+ * Translated additional fee's name.
1843
+ * @minLength 1
1844
+ * @maxLength 50
1845
+ */
1846
+ name?: string;
1847
+ /** Additional fee's price. */
1848
+ price?: MultiCurrencyPrice;
1849
+ /** Tax details. */
1850
+ taxDetails?: ItemTaxFullDetails;
1851
+ /**
1852
+ * Provider's app id.
1853
+ * @minLength 1
1854
+ * @maxLength 100
1855
+ */
1856
+ providerAppId?: string | null;
1857
+ /** Additional fee's price before tax. */
1858
+ priceBeforeTax?: MultiCurrencyPrice;
1859
+ /** Additional fee's price after tax. */
1860
+ priceAfterTax?: MultiCurrencyPrice;
1861
+ /**
1862
+ * Optional - Line items associated with this additional fee.
1863
+ * If no `lineItemIds` are provided, the fee will be associated with the whole cart/checkout/order.
1864
+ * @format GUID
1865
+ */
1866
+ lineItemIds?: string[];
1867
+ /** the source the additional fee was added from */
1868
+ source?: AdditionalFeeSourceWithLiterals;
1869
+ }
1870
+ declare enum AdditionalFeeSource {
1871
+ UNKNOWN_ADDITIONAL_FEE_SOURCE = "UNKNOWN_ADDITIONAL_FEE_SOURCE",
1872
+ /** The additional fee was added by an additional fee service plugin */
1873
+ SERVICE_PLUGIN = "SERVICE_PLUGIN",
1874
+ /** The additional fee was added on the item either via the catalog or on custom line item */
1875
+ ITEM = "ITEM",
1876
+ /** The additional fee was added manually on the request */
1877
+ MANUAL = "MANUAL",
1878
+ /** The additional fee was added by the shipping provider */
1879
+ SHIPPING = "SHIPPING"
1880
+ }
1881
+ /** @enumType */
1882
+ type AdditionalFeeSourceWithLiterals = AdditionalFeeSource | 'UNKNOWN_ADDITIONAL_FEE_SOURCE' | 'SERVICE_PLUGIN' | 'ITEM' | 'MANUAL' | 'SHIPPING';
1883
+ interface Violation {
1884
+ /** 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. */
1885
+ severity?: SeverityWithLiterals;
1886
+ /** Target location on a checkout or cart page where the violation will be displayed. */
1887
+ target?: Target;
1888
+ /**
1889
+ * 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>`.
1890
+ * @minLength 1
1891
+ * @maxLength 1000
1892
+ */
1893
+ description?: string | null;
1894
+ }
1895
+ declare enum Severity {
1896
+ /** The user is allowed to move forward in the flow. */
1897
+ WARNING = "WARNING",
1898
+ /**
1899
+ * The user is blocked from moving forward in the flow.
1900
+ * For example, if callerContext is CART - moving to checkout is blocked. if callerContext is CHECKOUT, placing an order is blocked.
1901
+ */
1902
+ ERROR = "ERROR"
1903
+ }
1904
+ /** @enumType */
1905
+ type SeverityWithLiterals = Severity | 'WARNING' | 'ERROR';
1906
+ interface Target extends TargetTargetTypeOneOf {
1907
+ /** General (other) violation. */
1908
+ other?: Other;
1909
+ /** Specific line item violation. */
1910
+ lineItem?: TargetLineItem;
1911
+ }
1912
+ /** @oneof */
1913
+ interface TargetTargetTypeOneOf {
1914
+ /** General (other) violation. */
1915
+ other?: Other;
1916
+ /** Specific line item violation. */
1917
+ lineItem?: TargetLineItem;
1918
+ }
1919
+ /** Available locations on the webpage */
1920
+ declare enum NameInOther {
1921
+ /** Default location, in case no specific location is specified. */
1922
+ OTHER_DEFAULT = "OTHER_DEFAULT"
1923
+ }
1924
+ /** @enumType */
1925
+ type NameInOtherWithLiterals = NameInOther | 'OTHER_DEFAULT';
1926
+ /** Available locations on the line item */
1927
+ declare enum NameInLineItem {
1928
+ /** Default location, in case no specific location is specified. */
1929
+ LINE_ITEM_DEFAULT = "LINE_ITEM_DEFAULT"
1930
+ }
1931
+ /** @enumType */
1932
+ type NameInLineItemWithLiterals = NameInLineItem | 'LINE_ITEM_DEFAULT';
1933
+ /** General (other) violation. */
1934
+ interface Other {
1935
+ /** Location on a checkout or a cart page where a general (other) violation will be displayed. */
1936
+ name?: NameInOtherWithLiterals;
1937
+ }
1938
+ /** Specific line item violation. */
1939
+ interface TargetLineItem {
1940
+ /** Location on a checkout or a cart page where the specific line item violation will be displayed. */
1941
+ name?: NameInLineItemWithLiterals;
1942
+ /** ID of the line item containing the violation. */
1943
+ id?: string | null;
1944
+ }
1945
+ interface CustomSettings {
1946
+ /**
1947
+ * Whether to restrict the option to add or remove a gift card on the checkout page.
1948
+ *
1949
+ * Default: `false`
1950
+ */
1951
+ lockGiftCard?: boolean;
1952
+ /**
1953
+ * Whether to restrict the option to add or remove a coupon code on the checkout page.
1954
+ *
1955
+ * Default: `false`
1956
+ */
1957
+ lockCouponCode?: boolean;
1958
+ /**
1959
+ * Whether to disable policy agreement checkout in the checkout page
1960
+ *
1961
+ * Default: `false`
1962
+ */
1963
+ disabledPolicyAgreementCheckbox?: boolean;
1964
+ /**
1965
+ * Whether to disable manual payment option for this checkout.
1966
+ *
1967
+ * Default: `false`
1968
+ */
1969
+ disabledManualPayment?: boolean;
1970
+ }
1971
+ interface CustomContentReference {
1972
+ /**
1973
+ * ID of the app providing the content.
1974
+ *
1975
+ * You can get your app's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).
1976
+ * @format GUID
1977
+ */
1978
+ appId?: string;
1979
+ /**
1980
+ * ID of the component within the app it belongs to.
1981
+ *
1982
+ * You can get your component's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).
1983
+ * @format GUID
1984
+ */
1985
+ componentId?: string;
1986
+ }
1987
+ interface ExternalReference {
1988
+ /**
1989
+ * ID of the app associated with the purchase flow.
1990
+ * For example, the Wix Pay Links app ID.
1991
+ * @format GUID
1992
+ * @immutable
1993
+ */
1994
+ appId?: string;
1995
+ /**
1996
+ * Reference to an external resource ID. Used to link the purchase flow to a specific entity in an external system.
1997
+ * For example, a Wix Pay Link ID.
1998
+ * @minLength 1
1999
+ * @maxLength 100
2000
+ * @immutable
2001
+ */
2002
+ resourceId?: string | null;
2003
+ }
2004
+ interface CreateCheckoutRequest {
2005
+ /** Checkout information. */
2006
+ checkoutInfo?: Checkout;
2007
+ /** Coupon code. */
2008
+ couponCode?: string | null;
2009
+ /**
2010
+ * Catalog line items to add to the checkout.
2011
+ * @maxSize 300
2012
+ */
2013
+ lineItems?: LineItem[];
2014
+ /**
2015
+ * Custom line items to add to the checkout. Custom line items don't trigger the Catalog service plugin.
2016
+ *
2017
+ * To access and manage custom line items, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
2018
+ * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
2019
+ * @maxSize 300
2020
+ */
2021
+ customLineItems?: CustomLineItem[];
2022
+ /** Sales channel that submitted the order. */
2023
+ channelType: ChannelTypeWithLiterals;
2024
+ /**
2025
+ * Gift card code.
2026
+ *
2027
+ * The checkout can only hold 1 `giftCardCode` at a time. If an additional `giftCardCode` is added, it will override the existing `giftCardCode`.
2028
+ *
2029
+ * >**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).
2030
+ */
2031
+ giftCardCode?: string | null;
2032
+ /**
2033
+ * `overrideCheckoutUrl` allows the flexibility to redirect customers to a customized checkout page.
2034
+ *
2035
+ * This field overrides the `checkoutUrl` in a cart or checkout. `checkoutUrl` is used in the Abandoned Checkout API
2036
+ * to send customers back to their checkouts. By default, a `checkoutUrl` generates for a checkout and directs to a
2037
+ * standard Wix checkout page. When `overrideCheckoutUrl` has a value, it will replace and set the value of `checkoutUrl`.
2038
+ * @maxLength 1000
2039
+ */
2040
+ overrideCheckoutUrl?: string | null;
2041
+ }
2042
+ interface CustomLineItem {
2043
+ /**
2044
+ * Custom line item quantity.
2045
+ *
2046
+ * Min: `1`
2047
+ * Max: `100000`
2048
+ * @min 1
2049
+ * @max 100000
2050
+ */
2051
+ quantity?: number;
2052
+ /**
2053
+ * Custom line item price.
2054
+ *
2055
+ * Must be a number or a decimal without symbols.
2056
+ * @format DECIMAL_VALUE
2057
+ * @decimalValue options { gte:0, lte:1000000000000000 }
2058
+ */
2059
+ price?: string;
2060
+ /** Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67". */
2061
+ priceDescription?: PriceDescription;
2062
+ /**
2063
+ * Custom line item description lines. Used for display purposes for the cart, checkout and order.
2064
+ * @maxSize 10
2065
+ */
2066
+ descriptionLines?: DescriptionLine[];
2067
+ /** Custom line item's media. */
2068
+ media?: Image;
2069
+ /**
2070
+ * Custom line item ID. If passed, `id` must be unique.
2071
+ *
2072
+ * Default: auto-generated ID
2073
+ * @format GUID
2074
+ */
2075
+ id?: string | null;
2076
+ /**
2077
+ * Tax group ID for this custom line item.
2078
+ * @format GUID
2079
+ */
2080
+ taxGroupId?: string | null;
2081
+ /** Name of the item or product. */
2082
+ productName?: ProductName;
2083
+ /** 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. */
2084
+ url?: PageUrlV2;
2085
+ /** Item type. Either a preset type or custom. */
2086
+ itemType?: ItemType;
2087
+ /**
2088
+ * Item price **before** catalog-defined discount. Defaults to `price` when not provided.
2089
+ * @format DECIMAL_VALUE
2090
+ */
2091
+ fullPrice?: string | null;
2092
+ /**
2093
+ * Item quantity available for purchase. Only return this if inventory is managed.
2094
+ * Not returning this field means that the buyer can "infinitely" tick up the number of items in the cart.
2095
+ * @max 100000
2096
+ */
2097
+ quantityAvailable?: number | null;
2098
+ /** Physical properties of the item. */
2099
+ physicalProperties?: PhysicalProperties;
2100
+ /**
2101
+ * Type of selected payment option for current item. Defaults to `FULL_PAYMENT_ONLINE`.
2102
+ *
2103
+ * + `FULL_PAYMENT_ONLINE` - Entire payment for this item happens as part of the checkout.
2104
+ * + `FULL_PAYMENT_OFFLINE` - Entire payment for this item happens after the checkout. For example, when using cash, check, or other offline payment methods.
2105
+ * + `MEMBERSHIP` - Payment for this item is done by charging a membership. When this option is used, `lineItem.price.amount` is 0.
2106
+ * + `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.
2107
+ */
2108
+ paymentOption?: PaymentOptionTypeWithLiterals;
2109
+ /**
2110
+ * Service properties. When relevant, this contains information such as date and number of participants.
2111
+ * Used, among other things, when checking for valid memberships.
2112
+ */
2113
+ serviceProperties?: ServiceProperties;
2114
+ /**
2115
+ * In cases where `catalogReference.catalogItemId` is NOT the actual catalog item ID, this field will return the true item's ID.
2116
+ *
2117
+ * + For example, for Wix Bookings, `catalogReference.catalogItemId` is the booking ID. Therefore this value is set to the service ID.
2118
+ * + In most cases, this field is the same as `catalogReference.catalogItemId`.
2119
+ * + Used in membership validation.
2120
+ * @minLength 1
2121
+ * @maxLength 36
2122
+ */
2123
+ rootCatalogItemId?: string | null;
2124
+ /**
2125
+ * Partial payment for the given item to be paid upfront during the checkout.
2126
+ *
2127
+ * Eligible for catalog items with type `DEPOSIT_ONLINE`.
2128
+ * When omitted, the item's price will not be split and is expected to be paid in a single installment.
2129
+ * @format DECIMAL_VALUE
2130
+ */
2131
+ depositAmount?: string | null;
2132
+ /**
2133
+ * Delivery profile ID.
2134
+ * @format GUID
2135
+ */
2136
+ deliveryProfileId?: string | null;
2137
+ /** 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. */
2138
+ catalogReference?: CatalogReference;
2139
+ /**
2140
+ * Item payment policy that requires customer consent to complete purchase. The payment policy will be displayed on the checkout page.
2141
+ * @minLength 1
2142
+ * @maxLength 1000
2143
+ * @readonly
2144
+ */
2145
+ consentRequiredPaymentPolicy?: string | null;
2146
+ /**
2147
+ * Whether to save the payment method on the order.
2148
+ *
2149
+ * Default: `false`
2150
+ * @readonly
2151
+ */
2152
+ savePaymentMethod?: boolean;
2153
+ /**
2154
+ * Policies to be displayed to the customer on the checkout page.
2155
+ * @maxSize 5
2156
+ */
2157
+ policies?: Policy[];
2158
+ /**
2159
+ * Whether the item can only be purchased by site members.
2160
+ *
2161
+ * Default: `false`
2162
+ */
2163
+ membersOnly?: boolean;
2164
+ /** Address to use for tax calculation purposes. */
2165
+ taxableAddress?: TaxableAddress;
2166
+ /**
2167
+ * Modifier groups that were added to the item.
2168
+ * @maxSize 25
2169
+ */
2170
+ modifierGroups?: V1ModifierGroup[];
2171
+ }
2172
+ interface V1ModifierGroup {
2173
+ /**
2174
+ * Modifier group id.
2175
+ * @minLength 1
2176
+ * @maxLength 36
2177
+ */
2178
+ id?: string;
2179
+ /** Modifier group name. */
2180
+ name?: TranslatableString;
2181
+ /**
2182
+ * List of modifiers in this group.
2183
+ * @minSize 1
2184
+ * @maxSize 25
2185
+ */
2186
+ modifiers?: V1ItemModifier[];
2187
+ }
2188
+ interface V1ItemModifier {
2189
+ /**
2190
+ * Modifier ID.
2191
+ * @minLength 1
2192
+ * @maxLength 36
2193
+ */
2194
+ id?: string;
2195
+ /**
2196
+ * The quantity of this modifier.
2197
+ * @min 1
2198
+ * @max 100000
2199
+ */
2200
+ quantity?: number | null;
2201
+ /** Primary display label for the modifier. */
2202
+ label?: TranslatableString;
2203
+ /** Optional additional details or clarification for the modifier. */
2204
+ details?: TranslatableString;
2205
+ /**
2206
+ * The price of the modifier.
2207
+ * @decimalValue options { gte:0, lte:1000000000000000, maxScale:3 }
2208
+ */
2209
+ price?: string | null;
2210
+ }
2211
+ interface CreateCheckoutResponse {
2212
+ /** Newly created checkout. */
2213
+ checkout?: Checkout;
2214
+ }
2215
+ interface GetCheckoutRequest {
2216
+ /**
2217
+ * Checkout ID.
2218
+ * @format GUID
2219
+ */
2220
+ id: string;
2221
+ }
2222
+ interface GetCheckoutResponse {
2223
+ /** Retrieved checkout. */
2224
+ checkout?: Checkout;
2225
+ }
2226
+ interface GetCheckoutByCartIdRequest {
2227
+ /**
2228
+ * Cart ID.
2229
+ * @format GUID
2230
+ */
2231
+ id: string;
2232
+ }
2233
+ interface GetCheckoutByCartIdResponse {
2234
+ /** Retrieved checkout. */
2235
+ checkout?: Checkout;
2236
+ }
2237
+ interface GetWixCheckoutURLRequest {
2238
+ /**
2239
+ * Checkout ID.
2240
+ * @format GUID
2241
+ */
2242
+ id: string;
2243
+ }
2244
+ interface GetWixCheckoutURLResponse {
2245
+ /** Checkout URL. */
2246
+ checkoutUrl?: string;
2247
+ }
2248
+ interface GetCheckoutURLRequest {
2249
+ /**
2250
+ * Checkout ID.
2251
+ * @format GUID
2252
+ */
2253
+ id: string;
2254
+ }
2255
+ interface GetCheckoutURLResponse {
2256
+ /** Checkout URL. */
2257
+ checkoutUrl?: string;
2258
+ }
2259
+ interface UpdateCheckoutRequest {
2260
+ /** Checkout information. */
2261
+ checkout: Checkout;
2262
+ /**
2263
+ * Coupon code.
2264
+ *
2265
+ * The checkout can only hold 1 `couponCode` at a time. If an additional `couponCode` is added, it will override the existing `couponCode`.
2266
+ */
2267
+ couponCode?: string | null;
2268
+ /** Gift card code. */
2269
+ giftCardCode?: string | null;
2270
+ /**
2271
+ * `overrideCheckoutUrl` allows the flexibility to redirect customers to a customized checkout page.
2272
+ *
2273
+ * This field overrides the `checkoutUrl` in a cart or checkout. `checkoutUrl` is used in the Abandoned Checkout API
2274
+ * to send customers back to their checkouts. By default, a `checkoutUrl` generates for a checkout and directs to a
2275
+ * standard Wix checkout page. When `overrideCheckoutUrl` has a value, it will replace and set the value of `checkoutUrl`.
2276
+ * @maxLength 1000
2277
+ */
2278
+ overrideCheckoutUrl?: string | null;
2279
+ /**
2280
+ * Catalog line items.
2281
+ * @maxSize 300
2282
+ */
2283
+ lineItems?: LineItem[];
2284
+ /**
2285
+ * Custom line items. Custom line items don't trigger the Catalog service plugin.
2286
+ *
2287
+ * To access and manage custom line items, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
2288
+ * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
2289
+ * @maxSize 300
2290
+ */
2291
+ customLineItems?: CustomLineItem[];
2292
+ }
2293
+ interface UpdateCheckoutResponse {
2294
+ /** Updated checkout. */
2295
+ checkout?: Checkout;
2296
+ }
2297
+ interface RemoveCouponRequest {
2298
+ /**
2299
+ * ID of the checkout to remove the coupon from.
2300
+ * @format GUID
2301
+ */
2302
+ id: string;
2303
+ }
2304
+ interface RemoveCouponResponse {
2305
+ /** Updated checkout after removal of coupon. */
2306
+ checkout?: Checkout;
2307
+ }
2308
+ interface RemoveGiftCardRequest {
2309
+ /**
2310
+ * ID of the checkout to remove the gift card from.
2311
+ * @format GUID
2312
+ */
2313
+ id: string;
2314
+ }
2315
+ interface RemoveGiftCardResponse {
2316
+ /** Updated checkout after removal of gift card. */
2317
+ checkout?: Checkout;
2318
+ }
2319
+ interface RemoveOverrideCheckoutUrlRequest {
2320
+ /**
2321
+ * ID of the checkout to remove the override checkout url from.
2322
+ * @format GUID
2323
+ */
2324
+ id: string;
2325
+ }
2326
+ interface RemoveOverrideCheckoutUrlResponse {
2327
+ /** Updated checkout after removal of override checkout url. */
2328
+ checkout?: Checkout;
2329
+ }
2330
+ interface AddToCheckoutRequest {
2331
+ /**
2332
+ * Checkout ID.
2333
+ * @format GUID
2334
+ */
2335
+ id: string;
2336
+ /**
2337
+ * Catalog line items.
2338
+ * @maxSize 100
2339
+ */
2340
+ lineItems?: LineItem[];
2341
+ /**
2342
+ * Custom line items. Custom line items don't trigger the Catalog service plugin.
2343
+ *
2344
+ * To access and manage custom line items, your app must have the permission scope named "Manage eCommerce - Admin Permissions".
2345
+ * Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions).
2346
+ * @maxSize 100
2347
+ */
2348
+ customLineItems?: CustomLineItem[];
2349
+ }
2350
+ interface AddToCheckoutResponse {
2351
+ /** Updated checkout. */
2352
+ checkout?: Checkout;
2353
+ }
2354
+ interface RemoveLineItemsRequest {
2355
+ /**
2356
+ * ID of the checkout to remove line items from.
2357
+ * @format GUID
2358
+ */
2359
+ id: string;
2360
+ /**
2361
+ * IDs of the line items to remove from the checkout.
2362
+ *
2363
+ * To find the IDs of the checkout line items you'd like to remove,
2364
+ * pass the checkout ID to Get Checkout and look for the IDs under
2365
+ * `lineItems`.
2366
+ * @format GUID
2367
+ * @minSize 1
2368
+ * @maxSize 300
2369
+ */
2370
+ lineItemIds: string[];
2371
+ }
2372
+ interface RemoveLineItemsResponse {
2373
+ /** Updated checkout after removal of line items. */
2374
+ checkout?: Checkout;
2375
+ }
2376
+ interface CreateOrderRequest {
2377
+ /**
2378
+ * Checkout ID.
2379
+ * @format GUID
2380
+ */
2381
+ id: string;
2382
+ /** Whether the payment method should be saved on the order. */
2383
+ savePaymentMethod?: boolean;
2384
+ /** Whether to authorize the payment and delay the capture. */
2385
+ delayCapture?: boolean;
2386
+ }
2387
+ interface CreateOrderResponse extends CreateOrderResponseIdOneOf {
2388
+ /**
2389
+ * ID of newly created order.
2390
+ * @format GUID
2391
+ */
2392
+ orderId?: string;
2393
+ /**
2394
+ * ID of newly created subscription. Learn more about your site's [Subscriptions](https://support.wix.com/en/article/wix-stores-managing-product-subscriptions).
2395
+ * @format GUID
2396
+ */
2397
+ subscriptionId?: string;
2398
+ /**
2399
+ * Payment gateway order ID.
2400
+ *
2401
+ * 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.
2402
+ * `paymentGatewayOrderId` will be returned if money needs to be charged.
2403
+ *
2404
+ * In some cases, money cannot be charged:
2405
+ * + 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.
2406
+ * + If the total price is not `0`, but the payment is covered by alternative payment methods, such as a gift card.
2407
+ */
2408
+ paymentGatewayOrderId?: string | null;
2409
+ }
2410
+ /** @oneof */
2411
+ interface CreateOrderResponseIdOneOf {
2412
+ /**
2413
+ * ID of newly created order.
2414
+ * @format GUID
2415
+ */
2416
+ orderId?: string;
2417
+ /**
2418
+ * ID of newly created subscription. Learn more about your site's [Subscriptions](https://support.wix.com/en/article/wix-stores-managing-product-subscriptions).
2419
+ * @format GUID
2420
+ */
2421
+ subscriptionId?: string;
2422
+ }
2423
+ interface CreateOrderAndChargeRequest {
2424
+ /**
2425
+ * Checkout ID.
2426
+ * @format GUID
2427
+ */
2428
+ id: string;
2429
+ /** Payment token. */
2430
+ paymentToken?: string | null;
2431
+ /** Whether the payment method should be saved on the order. */
2432
+ savePaymentMethod?: boolean;
2433
+ /** Whether to authorize the payment and delay the capture. */
2434
+ delayCapture?: boolean;
2435
+ }
2436
+ interface CreateOrderAndChargeResponse extends CreateOrderAndChargeResponseIdOneOf {
2437
+ /**
2438
+ * ID of newly created order.
2439
+ * @format GUID
2440
+ */
2441
+ orderId?: string;
2442
+ /**
2443
+ * ID of newly created subscription.
2444
+ * @format GUID
2445
+ */
2446
+ subscriptionId?: string;
2447
+ /** Payment response token. */
2448
+ paymentResponseToken?: string | null;
2449
+ /**
2450
+ * The payment gateway is cashier.
2451
+ * payment_gateway_order_id will be returned given that money was charged.
2452
+ * In some cases, money will not be charged:
2453
+ * If the total price is 0 - For example, could be a free item or a an item with 100% discount
2454
+ * If the total price is not 0, but the payment is covered by alternative payment methods such as gift card
2455
+ */
2456
+ paymentGatewayOrderId?: string | null;
2457
+ }
2458
+ /** @oneof */
2459
+ interface CreateOrderAndChargeResponseIdOneOf {
2460
+ /**
2461
+ * ID of newly created order.
2462
+ * @format GUID
2463
+ */
2464
+ orderId?: string;
2465
+ /**
2466
+ * ID of newly created subscription.
2467
+ * @format GUID
2468
+ */
2469
+ subscriptionId?: string;
2470
+ }
2471
+ interface MarkCheckoutAsCompletedAndRedirectToUrlRequest {
2472
+ /**
2473
+ * Server-signed JWT token with required information to complete checkout
2474
+ * @maxLength 4096
2475
+ */
2476
+ token: string;
2477
+ }
2478
+ interface RawHttpResponse {
2479
+ body?: Uint8Array;
2480
+ statusCode?: number | null;
2481
+ headers?: HeadersEntry[];
2482
+ }
2483
+ interface HeadersEntry {
2484
+ key?: string;
2485
+ value?: string;
2486
+ }
2487
+ interface MarkCheckoutAsCompletedRequest {
2488
+ /**
2489
+ * Checkout ID.
2490
+ * @format GUID
2491
+ */
2492
+ id: string;
2493
+ }
2494
+ interface MarkCheckoutAsCompletedResponse {
2495
+ }
2496
+ interface UpdateLineItemsQuantityRequest {
2497
+ /**
2498
+ * Checkout ID.
2499
+ * @format GUID
2500
+ */
2501
+ id: string;
2502
+ /**
2503
+ * Line item info to update.
2504
+ * @minSize 1
2505
+ * @maxSize 100
2506
+ */
2507
+ lineItems: LineItemQuantityUpdate[];
2508
+ }
2509
+ interface LineItemQuantityUpdate {
2510
+ /**
2511
+ * ID of the line item to update.
2512
+ * @format GUID
2513
+ */
2514
+ id?: string;
2515
+ /**
2516
+ * New total amount of the line item,
2517
+ * not the amount to add to the current `quantity`.
2518
+ *
2519
+ * Min: `1`
2520
+ *
2521
+ * Max: `100000`
2522
+ * @min 1
2523
+ * @max 100000
2524
+ */
2525
+ quantity?: number;
2526
+ }
2527
+ interface UpdateLineItemsQuantityResponse {
2528
+ /** Updated checkout. */
2529
+ checkout?: Checkout;
2530
+ }
2531
+ interface GetCheckoutPaymentSettingsRequest {
2532
+ /**
2533
+ * Checkout ID.
2534
+ * @format GUID
2535
+ */
2536
+ id: string;
2537
+ }
2538
+ interface GetCheckoutPaymentSettingsResponse {
2539
+ blockedPaymentOptions?: GetCheckoutPaymentSettingsResponsePaymentOptionWithLiterals[];
2540
+ }
2541
+ declare enum GetCheckoutPaymentSettingsResponsePaymentOption {
2542
+ UNKNOWN_PAYMENT_OPTION = "UNKNOWN_PAYMENT_OPTION",
2543
+ MANUAL = "MANUAL"
2544
+ }
2545
+ /** @enumType */
2546
+ type GetCheckoutPaymentSettingsResponsePaymentOptionWithLiterals = GetCheckoutPaymentSettingsResponsePaymentOption | 'UNKNOWN_PAYMENT_OPTION' | 'MANUAL';
2547
+
2548
+ type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
2549
+ getUrl: (context: any) => string;
2550
+ httpMethod: K;
2551
+ path: string;
2552
+ pathParams: M;
2553
+ __requestType: T;
2554
+ __originalRequestType: S;
2555
+ __responseType: Q;
2556
+ __originalResponseType: R;
2557
+ };
2558
+ declare function createCheckout(): __PublicMethodMetaInfo<'POST', {}, CreateCheckoutRequest$1, CreateCheckoutRequest, CreateCheckoutResponse$1, CreateCheckoutResponse>;
2559
+ declare function getCheckout(): __PublicMethodMetaInfo<'GET', {
2560
+ id: string;
2561
+ }, GetCheckoutRequest$1, GetCheckoutRequest, GetCheckoutResponse$1, GetCheckoutResponse>;
2562
+ declare function getCheckoutByCartId(): __PublicMethodMetaInfo<'GET', {
2563
+ id: string;
2564
+ }, GetCheckoutByCartIdRequest$1, GetCheckoutByCartIdRequest, GetCheckoutByCartIdResponse$1, GetCheckoutByCartIdResponse>;
2565
+ declare function getWixCheckoutUrl(): __PublicMethodMetaInfo<'GET', {
2566
+ id: string;
2567
+ }, GetWixCheckoutURLRequest$1, GetWixCheckoutURLRequest, GetWixCheckoutURLResponse$1, GetWixCheckoutURLResponse>;
2568
+ declare function getCheckoutUrl(): __PublicMethodMetaInfo<'GET', {
2569
+ id: string;
2570
+ }, GetCheckoutURLRequest$1, GetCheckoutURLRequest, GetCheckoutURLResponse$1, GetCheckoutURLResponse>;
2571
+ declare function updateCheckout(): __PublicMethodMetaInfo<'PATCH', {
2572
+ checkoutId: string;
2573
+ }, UpdateCheckoutRequest$1, UpdateCheckoutRequest, UpdateCheckoutResponse$1, UpdateCheckoutResponse>;
2574
+ declare function removeCoupon(): __PublicMethodMetaInfo<'POST', {
2575
+ id: string;
2576
+ }, RemoveCouponRequest$1, RemoveCouponRequest, RemoveCouponResponse$1, RemoveCouponResponse>;
2577
+ declare function removeGiftCard(): __PublicMethodMetaInfo<'POST', {
2578
+ id: string;
2579
+ }, RemoveGiftCardRequest$1, RemoveGiftCardRequest, RemoveGiftCardResponse$1, RemoveGiftCardResponse>;
2580
+ declare function removeOverrideCheckoutUrl(): __PublicMethodMetaInfo<'POST', {
2581
+ id: string;
2582
+ }, RemoveOverrideCheckoutUrlRequest$1, RemoveOverrideCheckoutUrlRequest, RemoveOverrideCheckoutUrlResponse$1, RemoveOverrideCheckoutUrlResponse>;
2583
+ declare function addToCheckout(): __PublicMethodMetaInfo<'POST', {
2584
+ id: string;
2585
+ }, AddToCheckoutRequest$1, AddToCheckoutRequest, AddToCheckoutResponse$1, AddToCheckoutResponse>;
2586
+ declare function removeLineItems(): __PublicMethodMetaInfo<'POST', {
2587
+ id: string;
2588
+ }, RemoveLineItemsRequest$1, RemoveLineItemsRequest, RemoveLineItemsResponse$1, RemoveLineItemsResponse>;
2589
+ declare function createOrder(): __PublicMethodMetaInfo<'POST', {
2590
+ id: string;
2591
+ }, CreateOrderRequest$1, CreateOrderRequest, CreateOrderResponse$1, CreateOrderResponse>;
2592
+ declare function createOrderAndCharge(): __PublicMethodMetaInfo<'POST', {
2593
+ id: string;
2594
+ }, CreateOrderAndChargeRequest$1, CreateOrderAndChargeRequest, CreateOrderAndChargeResponse$1, CreateOrderAndChargeResponse>;
2595
+ declare function markCheckoutAsCompletedAndRedirectToUrl(): __PublicMethodMetaInfo<'GET', {}, MarkCheckoutAsCompletedAndRedirectToUrlRequest$1, MarkCheckoutAsCompletedAndRedirectToUrlRequest, RawHttpResponse$1, RawHttpResponse>;
2596
+ declare function markCheckoutAsCompleted(): __PublicMethodMetaInfo<'POST', {
2597
+ id: string;
2598
+ }, MarkCheckoutAsCompletedRequest$1, MarkCheckoutAsCompletedRequest, MarkCheckoutAsCompletedResponse$1, MarkCheckoutAsCompletedResponse>;
2599
+ declare function updateLineItemsQuantity(): __PublicMethodMetaInfo<'POST', {
2600
+ id: string;
2601
+ }, UpdateLineItemsQuantityRequest$1, UpdateLineItemsQuantityRequest, UpdateLineItemsQuantityResponse$1, UpdateLineItemsQuantityResponse>;
2602
+ declare function getCheckoutPaymentSettings(): __PublicMethodMetaInfo<'GET', {
2603
+ id: string;
2604
+ }, GetCheckoutPaymentSettingsRequest$1, GetCheckoutPaymentSettingsRequest, GetCheckoutPaymentSettingsResponse$1, GetCheckoutPaymentSettingsResponse>;
2605
+
2606
+ export { type __PublicMethodMetaInfo, addToCheckout, createCheckout, createOrder, createOrderAndCharge, getCheckout, getCheckoutByCartId, getCheckoutPaymentSettings, getCheckoutUrl, getWixCheckoutUrl, markCheckoutAsCompleted, markCheckoutAsCompletedAndRedirectToUrl, removeCoupon, removeGiftCard, removeLineItems, removeOverrideCheckoutUrl, updateCheckout, updateLineItemsQuantity };