@wix/auto_sdk_ecom_subscription-contracts 1.0.17 → 1.0.19

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 (132) hide show
  1. package/build/{cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.types.d.ts → ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal-C1mp-xS2.d.mts} +251 -398
  2. package/build/{es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.types.d.ts → ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal-C1mp-xS2.d.ts} +251 -398
  3. package/build/index.d.mts +39 -0
  4. package/build/index.d.ts +39 -0
  5. package/build/index.js +659 -0
  6. package/build/index.js.map +1 -0
  7. package/build/index.mjs +615 -0
  8. package/build/index.mjs.map +1 -0
  9. package/build/{cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.d.ts → internal/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal-WYe0iZSk.d.mts} +207 -447
  10. package/build/{es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.d.ts → internal/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal-WYe0iZSk.d.ts} +207 -447
  11. package/build/internal/index.d.mts +39 -0
  12. package/build/internal/index.d.ts +39 -0
  13. package/build/internal/index.js +659 -0
  14. package/build/internal/index.js.map +1 -0
  15. package/build/internal/index.mjs +615 -0
  16. package/build/internal/index.mjs.map +1 -0
  17. package/build/internal/{cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.types.d.ts → meta.d.mts} +93 -751
  18. package/build/internal/{es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.types.d.ts → meta.d.ts} +93 -751
  19. package/build/internal/meta.js +257 -0
  20. package/build/internal/meta.js.map +1 -0
  21. package/build/internal/meta.mjs +229 -0
  22. package/build/internal/meta.mjs.map +1 -0
  23. package/build/meta.d.mts +1320 -0
  24. package/build/meta.d.ts +1320 -0
  25. package/build/meta.js +257 -0
  26. package/build/meta.js.map +1 -0
  27. package/build/meta.mjs +229 -0
  28. package/build/meta.mjs.map +1 -0
  29. package/package.json +13 -12
  30. package/build/cjs/index.d.ts +0 -1
  31. package/build/cjs/index.js +0 -18
  32. package/build/cjs/index.js.map +0 -1
  33. package/build/cjs/index.typings.d.ts +0 -1
  34. package/build/cjs/index.typings.js +0 -18
  35. package/build/cjs/index.typings.js.map +0 -1
  36. package/build/cjs/meta.d.ts +0 -1
  37. package/build/cjs/meta.js +0 -18
  38. package/build/cjs/meta.js.map +0 -1
  39. package/build/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.context.d.ts +0 -16
  40. package/build/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.context.js +0 -35
  41. package/build/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.context.js.map +0 -1
  42. package/build/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.http.d.ts +0 -14
  43. package/build/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.http.js +0 -198
  44. package/build/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.http.js.map +0 -1
  45. package/build/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.meta.d.ts +0 -16
  46. package/build/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.meta.js +0 -66
  47. package/build/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.meta.js.map +0 -1
  48. package/build/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.d.ts +0 -32
  49. package/build/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.js +0 -153
  50. package/build/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.js.map +0 -1
  51. package/build/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.types.js +0 -161
  52. package/build/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.types.js.map +0 -1
  53. package/build/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js +0 -342
  54. package/build/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js.map +0 -1
  55. package/build/es/index.d.ts +0 -1
  56. package/build/es/index.js +0 -2
  57. package/build/es/index.js.map +0 -1
  58. package/build/es/index.typings.d.ts +0 -1
  59. package/build/es/index.typings.js +0 -2
  60. package/build/es/index.typings.js.map +0 -1
  61. package/build/es/meta.d.ts +0 -1
  62. package/build/es/meta.js +0 -2
  63. package/build/es/meta.js.map +0 -1
  64. package/build/es/package.json +0 -3
  65. package/build/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.context.d.ts +0 -16
  66. package/build/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.context.js +0 -16
  67. package/build/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.context.js.map +0 -1
  68. package/build/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.http.d.ts +0 -14
  69. package/build/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.http.js +0 -193
  70. package/build/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.http.js.map +0 -1
  71. package/build/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.meta.d.ts +0 -16
  72. package/build/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.meta.js +0 -38
  73. package/build/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.meta.js.map +0 -1
  74. package/build/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.d.ts +0 -32
  75. package/build/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.js +0 -132
  76. package/build/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.js.map +0 -1
  77. package/build/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.types.js +0 -158
  78. package/build/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.types.js.map +0 -1
  79. package/build/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js +0 -314
  80. package/build/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js.map +0 -1
  81. package/build/internal/cjs/index.d.ts +0 -1
  82. package/build/internal/cjs/index.js +0 -18
  83. package/build/internal/cjs/index.js.map +0 -1
  84. package/build/internal/cjs/index.typings.d.ts +0 -1
  85. package/build/internal/cjs/index.typings.js +0 -18
  86. package/build/internal/cjs/index.typings.js.map +0 -1
  87. package/build/internal/cjs/meta.d.ts +0 -1
  88. package/build/internal/cjs/meta.js +0 -18
  89. package/build/internal/cjs/meta.js.map +0 -1
  90. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.context.d.ts +0 -16
  91. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.context.js +0 -35
  92. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.context.js.map +0 -1
  93. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.http.d.ts +0 -14
  94. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.http.js +0 -198
  95. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.http.js.map +0 -1
  96. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.meta.d.ts +0 -16
  97. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.meta.js +0 -66
  98. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.meta.js.map +0 -1
  99. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.d.ts +0 -32
  100. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.js +0 -153
  101. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.js.map +0 -1
  102. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.types.js +0 -161
  103. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.types.js.map +0 -1
  104. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.d.ts +0 -2251
  105. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js +0 -342
  106. package/build/internal/cjs/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js.map +0 -1
  107. package/build/internal/es/index.d.ts +0 -1
  108. package/build/internal/es/index.js +0 -2
  109. package/build/internal/es/index.js.map +0 -1
  110. package/build/internal/es/index.typings.d.ts +0 -1
  111. package/build/internal/es/index.typings.js +0 -2
  112. package/build/internal/es/index.typings.js.map +0 -1
  113. package/build/internal/es/meta.d.ts +0 -1
  114. package/build/internal/es/meta.js +0 -2
  115. package/build/internal/es/meta.js.map +0 -1
  116. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.context.d.ts +0 -16
  117. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.context.js +0 -16
  118. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.context.js.map +0 -1
  119. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.http.d.ts +0 -14
  120. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.http.js +0 -193
  121. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.http.js.map +0 -1
  122. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.meta.d.ts +0 -16
  123. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.meta.js +0 -38
  124. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.meta.js.map +0 -1
  125. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.d.ts +0 -32
  126. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.js +0 -132
  127. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.js.map +0 -1
  128. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.types.js +0 -158
  129. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.types.js.map +0 -1
  130. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.d.ts +0 -2251
  131. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js +0 -314
  132. package/build/internal/es/src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js.map +0 -1
@@ -1,2251 +0,0 @@
1
- /**
2
- * A SubscriptionContract is a ...
3
- * You can ...
4
- * Read more about SubscriptionContracts
5
- * in this [article](<LINK_TO_KB_ARTICLE>).
6
- */
7
- export interface SubscriptionContract {
8
- /**
9
- * SubscriptionContract ID.
10
- * @format GUID
11
- * @readonly
12
- */
13
- _id?: string | null;
14
- /**
15
- * Revision number, which increments by 1 each time the SubscriptionContract is updated.
16
- * To prevent conflicting changes, the current revision must be passed when updating the SubscriptionContract.
17
- *
18
- * Ignored when creating a SubscriptionOrderContract.
19
- * @readonly
20
- */
21
- revision?: string | null;
22
- /**
23
- * Date and time the subscription contract was created in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format.
24
- * @readonly
25
- */
26
- _createdDate?: Date | null;
27
- /**
28
- * Date and time the subscription contract was last updated in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format.
29
- * @readonly
30
- */
31
- _updatedDate?: Date | null;
32
- /**
33
- * Subscription option description. For example, `"1kg of selected coffee, once a month"`.
34
- * @maxLength 500
35
- * @deprecated Subscription option description. For example, `"1kg of selected coffee, once a month"`.
36
- * @replacedBy subscription_description
37
- * @targetRemovalDate 2025-10-01
38
- */
39
- description?: string | null;
40
- /**
41
- * Subscription option description. For example, `"1kg of selected coffee, once a month"`.
42
- * @internal
43
- */
44
- subscriptionDescription?: V1SubscriptionDescription;
45
- /**
46
- * Subscription detailed information.
47
- * @immutable
48
- */
49
- subscriptionSettings?: V1SubscriptionSettings;
50
- /**
51
- * Order line items.
52
- * @minSize 1
53
- * @maxSize 1
54
- * @readonly
55
- */
56
- lineItems?: OrderLineItem[];
57
- /** Buyer information. */
58
- buyerInfo?: BuyerInfo;
59
- /**
60
- * Language for communication with the buyer. Defaults to the site language.
61
- * For a site that supports multiple languages, this is the language the buyer selected.
62
- */
63
- buyerLanguage?: string | null;
64
- /** Weight measurement unit - defaults to site's weight unit. */
65
- weightUnit?: WeightUnit;
66
- /**
67
- * Currency used for the pricing of this order in [ISO-4217](https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes) format.
68
- * @format CURRENCY
69
- * @immutable
70
- */
71
- currency?: string | null;
72
- /** Multi-currency information of the subscription. conversionRate may reflect updated exchange rate on created order per recurring cycle. */
73
- currencyConversionDetails?: CurrencyConversionDetails;
74
- /**
75
- * Whether tax is included in line item prices.
76
- *
77
- * Default: `false`
78
- * @immutable
79
- */
80
- taxIncludedInPrices?: boolean;
81
- /**
82
- * Order price summary.
83
- * @readonly
84
- */
85
- priceSummary?: PriceSummary;
86
- /** Billing address and contact details. */
87
- billingInfo?: AddressWithContact;
88
- /** Shipping info and selected shipping option details. */
89
- shippingInfo?: ShippingInformation;
90
- /** Applied discounts. */
91
- appliedDiscounts?: AppliedDiscount[];
92
- /** Information about the sales channel that submitted this order. */
93
- channelInfo?: ChannelInfo;
94
- /** Custom fields. */
95
- customFields?: CustomField[];
96
- /**
97
- * Order recipient address and contact details.
98
- *
99
- * This field may differ from the address in `shippingInfo.logistics` when:
100
- * + The chosen shipping option is pickup point or store pickup.
101
- * + No shipping option is selected.
102
- */
103
- recipientInfo?: AddressWithContact;
104
- /**
105
- * Custom field data for the subscription contract object.
106
- *
107
- * [Extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields) must be configured in the [app dashboard](https://dev.wix.com/dc3/my-apps/) before they can be accessed with API calls.
108
- */
109
- extendedFields?: ExtendedFields;
110
- /**
111
- * Subscription option title. For example, `"Monthly coffee Subscription"`.
112
- * @maxLength 150
113
- * @deprecated Subscription option title. For example, `"Monthly coffee Subscription"`.
114
- * @replacedBy subscription_title
115
- * @targetRemovalDate 2025-10-01
116
- */
117
- title?: string | null;
118
- /**
119
- * Subscription title. For example, `"Monthly coffee Subscription"`.
120
- * @internal
121
- */
122
- subscriptionTitle?: V1SubscriptionTitle;
123
- /**
124
- * Additional fees applied to subscription contract.
125
- * @maxSize 100
126
- */
127
- additionalFees?: AdditionalFee[];
128
- }
129
- export interface V1SubscriptionDescription {
130
- /**
131
- * Subscription option description.
132
- * @maxLength 500
133
- */
134
- original?: string;
135
- /**
136
- * Translated subscription option description.
137
- * @maxLength 500
138
- */
139
- translated?: string | null;
140
- }
141
- export interface V1SubscriptionSettings {
142
- /** Frequency of recurring payment. */
143
- frequency?: SubscriptionFrequency;
144
- /**
145
- * Interval of recurring payment.
146
- * @min 1
147
- * @max 50
148
- */
149
- interval?: number | null;
150
- /** Whether subscription is renewed automatically at the end of each period. */
151
- autoRenewal?: boolean;
152
- /**
153
- * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`.
154
- * @min 1
155
- */
156
- billingCycles?: number | null;
157
- /** Whether to allow the customer to cancel the subscription. */
158
- enableCustomerCancellation?: boolean;
159
- /**
160
- * Period until first cycle starts. If None => no free trial
161
- * @internal
162
- */
163
- freeTrialPeriod?: V1FreeTrialPeriod;
164
- /**
165
- * The date the subscription will start. The subscription will be charged either now or according to freeTrialDays.
166
- * @internal
167
- */
168
- startDate?: Date | null;
169
- }
170
- export declare enum SubscriptionFrequency {
171
- UNDEFINED = "UNDEFINED",
172
- DAY = "DAY",
173
- WEEK = "WEEK",
174
- MONTH = "MONTH",
175
- YEAR = "YEAR"
176
- }
177
- export interface V1FreeTrialPeriod {
178
- /** Frequency of period. Values: DAY, WEEK, MONTH, YEAR */
179
- frequency?: SubscriptionFrequency;
180
- /**
181
- * interval of period
182
- * @min 1
183
- * @max 999
184
- */
185
- interval?: number;
186
- }
187
- export interface OrderLineItem {
188
- /**
189
- * Line item ID.
190
- * @immutable
191
- */
192
- _id?: string;
193
- /**
194
- * Item name.
195
- * + Stores - `product.name`
196
- * + Bookings - `service.info.name`
197
- * + Events - `ticket.name`
198
- */
199
- productName?: ProductName;
200
- /**
201
- * References to the line item's origin catalog.
202
- * This field may be empty in the case of a custom line item.
203
- */
204
- catalogReference?: CatalogReference;
205
- /**
206
- * Line item quantity.
207
- * @min 1
208
- * @max 100000
209
- */
210
- quantity?: number;
211
- /**
212
- * Total discount for this line item's entire quantity.
213
- * @readonly
214
- */
215
- totalDiscount?: Price;
216
- /**
217
- * Line item description lines. Used for display purposes for the cart, checkout and order.
218
- * @maxSize 20
219
- */
220
- descriptionLines?: DescriptionLine[];
221
- /** Line item image. */
222
- image?: string;
223
- /** Physical properties of the item. When relevant, contains information such as SKU and item weight. */
224
- physicalProperties?: PhysicalProperties;
225
- /** Item type. Either a preset type or custom. */
226
- itemType?: ItemType;
227
- /**
228
- * Fulfiller ID. Field is empty when the line item is self-fulfilled.
229
- * To get fulfillment information, pass the order ID to [List Fulfillments For Single Order](https://dev.wix.com/docs/rest/api-reference/wix-e-commerce/order-fulfillments/list-fulfillments-for-single-order).
230
- * @format GUID
231
- */
232
- fulfillerId?: string | null;
233
- /**
234
- * Number of items that were refunded.
235
- * @max 100000
236
- */
237
- refundQuantity?: number | null;
238
- /**
239
- * Number of items restocked.
240
- * @max 100000
241
- */
242
- restockQuantity?: number | null;
243
- /** Line item price after line item discounts for display purposes. */
244
- price?: Price;
245
- /**
246
- * Line item price before line item discounts for display purposes. Defaults to `price` when not provided.
247
- * @readonly
248
- */
249
- priceBeforeDiscounts?: Price;
250
- /**
251
- * Total price after discounts, and before tax.
252
- * @readonly
253
- */
254
- totalPriceBeforeTax?: Price;
255
- /**
256
- * Total price after all discounts and tax.
257
- * @readonly
258
- */
259
- totalPriceAfterTax?: Price;
260
- /**
261
- * Type of selected payment option for current item.
262
- *
263
- * Default: `FULL_PAYMENT_ONLINE`
264
- */
265
- paymentOption?: PaymentOptionType;
266
- /**
267
- * Deprecated. Use `taxInfo` instead.
268
- * This field will be removed on September 30, 2024.
269
- * Tax details for this line item.
270
- * @deprecated Deprecated. Use `taxInfo` instead.
271
- * This field will be removed on September 30, 2024.
272
- * Tax details for this line item.
273
- * @replacedBy tax_info
274
- * @targetRemovalDate 2024-09-30
275
- */
276
- taxDetails?: ItemTaxFullDetails;
277
- /** Represents all the relevant tax details for a specific line item. */
278
- taxInfo?: LineItemTaxInfo;
279
- /** Digital file identifier, relevant only for items with type DIGITAL. */
280
- digitalFile?: DigitalFile;
281
- /** Subscription info. */
282
- subscriptionInfo?: SubscriptionInfo;
283
- /** Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67". */
284
- priceDescription?: PriceDescription;
285
- /**
286
- * Item's price amount to be charged during checkout. Relevant for items with a `paymentOption` value of `"DEPOSIT_ONLINE"`.
287
- * @readonly
288
- */
289
- depositAmount?: Price;
290
- /**
291
- * Line item locations.
292
- *
293
- * The location's total quantity must not exceed the line item quantity.
294
- * @maxSize 5
295
- */
296
- locations?: LocationAndQuantity[];
297
- /**
298
- * Address used for tax calculation.
299
- * @internal
300
- */
301
- taxableAddress?: TaxableAddress;
302
- /**
303
- * ID of the app managing the inventory.
304
- * @internal
305
- * @format GUID
306
- */
307
- inventoryAppId?: string | null;
308
- /**
309
- * Custom extended fields for the line item object.
310
- *
311
- * [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.
312
- */
313
- extendedFields?: ExtendedFields;
314
- }
315
- export interface ProductName {
316
- /**
317
- * __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).
318
- *
319
- * Min: 1 character.
320
- * Max: 200 characters.
321
- * @minLength 1
322
- * @maxLength 200
323
- */
324
- original?: string;
325
- /**
326
- * Item name translated into the buyer's language.
327
- *
328
- * Min: 1 character.
329
- * Max: 400 characters.
330
- * Default: Same as `original`.
331
- * @minLength 1
332
- * @maxLength 400
333
- */
334
- translated?: string | null;
335
- }
336
- /** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */
337
- export interface CatalogReference {
338
- /**
339
- * ID of the item within the catalog it belongs to.
340
- * @minLength 1
341
- * @maxLength 36
342
- */
343
- catalogItemId?: string;
344
- /**
345
- * ID of the app providing the catalog.
346
- *
347
- * You can get your app's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).
348
- *
349
- * For items from Wix catalogs, the following values always apply:
350
- * + Wix Stores: `"215238eb-22a5-4c36-9e7b-e7c08025e04e"`
351
- * + Wix Bookings: `"13d21c63-b5ec-5912-8397-c3a5ddb27a97"`
352
- * + Wix Restaurants: `"9a5d83fd-8570-482e-81ab-cfa88942ee60"`
353
- * @minLength 1
354
- */
355
- appId?: string;
356
- /**
357
- * 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.
358
- *
359
- * 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)).
360
- */
361
- options?: Record<string, any> | null;
362
- }
363
- export interface Price {
364
- /**
365
- * Amount.
366
- * @decimalValue options { gte:0, lte:1000000000000000 }
367
- */
368
- amount?: string;
369
- /**
370
- * Amount formatted with currency symbol.
371
- * @readonly
372
- */
373
- formattedAmount?: string;
374
- }
375
- export interface DescriptionLine extends DescriptionLineValueOneOf, DescriptionLineDescriptionLineValueOneOf {
376
- /** Description line plain text value. */
377
- plainText?: PlainTextValue;
378
- /** Description line color value. */
379
- colorInfo?: Color;
380
- /** Description line name. */
381
- name?: DescriptionLineName;
382
- }
383
- /** @oneof */
384
- export interface DescriptionLineValueOneOf {
385
- /** Description line plain text value. */
386
- plainText?: PlainTextValue;
387
- /** Description line color value. */
388
- colorInfo?: Color;
389
- }
390
- /** @oneof */
391
- export interface DescriptionLineDescriptionLineValueOneOf {
392
- }
393
- export interface DescriptionLineName {
394
- /**
395
- * 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).
396
- * @maxLength 100
397
- */
398
- original?: string;
399
- /**
400
- * Description line name translated into the buyer's language.
401
- *
402
- * Default: Same as `original`.
403
- * @maxLength 200
404
- */
405
- translated?: string | null;
406
- }
407
- export interface PlainTextValue {
408
- /**
409
- * 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).
410
- * @maxLength 600
411
- */
412
- original?: string;
413
- /**
414
- * Description line plain text value translated into the buyer's language.
415
- *
416
- * Default: Same as `original`.
417
- * @maxLength 600
418
- */
419
- translated?: string | null;
420
- }
421
- export interface Color {
422
- /**
423
- * 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).
424
- * @maxLength 500
425
- */
426
- original?: string;
427
- /**
428
- * Description line color name translated into the buyer's language.
429
- *
430
- * Default: Same as `original`.
431
- * @maxLength 500
432
- */
433
- translated?: string | null;
434
- /** HEX or RGB color code for display. */
435
- code?: string | null;
436
- }
437
- export declare enum DescriptionLineType {
438
- /** Unrecognized type. */
439
- UNRECOGNISED = "UNRECOGNISED",
440
- /** Plain text type. */
441
- PLAIN_TEXT = "PLAIN_TEXT",
442
- /** Color type. */
443
- COLOR = "COLOR"
444
- }
445
- export interface FocalPoint {
446
- /** X-coordinate of the focal point. */
447
- x?: number;
448
- /** Y-coordinate of the focal point. */
449
- y?: number;
450
- /** crop by height */
451
- height?: number | null;
452
- /** crop by width */
453
- width?: number | null;
454
- }
455
- export interface PhysicalProperties {
456
- /** Line item weight. Measurement unit matches the weight unit specified in `weightUnit` in the request. */
457
- weight?: number | null;
458
- /**
459
- * Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku).
460
- * @maxLength 40
461
- */
462
- sku?: string | null;
463
- /** Whether this line item is shippable. */
464
- shippable?: boolean;
465
- }
466
- export interface ItemType extends ItemTypeItemTypeDataOneOf {
467
- /** Preset item type. */
468
- preset?: ItemTypeItemType;
469
- /** Custom item type. When none of the preset types are suitable, specifies the custom type. */
470
- custom?: string;
471
- }
472
- /** @oneof */
473
- export interface ItemTypeItemTypeDataOneOf {
474
- /** Preset item type. */
475
- preset?: ItemTypeItemType;
476
- /** Custom item type. When none of the preset types are suitable, specifies the custom type. */
477
- custom?: string;
478
- }
479
- export declare enum ItemTypeItemType {
480
- UNRECOGNISED = "UNRECOGNISED",
481
- PHYSICAL = "PHYSICAL",
482
- DIGITAL = "DIGITAL",
483
- GIFT_CARD = "GIFT_CARD",
484
- SERVICE = "SERVICE"
485
- }
486
- /** Type of selected payment option for catalog item */
487
- export declare enum PaymentOptionType {
488
- /** The entire payment for this item happens as part of the checkout. */
489
- FULL_PAYMENT_ONLINE = "FULL_PAYMENT_ONLINE",
490
- /** The entire payment for this item happens after checkout. For example, when using cash, check, or other offline payment methods. */
491
- FULL_PAYMENT_OFFLINE = "FULL_PAYMENT_OFFLINE",
492
- /** Payment for this item is done by charging a membership. When selected, `price` is `0`. */
493
- MEMBERSHIP = "MEMBERSHIP",
494
- /** Partial payment to be paid upfront during checkout. The initial amount to be paid for each line item is specified in `depositAmount`. */
495
- DEPOSIT_ONLINE = "DEPOSIT_ONLINE",
496
- /** 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`. */
497
- MEMBERSHIP_OFFLINE = "MEMBERSHIP_OFFLINE"
498
- }
499
- export interface ItemTaxFullDetails {
500
- /** Taxable amount of this line item. */
501
- taxableAmount?: Price;
502
- /**
503
- * Tax rate percentage, as a decimal numeral between 0 and 1. For example, `"0.13"`.
504
- * @decimalValue options { gte:0, maxScale:6 }
505
- */
506
- taxRate?: string;
507
- /** The calculated tax, based on the `taxableAmount` and `taxRate`. */
508
- totalTax?: Price;
509
- }
510
- export interface LineItemTaxInfo {
511
- /** Calculated tax, based on `taxable_amount` and `tax_rate`. */
512
- taxAmount?: Price;
513
- /** Amount for which tax is calculated. */
514
- taxableAmount?: Price;
515
- /**
516
- * Tax rate %, as a decimal point.
517
- * @format DECIMAL_VALUE
518
- * @decimalValue options { gte:0, maxScale:6 }
519
- */
520
- taxRate?: string | null;
521
- /**
522
- * Tax group ID.
523
- * @format GUID
524
- */
525
- taxGroupId?: string | null;
526
- /** Indicates whether the price already includes tax. */
527
- taxIncludedInPrice?: boolean;
528
- /**
529
- * Tax information for a line item.
530
- * @maxSize 7
531
- */
532
- taxBreakdown?: LineItemTaxBreakdown[];
533
- }
534
- /**
535
- * TaxBreakdown represents tax information for a line item.
536
- * It holds the tax amount and the tax rate for each tax authority that apply on the line item.
537
- */
538
- export interface LineItemTaxBreakdown {
539
- /**
540
- * Jurisdiction that taxes were calculated for. For example, "New York", or "Quebec".
541
- * @maxLength 200
542
- */
543
- jurisdiction?: string | null;
544
- /**
545
- * Tax rate used for this jurisdiction, as a decimal. For example, 10% tax is 0.1000.
546
- * @format DECIMAL_VALUE
547
- * @decimalValue options { gte:0, maxScale:6 }
548
- */
549
- rate?: string | null;
550
- /** Amount of tax calculated for this line item. */
551
- taxAmount?: Price;
552
- /**
553
- * The type of tax that was calculated. Depends on the jurisdiction's tax laws. For example, "Sales Tax", "Income Tax", "Value Added Tax", etc.
554
- * @maxLength 200
555
- */
556
- taxType?: string | null;
557
- /**
558
- * The name of the tax against which this tax amount was calculated. For example, "NY State Sales Tax", "Quebec GST", etc.
559
- * This name should be explicit enough to allow the merchant to understand what tax was calculated.
560
- * @maxLength 200
561
- */
562
- taxName?: string | null;
563
- /** Type of jurisdiction that taxes were calculated for. */
564
- jurisdictionType?: JurisdictionType;
565
- /** Non-taxable amount of the line item price. */
566
- nonTaxableAmount?: Price;
567
- /** Taxable amount of the line item price. */
568
- taxableAmount?: Price;
569
- }
570
- /** JurisdictionType represents the type of the jurisdiction in which this tax detail applies (e.g. Country,State,County,City,Special). */
571
- export declare enum JurisdictionType {
572
- UNDEFINED = "UNDEFINED",
573
- COUNTRY = "COUNTRY",
574
- STATE = "STATE",
575
- COUNTY = "COUNTY",
576
- CITY = "CITY",
577
- SPECIAL = "SPECIAL"
578
- }
579
- export interface DigitalFile {
580
- /**
581
- * ID of the secure file in media.
582
- * @minLength 1
583
- * @maxLength 100
584
- */
585
- fileId?: string;
586
- /**
587
- * Link will exist after the digital links have been generated on the order.
588
- * @format WEB_URL
589
- * @minLength 1
590
- * @maxLength 2000
591
- */
592
- link?: string | null;
593
- /**
594
- * Link expiration time and date.
595
- * @readonly
596
- */
597
- expirationDate?: Date | null;
598
- }
599
- export interface SubscriptionInfo {
600
- /**
601
- * Subscription ID.
602
- * @format GUID
603
- */
604
- _id?: string | null;
605
- /**
606
- * Subscription cycle. For example, if this order is for the 3rd cycle of a subscription, value will be `3`.
607
- * @min 1
608
- */
609
- cycleNumber?: number;
610
- /**
611
- * Subscription option title. For example, `"Monthly coffee Subscription"`.
612
- * @maxLength 20
613
- * @deprecated Subscription option title. For example, `"Monthly coffee Subscription"`.
614
- * @replacedBy title
615
- * @targetRemovalDate 2025-10-01
616
- */
617
- subscriptionOptionTitle?: string;
618
- /**
619
- * Subscription title. For example, `"Monthly coffee Subscription"`.
620
- * @internal
621
- */
622
- title?: SubscriptionTitle;
623
- /**
624
- * Subscription option description. For example, `"1kg of selected coffee, once a month"`.
625
- * @maxLength 60
626
- * @deprecated Subscription option description. For example, `"1kg of selected coffee, once a month"`.
627
- * @replacedBy description
628
- * @targetRemovalDate 2025-10-01
629
- */
630
- subscriptionOptionDescription?: string | null;
631
- /**
632
- * Subscription description. For example, `"1kg of selected coffee, once a month"`.
633
- * @internal
634
- */
635
- description?: SubscriptionDescription;
636
- /**
637
- * Subscription detailed information.
638
- * @immutable
639
- */
640
- subscriptionSettings?: SubscriptionSettings;
641
- /**
642
- * Description of the charges that will be applied for subscription.
643
- * @internal
644
- * @maxLength 1000
645
- */
646
- chargesDescription?: string | null;
647
- /**
648
- * Details of the billing adjustment applied to the current subscription cycle due to a shift in the subscription’s billing date.
649
- * @internal
650
- */
651
- billingAdjustment?: BillingAdjustment;
652
- }
653
- export interface SubscriptionTitle {
654
- /**
655
- * 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).
656
- * @minLength 1
657
- * @maxLength 150
658
- */
659
- original?: string;
660
- /**
661
- * Subscription option name translated into the buyer's language.
662
- *
663
- * Default: Same as `original`.
664
- * @minLength 1
665
- * @maxLength 150
666
- */
667
- translated?: string | null;
668
- }
669
- export interface SubscriptionDescription {
670
- /**
671
- * Subscription option description.
672
- * @maxLength 500
673
- */
674
- original?: string;
675
- /**
676
- * Translated subscription option description.
677
- * @maxLength 500
678
- */
679
- translated?: string | null;
680
- }
681
- export interface SubscriptionSettings {
682
- /** Frequency of recurring payment. */
683
- frequency?: V2SubscriptionFrequency;
684
- /**
685
- * Interval of recurring payment.
686
- * @min 1
687
- * @max 50
688
- */
689
- interval?: number | null;
690
- /** Whether subscription is renewed automatically at the end of each period. */
691
- autoRenewal?: boolean;
692
- /**
693
- * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`.
694
- * @min 1
695
- */
696
- billingCycles?: number | null;
697
- /**
698
- * Whether to allow the customer to cancel the subscription.
699
- * @internal
700
- */
701
- enableCustomerCancellation?: boolean;
702
- /**
703
- * Period until first cycle starts. If None => no free trial
704
- * @internal
705
- */
706
- freeTrialPeriod?: FreeTrialPeriod;
707
- /**
708
- * The date the subscription will start. The subscription will be charged either now or according to freeTrialDays.
709
- * @internal
710
- */
711
- startDate?: Date | null;
712
- }
713
- /** Frequency unit of recurring payment */
714
- export declare enum V2SubscriptionFrequency {
715
- UNDEFINED = "UNDEFINED",
716
- DAY = "DAY",
717
- WEEK = "WEEK",
718
- MONTH = "MONTH",
719
- YEAR = "YEAR"
720
- }
721
- export interface FreeTrialPeriod {
722
- /** Frequency of period. Values: DAY, WEEK, MONTH, YEAR */
723
- frequency?: V2SubscriptionFrequency;
724
- /**
725
- * interval of period
726
- * @min 1
727
- * @max 999
728
- */
729
- interval?: number;
730
- }
731
- export interface BillingAdjustment {
732
- /** The type of adjustment. */
733
- type?: AdjustmentType;
734
- /** Summary of the prorated adjustment amount. */
735
- priceSummary?: BillingAdjustmentPriceSummary;
736
- }
737
- export declare enum AdjustmentType {
738
- UNKNOWN_ADJUSTMENT_TYPE = "UNKNOWN_ADJUSTMENT_TYPE",
739
- /** Adjustment increases the total amount due to changes like covering extra billing days. Typically results in an additional fee. */
740
- EXTRA_CHARGE = "EXTRA_CHARGE",
741
- /** Adjustment reduces the total amount due to changes like covering fewer billing days. Typically results in a credit or discount. */
742
- CREDIT = "CREDIT"
743
- }
744
- export interface BillingAdjustmentPriceSummary {
745
- /** Subtotal of adjustment, before tax. */
746
- subtotal?: Price;
747
- /** Tax on adjustment. */
748
- tax?: Price;
749
- /** Total price after tax. */
750
- total?: Price;
751
- }
752
- export interface PriceDescription {
753
- /**
754
- * __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).
755
- * @minLength 1
756
- * @maxLength 100
757
- */
758
- original?: string;
759
- /**
760
- * Price description translated into the buyer's language.
761
- *
762
- * Default: Same as `original`.
763
- * @minLength 1
764
- * @maxLength 100
765
- */
766
- translated?: string | null;
767
- }
768
- export interface LocationAndQuantity {
769
- /**
770
- * Location id in the associated owner app.
771
- * @format GUID
772
- */
773
- _id?: string;
774
- /**
775
- * Location owner app, if not provided then the site business info locations will be used.
776
- * @format GUID
777
- * @deprecated Location owner app, if not provided then the site business info locations will be used.
778
- * @targetRemovalDate 2025-03-01
779
- */
780
- appId?: string | null;
781
- /**
782
- * Quantity for specific location.
783
- * @min 1
784
- * @max 100000
785
- */
786
- quantity?: number;
787
- /**
788
- * Location name.
789
- * @maxLength 500
790
- * @readonly
791
- */
792
- name?: string | null;
793
- }
794
- export interface TaxableAddress extends TaxableAddressTaxableAddressDataOneOf {
795
- /** taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. */
796
- addressType?: TaxableAddressType;
797
- }
798
- /** @oneof */
799
- export interface TaxableAddressTaxableAddressDataOneOf {
800
- /** taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. */
801
- addressType?: TaxableAddressType;
802
- }
803
- export declare enum TaxableAddressType {
804
- UNKNOWN_TAXABLE_ADDRESS = "UNKNOWN_TAXABLE_ADDRESS",
805
- BUSINESS = "BUSINESS",
806
- BILLING = "BILLING",
807
- SHIPPING = "SHIPPING"
808
- }
809
- export interface ExtendedFields {
810
- /**
811
- * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.
812
- * The value of each key is structured according to the schema defined when the extended fields were configured.
813
- *
814
- * You can only access fields for which you have the appropriate permissions.
815
- *
816
- * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).
817
- */
818
- namespaces?: Record<string, Record<string, any>>;
819
- }
820
- /** Buyer Info */
821
- export interface BuyerInfo extends BuyerInfoIdOneOf {
822
- /**
823
- * Visitor ID (if site visitor is not a member).
824
- * @format GUID
825
- */
826
- visitorId?: string;
827
- /**
828
- * Member ID (if site visitor is a site member).
829
- * @format GUID
830
- */
831
- memberId?: string;
832
- /**
833
- * Contact ID. Auto-created if one does not yet exist. For more information, see [Contacts API](https://dev.wix.com/api/rest/contacts/contacts/introduction).
834
- * @format GUID
835
- */
836
- contactId?: string | null;
837
- /**
838
- * Buyer email address.
839
- * @format EMAIL
840
- */
841
- email?: string | null;
842
- }
843
- /** @oneof */
844
- export interface BuyerInfoIdOneOf {
845
- /**
846
- * Visitor ID (if site visitor is not a member).
847
- * @format GUID
848
- */
849
- visitorId?: string;
850
- /**
851
- * Member ID (if site visitor is a site member).
852
- * @format GUID
853
- */
854
- memberId?: string;
855
- }
856
- export declare enum WeightUnit {
857
- /** Weight unit can't be classified due to an error. */
858
- UNSPECIFIED_WEIGHT_UNIT = "UNSPECIFIED_WEIGHT_UNIT",
859
- /** Kilograms. */
860
- KG = "KG",
861
- /** Pounds. */
862
- LB = "LB"
863
- }
864
- export interface CurrencyConversionDetails {
865
- /**
866
- * Original currency used to calculate the pricing before conversion to payment currency set on the order [ISO-4217](https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes) format.
867
- * @readonly
868
- * @immutable
869
- * @format CURRENCY
870
- */
871
- originalCurrency?: string | null;
872
- /**
873
- * The rate used when converting from the original currency to the payment currency.
874
- * @readonly
875
- * @immutable
876
- * @decimalValue options { gt:0, lte:1000000000000000 }
877
- */
878
- conversionRate?: string | null;
879
- }
880
- export interface PriceSummary {
881
- /** Subtotal of all the line items, before discounts and before tax. */
882
- subtotal?: Price;
883
- /** Total shipping price, before discounts and before tax. */
884
- shipping?: Price;
885
- /** Total tax on this order. */
886
- tax?: Price;
887
- /** Total calculated discount value. */
888
- discount?: Price;
889
- /** Order’s total price after discounts and tax. */
890
- total?: Price;
891
- /** Total price of additional fees before tax. */
892
- totalAdditionalFees?: Price;
893
- }
894
- /** Billing Info and shipping details */
895
- export interface AddressWithContact {
896
- /** Address. */
897
- address?: Address;
898
- /** Contact details. */
899
- contactDetails?: FullAddressContactDetails;
900
- }
901
- /** Physical address */
902
- export interface Address {
903
- /**
904
- * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format.
905
- * @format COUNTRY
906
- */
907
- country?: string | null;
908
- /**
909
- * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format.
910
- * @maxLength 50
911
- */
912
- subdivision?: string | null;
913
- /**
914
- * City name.
915
- * @maxLength 50
916
- */
917
- city?: string | null;
918
- /**
919
- * Postal or zip code.
920
- * @maxLength 50
921
- */
922
- postalCode?: string | null;
923
- /** Street address. */
924
- streetAddress?: StreetAddress;
925
- /**
926
- * Main address line (usually street name and number).
927
- * @maxLength 150
928
- */
929
- addressLine1?: string | null;
930
- /**
931
- * Free text providing more detailed address info. Usually contains apt, suite, floor.
932
- * @maxLength 100
933
- */
934
- addressLine2?: string | null;
935
- /**
936
- * Country's full name.
937
- * @readonly
938
- */
939
- countryFullname?: string | null;
940
- /**
941
- * Subdivision full-name.
942
- * @readonly
943
- */
944
- subdivisionFullname?: string | null;
945
- }
946
- export interface StreetAddress {
947
- /** Street number. */
948
- number?: string;
949
- /** Street name. */
950
- name?: string;
951
- }
952
- export interface AddressLocation {
953
- /** Address latitude. */
954
- latitude?: number | null;
955
- /** Address longitude. */
956
- longitude?: number | null;
957
- }
958
- /** Full contact details for an address */
959
- export interface FullAddressContactDetails {
960
- /**
961
- * First name.
962
- * @maxLength 100
963
- */
964
- firstName?: string | null;
965
- /**
966
- * Last name.
967
- * @maxLength 100
968
- */
969
- lastName?: string | null;
970
- /**
971
- * Phone number.
972
- * @format PHONE
973
- */
974
- phone?: string | null;
975
- /**
976
- * Company name.
977
- * @maxLength 1000
978
- */
979
- company?: string | null;
980
- /** Tax information (for Brazil only). If ID is provided, `vatId.type` must also be set, `UNSPECIFIED` is not allowed. */
981
- vatId?: VatId;
982
- }
983
- export interface VatId {
984
- /** Customer's tax ID. */
985
- _id?: string;
986
- /**
987
- * Tax type.
988
- *
989
- * Supported values:
990
- * + `CPF`: for individual tax payers
991
- * + `CNPJ`: for corporations
992
- */
993
- type?: VatType;
994
- }
995
- /** tax info types */
996
- export declare enum VatType {
997
- UNSPECIFIED = "UNSPECIFIED",
998
- /** CPF - for individual tax payers. */
999
- CPF = "CPF",
1000
- /** CNPJ - for corporations */
1001
- CNPJ = "CNPJ"
1002
- }
1003
- export interface ShippingInformation {
1004
- /**
1005
- * App Def Id of external provider which was a source of shipping info
1006
- * @minLength 1
1007
- * @maxLength 100
1008
- */
1009
- carrierId?: string | null;
1010
- /**
1011
- * Unique code (or ID) of selected shipping option. For example, `"usps_std_overnight"`.
1012
- * @minLength 1
1013
- * @maxLength 100
1014
- */
1015
- code?: string | null;
1016
- /**
1017
- * Shipping option title.
1018
- * For example, `"USPS Standard Overnight Delivery"`, `"Standard"` or `"First-Class Package International"`.
1019
- * @maxLength 250
1020
- */
1021
- title?: string;
1022
- /** Shipping logistics. */
1023
- logistics?: DeliveryLogistics;
1024
- /** Shipping costs. */
1025
- cost?: ShippingPrice;
1026
- /** Shipping region. */
1027
- region?: ShippingRegion;
1028
- }
1029
- export interface DeliveryLogistics extends DeliveryLogisticsAddressOneOf {
1030
- /** Shipping address and contact details. */
1031
- shippingDestination?: AddressWithContact;
1032
- /** Pickup details. */
1033
- pickupDetails?: PickupDetails;
1034
- /**
1035
- * Expected delivery time in free text. For example, `"3-5 business days"`.
1036
- * @maxLength 500
1037
- */
1038
- deliveryTime?: string | null;
1039
- /**
1040
- * Instructions for carrier. For example, `"Please knock on the door. If unanswered, please call contact number. Thanks."`.
1041
- * @maxLength 1000
1042
- */
1043
- instructions?: string | null;
1044
- /**
1045
- * Deprecated - Latest expected delivery date and time in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format.
1046
- * @deprecated
1047
- */
1048
- deliverByDate?: Date | null;
1049
- /** Expected delivery time. */
1050
- deliveryTimeSlot?: DeliveryTimeSlot;
1051
- }
1052
- /** @oneof */
1053
- export interface DeliveryLogisticsAddressOneOf {
1054
- /** Shipping address and contact details. */
1055
- shippingDestination?: AddressWithContact;
1056
- /** Pickup details. */
1057
- pickupDetails?: PickupDetails;
1058
- }
1059
- export interface PickupDetails {
1060
- /** Pickup address. */
1061
- address?: PickupAddress;
1062
- /** Pickup method */
1063
- pickupMethod?: PickupMethod;
1064
- }
1065
- /** Physical address */
1066
- export interface PickupAddress {
1067
- /**
1068
- * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format.
1069
- * @format COUNTRY
1070
- */
1071
- country?: string | null;
1072
- /**
1073
- * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format.
1074
- * @maxLength 50
1075
- */
1076
- subdivision?: string | null;
1077
- /**
1078
- * City name.
1079
- * @maxLength 1000
1080
- */
1081
- city?: string | null;
1082
- /**
1083
- * Postal or zip code.
1084
- * @maxLength 1000
1085
- */
1086
- postalCode?: string | null;
1087
- /** Street address object, with number, name, and apartment number in separate fields. */
1088
- streetAddress?: StreetAddress;
1089
- /**
1090
- * Main address line (usually street name and number).
1091
- * @maxLength 1000
1092
- */
1093
- addressLine1?: string | null;
1094
- /**
1095
- * Free text providing more detailed address info. Usually contains apt, suite, floor.
1096
- * @maxLength 1000
1097
- */
1098
- addressLine2?: string | null;
1099
- /**
1100
- * Country's full name.
1101
- * @readonly
1102
- */
1103
- countryFullname?: string | null;
1104
- /**
1105
- * Subdivision full-name.
1106
- * @readonly
1107
- */
1108
- subdivisionFullname?: string | null;
1109
- }
1110
- export declare enum PickupMethod {
1111
- UNKNOWN_METHOD = "UNKNOWN_METHOD",
1112
- STORE_PICKUP = "STORE_PICKUP",
1113
- PICKUP_POINT = "PICKUP_POINT"
1114
- }
1115
- export interface DeliveryTimeSlot {
1116
- /** Delivery slot starting time. */
1117
- from?: Date | null;
1118
- /** Delivery slot ending time. */
1119
- to?: Date | null;
1120
- }
1121
- export interface ShippingPrice {
1122
- /** Shipping price for display purposes. */
1123
- price?: Price;
1124
- /**
1125
- * Total price of shipping after discounts (when relevant), and before tax.
1126
- * @readonly
1127
- */
1128
- totalPriceBeforeTax?: Price;
1129
- /**
1130
- * Shipping price after all discounts (if any exist), and after tax.
1131
- * @readonly
1132
- */
1133
- totalPriceAfterTax?: Price;
1134
- /** Tax details. */
1135
- taxDetails?: ItemTaxFullDetails;
1136
- /**
1137
- * Shipping discount before tax.
1138
- * @readonly
1139
- */
1140
- discount?: Price;
1141
- }
1142
- export interface ShippingRegion {
1143
- /**
1144
- * Name of shipping region. For example, `"Metropolitan London"`, or `"Outer Melbourne suburbs"`.
1145
- * @maxLength 100
1146
- */
1147
- name?: string | null;
1148
- }
1149
- export interface OrderTaxInfo {
1150
- /** Calculated tax, added from line items. */
1151
- totalTax?: Price;
1152
- /**
1153
- * The summary of the tax breakdown for all the line items. It will hold for each tax name, the aggregated tax amount paid for it and the tax rate.
1154
- * @maxSize 50
1155
- */
1156
- taxBreakdown?: OrderTaxBreakdown[];
1157
- /**
1158
- * Whether the order is exempt from tax calculations.
1159
- *
1160
- * Default: `false`
1161
- * @readonly
1162
- */
1163
- taxExempt?: boolean | null;
1164
- }
1165
- /**
1166
- * The summary of the tax breakdown for all the line items. It will hold for each tax name, the aggregated tax amount paid for it and the tax rate.
1167
- * Tax breakdown is the tax amount split to the tax authorities that applied on the line item.
1168
- */
1169
- export interface OrderTaxBreakdown {
1170
- /**
1171
- * The name of the tax against which this tax amount was calculated.
1172
- * @maxLength 200
1173
- */
1174
- taxName?: string;
1175
- /**
1176
- * The type of tax that was calculated. Depends on the company's nexus settings as well as the jurisdiction's tax laws.
1177
- * @maxLength 200
1178
- */
1179
- taxType?: string;
1180
- /**
1181
- * The name of the jurisdiction in which this tax detail applies.
1182
- * @maxLength 200
1183
- */
1184
- jurisdiction?: string;
1185
- /** The type of the jurisdiction in which this tax detail applies (e.g. Country,State,County,City,Special). */
1186
- jurisdictionType?: JurisdictionType;
1187
- /**
1188
- * The rate at which this tax detail was calculated.
1189
- * @format DECIMAL_VALUE
1190
- * @decimalValue options { gte:0, maxScale:6 }
1191
- */
1192
- rate?: string;
1193
- /** The sum of all the tax from line items that calculated by the tax identifiers. */
1194
- aggregatedTaxAmount?: Price;
1195
- }
1196
- export interface AppliedDiscount extends AppliedDiscountDiscountSourceOneOf {
1197
- /** Applied coupon info. */
1198
- coupon?: Coupon;
1199
- /** Merchant discount. */
1200
- merchantDiscount?: MerchantDiscount;
1201
- /** Automatic Discount */
1202
- discountRule?: DiscountRule;
1203
- /**
1204
- * Discount type.
1205
- * * `"GLOBAL"` - discount applies to entire order.
1206
- * * `"SPECIFIC-ITEMS"` - discount applies to specific items.
1207
- * * `"SHIPPING"` - discount applies to shipping. For example, free shipping.
1208
- */
1209
- discountType?: DiscountType;
1210
- /**
1211
- * IDs of line items discount applies to.
1212
- * Deprecated. Use `line_item_discounts` instead.
1213
- * @format GUID
1214
- * @maxSize 1
1215
- * @deprecated IDs of line items discount applies to.
1216
- * Deprecated. Use `line_item_discounts` instead.
1217
- * @replacedBy line_item_discounts
1218
- * @targetRemovalDate 2024-10-30
1219
- */
1220
- lineItemIds?: string[];
1221
- /**
1222
- * Discount id.
1223
- * @format GUID
1224
- * @immutable
1225
- */
1226
- _id?: string | null;
1227
- /**
1228
- * Number of subscription billing cycles the discount applies to.
1229
- * If None and discount is linked to subscription line item, it applies to all cycles.
1230
- * @internal
1231
- * @min 1
1232
- * @max 999
1233
- */
1234
- subscriptionCycles?: number | null;
1235
- }
1236
- /** @oneof */
1237
- export interface AppliedDiscountDiscountSourceOneOf {
1238
- /** Applied coupon info. */
1239
- coupon?: Coupon;
1240
- /** Merchant discount. */
1241
- merchantDiscount?: MerchantDiscount;
1242
- /** Automatic Discount */
1243
- discountRule?: DiscountRule;
1244
- }
1245
- export declare enum DiscountType {
1246
- GLOBAL = "GLOBAL",
1247
- SPECIFIC_ITEMS = "SPECIFIC_ITEMS",
1248
- SHIPPING = "SHIPPING"
1249
- }
1250
- /** Coupon */
1251
- export interface Coupon {
1252
- /** Coupon ID. */
1253
- _id?: string;
1254
- /** Coupon code. */
1255
- code?: string;
1256
- /** Coupon name. */
1257
- name?: string;
1258
- /** Coupon value. */
1259
- amount?: Price;
1260
- }
1261
- export interface MerchantDiscount extends MerchantDiscountMerchantDiscountReasonOneOf {
1262
- /**
1263
- * Pre-defined discount reason (optional).
1264
- * * `"ITEMS_EXCHANGE"` - exchange balance acquired as a result of items exchange.
1265
- */
1266
- discountReason?: DiscountReason;
1267
- /**
1268
- * Discount description as free text (optional).
1269
- * @maxLength 200
1270
- */
1271
- description?: string | null;
1272
- /** Discount amount. */
1273
- amount?: Price;
1274
- /**
1275
- * Discount percentage.
1276
- * @internal
1277
- * @format DECIMAL_VALUE
1278
- * @decimalValue options { gte:0, lte:100, maxScale:2 }
1279
- */
1280
- percentage?: string | null;
1281
- }
1282
- /** @oneof */
1283
- export interface MerchantDiscountMerchantDiscountReasonOneOf {
1284
- /**
1285
- * Pre-defined discount reason (optional).
1286
- * * `"ITEMS_EXCHANGE"` - exchange balance acquired as a result of items exchange.
1287
- */
1288
- discountReason?: DiscountReason;
1289
- /**
1290
- * Discount description as free text (optional).
1291
- * @maxLength 200
1292
- */
1293
- description?: string | null;
1294
- }
1295
- export declare enum DiscountReason {
1296
- UNSPECIFIED = "UNSPECIFIED",
1297
- EXCHANGED_ITEMS = "EXCHANGED_ITEMS",
1298
- BILLING_ADJUSTMENT = "BILLING_ADJUSTMENT"
1299
- }
1300
- export interface DiscountRule {
1301
- /**
1302
- * Discount rule ID
1303
- * @format GUID
1304
- */
1305
- _id?: string;
1306
- /** Discount rule name */
1307
- name?: DiscountRuleName;
1308
- /** Discount value. */
1309
- amount?: Price;
1310
- }
1311
- export interface DiscountRuleName {
1312
- /**
1313
- * Original discount rule name (in site's default language).
1314
- * @minLength 1
1315
- * @maxLength 256
1316
- */
1317
- original?: string;
1318
- /**
1319
- * Translated discount rule name according to buyer language. Defaults to `original` when not provided.
1320
- * @minLength 1
1321
- * @maxLength 500
1322
- */
1323
- translated?: string | null;
1324
- }
1325
- export interface LineItemDiscount {
1326
- /**
1327
- * ID of line item the discount applies to.
1328
- * @format GUID
1329
- */
1330
- _id?: string;
1331
- /** Total discount for this line item. */
1332
- totalDiscount?: Price;
1333
- }
1334
- export interface ChannelInfo {
1335
- /** Sales channel that submitted the order. */
1336
- type?: ChannelType;
1337
- /**
1338
- * Reference to an order ID from an external system.
1339
- * @maxLength 100
1340
- */
1341
- externalOrderId?: string | null;
1342
- /**
1343
- * URL to the order in the external system.
1344
- * @maxLength 300
1345
- */
1346
- externalOrderUrl?: string | null;
1347
- }
1348
- export declare enum ChannelType {
1349
- /** Unspecified sales channel. This value is not supported. */
1350
- UNSPECIFIED = "UNSPECIFIED",
1351
- /** A web client. */
1352
- WEB = "WEB",
1353
- /** [Point of sale solutions](https://support.wix.com/en/wix-mobile-pos-2196395). */
1354
- POS = "POS",
1355
- /** [eBay shop](https://support.wix.com/en/article/wix-stores-connecting-and-setting-up-an-ebay-shop). */
1356
- EBAY = "EBAY",
1357
- /** [Amazon shop](https://support.wix.com/en/article/wix-stores-connecting-and-setting-up-an-amazon-shop). */
1358
- AMAZON = "AMAZON",
1359
- /** Other sales platform. */
1360
- OTHER_PLATFORM = "OTHER_PLATFORM",
1361
- /** [Wix Owner app](https://support.wix.com/article/wix-owner-app-an-overview). */
1362
- WIX_APP_STORE = "WIX_APP_STORE",
1363
- /** 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) */
1364
- WIX_INVOICES = "WIX_INVOICES",
1365
- /** Wix merchant backoffice. */
1366
- BACKOFFICE_MERCHANT = "BACKOFFICE_MERCHANT",
1367
- /** Wish sales channel. */
1368
- WISH = "WISH",
1369
- /** [ClassPass sales channel](https://support.wix.com/en/article/wix-bookings-letting-clients-book-your-services-with-classpass). */
1370
- CLASS_PASS = "CLASS_PASS",
1371
- /** Global-E sales channel. */
1372
- GLOBAL_E = "GLOBAL_E",
1373
- /** [Facebook shop](https://support.wix.com/en/article/wix-stores-changes-to-facebook-shops). */
1374
- FACEBOOK = "FACEBOOK",
1375
- /** [Etsy sales channel](https://support.wix.com/en/article/wix-stores-request-adding-etsy-as-a-sales-channel). */
1376
- ETSY = "ETSY",
1377
- /** [TikTok sales channel](https://support.wix.com/en/article/wix-stores-request-adding-tiktok-as-a-sales-channel). */
1378
- TIKTOK = "TIKTOK",
1379
- /** [Faire marketplace integration](https://support.wix.com/en/article/wix-stores-creating-a-faire-store-using-the-faire-integration-app). */
1380
- FAIRE_COM = "FAIRE_COM"
1381
- }
1382
- export interface CustomField {
1383
- /** Custom field value. */
1384
- value?: any;
1385
- /**
1386
- * Custom field title.
1387
- * @minLength 1
1388
- * @maxLength 500
1389
- */
1390
- title?: string;
1391
- /**
1392
- * Translated custom field title.
1393
- * @minLength 1
1394
- * @maxLength 500
1395
- */
1396
- translatedTitle?: string | null;
1397
- }
1398
- export interface V1SubscriptionTitle {
1399
- /**
1400
- * 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).
1401
- * @minLength 1
1402
- * @maxLength 150
1403
- */
1404
- original?: string;
1405
- /**
1406
- * Subscription option name translated into the buyer's language.
1407
- *
1408
- * Default: Same as `original`.
1409
- * @minLength 1
1410
- * @maxLength 150
1411
- */
1412
- translated?: string | null;
1413
- }
1414
- export interface AdditionalFee {
1415
- /**
1416
- * Additional fee's unique code for future processing.
1417
- * @minLength 1
1418
- * @maxLength 100
1419
- */
1420
- code?: string | null;
1421
- /**
1422
- * Name of additional fee.
1423
- * @minLength 1
1424
- * @maxLength 50
1425
- */
1426
- name?: string;
1427
- /** Additional fee's price. */
1428
- price?: Price;
1429
- /** Tax details. */
1430
- taxDetails?: ItemTaxFullDetails;
1431
- /**
1432
- * SPI implementer's `appId`.
1433
- * @format GUID
1434
- */
1435
- providerAppId?: string | null;
1436
- /** Additional fee's price before tax. */
1437
- priceBeforeTax?: Price;
1438
- /** Additional fee's price after tax. */
1439
- priceAfterTax?: Price;
1440
- /**
1441
- * Additional fee's id.
1442
- * @format GUID
1443
- * @immutable
1444
- */
1445
- _id?: string;
1446
- /**
1447
- * Optional - Line items associated with this additional fee.
1448
- * If no `lineItemIds` are provided, the fee will be associated with the whole cart/checkout/order.
1449
- * @format GUID
1450
- */
1451
- lineItemIds?: string[];
1452
- /**
1453
- * Number of subscription billing cycles the additional fee applies to.
1454
- * If None and additional fee is linked to subscription line item, it applies to all cycles.
1455
- * @internal
1456
- * @min 1
1457
- * @max 999
1458
- */
1459
- subscriptionCycles?: number | null;
1460
- }
1461
- export interface Location {
1462
- /**
1463
- * Location ID.
1464
- * Learn more about the [Wix Locations API](https://dev.wix.com/docs/rest/business-management/locations/introduction).
1465
- * @format GUID
1466
- */
1467
- _id?: string;
1468
- /**
1469
- * Location name.
1470
- * @minLength 1
1471
- * @maxLength 500
1472
- * @readonly
1473
- */
1474
- name?: string;
1475
- }
1476
- export interface CreateSubscriptionContractRequest {
1477
- /** SubscriptionContract to be created. */
1478
- subscriptionContract?: SubscriptionContract;
1479
- }
1480
- export interface CreateSubscriptionContractResponse {
1481
- /** The created SubscriptionContract. */
1482
- subscriptionContract?: SubscriptionContract;
1483
- }
1484
- export interface GetSubscriptionContractRequest {
1485
- /**
1486
- * ID of the SubscriptionContract to retrieve.
1487
- * @format GUID
1488
- */
1489
- subscriptionContractId: string;
1490
- }
1491
- export interface GetSubscriptionContractResponse {
1492
- /** The requested SubscriptionContract. */
1493
- subscriptionContract?: SubscriptionContract;
1494
- }
1495
- export interface UpdateSubscriptionContractRequest {
1496
- /** SubscriptionContract to be updated, may be partial. */
1497
- subscriptionContract?: SubscriptionContract;
1498
- }
1499
- export interface UpdateSubscriptionContractResponse {
1500
- /** Updated SubscriptionContract. */
1501
- subscriptionContract?: SubscriptionContract;
1502
- }
1503
- export interface QuerySubscriptionContractsRequest {
1504
- /** WQL expression. */
1505
- query?: CursorQuery;
1506
- }
1507
- export interface CursorQuery extends CursorQueryPagingMethodOneOf {
1508
- /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
1509
- cursorPaging?: CursorPaging;
1510
- /**
1511
- * Filter object in the following format:
1512
- * `"filter" : {
1513
- * "fieldName1": "value1",
1514
- * "fieldName2":{"$operator":"value2"}
1515
- * }`
1516
- * Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`
1517
- * Learn more about the [filter format](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-filter-section).
1518
- */
1519
- filter?: Record<string, any> | null;
1520
- /**
1521
- * Sort object in the following format:
1522
- * `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]`
1523
- * Learn more about the [sort format](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-sort-section).
1524
- * @maxSize 5
1525
- */
1526
- sort?: Sorting[];
1527
- }
1528
- /** @oneof */
1529
- export interface CursorQueryPagingMethodOneOf {
1530
- /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
1531
- cursorPaging?: CursorPaging;
1532
- }
1533
- export interface Sorting {
1534
- /**
1535
- * Name of the field to sort by.
1536
- * @maxLength 512
1537
- */
1538
- fieldName?: string;
1539
- /** Sort order. */
1540
- order?: SortOrder;
1541
- }
1542
- export declare enum SortOrder {
1543
- ASC = "ASC",
1544
- DESC = "DESC"
1545
- }
1546
- export interface CursorPaging {
1547
- /**
1548
- * Maximum number of items to return in the results.
1549
- * @max 100
1550
- */
1551
- limit?: number | null;
1552
- /**
1553
- * Pointer to the next or previous page in the list of results.
1554
- *
1555
- * Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.
1556
- * Not relevant for the first request.
1557
- * @maxLength 16000
1558
- */
1559
- cursor?: string | null;
1560
- }
1561
- export interface QuerySubscriptionContractsResponse {
1562
- /** List of SubscriptionContracts. */
1563
- subscriptionContracts?: SubscriptionContract[];
1564
- /** Paging metadata */
1565
- pagingMetadata?: CursorPagingMetadata;
1566
- }
1567
- export interface CursorPagingMetadata {
1568
- /** Number of items returned in the response. */
1569
- count?: number | null;
1570
- /** Cursor strings that point to the next page, previous page, or both. */
1571
- cursors?: Cursors;
1572
- /**
1573
- * Whether there are more pages to retrieve following the current page.
1574
- *
1575
- * + `true`: Another page of results can be retrieved.
1576
- * + `false`: This is the last page.
1577
- */
1578
- hasNext?: boolean | null;
1579
- }
1580
- export interface Cursors {
1581
- /**
1582
- * Cursor string pointing to the next page in the list of results.
1583
- * @maxLength 16000
1584
- */
1585
- next?: string | null;
1586
- /**
1587
- * Cursor pointing to the previous page in the list of results.
1588
- * @maxLength 16000
1589
- */
1590
- prev?: string | null;
1591
- }
1592
- export interface DomainEvent extends DomainEventBodyOneOf {
1593
- createdEvent?: EntityCreatedEvent;
1594
- updatedEvent?: EntityUpdatedEvent;
1595
- deletedEvent?: EntityDeletedEvent;
1596
- actionEvent?: ActionEvent;
1597
- /**
1598
- * Unique event ID.
1599
- * Allows clients to ignore duplicate webhooks.
1600
- */
1601
- _id?: string;
1602
- /**
1603
- * Assumes actions are also always typed to an entity_type
1604
- * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
1605
- */
1606
- entityFqdn?: string;
1607
- /**
1608
- * This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug)
1609
- * This is although the created/updated/deleted notion is duplication of the oneof types
1610
- * Example: created/updated/deleted/started/completed/email_opened
1611
- */
1612
- slug?: string;
1613
- /** ID of the entity associated with the event. */
1614
- entityId?: string;
1615
- /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example: 2020-04-26T13:57:50.699Z */
1616
- eventTime?: Date | null;
1617
- /**
1618
- * Whether the event was triggered as a result of a privacy regulation application
1619
- * (for example, GDPR).
1620
- */
1621
- triggeredByAnonymizeRequest?: boolean | null;
1622
- /** If present, indicates the action that triggered the event. */
1623
- originatedFrom?: string | null;
1624
- /**
1625
- * A sequence number defining the order of updates to the underlying entity.
1626
- * For example, given that some entity was updated at 16:00 and than again at 16:01,
1627
- * it is guaranteed that the sequence number of the second update is strictly higher than the first.
1628
- * As the consumer, you can use this value to ensure that you handle messages in the correct order.
1629
- * To do so, you will need to persist this number on your end, and compare the sequence number from the
1630
- * message against the one you have stored. Given that the stored number is higher, you should ignore the message.
1631
- */
1632
- entityEventSequence?: string | null;
1633
- }
1634
- /** @oneof */
1635
- export interface DomainEventBodyOneOf {
1636
- createdEvent?: EntityCreatedEvent;
1637
- updatedEvent?: EntityUpdatedEvent;
1638
- deletedEvent?: EntityDeletedEvent;
1639
- actionEvent?: ActionEvent;
1640
- }
1641
- export interface EntityCreatedEvent {
1642
- entity?: string;
1643
- }
1644
- export interface RestoreInfo {
1645
- deletedDate?: Date | null;
1646
- }
1647
- export interface EntityUpdatedEvent {
1648
- /**
1649
- * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
1650
- * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
1651
- * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
1652
- */
1653
- currentEntity?: string;
1654
- }
1655
- export interface EntityDeletedEvent {
1656
- /** Entity that was deleted */
1657
- deletedEntity?: string | null;
1658
- }
1659
- export interface ActionEvent {
1660
- body?: string;
1661
- }
1662
- export interface Empty {
1663
- }
1664
- export interface MessageEnvelope {
1665
- /**
1666
- * App instance ID.
1667
- * @format GUID
1668
- */
1669
- instanceId?: string | null;
1670
- /**
1671
- * Event type.
1672
- * @maxLength 150
1673
- */
1674
- eventType?: string;
1675
- /** The identification type and identity data. */
1676
- identity?: IdentificationData;
1677
- /** Stringify payload. */
1678
- data?: string;
1679
- }
1680
- export interface IdentificationData extends IdentificationDataIdOneOf {
1681
- /**
1682
- * ID of a site visitor that has not logged in to the site.
1683
- * @format GUID
1684
- */
1685
- anonymousVisitorId?: string;
1686
- /**
1687
- * ID of a site visitor that has logged in to the site.
1688
- * @format GUID
1689
- */
1690
- memberId?: string;
1691
- /**
1692
- * ID of a Wix user (site owner, contributor, etc.).
1693
- * @format GUID
1694
- */
1695
- wixUserId?: string;
1696
- /**
1697
- * ID of an app.
1698
- * @format GUID
1699
- */
1700
- appId?: string;
1701
- /** @readonly */
1702
- identityType?: WebhookIdentityType;
1703
- }
1704
- /** @oneof */
1705
- export interface IdentificationDataIdOneOf {
1706
- /**
1707
- * ID of a site visitor that has not logged in to the site.
1708
- * @format GUID
1709
- */
1710
- anonymousVisitorId?: string;
1711
- /**
1712
- * ID of a site visitor that has logged in to the site.
1713
- * @format GUID
1714
- */
1715
- memberId?: string;
1716
- /**
1717
- * ID of a Wix user (site owner, contributor, etc.).
1718
- * @format GUID
1719
- */
1720
- wixUserId?: string;
1721
- /**
1722
- * ID of an app.
1723
- * @format GUID
1724
- */
1725
- appId?: string;
1726
- }
1727
- export declare enum WebhookIdentityType {
1728
- UNKNOWN = "UNKNOWN",
1729
- ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
1730
- MEMBER = "MEMBER",
1731
- WIX_USER = "WIX_USER",
1732
- APP = "APP"
1733
- }
1734
- interface V1SubscriptionDescriptionNonNullableFields {
1735
- original: string;
1736
- }
1737
- interface V1FreeTrialPeriodNonNullableFields {
1738
- frequency: SubscriptionFrequency;
1739
- interval: number;
1740
- }
1741
- interface V1SubscriptionSettingsNonNullableFields {
1742
- frequency: SubscriptionFrequency;
1743
- autoRenewal: boolean;
1744
- enableCustomerCancellation: boolean;
1745
- /** @internal */
1746
- freeTrialPeriod?: V1FreeTrialPeriodNonNullableFields;
1747
- }
1748
- interface ProductNameNonNullableFields {
1749
- original: string;
1750
- }
1751
- interface CatalogReferenceNonNullableFields {
1752
- catalogItemId: string;
1753
- appId: string;
1754
- }
1755
- interface PriceNonNullableFields {
1756
- amount: string;
1757
- formattedAmount: string;
1758
- }
1759
- interface PlainTextValueNonNullableFields {
1760
- original: string;
1761
- }
1762
- interface ColorNonNullableFields {
1763
- original: string;
1764
- }
1765
- interface DescriptionLineNameNonNullableFields {
1766
- original: string;
1767
- }
1768
- interface DescriptionLineNonNullableFields {
1769
- plainText?: PlainTextValueNonNullableFields;
1770
- colorInfo?: ColorNonNullableFields;
1771
- plainTextValue?: PlainTextValueNonNullableFields;
1772
- color: string;
1773
- name?: DescriptionLineNameNonNullableFields;
1774
- lineType: DescriptionLineType;
1775
- }
1776
- interface PhysicalPropertiesNonNullableFields {
1777
- shippable: boolean;
1778
- }
1779
- interface ItemTypeNonNullableFields {
1780
- preset: ItemTypeItemType;
1781
- custom: string;
1782
- }
1783
- interface ItemTaxFullDetailsNonNullableFields {
1784
- taxableAmount?: PriceNonNullableFields;
1785
- taxRate: string;
1786
- totalTax?: PriceNonNullableFields;
1787
- }
1788
- interface LineItemTaxBreakdownNonNullableFields {
1789
- taxAmount?: PriceNonNullableFields;
1790
- jurisdictionType: JurisdictionType;
1791
- nonTaxableAmount?: PriceNonNullableFields;
1792
- taxableAmount?: PriceNonNullableFields;
1793
- }
1794
- interface LineItemTaxInfoNonNullableFields {
1795
- taxAmount?: PriceNonNullableFields;
1796
- taxableAmount?: PriceNonNullableFields;
1797
- taxIncludedInPrice: boolean;
1798
- taxBreakdown: LineItemTaxBreakdownNonNullableFields[];
1799
- }
1800
- interface DigitalFileNonNullableFields {
1801
- fileId: string;
1802
- }
1803
- interface SubscriptionTitleNonNullableFields {
1804
- original: string;
1805
- }
1806
- interface SubscriptionDescriptionNonNullableFields {
1807
- original: string;
1808
- }
1809
- interface FreeTrialPeriodNonNullableFields {
1810
- frequency: V2SubscriptionFrequency;
1811
- interval: number;
1812
- }
1813
- interface SubscriptionSettingsNonNullableFields {
1814
- frequency: V2SubscriptionFrequency;
1815
- autoRenewal: boolean;
1816
- /** @internal */
1817
- enableCustomerCancellation: boolean;
1818
- /** @internal */
1819
- freeTrialPeriod?: FreeTrialPeriodNonNullableFields;
1820
- }
1821
- interface BillingAdjustmentPriceSummaryNonNullableFields {
1822
- subtotal?: PriceNonNullableFields;
1823
- tax?: PriceNonNullableFields;
1824
- total?: PriceNonNullableFields;
1825
- }
1826
- interface BillingAdjustmentNonNullableFields {
1827
- type: AdjustmentType;
1828
- priceSummary?: BillingAdjustmentPriceSummaryNonNullableFields;
1829
- }
1830
- interface SubscriptionInfoNonNullableFields {
1831
- cycleNumber: number;
1832
- subscriptionOptionTitle: string;
1833
- /** @internal */
1834
- title?: SubscriptionTitleNonNullableFields;
1835
- /** @internal */
1836
- description?: SubscriptionDescriptionNonNullableFields;
1837
- subscriptionSettings?: SubscriptionSettingsNonNullableFields;
1838
- /** @internal */
1839
- billingAdjustment?: BillingAdjustmentNonNullableFields;
1840
- }
1841
- interface PriceDescriptionNonNullableFields {
1842
- original: string;
1843
- }
1844
- interface LocationAndQuantityNonNullableFields {
1845
- _id: string;
1846
- quantity: number;
1847
- }
1848
- interface TaxableAddressNonNullableFields {
1849
- addressType: TaxableAddressType;
1850
- }
1851
- interface OrderLineItemNonNullableFields {
1852
- _id: string;
1853
- productName?: ProductNameNonNullableFields;
1854
- catalogReference?: CatalogReferenceNonNullableFields;
1855
- quantity: number;
1856
- totalDiscount?: PriceNonNullableFields;
1857
- descriptionLines: DescriptionLineNonNullableFields[];
1858
- image: string;
1859
- physicalProperties?: PhysicalPropertiesNonNullableFields;
1860
- itemType?: ItemTypeNonNullableFields;
1861
- price?: PriceNonNullableFields;
1862
- priceBeforeDiscounts?: PriceNonNullableFields;
1863
- totalPriceBeforeTax?: PriceNonNullableFields;
1864
- totalPriceAfterTax?: PriceNonNullableFields;
1865
- paymentOption: PaymentOptionType;
1866
- taxDetails?: ItemTaxFullDetailsNonNullableFields;
1867
- taxInfo?: LineItemTaxInfoNonNullableFields;
1868
- digitalFile?: DigitalFileNonNullableFields;
1869
- subscriptionInfo?: SubscriptionInfoNonNullableFields;
1870
- priceDescription?: PriceDescriptionNonNullableFields;
1871
- depositAmount?: PriceNonNullableFields;
1872
- locations: LocationAndQuantityNonNullableFields[];
1873
- lineItemPrice?: PriceNonNullableFields;
1874
- /** @internal */
1875
- taxableAddress?: TaxableAddressNonNullableFields;
1876
- /** @internal */
1877
- priceUndetermined: boolean;
1878
- /** @internal */
1879
- fixedQuantity: boolean;
1880
- }
1881
- interface BuyerInfoNonNullableFields {
1882
- visitorId: string;
1883
- memberId: string;
1884
- }
1885
- interface PriceSummaryNonNullableFields {
1886
- subtotal?: PriceNonNullableFields;
1887
- shipping?: PriceNonNullableFields;
1888
- tax?: PriceNonNullableFields;
1889
- discount?: PriceNonNullableFields;
1890
- totalPrice?: PriceNonNullableFields;
1891
- total?: PriceNonNullableFields;
1892
- totalWithGiftCard?: PriceNonNullableFields;
1893
- totalWithoutGiftCard?: PriceNonNullableFields;
1894
- totalAdditionalFees?: PriceNonNullableFields;
1895
- }
1896
- interface StreetAddressNonNullableFields {
1897
- number: string;
1898
- name: string;
1899
- apt: string;
1900
- }
1901
- interface AddressNonNullableFields {
1902
- streetAddress?: StreetAddressNonNullableFields;
1903
- }
1904
- interface VatIdNonNullableFields {
1905
- _id: string;
1906
- type: VatType;
1907
- }
1908
- interface FullAddressContactDetailsNonNullableFields {
1909
- vatId?: VatIdNonNullableFields;
1910
- }
1911
- interface AddressWithContactNonNullableFields {
1912
- address?: AddressNonNullableFields;
1913
- contactDetails?: FullAddressContactDetailsNonNullableFields;
1914
- }
1915
- interface PickupAddressNonNullableFields {
1916
- streetAddress?: StreetAddressNonNullableFields;
1917
- }
1918
- interface PickupDetailsNonNullableFields {
1919
- address?: PickupAddressNonNullableFields;
1920
- pickupMethod: PickupMethod;
1921
- }
1922
- interface DeliveryLogisticsNonNullableFields {
1923
- shippingDestination?: AddressWithContactNonNullableFields;
1924
- pickupDetails?: PickupDetailsNonNullableFields;
1925
- }
1926
- interface ShippingPriceNonNullableFields {
1927
- price?: PriceNonNullableFields;
1928
- totalPriceBeforeTax?: PriceNonNullableFields;
1929
- totalPriceAfterTax?: PriceNonNullableFields;
1930
- taxDetails?: ItemTaxFullDetailsNonNullableFields;
1931
- discount?: PriceNonNullableFields;
1932
- }
1933
- interface ShippingInformationNonNullableFields {
1934
- title: string;
1935
- logistics?: DeliveryLogisticsNonNullableFields;
1936
- cost?: ShippingPriceNonNullableFields;
1937
- }
1938
- interface OrderTaxBreakdownNonNullableFields {
1939
- taxName: string;
1940
- taxType: string;
1941
- jurisdiction: string;
1942
- jurisdictionType: JurisdictionType;
1943
- rate: string;
1944
- aggregatedTaxAmount?: PriceNonNullableFields;
1945
- aggregatedTaxableAmount?: PriceNonNullableFields;
1946
- }
1947
- interface OrderTaxInfoNonNullableFields {
1948
- totalTax?: PriceNonNullableFields;
1949
- taxBreakdown: OrderTaxBreakdownNonNullableFields[];
1950
- }
1951
- interface CouponNonNullableFields {
1952
- _id: string;
1953
- code: string;
1954
- name: string;
1955
- amount?: PriceNonNullableFields;
1956
- }
1957
- interface MerchantDiscountNonNullableFields {
1958
- discountReason: DiscountReason;
1959
- amount?: PriceNonNullableFields;
1960
- }
1961
- interface DiscountRuleNameNonNullableFields {
1962
- original: string;
1963
- }
1964
- interface DiscountRuleNonNullableFields {
1965
- _id: string;
1966
- name?: DiscountRuleNameNonNullableFields;
1967
- amount?: PriceNonNullableFields;
1968
- }
1969
- interface LineItemDiscountNonNullableFields {
1970
- _id: string;
1971
- totalDiscount?: PriceNonNullableFields;
1972
- }
1973
- interface AppliedDiscountNonNullableFields {
1974
- coupon?: CouponNonNullableFields;
1975
- merchantDiscount?: MerchantDiscountNonNullableFields;
1976
- discountRule?: DiscountRuleNonNullableFields;
1977
- discountType: DiscountType;
1978
- lineItemIds: string[];
1979
- /** @internal */
1980
- lineItemDiscounts: LineItemDiscountNonNullableFields[];
1981
- }
1982
- interface ChannelInfoNonNullableFields {
1983
- type: ChannelType;
1984
- }
1985
- interface CustomFieldNonNullableFields {
1986
- title: string;
1987
- }
1988
- interface V1SubscriptionTitleNonNullableFields {
1989
- original: string;
1990
- }
1991
- interface AdditionalFeeNonNullableFields {
1992
- name: string;
1993
- price?: PriceNonNullableFields;
1994
- taxDetails?: ItemTaxFullDetailsNonNullableFields;
1995
- priceBeforeTax?: PriceNonNullableFields;
1996
- priceAfterTax?: PriceNonNullableFields;
1997
- _id: string;
1998
- lineItemIds: string[];
1999
- }
2000
- interface LocationNonNullableFields {
2001
- _id: string;
2002
- name: string;
2003
- }
2004
- export interface SubscriptionContractNonNullableFields {
2005
- /** @internal */
2006
- subscriptionDescription?: V1SubscriptionDescriptionNonNullableFields;
2007
- subscriptionSettings?: V1SubscriptionSettingsNonNullableFields;
2008
- lineItems: OrderLineItemNonNullableFields[];
2009
- buyerInfo?: BuyerInfoNonNullableFields;
2010
- weightUnit: WeightUnit;
2011
- taxIncludedInPrices: boolean;
2012
- priceSummary?: PriceSummaryNonNullableFields;
2013
- billingInfo?: AddressWithContactNonNullableFields;
2014
- shippingInfo?: ShippingInformationNonNullableFields;
2015
- taxInfo?: OrderTaxInfoNonNullableFields;
2016
- appliedDiscounts: AppliedDiscountNonNullableFields[];
2017
- channelInfo?: ChannelInfoNonNullableFields;
2018
- customFields: CustomFieldNonNullableFields[];
2019
- recipientInfo?: AddressWithContactNonNullableFields;
2020
- /** @internal */
2021
- subscriptionTitle?: V1SubscriptionTitleNonNullableFields;
2022
- additionalFees: AdditionalFeeNonNullableFields[];
2023
- /** @internal */
2024
- businessLocation?: LocationNonNullableFields;
2025
- }
2026
- export interface GetSubscriptionContractResponseNonNullableFields {
2027
- subscriptionContract?: SubscriptionContractNonNullableFields;
2028
- }
2029
- export interface QuerySubscriptionContractsResponseNonNullableFields {
2030
- subscriptionContracts: SubscriptionContractNonNullableFields[];
2031
- }
2032
- export interface BaseEventMetadata {
2033
- /**
2034
- * App instance ID.
2035
- * @format GUID
2036
- */
2037
- instanceId?: string | null;
2038
- /**
2039
- * Event type.
2040
- * @maxLength 150
2041
- */
2042
- eventType?: string;
2043
- /** The identification type and identity data. */
2044
- identity?: IdentificationData;
2045
- }
2046
- export interface EventMetadata extends BaseEventMetadata {
2047
- /**
2048
- * Unique event ID.
2049
- * Allows clients to ignore duplicate webhooks.
2050
- */
2051
- _id?: string;
2052
- /**
2053
- * Assumes actions are also always typed to an entity_type
2054
- * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
2055
- */
2056
- entityFqdn?: string;
2057
- /**
2058
- * This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug)
2059
- * This is although the created/updated/deleted notion is duplication of the oneof types
2060
- * Example: created/updated/deleted/started/completed/email_opened
2061
- */
2062
- slug?: string;
2063
- /** ID of the entity associated with the event. */
2064
- entityId?: string;
2065
- /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example: 2020-04-26T13:57:50.699Z */
2066
- eventTime?: Date | null;
2067
- /**
2068
- * Whether the event was triggered as a result of a privacy regulation application
2069
- * (for example, GDPR).
2070
- */
2071
- triggeredByAnonymizeRequest?: boolean | null;
2072
- /** If present, indicates the action that triggered the event. */
2073
- originatedFrom?: string | null;
2074
- /**
2075
- * A sequence number defining the order of updates to the underlying entity.
2076
- * For example, given that some entity was updated at 16:00 and than again at 16:01,
2077
- * it is guaranteed that the sequence number of the second update is strictly higher than the first.
2078
- * As the consumer, you can use this value to ensure that you handle messages in the correct order.
2079
- * To do so, you will need to persist this number on your end, and compare the sequence number from the
2080
- * message against the one you have stored. Given that the stored number is higher, you should ignore the message.
2081
- */
2082
- entityEventSequence?: string | null;
2083
- }
2084
- export interface SubscriptionContractCreatedEnvelope {
2085
- entity: SubscriptionContract;
2086
- metadata: EventMetadata;
2087
- }
2088
- /** @permissionScope Manage Stores - all permissions
2089
- * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
2090
- * @permissionScope Read eCommerce - all read permissions
2091
- * @permissionScopeId SCOPE.DC-ECOM-MEGA.READ-ECOM
2092
- * @permissionScope Manage Restaurants - all permissions
2093
- * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2094
- * @permissionScope Manage eCommerce - all permissions
2095
- * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
2096
- * @permissionScope Picasso private app mega scope
2097
- * @permissionScopeId SCOPE.TEST.MEGA-PICASSO-MANAGE-SITE
2098
- * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ
2099
- * @webhook
2100
- * @eventType wix.ecom.subscription_contracts.v1.subscription_contract_created
2101
- * @slug created
2102
- * @documentationMaturity preview
2103
- */
2104
- export declare function onSubscriptionContractCreated(handler: (event: SubscriptionContractCreatedEnvelope) => void | Promise<void>): void;
2105
- export interface SubscriptionContractDeletedEnvelope {
2106
- metadata: EventMetadata;
2107
- }
2108
- /** @permissionScope Manage Stores - all permissions
2109
- * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
2110
- * @permissionScope Read eCommerce - all read permissions
2111
- * @permissionScopeId SCOPE.DC-ECOM-MEGA.READ-ECOM
2112
- * @permissionScope Manage Restaurants - all permissions
2113
- * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2114
- * @permissionScope Manage eCommerce - all permissions
2115
- * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
2116
- * @permissionScope Picasso private app mega scope
2117
- * @permissionScopeId SCOPE.TEST.MEGA-PICASSO-MANAGE-SITE
2118
- * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ
2119
- * @webhook
2120
- * @eventType wix.ecom.subscription_contracts.v1.subscription_contract_deleted
2121
- * @slug deleted
2122
- * @documentationMaturity preview
2123
- */
2124
- export declare function onSubscriptionContractDeleted(handler: (event: SubscriptionContractDeletedEnvelope) => void | Promise<void>): void;
2125
- export interface SubscriptionContractUpdatedEnvelope {
2126
- entity: SubscriptionContract;
2127
- metadata: EventMetadata;
2128
- }
2129
- /** @permissionScope Manage Stores - all permissions
2130
- * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
2131
- * @permissionScope Read eCommerce - all read permissions
2132
- * @permissionScopeId SCOPE.DC-ECOM-MEGA.READ-ECOM
2133
- * @permissionScope Manage Restaurants - all permissions
2134
- * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2135
- * @permissionScope Manage eCommerce - all permissions
2136
- * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
2137
- * @permissionScope Picasso private app mega scope
2138
- * @permissionScopeId SCOPE.TEST.MEGA-PICASSO-MANAGE-SITE
2139
- * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ
2140
- * @webhook
2141
- * @eventType wix.ecom.subscription_contracts.v1.subscription_contract_updated
2142
- * @slug updated
2143
- * @documentationMaturity preview
2144
- */
2145
- export declare function onSubscriptionContractUpdated(handler: (event: SubscriptionContractUpdatedEnvelope) => void | Promise<void>): void;
2146
- /**
2147
- * Retrieves a SubscriptionContract.
2148
- * @param subscriptionContractId - ID of the SubscriptionContract to retrieve.
2149
- * @public
2150
- * @documentationMaturity preview
2151
- * @requiredField subscriptionContractId
2152
- * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ
2153
- * @permissionScope Manage Stores - all permissions
2154
- * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
2155
- * @permissionScope Read eCommerce - all read permissions
2156
- * @permissionScopeId SCOPE.DC-ECOM-MEGA.READ-ECOM
2157
- * @permissionScope Manage Restaurants - all permissions
2158
- * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2159
- * @permissionScope Manage eCommerce - all permissions
2160
- * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
2161
- * @permissionScope Picasso private app mega scope
2162
- * @permissionScopeId SCOPE.TEST.MEGA-PICASSO-MANAGE-SITE
2163
- * @applicableIdentity APP
2164
- * @returns The requested SubscriptionContract.
2165
- * @fqn wix.ecom.subscription_contracts.v1.SubscriptionContracts.GetSubscriptionContract
2166
- */
2167
- export declare function getSubscriptionContract(subscriptionContractId: string): Promise<SubscriptionContract & SubscriptionContractNonNullableFields>;
2168
- /**
2169
- * Retrieves a list of SubscriptionContracts, given the provided [paging, filtering, and sorting][1].
2170
- *
2171
- * Up to 300 SubscriptionContracts can be returned per request.
2172
- *
2173
- * To learn how to query SubscriptionContracts, see [API Query Language][2].
2174
- *
2175
- * [1]: https://dev.wix.com/api/rest/getting-started/sorting-and-paging
2176
- * [2]: https://dev.wix.com/api/rest/getting-started/api-query-language
2177
- * @public
2178
- * @documentationMaturity preview
2179
- * @permissionScope Manage Stores - all permissions
2180
- * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES
2181
- * @permissionScope Read eCommerce - all read permissions
2182
- * @permissionScopeId SCOPE.DC-ECOM-MEGA.READ-ECOM
2183
- * @permissionScope Manage Restaurants - all permissions
2184
- * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES
2185
- * @permissionScope Manage eCommerce - all permissions
2186
- * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM
2187
- * @permissionScope Picasso private app mega scope
2188
- * @permissionScopeId SCOPE.TEST.MEGA-PICASSO-MANAGE-SITE
2189
- * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ
2190
- * @applicableIdentity APP
2191
- * @fqn wix.ecom.subscription_contracts.v1.SubscriptionContracts.QuerySubscriptionContracts
2192
- */
2193
- export declare function querySubscriptionContracts(): SubscriptionContractsQueryBuilder;
2194
- interface QueryCursorResult {
2195
- cursors: Cursors;
2196
- hasNext: () => boolean;
2197
- hasPrev: () => boolean;
2198
- length: number;
2199
- pageSize: number;
2200
- }
2201
- export interface SubscriptionContractsQueryResult extends QueryCursorResult {
2202
- items: SubscriptionContract[];
2203
- query: SubscriptionContractsQueryBuilder;
2204
- next: () => Promise<SubscriptionContractsQueryResult>;
2205
- prev: () => Promise<SubscriptionContractsQueryResult>;
2206
- }
2207
- export interface SubscriptionContractsQueryBuilder {
2208
- /** @param propertyName - Property whose value is compared with `value`.
2209
- * @param value - Value to compare against.
2210
- * @documentationMaturity preview
2211
- */
2212
- eq: (propertyName: '_id' | 'buyerInfo.contactId', value: any) => SubscriptionContractsQueryBuilder;
2213
- /** @param propertyName - Property whose value is compared with `value`.
2214
- * @param value - Value to compare against.
2215
- * @documentationMaturity preview
2216
- */
2217
- ne: (propertyName: '_id' | 'buyerInfo.contactId', value: any) => SubscriptionContractsQueryBuilder;
2218
- /** @param propertyName - Property whose value is compared with `string`.
2219
- * @param string - String to compare against. Case-insensitive.
2220
- * @documentationMaturity preview
2221
- */
2222
- startsWith: (propertyName: '_id' | 'buyerInfo.contactId', value: string) => SubscriptionContractsQueryBuilder;
2223
- /** @param propertyName - Property whose value is compared with `values`.
2224
- * @param values - List of values to compare against.
2225
- * @documentationMaturity preview
2226
- */
2227
- hasSome: (propertyName: '_id' | 'buyerInfo.contactId', value: any[]) => SubscriptionContractsQueryBuilder;
2228
- /** @documentationMaturity preview */
2229
- in: (propertyName: '_id' | 'buyerInfo.contactId', value: any) => SubscriptionContractsQueryBuilder;
2230
- /** @documentationMaturity preview */
2231
- exists: (propertyName: '_id' | 'buyerInfo.contactId', value: boolean) => SubscriptionContractsQueryBuilder;
2232
- /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments.
2233
- * @documentationMaturity preview
2234
- */
2235
- ascending: (...propertyNames: Array<'_id' | 'buyerInfo.contactId'>) => SubscriptionContractsQueryBuilder;
2236
- /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments.
2237
- * @documentationMaturity preview
2238
- */
2239
- descending: (...propertyNames: Array<'_id' | 'buyerInfo.contactId'>) => SubscriptionContractsQueryBuilder;
2240
- /** @param limit - Number of items to return, which is also the `pageSize` of the results object.
2241
- * @documentationMaturity preview
2242
- */
2243
- limit: (limit: number) => SubscriptionContractsQueryBuilder;
2244
- /** @param cursor - A pointer to specific record
2245
- * @documentationMaturity preview
2246
- */
2247
- skipTo: (cursor: string) => SubscriptionContractsQueryBuilder;
2248
- /** @documentationMaturity preview */
2249
- find: () => Promise<SubscriptionContractsQueryResult>;
2250
- }
2251
- export {};