@wix/auto_sdk_ecom_subscription-contracts 1.0.124 → 1.0.126

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 (39) hide show
  1. package/build/cjs/index.d.ts +1 -1
  2. package/build/cjs/index.js.map +1 -1
  3. package/build/cjs/index.typings.d.ts +17 -2
  4. package/build/cjs/index.typings.js.map +1 -1
  5. package/build/cjs/meta.d.ts +17 -2
  6. package/build/cjs/meta.js.map +1 -1
  7. package/build/cjs/schemas.js +1446 -1400
  8. package/build/cjs/schemas.js.map +1 -1
  9. package/build/es/index.d.mts +1 -1
  10. package/build/es/index.mjs.map +1 -1
  11. package/build/es/index.typings.d.mts +17 -2
  12. package/build/es/index.typings.mjs.map +1 -1
  13. package/build/es/meta.d.mts +17 -2
  14. package/build/es/meta.mjs.map +1 -1
  15. package/build/es/schemas.mjs +1446 -1400
  16. package/build/es/schemas.mjs.map +1 -1
  17. package/build/internal/cjs/index.d.ts +1 -1
  18. package/build/internal/cjs/index.typings.d.ts +17 -2
  19. package/build/internal/cjs/meta.d.ts +17 -2
  20. package/build/internal/es/index.d.mts +1 -1
  21. package/build/internal/es/index.typings.d.mts +17 -2
  22. package/build/internal/es/meta.d.mts +17 -2
  23. package/package.json +2 -2
  24. package/build/internal/cjs/index.js +0 -950
  25. package/build/internal/cjs/index.js.map +0 -1
  26. package/build/internal/cjs/index.typings.js +0 -717
  27. package/build/internal/cjs/index.typings.js.map +0 -1
  28. package/build/internal/cjs/meta.js +0 -586
  29. package/build/internal/cjs/meta.js.map +0 -1
  30. package/build/internal/cjs/schemas.js +0 -3041
  31. package/build/internal/cjs/schemas.js.map +0 -1
  32. package/build/internal/es/index.mjs +0 -894
  33. package/build/internal/es/index.mjs.map +0 -1
  34. package/build/internal/es/index.typings.mjs +0 -663
  35. package/build/internal/es/index.typings.mjs.map +0 -1
  36. package/build/internal/es/meta.mjs +0 -531
  37. package/build/internal/es/meta.mjs.map +0 -1
  38. package/build/internal/es/schemas.mjs +0 -3001
  39. package/build/internal/es/schemas.mjs.map +0 -1
@@ -1,141 +1,141 @@
1
1
  // src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.schemas.ts
2
2
  import * as z from "zod";
3
3
  var GetSubscriptionContractRequest = /* @__PURE__ */ z.object({
4
- subscriptionContractId: z.string().describe("ID of the SubscriptionContract to retrieve.").regex(
4
+ subscriptionContractId: /* @__PURE__ */ z.string().describe("ID of the SubscriptionContract to retrieve.").regex(
5
5
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
6
6
  "Must be a valid GUID"
7
7
  )
8
8
  });
9
9
  var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
10
- _id: z.string().describe("SubscriptionContract ID.").regex(
10
+ _id: /* @__PURE__ */ z.string().describe("SubscriptionContract ID.").regex(
11
11
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
12
12
  "Must be a valid GUID"
13
13
  ).optional().nullable(),
14
- revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
14
+ revision: /* @__PURE__ */ z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
15
15
  "Revision number, which increments by 1 each time the SubscriptionContract is updated.\nTo prevent conflicting changes, the current revision must be passed when updating the SubscriptionContract.\n\nIgnored when creating a SubscriptionOrderContract."
16
16
  ).optional().nullable(),
17
- _createdDate: z.date().describe(
17
+ _createdDate: /* @__PURE__ */ z.date().describe(
18
18
  "Date and time the subscription contract was created in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format."
19
19
  ).optional().nullable(),
20
- _updatedDate: z.date().describe(
20
+ _updatedDate: /* @__PURE__ */ z.date().describe(
21
21
  "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."
22
22
  ).optional().nullable(),
23
- description: z.string().describe(
23
+ description: /* @__PURE__ */ z.string().describe(
24
24
  'Subscription option description. For example, `"1kg of selected coffee, once a month"`.'
25
25
  ).max(500).optional().nullable(),
26
- subscriptionSettings: z.object({
27
- frequency: z.enum(["UNDEFINED", "DAY", "WEEK", "MONTH", "YEAR"]).describe("Frequency of recurring payment.").optional(),
28
- interval: z.number().int().describe(
26
+ subscriptionSettings: /* @__PURE__ */ z.object({
27
+ frequency: /* @__PURE__ */ z.enum(["UNDEFINED", "DAY", "WEEK", "MONTH", "YEAR"]).describe("Frequency of recurring payment.").optional(),
28
+ interval: /* @__PURE__ */ z.number().int().describe(
29
29
  "Number of frequency units in a billing cycle. For example, frequency `MONTH` with interval `3` means billing every 3 months."
30
30
  ).min(1).max(3650).optional().nullable(),
31
- autoRenewal: z.boolean().describe(
31
+ autoRenewal: /* @__PURE__ */ z.boolean().describe(
32
32
  "Whether subscription is renewed automatically at the end of each period."
33
33
  ).optional(),
34
- billingCycles: z.number().int().describe(
34
+ billingCycles: /* @__PURE__ */ z.number().int().describe(
35
35
  "Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`."
36
36
  ).min(1).optional().nullable(),
37
- enableCustomerCancellation: z.boolean().describe("Whether to allow the customer to cancel the subscription.").optional(),
38
- freeTrialPeriod: z.object({
39
- frequency: z.enum(["UNDEFINED", "DAY", "WEEK", "MONTH", "YEAR"]).describe("Frequency of period. Values: DAY, WEEK, MONTH, YEAR").optional(),
40
- interval: z.number().int().describe(
37
+ enableCustomerCancellation: /* @__PURE__ */ z.boolean().describe("Whether to allow the customer to cancel the subscription.").optional(),
38
+ freeTrialPeriod: /* @__PURE__ */ z.object({
39
+ frequency: /* @__PURE__ */ z.enum(["UNDEFINED", "DAY", "WEEK", "MONTH", "YEAR"]).describe("Frequency of period. Values: DAY, WEEK, MONTH, YEAR").optional(),
40
+ interval: /* @__PURE__ */ z.number().int().describe(
41
41
  "Number of frequency units in the free trial period. For example, frequency `MONTH` with interval `3` means a 3-month free trial."
42
42
  ).min(1).max(3650).optional()
43
43
  }).describe("Period until first cycle starts. If None => no free trial").optional()
44
44
  }).describe("Subscription detailed information.").optional(),
45
- lineItems: z.array(
46
- z.object({
47
- _id: z.string().describe("Line item ID.").optional(),
48
- productName: z.object({
49
- original: z.string().describe(
45
+ lineItems: /* @__PURE__ */ z.array(
46
+ /* @__PURE__ */ z.object({
47
+ _id: /* @__PURE__ */ z.string().describe("Line item ID.").optional(),
48
+ productName: /* @__PURE__ */ z.object({
49
+ original: /* @__PURE__ */ z.string().describe(
50
50
  "__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).\n\nMin: 1 character.\nMax: 200 characters."
51
51
  ).min(1).max(200).optional(),
52
- translated: z.string().describe(
52
+ translated: /* @__PURE__ */ z.string().describe(
53
53
  "Item name translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
54
54
  ).min(1).max(400).optional().nullable()
55
55
  }).describe(
56
56
  "Item name.\n\n+ Stores - `product.name`\n+ Bookings - `service.info.name`\n+ Events - `ticket.name`"
57
57
  ).optional(),
58
- catalogReference: z.object({
59
- catalogItemId: z.string().describe("ID of the item within the catalog it belongs to.").min(1).max(36).optional(),
60
- appId: z.string().describe(
58
+ catalogReference: /* @__PURE__ */ z.object({
59
+ catalogItemId: /* @__PURE__ */ z.string().describe("ID of the item within the catalog it belongs to.").min(1).max(36).optional(),
60
+ appId: /* @__PURE__ */ z.string().describe(
61
61
  'ID of the app providing the catalog.\n\nYou can get your app\'s ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).\n\nFor items from Wix catalogs, the following values always apply:\n+ Wix Stores: `"215238eb-22a5-4c36-9e7b-e7c08025e04e"`\n+ Wix Bookings: `"13d21c63-b5ec-5912-8397-c3a5ddb27a97"`\n+ Wix Restaurants: `"9a5d83fd-8570-482e-81ab-cfa88942ee60"`'
62
62
  ).min(1).optional(),
63
- options: z.record(z.string(), z.any()).describe(
63
+ options: /* @__PURE__ */ z.record(/* @__PURE__ */ z.string(), /* @__PURE__ */ z.any()).describe(
64
64
  "Additional item details in `key:value` pairs.\n\nUse this optional field for more specificity with item selection. The values of the `options` field differ depending on which catalog is providing the items.\n\nFor Wix Stores products, learn more about integrating with [Catalog V3](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)\nor [Catalog V1](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v1/catalog/e-commerce-integration), depending on [the version the site uses](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-versioning/introduction)."
65
65
  ).optional().nullable()
66
66
  }).describe(
67
67
  "References to the line item's origin catalog. Empty for custom line items."
68
68
  ).optional(),
69
- quantity: z.number().int().describe("Line item quantity.").min(1).max(1e5).optional(),
70
- totalDiscount: z.object({
71
- amount: z.string().describe("Amount.").optional(),
72
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
69
+ quantity: /* @__PURE__ */ z.number().int().describe("Line item quantity.").min(1).max(1e5).optional(),
70
+ totalDiscount: /* @__PURE__ */ z.object({
71
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
72
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
73
73
  }).describe("Total discount for this line item's entire quantity.").optional(),
74
- descriptionLines: z.array(
75
- z.intersection(
76
- z.object({
77
- name: z.object({
78
- original: z.string().describe(
74
+ descriptionLines: /* @__PURE__ */ z.array(
75
+ /* @__PURE__ */ z.intersection(
76
+ /* @__PURE__ */ z.object({
77
+ name: /* @__PURE__ */ z.object({
78
+ original: /* @__PURE__ */ z.string().describe(
79
79
  "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)."
80
80
  ).max(100).optional(),
81
- translated: z.string().describe(
81
+ translated: /* @__PURE__ */ z.string().describe(
82
82
  "Description line name translated into the buyer's language.\n\nDefault: Same as `original`."
83
83
  ).max(200).optional().nullable()
84
84
  }).describe("Description line name.").optional()
85
85
  }),
86
- z.xor([
87
- z.object({
88
- plainText: z.never().optional(),
89
- colorInfo: z.never().optional()
86
+ /* @__PURE__ */ z.xor([
87
+ /* @__PURE__ */ z.object({
88
+ plainText: /* @__PURE__ */ z.never().optional(),
89
+ colorInfo: /* @__PURE__ */ z.never().optional()
90
90
  }),
91
- z.object({
92
- colorInfo: z.never().optional(),
93
- plainText: z.object({
94
- original: z.string().describe(
91
+ /* @__PURE__ */ z.object({
92
+ colorInfo: /* @__PURE__ */ z.never().optional(),
93
+ plainText: /* @__PURE__ */ z.object({
94
+ original: /* @__PURE__ */ z.string().describe(
95
95
  "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)."
96
96
  ).max(600).optional(),
97
- translated: z.string().describe(
97
+ translated: /* @__PURE__ */ z.string().describe(
98
98
  "Description line plain text value translated into the buyer's language.\n\nDefault: Same as `original`."
99
99
  ).max(600).optional().nullable()
100
100
  }).describe("Description line plain text value.")
101
101
  }),
102
- z.object({
103
- plainText: z.never().optional(),
104
- colorInfo: z.object({
105
- original: z.string().describe(
102
+ /* @__PURE__ */ z.object({
103
+ plainText: /* @__PURE__ */ z.never().optional(),
104
+ colorInfo: /* @__PURE__ */ z.object({
105
+ original: /* @__PURE__ */ z.string().describe(
106
106
  "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)."
107
107
  ).max(500).optional(),
108
- translated: z.string().describe(
108
+ translated: /* @__PURE__ */ z.string().describe(
109
109
  "Description line color name translated into the buyer's language.\n\nDefault: Same as `original`."
110
110
  ).max(500).optional().nullable(),
111
- code: z.string().describe("HEX or RGB color code for display.").optional().nullable()
111
+ code: /* @__PURE__ */ z.string().describe("HEX or RGB color code for display.").optional().nullable()
112
112
  }).describe("Description line color value.")
113
113
  })
114
114
  ])
115
115
  )
116
116
  ).min(0).max(20).optional(),
117
- image: z.string().describe("Line item image.").optional(),
118
- physicalProperties: z.object({
119
- weight: z.number().describe(
117
+ image: /* @__PURE__ */ z.string().describe("Line item image.").optional(),
118
+ physicalProperties: /* @__PURE__ */ z.object({
119
+ weight: /* @__PURE__ */ z.number().describe(
120
120
  "Line item weight. Measurement unit matches the weight unit specified in `weightUnit` in the request."
121
121
  ).optional().nullable(),
122
- sku: z.string().describe(
122
+ sku: /* @__PURE__ */ z.string().describe(
123
123
  "Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku)."
124
124
  ).max(40).optional().nullable(),
125
- shippable: z.boolean().describe("Whether this line item is shippable.").optional()
125
+ shippable: /* @__PURE__ */ z.boolean().describe("Whether this line item is shippable.").optional()
126
126
  }).describe(
127
127
  "Physical properties of the item. When relevant, contains information such as SKU and item weight."
128
128
  ).optional(),
129
- itemType: z.intersection(
130
- z.object({}),
131
- z.xor([
132
- z.object({
133
- preset: z.never().optional(),
134
- custom: z.never().optional()
129
+ itemType: /* @__PURE__ */ z.intersection(
130
+ /* @__PURE__ */ z.object({}),
131
+ /* @__PURE__ */ z.xor([
132
+ /* @__PURE__ */ z.object({
133
+ preset: /* @__PURE__ */ z.never().optional(),
134
+ custom: /* @__PURE__ */ z.never().optional()
135
135
  }),
136
- z.object({
137
- custom: z.never().optional(),
138
- preset: z.enum([
136
+ /* @__PURE__ */ z.object({
137
+ custom: /* @__PURE__ */ z.never().optional(),
138
+ preset: /* @__PURE__ */ z.enum([
139
139
  "UNRECOGNISED",
140
140
  "PHYSICAL",
141
141
  "DIGITAL",
@@ -143,45 +143,45 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
143
143
  "SERVICE"
144
144
  ]).describe("Preset item type.")
145
145
  }),
146
- z.object({
147
- preset: z.never().optional(),
148
- custom: z.string().describe(
146
+ /* @__PURE__ */ z.object({
147
+ preset: /* @__PURE__ */ z.never().optional(),
148
+ custom: /* @__PURE__ */ z.string().describe(
149
149
  "Custom item type. When none of the preset types are suitable, specifies the custom type."
150
150
  )
151
151
  })
152
152
  ])
153
153
  ).describe("Item type. Either a preset type or custom.").optional(),
154
- fulfillerId: z.string().describe(
154
+ fulfillerId: /* @__PURE__ */ z.string().describe(
155
155
  "Fulfiller ID. Field is empty when the line item is self-fulfilled.\nTo 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)."
156
156
  ).regex(
157
157
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
158
158
  "Must be a valid GUID"
159
159
  ).optional().nullable(),
160
- refundQuantity: z.number().int().describe("Number of items that were refunded.").min(0).max(1e5).optional().nullable(),
161
- restockQuantity: z.number().int().describe(
160
+ refundQuantity: /* @__PURE__ */ z.number().int().describe("Number of items that were refunded.").min(0).max(1e5).optional().nullable(),
161
+ restockQuantity: /* @__PURE__ */ z.number().int().describe(
162
162
  "Number of items restocked.\n\nFor a per-location breakdown, see `restockLocations`."
163
163
  ).min(0).max(1e5).optional().nullable(),
164
- price: z.object({
165
- amount: z.string().describe("Amount.").optional(),
166
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
164
+ price: /* @__PURE__ */ z.object({
165
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
166
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
167
167
  }).describe(
168
168
  "Line item price after line item discounts for display purposes."
169
169
  ).optional(),
170
- priceBeforeDiscounts: z.object({
171
- amount: z.string().describe("Amount.").optional(),
172
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
170
+ priceBeforeDiscounts: /* @__PURE__ */ z.object({
171
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
172
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
173
173
  }).describe(
174
174
  "Line item price before line item discounts for display purposes. Defaults to `price` when not provided."
175
175
  ).optional(),
176
- totalPriceBeforeTax: z.object({
177
- amount: z.string().describe("Amount.").optional(),
178
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
176
+ totalPriceBeforeTax: /* @__PURE__ */ z.object({
177
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
178
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
179
179
  }).describe("Total price after discounts, and before tax.").optional(),
180
- totalPriceAfterTax: z.object({
181
- amount: z.string().describe("Amount.").optional(),
182
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
180
+ totalPriceAfterTax: /* @__PURE__ */ z.object({
181
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
182
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
183
183
  }).describe("Total price after all discounts and tax.").optional(),
184
- paymentOption: z.enum([
184
+ paymentOption: /* @__PURE__ */ z.enum([
185
185
  "FULL_PAYMENT_ONLINE",
186
186
  "FULL_PAYMENT_OFFLINE",
187
187
  "MEMBERSHIP",
@@ -191,59 +191,59 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
191
191
  ]).describe(
192
192
  "Type of selected payment option for current item.\n\nDefault: `FULL_PAYMENT_ONLINE`"
193
193
  ).optional(),
194
- taxDetails: z.object({
195
- taxableAmount: z.object({
196
- amount: z.string().describe("Amount.").optional(),
197
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
194
+ taxDetails: /* @__PURE__ */ z.object({
195
+ taxableAmount: /* @__PURE__ */ z.object({
196
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
197
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
198
198
  }).describe("Taxable amount of this line item.").optional(),
199
- taxRate: z.string().describe(
199
+ taxRate: /* @__PURE__ */ z.string().describe(
200
200
  'Tax rate percentage, as a decimal numeral between 0 and 1. For example, `"0.13"`.'
201
201
  ).optional(),
202
- totalTax: z.object({
203
- amount: z.string().describe("Amount.").optional(),
204
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
202
+ totalTax: /* @__PURE__ */ z.object({
203
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
204
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
205
205
  }).describe(
206
206
  "The calculated tax, based on the `taxableAmount` and `taxRate`."
207
207
  ).optional()
208
208
  }).describe(
209
209
  "Deprecated. Use `taxInfo` instead.\nThis field will be removed on September 30, 2024.\nTax details for this line item."
210
210
  ).optional(),
211
- taxInfo: z.object({
212
- taxAmount: z.object({
213
- amount: z.string().describe("Amount.").optional(),
214
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
211
+ taxInfo: /* @__PURE__ */ z.object({
212
+ taxAmount: /* @__PURE__ */ z.object({
213
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
214
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
215
215
  }).describe(
216
216
  "Calculated tax, based on `taxable_amount` and `tax_rate`."
217
217
  ).optional(),
218
- taxableAmount: z.object({
219
- amount: z.string().describe("Amount.").optional(),
220
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
218
+ taxableAmount: /* @__PURE__ */ z.object({
219
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
220
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
221
221
  }).describe("Amount for which tax is calculated.").optional(),
222
- taxRate: z.string().describe("Tax rate %, as a decimal point.").optional().nullable(),
223
- taxGroupId: z.string().describe("Tax group ID.").regex(
222
+ taxRate: /* @__PURE__ */ z.string().describe("Tax rate %, as a decimal point.").optional().nullable(),
223
+ taxGroupId: /* @__PURE__ */ z.string().describe("Tax group ID.").regex(
224
224
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
225
225
  "Must be a valid GUID"
226
226
  ).optional().nullable(),
227
- taxIncludedInPrice: z.boolean().describe("Indicates whether the price already includes tax.").optional(),
228
- taxBreakdown: z.array(
229
- z.object({
230
- jurisdiction: z.string().describe(
227
+ taxIncludedInPrice: /* @__PURE__ */ z.boolean().describe("Indicates whether the price already includes tax.").optional(),
228
+ taxBreakdown: /* @__PURE__ */ z.array(
229
+ /* @__PURE__ */ z.object({
230
+ jurisdiction: /* @__PURE__ */ z.string().describe(
231
231
  'Jurisdiction that taxes were calculated for. For example, "New York", or "Quebec".'
232
232
  ).max(200).optional().nullable(),
233
- rate: z.string().describe(
233
+ rate: /* @__PURE__ */ z.string().describe(
234
234
  "Tax rate used for this jurisdiction, as a decimal. For example, 10% tax is 0.1000."
235
235
  ).optional().nullable(),
236
- taxAmount: z.object({
237
- amount: z.string().describe("Amount.").optional(),
238
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
236
+ taxAmount: /* @__PURE__ */ z.object({
237
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
238
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
239
239
  }).describe("Amount of tax calculated for this line item.").optional(),
240
- taxType: z.string().describe(
240
+ taxType: /* @__PURE__ */ z.string().describe(
241
241
  `The type of tax that was calculated. Depends on the jurisdiction's tax laws. For example, "Sales Tax", "Income Tax", "Value Added Tax", etc.`
242
242
  ).max(200).optional().nullable(),
243
- taxName: z.string().describe(
243
+ taxName: /* @__PURE__ */ z.string().describe(
244
244
  'The name of the tax against which this tax amount was calculated. For example, "NY State Sales Tax", "Quebec GST", etc.\nThis name should be explicit enough to allow the merchant to understand what tax was calculated.'
245
245
  ).max(200).optional().nullable(),
246
- jurisdictionType: z.enum([
246
+ jurisdictionType: /* @__PURE__ */ z.enum([
247
247
  "UNDEFINED",
248
248
  "COUNTRY",
249
249
  "STATE",
@@ -253,150 +253,152 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
253
253
  ]).describe(
254
254
  "Type of jurisdiction that taxes were calculated for."
255
255
  ).optional(),
256
- nonTaxableAmount: z.object({
257
- amount: z.string().describe("Amount.").optional(),
258
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
256
+ nonTaxableAmount: /* @__PURE__ */ z.object({
257
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
258
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
259
259
  }).describe("Non-taxable amount of the line item price.").optional(),
260
- taxableAmount: z.object({
261
- amount: z.string().describe("Amount.").optional(),
262
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
260
+ taxableAmount: /* @__PURE__ */ z.object({
261
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
262
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
263
263
  }).describe("Taxable amount of the line item price.").optional()
264
264
  })
265
265
  ).max(7).optional()
266
266
  }).describe(
267
267
  "Represents all the relevant tax details for a specific line item."
268
268
  ).optional(),
269
- digitalFile: z.object({
270
- fileId: z.string().describe("ID of the secure file in media.").min(1).max(100).optional(),
271
- link: z.string().describe(
269
+ digitalFile: /* @__PURE__ */ z.object({
270
+ fileId: /* @__PURE__ */ z.string().describe("ID of the secure file in media.").min(1).max(100).optional(),
271
+ link: /* @__PURE__ */ z.string().describe(
272
272
  "Link will exist after the digital links have been generated on the order."
273
273
  ).url().min(1).max(2e3).optional().nullable(),
274
- expirationDate: z.date().describe("Link expiration time and date.").optional().nullable()
274
+ expirationDate: /* @__PURE__ */ z.date().describe("Link expiration time and date.").optional().nullable()
275
275
  }).describe(
276
276
  "Digital file identifier, relevant only for items with type DIGITAL."
277
277
  ).optional(),
278
- subscriptionInfo: z.object({
279
- _id: z.string().describe("Subscription ID.").regex(
278
+ subscriptionInfo: /* @__PURE__ */ z.object({
279
+ _id: /* @__PURE__ */ z.string().describe("Subscription ID.").regex(
280
280
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
281
281
  "Must be a valid GUID"
282
282
  ).optional().nullable(),
283
- cycleNumber: z.number().int().describe(
283
+ cycleNumber: /* @__PURE__ */ z.number().int().describe(
284
284
  "Subscription cycle. For example, if this order is for the 3rd cycle of a subscription, value will be `3`."
285
285
  ).min(0).optional(),
286
- subscriptionOptionTitle: z.string().describe(
286
+ subscriptionOptionTitle: /* @__PURE__ */ z.string().describe(
287
287
  'Subscription option title. For example, `"Monthly coffee Subscription"`.'
288
288
  ).min(0).max(150).optional(),
289
- subscriptionOptionDescription: z.string().describe(
289
+ subscriptionOptionDescription: /* @__PURE__ */ z.string().describe(
290
290
  'Subscription option description. For example, `"1kg of selected coffee, once a month"`.'
291
291
  ).max(500).optional().nullable(),
292
- subscriptionSettings: z.object({
293
- frequency: z.enum(["UNDEFINED", "DAY", "WEEK", "MONTH", "YEAR"]).describe("Frequency of recurring payment.").optional(),
294
- interval: z.number().int().describe(
292
+ subscriptionSettings: /* @__PURE__ */ z.object({
293
+ frequency: /* @__PURE__ */ z.enum(["UNDEFINED", "DAY", "WEEK", "MONTH", "YEAR"]).describe("Frequency of recurring payment.").optional(),
294
+ interval: /* @__PURE__ */ z.number().int().describe(
295
295
  "Number of frequency units in a billing cycle. For example, frequency `MONTH` with interval `3` means billing every 3 months."
296
296
  ).min(1).max(3650).optional().nullable(),
297
- autoRenewal: z.boolean().describe(
297
+ autoRenewal: /* @__PURE__ */ z.boolean().describe(
298
298
  "Whether subscription is renewed automatically at the end of each period."
299
299
  ).optional(),
300
- billingCycles: z.number().int().describe(
300
+ billingCycles: /* @__PURE__ */ z.number().int().describe(
301
301
  "Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`."
302
302
  ).min(1).optional().nullable(),
303
- enableCustomerCancellation: z.boolean().describe(
303
+ enableCustomerCancellation: /* @__PURE__ */ z.boolean().describe(
304
304
  "Whether to allow the customer to cancel the subscription."
305
305
  ).optional(),
306
- freeTrialPeriod: z.object({
307
- frequency: z.enum(["UNDEFINED", "DAY", "WEEK", "MONTH", "YEAR"]).describe(
306
+ freeTrialPeriod: /* @__PURE__ */ z.object({
307
+ frequency: /* @__PURE__ */ z.enum(["UNDEFINED", "DAY", "WEEK", "MONTH", "YEAR"]).describe(
308
308
  "Frequency of period. Values: DAY, WEEK, MONTH, YEAR"
309
309
  ).optional(),
310
- interval: z.number().int().describe(
310
+ interval: /* @__PURE__ */ z.number().int().describe(
311
311
  "Number of frequency units in the free trial period. For example, frequency `MONTH` with interval `3` means a 3-month free trial."
312
312
  ).min(1).max(3650).optional()
313
313
  }).describe(
314
314
  "Period until first cycle starts. If None => no free trial"
315
315
  ).optional()
316
316
  }).describe("Subscription detailed information.").optional(),
317
- chargesDescription: z.string().describe(
317
+ chargesDescription: /* @__PURE__ */ z.string().describe(
318
318
  "Description of the charges that will be applied for subscription."
319
319
  ).max(1e3).optional().nullable()
320
320
  }).describe("Subscription info.").optional(),
321
- priceDescription: z.object({
322
- original: z.string().describe(
321
+ priceDescription: /* @__PURE__ */ z.object({
322
+ original: /* @__PURE__ */ z.string().describe(
323
323
  "__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)."
324
324
  ).min(1).max(100).optional(),
325
- translated: z.string().describe(
325
+ translated: /* @__PURE__ */ z.string().describe(
326
326
  "Price description translated into the buyer's language.\n\nDefault: Same as `original`."
327
327
  ).min(1).max(100).optional().nullable()
328
328
  }).describe(
329
329
  'Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67".'
330
330
  ).optional(),
331
- depositAmount: z.object({
332
- amount: z.string().describe("Amount.").optional(),
333
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
331
+ depositAmount: /* @__PURE__ */ z.object({
332
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
333
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
334
334
  }).describe(
335
335
  'Item\'s price amount to be charged during checkout. Relevant for items with a `paymentOption` value of `"DEPOSIT_ONLINE"`.'
336
336
  ).optional(),
337
- locations: z.array(
338
- z.object({
339
- _id: z.string().describe("Location id in the associated owner app.").regex(
337
+ locations: /* @__PURE__ */ z.array(
338
+ /* @__PURE__ */ z.object({
339
+ _id: /* @__PURE__ */ z.string().describe("Location id in the associated owner app.").regex(
340
340
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
341
341
  "Must be a valid GUID"
342
342
  ).optional(),
343
- appId: z.string().describe(
343
+ appId: /* @__PURE__ */ z.string().describe(
344
344
  "Location owner app, if not provided then the site business info locations will be used."
345
345
  ).regex(
346
346
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
347
347
  "Must be a valid GUID"
348
348
  ).optional().nullable(),
349
- quantity: z.number().int().describe("Quantity for specific location.").min(1).max(1e5).optional(),
350
- name: z.string().describe("Location name.").max(500).optional().nullable()
349
+ quantity: /* @__PURE__ */ z.number().int().describe("Quantity for specific location.").min(1).max(1e5).optional(),
350
+ name: /* @__PURE__ */ z.string().describe("Location name.").max(500).optional().nullable()
351
351
  })
352
352
  ).min(0).max(5).optional(),
353
- lineItemPrice: z.object({
354
- amount: z.string().describe("Amount.").optional(),
355
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
353
+ lineItemPrice: /* @__PURE__ */ z.object({
354
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
355
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
356
356
  }).describe(
357
357
  "Total price **after** catalog discounts and line item discounts."
358
358
  ).optional(),
359
- taxableAddress: z.intersection(
360
- z.object({}),
361
- z.xor([
362
- z.object({ addressType: z.never().optional() }),
363
- z.object({
364
- addressType: z.enum(["BUSINESS", "BILLING", "SHIPPING"]).describe(
359
+ taxableAddress: /* @__PURE__ */ z.intersection(
360
+ /* @__PURE__ */ z.object({}),
361
+ /* @__PURE__ */ z.xor([
362
+ /* @__PURE__ */ z.object({
363
+ addressType: /* @__PURE__ */ z.never().optional()
364
+ }),
365
+ /* @__PURE__ */ z.object({
366
+ addressType: /* @__PURE__ */ z.enum(["BUSINESS", "BILLING", "SHIPPING"]).describe(
365
367
  "taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly."
366
368
  )
367
369
  })
368
370
  ])
369
371
  ).describe("Address used for tax calculation.").optional(),
370
- priceUndetermined: z.boolean().describe(
372
+ priceUndetermined: /* @__PURE__ */ z.boolean().describe(
371
373
  "Whether the price is not yet defined, and will be updated after the order is created.\n\nDefault: `false`"
372
374
  ).optional(),
373
- fixedQuantity: z.boolean().describe(
375
+ fixedQuantity: /* @__PURE__ */ z.boolean().describe(
374
376
  "Whether the line item quantity is fixed and cannot be changed.\n\nDefault: `false`"
375
377
  ).optional(),
376
- decimalQuantity: z.intersection(
377
- z.object({
378
- value: z.string().describe(
378
+ decimalQuantity: /* @__PURE__ */ z.intersection(
379
+ /* @__PURE__ */ z.object({
380
+ value: /* @__PURE__ */ z.string().describe(
379
381
  'The decimal quantity the buyer / merchant entered.\n\nString-encoded decimal. The exact value is preserved \u2014 no\nrounding, no conversion to an integer.\n\nExamples: "2.75", "1.5", "0.75".'
380
382
  ).optional(),
381
- description: z.object({
382
- original: z.string().describe(
383
+ description: /* @__PURE__ */ z.object({
384
+ original: /* @__PURE__ */ z.string().describe(
383
385
  "__Required.__ String in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n\nMin: 1 character.\nMax: 200 characters."
384
386
  ).min(1).max(200).optional(),
385
- translated: z.string().describe(
387
+ translated: /* @__PURE__ */ z.string().describe(
386
388
  "String translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
387
389
  ).min(1).max(400).optional().nullable()
388
390
  }).describe(
389
391
  'Human-readable, pre-formatted display string for the quantity. For example, "2.75 square meters of fake grass".\nAlways set alongside `value`; use this directly for display rather than composing your own string from `value` and `unit`.'
390
392
  ).optional()
391
393
  }),
392
- z.xor([
393
- z.object({
394
- measurementUnit: z.never().optional(),
395
- otherUnit: z.never().optional()
394
+ /* @__PURE__ */ z.xor([
395
+ /* @__PURE__ */ z.object({
396
+ measurementUnit: /* @__PURE__ */ z.never().optional(),
397
+ otherUnit: /* @__PURE__ */ z.never().optional()
396
398
  }),
397
- z.object({
398
- otherUnit: z.never().optional(),
399
- measurementUnit: z.enum([
399
+ /* @__PURE__ */ z.object({
400
+ otherUnit: /* @__PURE__ */ z.never().optional(),
401
+ measurementUnit: /* @__PURE__ */ z.enum([
400
402
  "UNSPECIFIED",
401
403
  "ML",
402
404
  "CL",
@@ -423,9 +425,9 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
423
425
  "Unit the value is expressed in, selected from the standard `measurementUnit` enum."
424
426
  )
425
427
  }),
426
- z.object({
427
- measurementUnit: z.never().optional(),
428
- otherUnit: z.string().describe(
428
+ /* @__PURE__ */ z.object({
429
+ measurementUnit: /* @__PURE__ */ z.never().optional(),
430
+ otherUnit: /* @__PURE__ */ z.string().describe(
429
431
  'Free-form unit name for standard units not in the\n`measurementUnit` enum (e.g. "hour", "minute", "session").'
430
432
  ).min(1).max(50)
431
433
  })
@@ -433,47 +435,53 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
433
435
  ).describe(
434
436
  "Decimal-quantity metadata. Set when the line represents a\nnon-integer purchase (e.g. 2.75 m\xB2 of fake grass).\n\nWhen set, the line item must have `fixedQuantity` = true and be set with `quantity` = 1.\nThe decimal value lives in `decimalQuantity.value`."
435
437
  ).optional(),
436
- extendedFields: z.object({
437
- namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
438
+ extendedFields: /* @__PURE__ */ z.object({
439
+ namespaces: /* @__PURE__ */ z.record(
440
+ /* @__PURE__ */ z.string(),
441
+ /* @__PURE__ */ z.record(
442
+ /* @__PURE__ */ z.string(),
443
+ /* @__PURE__ */ z.any()
444
+ )
445
+ ).describe(
438
446
  "Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\nThe value of each key is structured according to the schema defined when the extended fields were configured.\n\nYou can only access fields for which you have the appropriate permissions.\n\nLearn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields)."
439
447
  ).optional()
440
448
  }).describe(
441
449
  "Custom extended fields for the line item object.\n\n[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."
442
450
  ).optional(),
443
- modifierGroups: z.array(
444
- z.object({
445
- _id: z.string().describe("Modifier group ID.").min(1).max(36).optional(),
446
- name: z.object({
447
- original: z.string().describe(
451
+ modifierGroups: /* @__PURE__ */ z.array(
452
+ /* @__PURE__ */ z.object({
453
+ _id: /* @__PURE__ */ z.string().describe("Modifier group ID.").min(1).max(36).optional(),
454
+ name: /* @__PURE__ */ z.object({
455
+ original: /* @__PURE__ */ z.string().describe(
448
456
  "__Required.__ String in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n\nMin: 1 character.\nMax: 200 characters."
449
457
  ).min(1).max(200).optional(),
450
- translated: z.string().describe(
458
+ translated: /* @__PURE__ */ z.string().describe(
451
459
  "String translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
452
460
  ).min(1).max(400).optional().nullable()
453
461
  }).describe("Modifier group name.").optional(),
454
- modifiers: z.array(
455
- z.object({
456
- _id: z.string().describe("Modifier ID.").min(1).max(36).optional(),
457
- quantity: z.number().int().describe("The quantity of this modifier.").min(1).max(1e5).optional().nullable(),
458
- label: z.object({
459
- original: z.string().describe(
462
+ modifiers: /* @__PURE__ */ z.array(
463
+ /* @__PURE__ */ z.object({
464
+ _id: /* @__PURE__ */ z.string().describe("Modifier ID.").min(1).max(36).optional(),
465
+ quantity: /* @__PURE__ */ z.number().int().describe("The quantity of this modifier.").min(1).max(1e5).optional().nullable(),
466
+ label: /* @__PURE__ */ z.object({
467
+ original: /* @__PURE__ */ z.string().describe(
460
468
  "__Required.__ String in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n\nMin: 1 character.\nMax: 200 characters."
461
469
  ).min(1).max(200).optional(),
462
- translated: z.string().describe(
470
+ translated: /* @__PURE__ */ z.string().describe(
463
471
  "String translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
464
472
  ).min(1).max(400).optional().nullable()
465
473
  }).describe("Primary display label for the modifier.").optional(),
466
- details: z.object({
467
- original: z.string().describe(
474
+ details: /* @__PURE__ */ z.object({
475
+ original: /* @__PURE__ */ z.string().describe(
468
476
  "__Required.__ String in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n\nMin: 1 character.\nMax: 200 characters."
469
477
  ).min(1).max(200).optional(),
470
- translated: z.string().describe(
478
+ translated: /* @__PURE__ */ z.string().describe(
471
479
  "String translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
472
480
  ).min(1).max(400).optional().nullable()
473
481
  }).describe("Additional details.").optional(),
474
- price: z.object({
475
- amount: z.string().describe("Amount.").optional(),
476
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
482
+ price: /* @__PURE__ */ z.object({
483
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
484
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
477
485
  }).describe("The price of the modifier.").optional()
478
486
  })
479
487
  ).min(1).max(10).optional()
@@ -481,33 +489,33 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
481
489
  ).max(10).optional()
482
490
  })
483
491
  ).min(1).max(100).optional(),
484
- buyerInfo: z.intersection(
485
- z.object({
486
- contactId: z.string().describe(
492
+ buyerInfo: /* @__PURE__ */ z.intersection(
493
+ /* @__PURE__ */ z.object({
494
+ contactId: /* @__PURE__ */ z.string().describe(
487
495
  "Contact ID. Automatically created if one doesn't exist. For more information, see [Contacts API](https://dev.wix.com/docs/api-reference/crm/members-contacts/contacts/contacts/contact-v4/introduction)."
488
496
  ).regex(
489
497
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
490
498
  "Must be a valid GUID"
491
499
  ).optional().nullable(),
492
- email: z.string().describe("Buyer's email address.").email().optional().nullable()
500
+ email: /* @__PURE__ */ z.string().describe("Buyer's email address.").email().optional().nullable()
493
501
  }),
494
- z.xor([
495
- z.object({
496
- visitorId: z.never().optional(),
497
- memberId: z.never().optional()
502
+ /* @__PURE__ */ z.xor([
503
+ /* @__PURE__ */ z.object({
504
+ visitorId: /* @__PURE__ */ z.never().optional(),
505
+ memberId: /* @__PURE__ */ z.never().optional()
498
506
  }),
499
- z.object({
500
- memberId: z.never().optional(),
501
- visitorId: z.string().describe(
507
+ /* @__PURE__ */ z.object({
508
+ memberId: /* @__PURE__ */ z.never().optional(),
509
+ visitorId: /* @__PURE__ */ z.string().describe(
502
510
  "Visitor ID. Returned when the buyer isn't a logged-in site member."
503
511
  ).regex(
504
512
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
505
513
  "Must be a valid GUID"
506
514
  )
507
515
  }),
508
- z.object({
509
- visitorId: z.never().optional(),
510
- memberId: z.string().describe(
516
+ /* @__PURE__ */ z.object({
517
+ visitorId: /* @__PURE__ */ z.never().optional(),
518
+ memberId: /* @__PURE__ */ z.string().describe(
511
519
  "Member ID. Returned when the buyer is a logged-in site member."
512
520
  ).regex(
513
521
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
@@ -516,87 +524,87 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
516
524
  })
517
525
  ])
518
526
  ).describe("Buyer information.").optional(),
519
- buyerLanguage: z.string().describe(
527
+ buyerLanguage: /* @__PURE__ */ z.string().describe(
520
528
  "Language for communication with the buyer. Defaults to the site language.\nFor a site that supports multiple languages, this is the language the buyer selected."
521
529
  ).max(10).optional().nullable(),
522
- weightUnit: z.enum(["UNSPECIFIED_WEIGHT_UNIT", "KG", "LB"]).describe("Weight measurement unit - defaults to site's weight unit.").optional(),
523
- currency: z.string().describe(
530
+ weightUnit: /* @__PURE__ */ z.enum(["UNSPECIFIED_WEIGHT_UNIT", "KG", "LB"]).describe("Weight measurement unit - defaults to site's weight unit.").optional(),
531
+ currency: /* @__PURE__ */ z.string().describe(
524
532
  "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."
525
533
  ).optional().nullable(),
526
- currencyConversionDetails: z.object({
527
- originalCurrency: z.string().describe(
534
+ currencyConversionDetails: /* @__PURE__ */ z.object({
535
+ originalCurrency: /* @__PURE__ */ z.string().describe(
528
536
  "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.\n\nThis currency is used to calculate the pricing before conversion to the buyer's payment currency."
529
537
  ).optional().nullable(),
530
- conversionRate: z.string().describe(
538
+ conversionRate: /* @__PURE__ */ z.string().describe(
531
539
  "The rate used for converting the original currency to the currency used for payment.\n\nReturned only when a single rate produced every amount on the order.\nThis is the case for an order converted once at checkout."
532
540
  ).optional().nullable()
533
541
  }).describe(
534
542
  "Multi-currency information of the subscription. conversionRate may reflect updated exchange rate on created order per recurring cycle."
535
543
  ).optional(),
536
- taxIncludedInPrices: z.boolean().describe(
544
+ taxIncludedInPrices: /* @__PURE__ */ z.boolean().describe(
537
545
  "Whether tax is included in line item prices.\n\nDefault: `false`"
538
546
  ).optional(),
539
- priceSummary: z.object({
540
- subtotal: z.object({
541
- amount: z.string().describe("Amount.").optional(),
542
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
547
+ priceSummary: /* @__PURE__ */ z.object({
548
+ subtotal: /* @__PURE__ */ z.object({
549
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
550
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
543
551
  }).describe(
544
552
  "Subtotal of all line items, before discounts and before tax."
545
553
  ).optional(),
546
- shipping: z.object({
547
- amount: z.string().describe("Amount.").optional(),
548
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
554
+ shipping: /* @__PURE__ */ z.object({
555
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
556
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
549
557
  }).describe("Total shipping price, before discounts and before tax.").optional(),
550
- tax: z.object({
551
- amount: z.string().describe("Amount.").optional(),
552
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
558
+ tax: /* @__PURE__ */ z.object({
559
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
560
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
553
561
  }).describe("Total tax applied to the order.").optional(),
554
- discount: z.object({
555
- amount: z.string().describe("Amount.").optional(),
556
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
562
+ discount: /* @__PURE__ */ z.object({
563
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
564
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
557
565
  }).describe("Total discount amount applied to the order.").optional(),
558
- total: z.object({
559
- amount: z.string().describe("Amount.").optional(),
560
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
566
+ total: /* @__PURE__ */ z.object({
567
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
568
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
561
569
  }).describe("Order's total price after discounts and tax.").optional(),
562
- totalAdditionalFees: z.object({
563
- amount: z.string().describe("Amount.").optional(),
564
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
570
+ totalAdditionalFees: /* @__PURE__ */ z.object({
571
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
572
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
565
573
  }).describe("Total additional fees before tax.").optional()
566
574
  }).describe("Order price summary.").optional(),
567
- platformFeeSummary: z.object({
568
- total: z.object({
569
- amount: z.string().describe("Amount.").optional(),
570
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
575
+ platformFeeSummary: /* @__PURE__ */ z.object({
576
+ total: /* @__PURE__ */ z.object({
577
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
578
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
571
579
  }).describe("Total sum of all platform fees.").optional(),
572
- totalPassOn: z.object({
573
- amount: z.string().describe("Amount.").optional(),
574
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
580
+ totalPassOn: /* @__PURE__ */ z.object({
581
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
582
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
575
583
  }).describe("Total amount of platform fees with `PASS_ON` charge type.").optional(),
576
- totalAbsorbed: z.object({
577
- amount: z.string().describe("Amount.").optional(),
578
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
584
+ totalAbsorbed: /* @__PURE__ */ z.object({
585
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
586
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
579
587
  }).describe("Total amount of platform fees with `ABSORBED` charge type.").optional(),
580
- fees: z.array(
581
- z.object({
582
- name: z.object({
583
- original: z.string().describe(
588
+ fees: /* @__PURE__ */ z.array(
589
+ /* @__PURE__ */ z.object({
590
+ name: /* @__PURE__ */ z.object({
591
+ original: /* @__PURE__ */ z.string().describe(
584
592
  "__Required.__ String in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n\nMin: 1 character.\nMax: 200 characters."
585
593
  ).min(1).max(200).optional(),
586
- translated: z.string().describe(
594
+ translated: /* @__PURE__ */ z.string().describe(
587
595
  "String translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
588
596
  ).min(1).max(400).optional().nullable()
589
597
  }).describe("Platform fee name.").optional(),
590
- amount: z.object({
591
- amount: z.string().describe("Amount.").optional(),
592
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
598
+ amount: /* @__PURE__ */ z.object({
599
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
600
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
593
601
  }).describe("Platform fee amount.").optional(),
594
- lineItemId: z.string().describe("ID of the line item the platform fee applies to.").regex(
602
+ lineItemId: /* @__PURE__ */ z.string().describe("ID of the line item the platform fee applies to.").regex(
595
603
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
596
604
  "Must be a valid GUID"
597
605
  ).optional(),
598
- chargeType: z.enum(["PASS_ON", "ABSORBED"]).describe("Platform fee charge type.").optional(),
599
- percentageRate: z.string().describe(
606
+ chargeType: /* @__PURE__ */ z.enum(["PASS_ON", "ABSORBED"]).describe("Platform fee charge type.").optional(),
607
+ percentageRate: /* @__PURE__ */ z.string().describe(
600
608
  "Percentage rate charged as platform fee.\nThe fee rate percentage expressed as a decimal fraction between 0 and 1. For example, `0.05` for 5%."
601
609
  ).optional()
602
610
  })
@@ -604,26 +612,26 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
604
612
  }).describe(
605
613
  "Summary of platform fees for this subscription contract, including totals by charge type and a breakdown of individual fees."
606
614
  ).optional(),
607
- billingInfo: z.object({
608
- address: z.object({
609
- streetAddress: z.object({
610
- name: z.string().optional(),
611
- number: z.string().optional()
615
+ billingInfo: /* @__PURE__ */ z.object({
616
+ address: /* @__PURE__ */ z.object({
617
+ streetAddress: /* @__PURE__ */ z.object({
618
+ name: /* @__PURE__ */ z.string().optional(),
619
+ number: /* @__PURE__ */ z.string().optional()
612
620
  }).optional(),
613
- city: z.string().optional().nullable(),
614
- subdivision: z.string().optional().nullable(),
615
- country: z.string().optional().nullable(),
616
- postalCode: z.string().optional().nullable(),
617
- addressLine2: z.string().optional().nullable()
621
+ city: /* @__PURE__ */ z.string().optional().nullable(),
622
+ subdivision: /* @__PURE__ */ z.string().optional().nullable(),
623
+ country: /* @__PURE__ */ z.string().optional().nullable(),
624
+ postalCode: /* @__PURE__ */ z.string().optional().nullable(),
625
+ addressLine2: /* @__PURE__ */ z.string().optional().nullable()
618
626
  }).describe("Address.").optional(),
619
- contactDetails: z.object({
620
- firstName: z.string().describe("First name.").max(100).optional().nullable(),
621
- lastName: z.string().describe("Last name.").max(100).optional().nullable(),
622
- phone: z.string().describe("Phone number.").optional().nullable(),
623
- company: z.string().describe("Company name.").max(1e3).optional().nullable(),
624
- vatId: z.object({
625
- _id: z.string().describe("Customer's tax ID.").optional(),
626
- type: z.enum(["UNSPECIFIED", "CPF", "CNPJ"]).describe(
627
+ contactDetails: /* @__PURE__ */ z.object({
628
+ firstName: /* @__PURE__ */ z.string().describe("First name.").max(100).optional().nullable(),
629
+ lastName: /* @__PURE__ */ z.string().describe("Last name.").max(100).optional().nullable(),
630
+ phone: /* @__PURE__ */ z.string().describe("Phone number.").optional().nullable(),
631
+ company: /* @__PURE__ */ z.string().describe("Company name.").max(1e3).optional().nullable(),
632
+ vatId: /* @__PURE__ */ z.object({
633
+ _id: /* @__PURE__ */ z.string().describe("Customer's tax ID.").optional(),
634
+ type: /* @__PURE__ */ z.enum(["UNSPECIFIED", "CPF", "CNPJ"]).describe(
627
635
  "Tax type.\n\nSupported values:\n+ `CPF`: for individual tax payers\n+ `CNPJ`: for corporations"
628
636
  ).optional()
629
637
  }).describe(
@@ -631,59 +639,59 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
631
639
  ).optional()
632
640
  }).describe("Contact details.").optional()
633
641
  }).describe("Billing address and contact details.").optional(),
634
- shippingInfo: z.object({
635
- carrierId: z.string().describe(
642
+ shippingInfo: /* @__PURE__ */ z.object({
643
+ carrierId: /* @__PURE__ */ z.string().describe(
636
644
  "App Def Id of external provider which was a source of shipping info"
637
645
  ).min(1).max(100).optional().nullable(),
638
- code: z.string().describe(
646
+ code: /* @__PURE__ */ z.string().describe(
639
647
  'Unique code (or ID) of selected shipping option. For example, `"usps_std_overnight"`.'
640
648
  ).min(1).max(100).optional().nullable(),
641
- title: z.string().describe(
649
+ title: /* @__PURE__ */ z.string().describe(
642
650
  'Shipping option title.\nFor example, `"USPS Standard Overnight Delivery"`, `"Standard"` or `"First-Class Package International"`.'
643
651
  ).max(250).optional(),
644
- logistics: z.intersection(
645
- z.object({
646
- deliveryTime: z.string().describe(
652
+ logistics: /* @__PURE__ */ z.intersection(
653
+ /* @__PURE__ */ z.object({
654
+ deliveryTime: /* @__PURE__ */ z.string().describe(
647
655
  'Expected delivery time in free text. For example, `"3-5 business days"`.'
648
656
  ).max(500).optional().nullable(),
649
- instructions: z.string().describe(
657
+ instructions: /* @__PURE__ */ z.string().describe(
650
658
  'Instructions for the carrier. For example, `"Please knock on the door. If unanswered, please call contact number."`.'
651
659
  ).max(1e3).optional().nullable(),
652
- deliverByDate: z.date().describe(
660
+ deliverByDate: /* @__PURE__ */ z.date().describe(
653
661
  "Deprecated - Latest expected delivery date and time in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format."
654
662
  ).optional().nullable(),
655
- deliveryTimeSlot: z.object({
656
- from: z.date().describe("Delivery slot starting time.").optional().nullable(),
657
- to: z.date().describe("Delivery slot ending time.").optional().nullable()
663
+ deliveryTimeSlot: /* @__PURE__ */ z.object({
664
+ from: /* @__PURE__ */ z.date().describe("Delivery slot starting time.").optional().nullable(),
665
+ to: /* @__PURE__ */ z.date().describe("Delivery slot ending time.").optional().nullable()
658
666
  }).describe("Expected delivery time slot with start and end times.").optional()
659
667
  }),
660
- z.xor([
661
- z.object({
662
- shippingDestination: z.never().optional(),
663
- pickupDetails: z.never().optional()
668
+ /* @__PURE__ */ z.xor([
669
+ /* @__PURE__ */ z.object({
670
+ shippingDestination: /* @__PURE__ */ z.never().optional(),
671
+ pickupDetails: /* @__PURE__ */ z.never().optional()
664
672
  }),
665
- z.object({
666
- pickupDetails: z.never().optional(),
667
- shippingDestination: z.object({
668
- address: z.object({
669
- streetAddress: z.object({
670
- name: z.string().optional(),
671
- number: z.string().optional()
673
+ /* @__PURE__ */ z.object({
674
+ pickupDetails: /* @__PURE__ */ z.never().optional(),
675
+ shippingDestination: /* @__PURE__ */ z.object({
676
+ address: /* @__PURE__ */ z.object({
677
+ streetAddress: /* @__PURE__ */ z.object({
678
+ name: /* @__PURE__ */ z.string().optional(),
679
+ number: /* @__PURE__ */ z.string().optional()
672
680
  }).optional(),
673
- city: z.string().optional().nullable(),
674
- subdivision: z.string().optional().nullable(),
675
- country: z.string().optional().nullable(),
676
- postalCode: z.string().optional().nullable(),
677
- addressLine2: z.string().optional().nullable()
681
+ city: /* @__PURE__ */ z.string().optional().nullable(),
682
+ subdivision: /* @__PURE__ */ z.string().optional().nullable(),
683
+ country: /* @__PURE__ */ z.string().optional().nullable(),
684
+ postalCode: /* @__PURE__ */ z.string().optional().nullable(),
685
+ addressLine2: /* @__PURE__ */ z.string().optional().nullable()
678
686
  }).describe("Address.").optional(),
679
- contactDetails: z.object({
680
- firstName: z.string().describe("First name.").max(100).optional().nullable(),
681
- lastName: z.string().describe("Last name.").max(100).optional().nullable(),
682
- phone: z.string().describe("Phone number.").optional().nullable(),
683
- company: z.string().describe("Company name.").max(1e3).optional().nullable(),
684
- vatId: z.object({
685
- _id: z.string().describe("Customer's tax ID.").optional(),
686
- type: z.enum(["UNSPECIFIED", "CPF", "CNPJ"]).describe(
687
+ contactDetails: /* @__PURE__ */ z.object({
688
+ firstName: /* @__PURE__ */ z.string().describe("First name.").max(100).optional().nullable(),
689
+ lastName: /* @__PURE__ */ z.string().describe("Last name.").max(100).optional().nullable(),
690
+ phone: /* @__PURE__ */ z.string().describe("Phone number.").optional().nullable(),
691
+ company: /* @__PURE__ */ z.string().describe("Company name.").max(1e3).optional().nullable(),
692
+ vatId: /* @__PURE__ */ z.object({
693
+ _id: /* @__PURE__ */ z.string().describe("Customer's tax ID.").optional(),
694
+ type: /* @__PURE__ */ z.enum(["UNSPECIFIED", "CPF", "CNPJ"]).describe(
687
695
  "Tax type.\n\nSupported values:\n+ `CPF`: for individual tax payers\n+ `CNPJ`: for corporations"
688
696
  ).optional()
689
697
  }).describe(
@@ -694,95 +702,95 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
694
702
  "Shipping destination address and contact details. For pickup orders, this contains the pickup location address, not the recipient's address."
695
703
  )
696
704
  }),
697
- z.object({
698
- shippingDestination: z.never().optional(),
699
- pickupDetails: z.object({
700
- address: z.object({
701
- streetAddress: z.object({
702
- name: z.string().optional(),
703
- number: z.string().optional()
705
+ /* @__PURE__ */ z.object({
706
+ shippingDestination: /* @__PURE__ */ z.never().optional(),
707
+ pickupDetails: /* @__PURE__ */ z.object({
708
+ address: /* @__PURE__ */ z.object({
709
+ streetAddress: /* @__PURE__ */ z.object({
710
+ name: /* @__PURE__ */ z.string().optional(),
711
+ number: /* @__PURE__ */ z.string().optional()
704
712
  }).optional(),
705
- city: z.string().optional().nullable(),
706
- subdivision: z.string().optional().nullable(),
707
- country: z.string().optional().nullable(),
708
- postalCode: z.string().optional().nullable(),
709
- addressLine2: z.string().optional().nullable()
713
+ city: /* @__PURE__ */ z.string().optional().nullable(),
714
+ subdivision: /* @__PURE__ */ z.string().optional().nullable(),
715
+ country: /* @__PURE__ */ z.string().optional().nullable(),
716
+ postalCode: /* @__PURE__ */ z.string().optional().nullable(),
717
+ addressLine2: /* @__PURE__ */ z.string().optional().nullable()
710
718
  }).describe("Pickup address.").optional(),
711
- pickupMethod: z.enum(["STORE_PICKUP", "PICKUP_POINT"]).describe("Pickup method").optional()
719
+ pickupMethod: /* @__PURE__ */ z.enum(["STORE_PICKUP", "PICKUP_POINT"]).describe("Pickup method").optional()
712
720
  }).describe(
713
721
  "Pickup details for store pickup or pickup point orders."
714
722
  )
715
723
  })
716
724
  ])
717
725
  ).describe("Shipping logistics.").optional(),
718
- cost: z.object({
719
- price: z.object({
720
- amount: z.string().describe("Amount.").optional(),
721
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
726
+ cost: /* @__PURE__ */ z.object({
727
+ price: /* @__PURE__ */ z.object({
728
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
729
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
722
730
  }).describe("Shipping price for display purposes.").optional(),
723
- totalPriceBeforeTax: z.object({
724
- amount: z.string().describe("Amount.").optional(),
725
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
731
+ totalPriceBeforeTax: /* @__PURE__ */ z.object({
732
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
733
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
726
734
  }).describe(
727
735
  "Total price of shipping after discounts (when relevant), and before tax."
728
736
  ).optional(),
729
- totalPriceAfterTax: z.object({
730
- amount: z.string().describe("Amount.").optional(),
731
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
737
+ totalPriceAfterTax: /* @__PURE__ */ z.object({
738
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
739
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
732
740
  }).describe(
733
741
  "Shipping price after all discounts (if any exist), and after tax."
734
742
  ).optional(),
735
- taxDetails: z.object({
736
- taxableAmount: z.object({
737
- amount: z.string().describe("Amount.").optional(),
738
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
743
+ taxDetails: /* @__PURE__ */ z.object({
744
+ taxableAmount: /* @__PURE__ */ z.object({
745
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
746
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
739
747
  }).describe("Taxable amount of this line item.").optional(),
740
- taxRate: z.string().describe(
748
+ taxRate: /* @__PURE__ */ z.string().describe(
741
749
  'Tax rate percentage, as a decimal numeral between 0 and 1. For example, `"0.13"`.'
742
750
  ).optional(),
743
- totalTax: z.object({
744
- amount: z.string().describe("Amount.").optional(),
745
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
751
+ totalTax: /* @__PURE__ */ z.object({
752
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
753
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
746
754
  }).describe(
747
755
  "The calculated tax, based on the `taxableAmount` and `taxRate`."
748
756
  ).optional()
749
757
  }).describe("Tax details.").optional(),
750
- taxInfo: z.object({
751
- taxAmount: z.object({
752
- amount: z.string().describe("Amount.").optional(),
753
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
758
+ taxInfo: /* @__PURE__ */ z.object({
759
+ taxAmount: /* @__PURE__ */ z.object({
760
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
761
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
754
762
  }).describe(
755
763
  "Calculated tax, based on `taxable_amount` and `tax_rate`."
756
764
  ).optional(),
757
- taxableAmount: z.object({
758
- amount: z.string().describe("Amount.").optional(),
759
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
765
+ taxableAmount: /* @__PURE__ */ z.object({
766
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
767
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
760
768
  }).describe("Amount for which tax is calculated.").optional(),
761
- taxRate: z.string().describe("Tax rate %, as a decimal point.").optional().nullable(),
762
- taxGroupId: z.string().describe("Tax group ID.").regex(
769
+ taxRate: /* @__PURE__ */ z.string().describe("Tax rate %, as a decimal point.").optional().nullable(),
770
+ taxGroupId: /* @__PURE__ */ z.string().describe("Tax group ID.").regex(
763
771
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
764
772
  "Must be a valid GUID"
765
773
  ).optional().nullable(),
766
- taxIncludedInPrice: z.boolean().describe("Indicates whether the price already includes tax.").optional(),
767
- taxBreakdown: z.array(
768
- z.object({
769
- jurisdiction: z.string().describe(
774
+ taxIncludedInPrice: /* @__PURE__ */ z.boolean().describe("Indicates whether the price already includes tax.").optional(),
775
+ taxBreakdown: /* @__PURE__ */ z.array(
776
+ /* @__PURE__ */ z.object({
777
+ jurisdiction: /* @__PURE__ */ z.string().describe(
770
778
  'Jurisdiction that taxes were calculated for. For example, "New York", or "Quebec".'
771
779
  ).max(200).optional().nullable(),
772
- rate: z.string().describe(
780
+ rate: /* @__PURE__ */ z.string().describe(
773
781
  "Tax rate used for this jurisdiction, as a decimal. For example, 10% tax is 0.1000."
774
782
  ).optional().nullable(),
775
- taxAmount: z.object({
776
- amount: z.string().describe("Amount.").optional(),
777
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
783
+ taxAmount: /* @__PURE__ */ z.object({
784
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
785
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
778
786
  }).describe("Amount of tax calculated for this line item.").optional(),
779
- taxType: z.string().describe(
787
+ taxType: /* @__PURE__ */ z.string().describe(
780
788
  `The type of tax that was calculated. Depends on the jurisdiction's tax laws. For example, "Sales Tax", "Income Tax", "Value Added Tax", etc.`
781
789
  ).max(200).optional().nullable(),
782
- taxName: z.string().describe(
790
+ taxName: /* @__PURE__ */ z.string().describe(
783
791
  'The name of the tax against which this tax amount was calculated. For example, "NY State Sales Tax", "Quebec GST", etc.\nThis name should be explicit enough to allow the merchant to understand what tax was calculated.'
784
792
  ).max(200).optional().nullable(),
785
- jurisdictionType: z.enum([
793
+ jurisdictionType: /* @__PURE__ */ z.enum([
786
794
  "UNDEFINED",
787
795
  "COUNTRY",
788
796
  "STATE",
@@ -792,118 +800,118 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
792
800
  ]).describe(
793
801
  "Type of jurisdiction that taxes were calculated for."
794
802
  ).optional(),
795
- nonTaxableAmount: z.object({
796
- amount: z.string().describe("Amount.").optional(),
797
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
803
+ nonTaxableAmount: /* @__PURE__ */ z.object({
804
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
805
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
798
806
  }).describe("Non-taxable amount of the line item price.").optional(),
799
- taxableAmount: z.object({
800
- amount: z.string().describe("Amount.").optional(),
801
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
807
+ taxableAmount: /* @__PURE__ */ z.object({
808
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
809
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
802
810
  }).describe("Taxable amount of the line item price.").optional()
803
811
  })
804
812
  ).max(7).optional()
805
813
  }).describe("Represents all the relevant tax details for a shipping.").optional(),
806
- discount: z.object({
807
- amount: z.string().describe("Amount.").optional(),
808
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
814
+ discount: /* @__PURE__ */ z.object({
815
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
816
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
809
817
  }).describe("Shipping discount before tax.").optional()
810
818
  }).describe("Shipping costs.").optional(),
811
- region: z.object({
812
- name: z.string().describe(
819
+ region: /* @__PURE__ */ z.object({
820
+ name: /* @__PURE__ */ z.string().describe(
813
821
  'Name of shipping region. For example, `"Metropolitan London"`, or `"Outer Melbourne suburbs"`.'
814
822
  ).max(100).optional().nullable()
815
823
  }).describe("Shipping region.").optional()
816
824
  }).describe("Shipping info and selected shipping option details.").optional(),
817
- appliedDiscounts: z.array(
818
- z.intersection(
819
- z.object({
820
- discountType: z.enum(["GLOBAL", "SPECIFIC_ITEMS", "SHIPPING"]).optional(),
821
- lineItemIds: z.array(z.string()).min(0).max(300).optional(),
822
- _id: z.string().describe("Discount ID.").regex(
825
+ appliedDiscounts: /* @__PURE__ */ z.array(
826
+ /* @__PURE__ */ z.intersection(
827
+ /* @__PURE__ */ z.object({
828
+ discountType: /* @__PURE__ */ z.enum(["GLOBAL", "SPECIFIC_ITEMS", "SHIPPING"]).optional(),
829
+ lineItemIds: /* @__PURE__ */ z.array(/* @__PURE__ */ z.string()).min(0).max(300).optional(),
830
+ _id: /* @__PURE__ */ z.string().describe("Discount ID.").regex(
823
831
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
824
832
  "Must be a valid GUID"
825
833
  ).optional().nullable(),
826
- lineItemDiscounts: z.array(
827
- z.object({
828
- _id: z.string().describe("Line item ID.").regex(
834
+ lineItemDiscounts: /* @__PURE__ */ z.array(
835
+ /* @__PURE__ */ z.object({
836
+ _id: /* @__PURE__ */ z.string().describe("Line item ID.").regex(
829
837
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
830
838
  "Must be a valid GUID"
831
839
  ).optional(),
832
- totalDiscount: z.object({
833
- amount: z.string().describe("Amount.").optional(),
834
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
840
+ totalDiscount: /* @__PURE__ */ z.object({
841
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
842
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
835
843
  }).describe("Total discount amount for this line item.").optional()
836
844
  })
837
845
  ).max(300).optional()
838
846
  }),
839
- z.xor([
840
- z.object({
841
- coupon: z.never().optional(),
842
- merchantDiscount: z.never().optional(),
843
- discountRule: z.never().optional()
847
+ /* @__PURE__ */ z.xor([
848
+ /* @__PURE__ */ z.object({
849
+ coupon: /* @__PURE__ */ z.never().optional(),
850
+ merchantDiscount: /* @__PURE__ */ z.never().optional(),
851
+ discountRule: /* @__PURE__ */ z.never().optional()
844
852
  }),
845
- z.object({
846
- merchantDiscount: z.never().optional(),
847
- discountRule: z.never().optional(),
848
- coupon: z.object({
849
- _id: z.string().describe("Coupon ID.").optional(),
850
- code: z.string().describe("Coupon code.").optional(),
851
- name: z.string().describe("Coupon name.").optional(),
852
- amount: z.object({
853
- amount: z.string().describe("Amount.").optional(),
854
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
853
+ /* @__PURE__ */ z.object({
854
+ merchantDiscount: /* @__PURE__ */ z.never().optional(),
855
+ discountRule: /* @__PURE__ */ z.never().optional(),
856
+ coupon: /* @__PURE__ */ z.object({
857
+ _id: /* @__PURE__ */ z.string().describe("Coupon ID.").optional(),
858
+ code: /* @__PURE__ */ z.string().describe("Coupon code.").optional(),
859
+ name: /* @__PURE__ */ z.string().describe("Coupon name.").optional(),
860
+ amount: /* @__PURE__ */ z.object({
861
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
862
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
855
863
  }).describe("Coupon value.").optional()
856
864
  }).describe("Coupon applied by the customer.")
857
865
  }),
858
- z.object({
859
- coupon: z.never().optional(),
860
- discountRule: z.never().optional(),
861
- merchantDiscount: z.intersection(
862
- z.object({
863
- amount: z.object({
864
- amount: z.string().describe("Amount.").optional(),
865
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
866
+ /* @__PURE__ */ z.object({
867
+ coupon: /* @__PURE__ */ z.never().optional(),
868
+ discountRule: /* @__PURE__ */ z.never().optional(),
869
+ merchantDiscount: /* @__PURE__ */ z.intersection(
870
+ /* @__PURE__ */ z.object({
871
+ amount: /* @__PURE__ */ z.object({
872
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
873
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
866
874
  }).describe("Discount amount.").optional()
867
875
  }),
868
- z.xor([
869
- z.object({
870
- discountReason: z.never().optional(),
871
- description: z.never().optional()
876
+ /* @__PURE__ */ z.xor([
877
+ /* @__PURE__ */ z.object({
878
+ discountReason: /* @__PURE__ */ z.never().optional(),
879
+ description: /* @__PURE__ */ z.never().optional()
872
880
  }),
873
- z.object({
874
- description: z.never().optional(),
875
- discountReason: z.enum([
881
+ /* @__PURE__ */ z.object({
882
+ description: /* @__PURE__ */ z.never().optional(),
883
+ discountReason: /* @__PURE__ */ z.enum([
876
884
  "UNSPECIFIED",
877
885
  "EXCHANGED_ITEMS",
878
886
  "BILLING_ADJUSTMENT"
879
887
  ]).describe("Predefined discount reason.")
880
888
  }),
881
- z.object({
882
- discountReason: z.never().optional(),
883
- description: z.string().describe("Custom discount description as free text.").max(200)
889
+ /* @__PURE__ */ z.object({
890
+ discountReason: /* @__PURE__ */ z.never().optional(),
891
+ description: /* @__PURE__ */ z.string().describe("Custom discount description as free text.").max(200)
884
892
  })
885
893
  ])
886
894
  ).describe("Discount applied manually by the merchant.")
887
895
  }),
888
- z.object({
889
- coupon: z.never().optional(),
890
- merchantDiscount: z.never().optional(),
891
- discountRule: z.object({
892
- _id: z.string().describe("Discount rule ID").regex(
896
+ /* @__PURE__ */ z.object({
897
+ coupon: /* @__PURE__ */ z.never().optional(),
898
+ merchantDiscount: /* @__PURE__ */ z.never().optional(),
899
+ discountRule: /* @__PURE__ */ z.object({
900
+ _id: /* @__PURE__ */ z.string().describe("Discount rule ID").regex(
893
901
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
894
902
  "Must be a valid GUID"
895
903
  ).optional(),
896
- name: z.object({
897
- original: z.string().describe(
904
+ name: /* @__PURE__ */ z.object({
905
+ original: /* @__PURE__ */ z.string().describe(
898
906
  "Original discount rule name (in site's default language)."
899
907
  ).min(1).max(256).optional(),
900
- translated: z.string().describe(
908
+ translated: /* @__PURE__ */ z.string().describe(
901
909
  "Translated discount rule name according to buyer language. Defaults to `original` when not provided."
902
910
  ).min(1).max(500).optional().nullable()
903
911
  }).describe("Discount rule name").optional(),
904
- amount: z.object({
905
- amount: z.string().describe("Amount.").optional(),
906
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
912
+ amount: /* @__PURE__ */ z.object({
913
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
914
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
907
915
  }).describe("Discount value.").optional()
908
916
  }).describe(
909
917
  "Automatic discount applied by the system based on configured discount rules."
@@ -912,8 +920,8 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
912
920
  ])
913
921
  )
914
922
  ).max(100).optional(),
915
- channelInfo: z.object({
916
- type: z.enum([
923
+ channelInfo: /* @__PURE__ */ z.object({
924
+ type: /* @__PURE__ */ z.enum([
917
925
  "UNSPECIFIED",
918
926
  "WEB",
919
927
  "POS",
@@ -935,40 +943,40 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
935
943
  ]).describe(
936
944
  "Sales channel that submitted the order.\n\nWhen creating an order via the API to record an external order, use the channel type that matches the original source. If no matching type exists, use `OTHER_PLATFORM`."
937
945
  ).optional(),
938
- externalOrderId: z.string().describe(
946
+ externalOrderId: /* @__PURE__ */ z.string().describe(
939
947
  "Reference to an order ID from an external system. Relevant when recording orders from external platforms."
940
948
  ).max(100).optional().nullable(),
941
- externalOrderUrl: z.string().describe(
949
+ externalOrderUrl: /* @__PURE__ */ z.string().describe(
942
950
  "URL to the order in the external system. Relevant when recording orders from external platforms."
943
951
  ).max(300).optional().nullable()
944
952
  }).describe("Information about the sales channel that submitted this order.").optional(),
945
- customFields: z.array(
946
- z.object({
947
- value: z.any().describe("Custom field value.").optional().nullable(),
948
- title: z.string().describe("Custom field title.").min(1).max(500).optional(),
949
- translatedTitle: z.string().describe("Translated custom field title.").min(1).max(500).optional().nullable()
953
+ customFields: /* @__PURE__ */ z.array(
954
+ /* @__PURE__ */ z.object({
955
+ value: /* @__PURE__ */ z.any().describe("Custom field value.").optional().nullable(),
956
+ title: /* @__PURE__ */ z.string().describe("Custom field title.").min(1).max(500).optional(),
957
+ translatedTitle: /* @__PURE__ */ z.string().describe("Translated custom field title.").min(1).max(500).optional().nullable()
950
958
  })
951
959
  ).max(100).optional(),
952
- recipientInfo: z.object({
953
- address: z.object({
954
- streetAddress: z.object({
955
- name: z.string().optional(),
956
- number: z.string().optional()
960
+ recipientInfo: /* @__PURE__ */ z.object({
961
+ address: /* @__PURE__ */ z.object({
962
+ streetAddress: /* @__PURE__ */ z.object({
963
+ name: /* @__PURE__ */ z.string().optional(),
964
+ number: /* @__PURE__ */ z.string().optional()
957
965
  }).optional(),
958
- city: z.string().optional().nullable(),
959
- subdivision: z.string().optional().nullable(),
960
- country: z.string().optional().nullable(),
961
- postalCode: z.string().optional().nullable(),
962
- addressLine2: z.string().optional().nullable()
966
+ city: /* @__PURE__ */ z.string().optional().nullable(),
967
+ subdivision: /* @__PURE__ */ z.string().optional().nullable(),
968
+ country: /* @__PURE__ */ z.string().optional().nullable(),
969
+ postalCode: /* @__PURE__ */ z.string().optional().nullable(),
970
+ addressLine2: /* @__PURE__ */ z.string().optional().nullable()
963
971
  }).describe("Address.").optional(),
964
- contactDetails: z.object({
965
- firstName: z.string().describe("First name.").max(100).optional().nullable(),
966
- lastName: z.string().describe("Last name.").max(100).optional().nullable(),
967
- phone: z.string().describe("Phone number.").optional().nullable(),
968
- company: z.string().describe("Company name.").max(1e3).optional().nullable(),
969
- vatId: z.object({
970
- _id: z.string().describe("Customer's tax ID.").optional(),
971
- type: z.enum(["UNSPECIFIED", "CPF", "CNPJ"]).describe(
972
+ contactDetails: /* @__PURE__ */ z.object({
973
+ firstName: /* @__PURE__ */ z.string().describe("First name.").max(100).optional().nullable(),
974
+ lastName: /* @__PURE__ */ z.string().describe("Last name.").max(100).optional().nullable(),
975
+ phone: /* @__PURE__ */ z.string().describe("Phone number.").optional().nullable(),
976
+ company: /* @__PURE__ */ z.string().describe("Company name.").max(1e3).optional().nullable(),
977
+ vatId: /* @__PURE__ */ z.object({
978
+ _id: /* @__PURE__ */ z.string().describe("Customer's tax ID.").optional(),
979
+ type: /* @__PURE__ */ z.enum(["UNSPECIFIED", "CPF", "CNPJ"]).describe(
972
980
  "Tax type.\n\nSupported values:\n+ `CPF`: for individual tax payers\n+ `CNPJ`: for corporations"
973
981
  ).optional()
974
982
  }).describe(
@@ -978,75 +986,81 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
978
986
  }).describe(
979
987
  "Order recipient address and contact details.\n\nThis field may differ from the address in `shippingInfo.logistics` when:\n+ The chosen shipping option is pickup point or store pickup.\n+ No shipping option is selected."
980
988
  ).optional(),
981
- extendedFields: z.object({
982
- namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
989
+ extendedFields: /* @__PURE__ */ z.object({
990
+ namespaces: /* @__PURE__ */ z.record(
991
+ /* @__PURE__ */ z.string(),
992
+ /* @__PURE__ */ z.record(
993
+ /* @__PURE__ */ z.string(),
994
+ /* @__PURE__ */ z.any()
995
+ )
996
+ ).describe(
983
997
  "Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\nThe value of each key is structured according to the schema defined when the extended fields were configured.\n\nYou can only access fields for which you have the appropriate permissions.\n\nLearn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields)."
984
998
  ).optional()
985
999
  }).describe(
986
1000
  "Custom field data for the subscription contract object.\n\n[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."
987
1001
  ).optional(),
988
- title: z.string().describe(
1002
+ title: /* @__PURE__ */ z.string().describe(
989
1003
  'Subscription option title. For example, `"Monthly coffee Subscription"`.'
990
1004
  ).min(0).max(150).optional().nullable(),
991
- additionalFees: z.array(
992
- z.object({
993
- code: z.string().describe("Additional fee's unique code for future processing.").min(1).max(100).optional().nullable(),
994
- name: z.string().describe("Name of additional fee.").min(1).max(50).optional(),
995
- price: z.object({
996
- amount: z.string().describe("Amount.").optional(),
997
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1005
+ additionalFees: /* @__PURE__ */ z.array(
1006
+ /* @__PURE__ */ z.object({
1007
+ code: /* @__PURE__ */ z.string().describe("Additional fee's unique code for future processing.").min(1).max(100).optional().nullable(),
1008
+ name: /* @__PURE__ */ z.string().describe("Name of additional fee.").min(1).max(50).optional(),
1009
+ price: /* @__PURE__ */ z.object({
1010
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1011
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
998
1012
  }).describe("Additional fee's price.").optional(),
999
- taxDetails: z.object({
1000
- taxableAmount: z.object({
1001
- amount: z.string().describe("Amount.").optional(),
1002
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1013
+ taxDetails: /* @__PURE__ */ z.object({
1014
+ taxableAmount: /* @__PURE__ */ z.object({
1015
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1016
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1003
1017
  }).describe("Taxable amount of this line item.").optional(),
1004
- taxRate: z.string().describe(
1018
+ taxRate: /* @__PURE__ */ z.string().describe(
1005
1019
  'Tax rate percentage, as a decimal numeral between 0 and 1. For example, `"0.13"`.'
1006
1020
  ).optional(),
1007
- totalTax: z.object({
1008
- amount: z.string().describe("Amount.").optional(),
1009
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1021
+ totalTax: /* @__PURE__ */ z.object({
1022
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1023
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1010
1024
  }).describe(
1011
1025
  "The calculated tax, based on the `taxableAmount` and `taxRate`."
1012
1026
  ).optional()
1013
1027
  }).describe("Tax details.").optional(),
1014
- taxInfo: z.object({
1015
- taxAmount: z.object({
1016
- amount: z.string().describe("Amount.").optional(),
1017
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1028
+ taxInfo: /* @__PURE__ */ z.object({
1029
+ taxAmount: /* @__PURE__ */ z.object({
1030
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1031
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1018
1032
  }).describe(
1019
1033
  "Calculated tax, based on `taxable_amount` and `tax_rate`."
1020
1034
  ).optional(),
1021
- taxableAmount: z.object({
1022
- amount: z.string().describe("Amount.").optional(),
1023
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1035
+ taxableAmount: /* @__PURE__ */ z.object({
1036
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1037
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1024
1038
  }).describe("Amount for which tax is calculated.").optional(),
1025
- taxRate: z.string().describe("Tax rate %, as a decimal point.").optional().nullable(),
1026
- taxGroupId: z.string().describe("Tax group ID.").regex(
1039
+ taxRate: /* @__PURE__ */ z.string().describe("Tax rate %, as a decimal point.").optional().nullable(),
1040
+ taxGroupId: /* @__PURE__ */ z.string().describe("Tax group ID.").regex(
1027
1041
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1028
1042
  "Must be a valid GUID"
1029
1043
  ).optional().nullable(),
1030
- taxIncludedInPrice: z.boolean().describe("Indicates whether the price already includes tax.").optional(),
1031
- taxBreakdown: z.array(
1032
- z.object({
1033
- jurisdiction: z.string().describe(
1044
+ taxIncludedInPrice: /* @__PURE__ */ z.boolean().describe("Indicates whether the price already includes tax.").optional(),
1045
+ taxBreakdown: /* @__PURE__ */ z.array(
1046
+ /* @__PURE__ */ z.object({
1047
+ jurisdiction: /* @__PURE__ */ z.string().describe(
1034
1048
  'Jurisdiction that taxes were calculated for. For example, "New York", or "Quebec".'
1035
1049
  ).max(200).optional().nullable(),
1036
- rate: z.string().describe(
1050
+ rate: /* @__PURE__ */ z.string().describe(
1037
1051
  "Tax rate used for this jurisdiction, as a decimal. For example, 10% tax is 0.1000."
1038
1052
  ).optional().nullable(),
1039
- taxAmount: z.object({
1040
- amount: z.string().describe("Amount.").optional(),
1041
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1053
+ taxAmount: /* @__PURE__ */ z.object({
1054
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1055
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1042
1056
  }).describe("Amount of tax calculated for this line item.").optional(),
1043
- taxType: z.string().describe(
1057
+ taxType: /* @__PURE__ */ z.string().describe(
1044
1058
  `The type of tax that was calculated. Depends on the jurisdiction's tax laws. For example, "Sales Tax", "Income Tax", "Value Added Tax", etc.`
1045
1059
  ).max(200).optional().nullable(),
1046
- taxName: z.string().describe(
1060
+ taxName: /* @__PURE__ */ z.string().describe(
1047
1061
  'The name of the tax against which this tax amount was calculated. For example, "NY State Sales Tax", "Quebec GST", etc.\nThis name should be explicit enough to allow the merchant to understand what tax was calculated.'
1048
1062
  ).max(200).optional().nullable(),
1049
- jurisdictionType: z.enum([
1063
+ jurisdictionType: /* @__PURE__ */ z.enum([
1050
1064
  "UNDEFINED",
1051
1065
  "COUNTRY",
1052
1066
  "STATE",
@@ -1056,43 +1070,45 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
1056
1070
  ]).describe(
1057
1071
  "Type of jurisdiction that taxes were calculated for."
1058
1072
  ).optional(),
1059
- nonTaxableAmount: z.object({
1060
- amount: z.string().describe("Amount.").optional(),
1061
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1073
+ nonTaxableAmount: /* @__PURE__ */ z.object({
1074
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1075
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1062
1076
  }).describe("Non-taxable amount of the line item price.").optional(),
1063
- taxableAmount: z.object({
1064
- amount: z.string().describe("Amount.").optional(),
1065
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1077
+ taxableAmount: /* @__PURE__ */ z.object({
1078
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1079
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1066
1080
  }).describe("Taxable amount of the line item price.").optional()
1067
1081
  })
1068
1082
  ).max(7).optional()
1069
1083
  }).describe(
1070
1084
  "Represents all the relevant tax details for additional fee."
1071
1085
  ).optional(),
1072
- providerAppId: z.string().describe("SPI implementer's `appId`.").regex(
1086
+ providerAppId: /* @__PURE__ */ z.string().describe("SPI implementer's `appId`.").regex(
1073
1087
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1074
1088
  "Must be a valid GUID"
1075
1089
  ).optional().nullable(),
1076
- priceBeforeTax: z.object({
1077
- amount: z.string().describe("Amount.").optional(),
1078
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1090
+ priceBeforeTax: /* @__PURE__ */ z.object({
1091
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1092
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1079
1093
  }).describe("Additional fee's price before tax.").optional(),
1080
- priceAfterTax: z.object({
1081
- amount: z.string().describe("Amount.").optional(),
1082
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1094
+ priceAfterTax: /* @__PURE__ */ z.object({
1095
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1096
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1083
1097
  }).describe("Additional fee's price after tax.").optional(),
1084
- _id: z.string().describe("Additional fee's id.").regex(
1098
+ _id: /* @__PURE__ */ z.string().describe("Additional fee's id.").regex(
1085
1099
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1086
1100
  "Must be a valid GUID"
1087
1101
  ).optional(),
1088
- lineItemIds: z.array(z.string()).optional(),
1089
- source: z.enum(["SERVICE_PLUGIN", "ITEM", "MANUAL", "SHIPPING", "PLATFORM"]).describe("Specifies the entity that added the additional fee.").optional(),
1090
- taxableAddress: z.intersection(
1091
- z.object({}),
1092
- z.xor([
1093
- z.object({ addressType: z.never().optional() }),
1094
- z.object({
1095
- addressType: z.enum(["BUSINESS", "BILLING", "SHIPPING"]).describe(
1102
+ lineItemIds: /* @__PURE__ */ z.array(/* @__PURE__ */ z.string()).optional(),
1103
+ source: /* @__PURE__ */ z.enum(["SERVICE_PLUGIN", "ITEM", "MANUAL", "SHIPPING", "PLATFORM"]).describe("Specifies the entity that added the additional fee.").optional(),
1104
+ taxableAddress: /* @__PURE__ */ z.intersection(
1105
+ /* @__PURE__ */ z.object({}),
1106
+ /* @__PURE__ */ z.xor([
1107
+ /* @__PURE__ */ z.object({
1108
+ addressType: /* @__PURE__ */ z.never().optional()
1109
+ }),
1110
+ /* @__PURE__ */ z.object({
1111
+ addressType: /* @__PURE__ */ z.enum(["BUSINESS", "BILLING", "SHIPPING"]).describe(
1096
1112
  "taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly."
1097
1113
  )
1098
1114
  })
@@ -1100,33 +1116,33 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
1100
1116
  ).describe("Address type tax was calculated against for this fee.").optional()
1101
1117
  })
1102
1118
  ).max(100).optional(),
1103
- activities: z.array(
1104
- z.intersection(
1105
- z.object({
1106
- _id: z.string().describe("Activity ID.").regex(
1119
+ activities: /* @__PURE__ */ z.array(
1120
+ /* @__PURE__ */ z.intersection(
1121
+ /* @__PURE__ */ z.object({
1122
+ _id: /* @__PURE__ */ z.string().describe("Activity ID.").regex(
1107
1123
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1108
1124
  "Must be a valid GUID"
1109
1125
  ).optional(),
1110
- _createdDate: z.date().describe("When the activity occurred.").optional().nullable(),
1111
- author: z.intersection(
1112
- z.object({}),
1113
- z.xor([
1114
- z.object({
1115
- userId: z.never().optional(),
1116
- appId: z.never().optional()
1126
+ _createdDate: /* @__PURE__ */ z.date().describe("When the activity occurred.").optional().nullable(),
1127
+ author: /* @__PURE__ */ z.intersection(
1128
+ /* @__PURE__ */ z.object({}),
1129
+ /* @__PURE__ */ z.xor([
1130
+ /* @__PURE__ */ z.object({
1131
+ userId: /* @__PURE__ */ z.never().optional(),
1132
+ appId: /* @__PURE__ */ z.never().optional()
1117
1133
  }),
1118
- z.object({
1119
- appId: z.never().optional(),
1120
- userId: z.string().describe(
1134
+ /* @__PURE__ */ z.object({
1135
+ appId: /* @__PURE__ */ z.never().optional(),
1136
+ userId: /* @__PURE__ */ z.string().describe(
1121
1137
  "User ID. When the draft order was created by a Wix user."
1122
1138
  ).regex(
1123
1139
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1124
1140
  "Must be a valid GUID"
1125
1141
  )
1126
1142
  }),
1127
- z.object({
1128
- userId: z.never().optional(),
1129
- appId: z.string().describe(
1143
+ /* @__PURE__ */ z.object({
1144
+ userId: /* @__PURE__ */ z.never().optional(),
1145
+ appId: /* @__PURE__ */ z.string().describe(
1130
1146
  "App ID. When the draft order was created by an app."
1131
1147
  ).regex(
1132
1148
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
@@ -1135,14 +1151,16 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
1135
1151
  })
1136
1152
  ])
1137
1153
  ).describe("Identity of the draft order's initiator.").optional(),
1138
- activityType: z.enum(["UNKNOWN_ACTIVITY_TYPE", "CHANGES_APPLIED"]).describe("Activity type.").optional()
1154
+ activityType: /* @__PURE__ */ z.enum(["UNKNOWN_ACTIVITY_TYPE", "CHANGES_APPLIED"]).describe("Activity type.").optional()
1139
1155
  }),
1140
- z.intersection(
1141
- z.xor([
1142
- z.object({ contractTarget: z.never().optional() }),
1143
- z.object({
1144
- contractTarget: z.object({
1145
- nextCycleNumber: z.number().int().describe(
1156
+ /* @__PURE__ */ z.intersection(
1157
+ /* @__PURE__ */ z.xor([
1158
+ /* @__PURE__ */ z.object({
1159
+ contractTarget: /* @__PURE__ */ z.never().optional()
1160
+ }),
1161
+ /* @__PURE__ */ z.object({
1162
+ contractTarget: /* @__PURE__ */ z.object({
1163
+ nextCycleNumber: /* @__PURE__ */ z.number().int().describe(
1146
1164
  "Cycle number of the next billing cycle (1-based). Set by the caller; returned by the server on read."
1147
1165
  ).optional().nullable()
1148
1166
  }).describe(
@@ -1150,63 +1168,65 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
1150
1168
  )
1151
1169
  })
1152
1170
  ]),
1153
- z.xor([
1154
- z.object({ changesApplied: z.never().optional() }),
1155
- z.object({
1156
- changesApplied: z.intersection(
1157
- z.object({
1158
- draftSubscriptionContractId: z.string().describe(
1171
+ /* @__PURE__ */ z.xor([
1172
+ /* @__PURE__ */ z.object({
1173
+ changesApplied: /* @__PURE__ */ z.never().optional()
1174
+ }),
1175
+ /* @__PURE__ */ z.object({
1176
+ changesApplied: /* @__PURE__ */ z.intersection(
1177
+ /* @__PURE__ */ z.object({
1178
+ draftSubscriptionContractId: /* @__PURE__ */ z.string().describe(
1159
1179
  "ID of the DraftSubscriptionContract that was committed."
1160
1180
  ).regex(
1161
1181
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1162
1182
  "Must be a valid GUID"
1163
1183
  ).optional(),
1164
- changes: z.array(
1165
- z.intersection(
1166
- z.object({}),
1167
- z.xor([
1168
- z.object({
1169
- lineItemChanged: z.never().optional(),
1170
- lineItemAdded: z.never().optional(),
1171
- lineItemRemoved: z.never().optional(),
1172
- discountAdded: z.never().optional(),
1173
- discountRemoved: z.never().optional(),
1174
- additionalFeeAdded: z.never().optional(),
1175
- additionalFeeRemoved: z.never().optional(),
1176
- totalPriceChanged: z.never().optional()
1184
+ changes: /* @__PURE__ */ z.array(
1185
+ /* @__PURE__ */ z.intersection(
1186
+ /* @__PURE__ */ z.object({}),
1187
+ /* @__PURE__ */ z.xor([
1188
+ /* @__PURE__ */ z.object({
1189
+ lineItemChanged: /* @__PURE__ */ z.never().optional(),
1190
+ lineItemAdded: /* @__PURE__ */ z.never().optional(),
1191
+ lineItemRemoved: /* @__PURE__ */ z.never().optional(),
1192
+ discountAdded: /* @__PURE__ */ z.never().optional(),
1193
+ discountRemoved: /* @__PURE__ */ z.never().optional(),
1194
+ additionalFeeAdded: /* @__PURE__ */ z.never().optional(),
1195
+ additionalFeeRemoved: /* @__PURE__ */ z.never().optional(),
1196
+ totalPriceChanged: /* @__PURE__ */ z.never().optional()
1177
1197
  }),
1178
- z.object({
1179
- lineItemAdded: z.never().optional(),
1180
- lineItemRemoved: z.never().optional(),
1181
- discountAdded: z.never().optional(),
1182
- discountRemoved: z.never().optional(),
1183
- additionalFeeAdded: z.never().optional(),
1184
- additionalFeeRemoved: z.never().optional(),
1185
- totalPriceChanged: z.never().optional(),
1186
- lineItemChanged: z.object({
1187
- _id: z.string().describe("Line item ID.").regex(
1198
+ /* @__PURE__ */ z.object({
1199
+ lineItemAdded: /* @__PURE__ */ z.never().optional(),
1200
+ lineItemRemoved: /* @__PURE__ */ z.never().optional(),
1201
+ discountAdded: /* @__PURE__ */ z.never().optional(),
1202
+ discountRemoved: /* @__PURE__ */ z.never().optional(),
1203
+ additionalFeeAdded: /* @__PURE__ */ z.never().optional(),
1204
+ additionalFeeRemoved: /* @__PURE__ */ z.never().optional(),
1205
+ totalPriceChanged: /* @__PURE__ */ z.never().optional(),
1206
+ lineItemChanged: /* @__PURE__ */ z.object({
1207
+ _id: /* @__PURE__ */ z.string().describe("Line item ID.").regex(
1188
1208
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1189
1209
  "Must be a valid GUID"
1190
1210
  ).optional(),
1191
- name: z.object({
1192
- original: z.string().describe(
1211
+ name: /* @__PURE__ */ z.object({
1212
+ original: /* @__PURE__ */ z.string().describe(
1193
1213
  "__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).\n\nMin: 1 character.\nMax: 200 characters."
1194
1214
  ).min(1).max(200).optional(),
1195
- translated: z.string().describe(
1215
+ translated: /* @__PURE__ */ z.string().describe(
1196
1216
  "Item name translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
1197
1217
  ).min(1).max(400).optional().nullable()
1198
1218
  }).describe("Item name after change.").optional(),
1199
- quantity: z.object({
1200
- originalQuantity: z.number().int().describe(
1219
+ quantity: /* @__PURE__ */ z.object({
1220
+ originalQuantity: /* @__PURE__ */ z.number().int().describe(
1201
1221
  "Original item quantity before the change."
1202
1222
  ).min(0).max(1e6).optional(),
1203
- newQuantity: z.number().int().describe(
1223
+ newQuantity: /* @__PURE__ */ z.number().int().describe(
1204
1224
  "New item quantity after the change."
1205
1225
  ).min(0).max(1e6).optional(),
1206
- diff: z.number().int().describe(
1226
+ diff: /* @__PURE__ */ z.number().int().describe(
1207
1227
  "Difference between new and original quantities."
1208
1228
  ).min(1).max(1e6).optional(),
1209
- deltaType: z.enum([
1229
+ deltaType: /* @__PURE__ */ z.enum([
1210
1230
  "QUANTITY_INCREASED",
1211
1231
  "QUANTITY_DECREASED"
1212
1232
  ]).describe(
@@ -1215,80 +1235,80 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
1215
1235
  }).describe("Item quantity change.").optional()
1216
1236
  }).describe("Line item was modified.")
1217
1237
  }),
1218
- z.object({
1219
- lineItemChanged: z.never().optional(),
1220
- lineItemRemoved: z.never().optional(),
1221
- discountAdded: z.never().optional(),
1222
- discountRemoved: z.never().optional(),
1223
- additionalFeeAdded: z.never().optional(),
1224
- additionalFeeRemoved: z.never().optional(),
1225
- totalPriceChanged: z.never().optional(),
1226
- lineItemAdded: z.object({
1227
- _id: z.string().describe("Line item ID.").regex(
1238
+ /* @__PURE__ */ z.object({
1239
+ lineItemChanged: /* @__PURE__ */ z.never().optional(),
1240
+ lineItemRemoved: /* @__PURE__ */ z.never().optional(),
1241
+ discountAdded: /* @__PURE__ */ z.never().optional(),
1242
+ discountRemoved: /* @__PURE__ */ z.never().optional(),
1243
+ additionalFeeAdded: /* @__PURE__ */ z.never().optional(),
1244
+ additionalFeeRemoved: /* @__PURE__ */ z.never().optional(),
1245
+ totalPriceChanged: /* @__PURE__ */ z.never().optional(),
1246
+ lineItemAdded: /* @__PURE__ */ z.object({
1247
+ _id: /* @__PURE__ */ z.string().describe("Line item ID.").regex(
1228
1248
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1229
1249
  "Must be a valid GUID"
1230
1250
  ).optional(),
1231
- name: z.object({
1232
- original: z.string().describe(
1251
+ name: /* @__PURE__ */ z.object({
1252
+ original: /* @__PURE__ */ z.string().describe(
1233
1253
  "__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).\n\nMin: 1 character.\nMax: 200 characters."
1234
1254
  ).min(1).max(200).optional(),
1235
- translated: z.string().describe(
1255
+ translated: /* @__PURE__ */ z.string().describe(
1236
1256
  "Item name translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
1237
1257
  ).min(1).max(400).optional().nullable()
1238
1258
  }).describe("Item name.").optional(),
1239
- quantity: z.number().int().describe("Added or removed item quantity.").min(1).max(1e6).optional()
1259
+ quantity: /* @__PURE__ */ z.number().int().describe("Added or removed item quantity.").min(1).max(1e6).optional()
1240
1260
  }).describe(
1241
1261
  "Line item was added to the contract."
1242
1262
  )
1243
1263
  }),
1244
- z.object({
1245
- lineItemChanged: z.never().optional(),
1246
- lineItemAdded: z.never().optional(),
1247
- discountAdded: z.never().optional(),
1248
- discountRemoved: z.never().optional(),
1249
- additionalFeeAdded: z.never().optional(),
1250
- additionalFeeRemoved: z.never().optional(),
1251
- totalPriceChanged: z.never().optional(),
1252
- lineItemRemoved: z.object({
1253
- _id: z.string().describe("Line item ID.").regex(
1264
+ /* @__PURE__ */ z.object({
1265
+ lineItemChanged: /* @__PURE__ */ z.never().optional(),
1266
+ lineItemAdded: /* @__PURE__ */ z.never().optional(),
1267
+ discountAdded: /* @__PURE__ */ z.never().optional(),
1268
+ discountRemoved: /* @__PURE__ */ z.never().optional(),
1269
+ additionalFeeAdded: /* @__PURE__ */ z.never().optional(),
1270
+ additionalFeeRemoved: /* @__PURE__ */ z.never().optional(),
1271
+ totalPriceChanged: /* @__PURE__ */ z.never().optional(),
1272
+ lineItemRemoved: /* @__PURE__ */ z.object({
1273
+ _id: /* @__PURE__ */ z.string().describe("Line item ID.").regex(
1254
1274
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1255
1275
  "Must be a valid GUID"
1256
1276
  ).optional(),
1257
- name: z.object({
1258
- original: z.string().describe(
1277
+ name: /* @__PURE__ */ z.object({
1278
+ original: /* @__PURE__ */ z.string().describe(
1259
1279
  "__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).\n\nMin: 1 character.\nMax: 200 characters."
1260
1280
  ).min(1).max(200).optional(),
1261
- translated: z.string().describe(
1281
+ translated: /* @__PURE__ */ z.string().describe(
1262
1282
  "Item name translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
1263
1283
  ).min(1).max(400).optional().nullable()
1264
1284
  }).describe("Item name.").optional(),
1265
- quantity: z.number().int().describe("Added or removed item quantity.").min(1).max(1e6).optional()
1285
+ quantity: /* @__PURE__ */ z.number().int().describe("Added or removed item quantity.").min(1).max(1e6).optional()
1266
1286
  }).describe(
1267
1287
  "Line item was removed from the contract."
1268
1288
  )
1269
1289
  }),
1270
- z.object({
1271
- lineItemChanged: z.never().optional(),
1272
- lineItemAdded: z.never().optional(),
1273
- lineItemRemoved: z.never().optional(),
1274
- discountRemoved: z.never().optional(),
1275
- additionalFeeAdded: z.never().optional(),
1276
- additionalFeeRemoved: z.never().optional(),
1277
- totalPriceChanged: z.never().optional(),
1278
- discountAdded: z.object({
1279
- _id: z.string().describe("Discount ID.").regex(
1290
+ /* @__PURE__ */ z.object({
1291
+ lineItemChanged: /* @__PURE__ */ z.never().optional(),
1292
+ lineItemAdded: /* @__PURE__ */ z.never().optional(),
1293
+ lineItemRemoved: /* @__PURE__ */ z.never().optional(),
1294
+ discountRemoved: /* @__PURE__ */ z.never().optional(),
1295
+ additionalFeeAdded: /* @__PURE__ */ z.never().optional(),
1296
+ additionalFeeRemoved: /* @__PURE__ */ z.never().optional(),
1297
+ totalPriceChanged: /* @__PURE__ */ z.never().optional(),
1298
+ discountAdded: /* @__PURE__ */ z.object({
1299
+ _id: /* @__PURE__ */ z.string().describe("Discount ID.").regex(
1280
1300
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1281
1301
  "Must be a valid GUID"
1282
1302
  ).optional(),
1283
- name: z.object({
1284
- original: z.string().describe(
1303
+ name: /* @__PURE__ */ z.object({
1304
+ original: /* @__PURE__ */ z.string().describe(
1285
1305
  "Value in site default language."
1286
1306
  ).min(1).optional(),
1287
- translated: z.string().describe("Translated value.").min(1).optional().nullable()
1307
+ translated: /* @__PURE__ */ z.string().describe("Translated value.").min(1).optional().nullable()
1288
1308
  }).describe("Discount name.").optional(),
1289
- totalAmount: z.object({
1290
- amount: z.string().describe("Amount.").optional(),
1291
- formattedAmount: z.string().describe(
1309
+ totalAmount: /* @__PURE__ */ z.object({
1310
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1311
+ formattedAmount: /* @__PURE__ */ z.string().describe(
1292
1312
  "Amount formatted with currency symbol."
1293
1313
  ).optional()
1294
1314
  }).describe("Discount amount.").optional()
@@ -1296,28 +1316,28 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
1296
1316
  "Discount was added to the contract."
1297
1317
  )
1298
1318
  }),
1299
- z.object({
1300
- lineItemChanged: z.never().optional(),
1301
- lineItemAdded: z.never().optional(),
1302
- lineItemRemoved: z.never().optional(),
1303
- discountAdded: z.never().optional(),
1304
- additionalFeeAdded: z.never().optional(),
1305
- additionalFeeRemoved: z.never().optional(),
1306
- totalPriceChanged: z.never().optional(),
1307
- discountRemoved: z.object({
1308
- _id: z.string().describe("Discount ID.").regex(
1319
+ /* @__PURE__ */ z.object({
1320
+ lineItemChanged: /* @__PURE__ */ z.never().optional(),
1321
+ lineItemAdded: /* @__PURE__ */ z.never().optional(),
1322
+ lineItemRemoved: /* @__PURE__ */ z.never().optional(),
1323
+ discountAdded: /* @__PURE__ */ z.never().optional(),
1324
+ additionalFeeAdded: /* @__PURE__ */ z.never().optional(),
1325
+ additionalFeeRemoved: /* @__PURE__ */ z.never().optional(),
1326
+ totalPriceChanged: /* @__PURE__ */ z.never().optional(),
1327
+ discountRemoved: /* @__PURE__ */ z.object({
1328
+ _id: /* @__PURE__ */ z.string().describe("Discount ID.").regex(
1309
1329
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1310
1330
  "Must be a valid GUID"
1311
1331
  ).optional(),
1312
- name: z.object({
1313
- original: z.string().describe(
1332
+ name: /* @__PURE__ */ z.object({
1333
+ original: /* @__PURE__ */ z.string().describe(
1314
1334
  "Value in site default language."
1315
1335
  ).min(1).optional(),
1316
- translated: z.string().describe("Translated value.").min(1).optional().nullable()
1336
+ translated: /* @__PURE__ */ z.string().describe("Translated value.").min(1).optional().nullable()
1317
1337
  }).describe("Discount name.").optional(),
1318
- totalAmount: z.object({
1319
- amount: z.string().describe("Amount.").optional(),
1320
- formattedAmount: z.string().describe(
1338
+ totalAmount: /* @__PURE__ */ z.object({
1339
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1340
+ formattedAmount: /* @__PURE__ */ z.string().describe(
1321
1341
  "Amount formatted with currency symbol."
1322
1342
  ).optional()
1323
1343
  }).describe("Discount amount.").optional()
@@ -1325,28 +1345,28 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
1325
1345
  "Discount was removed from the contract."
1326
1346
  )
1327
1347
  }),
1328
- z.object({
1329
- lineItemChanged: z.never().optional(),
1330
- lineItemAdded: z.never().optional(),
1331
- lineItemRemoved: z.never().optional(),
1332
- discountAdded: z.never().optional(),
1333
- discountRemoved: z.never().optional(),
1334
- additionalFeeRemoved: z.never().optional(),
1335
- totalPriceChanged: z.never().optional(),
1336
- additionalFeeAdded: z.object({
1337
- _id: z.string().describe("Additional fee ID.").regex(
1348
+ /* @__PURE__ */ z.object({
1349
+ lineItemChanged: /* @__PURE__ */ z.never().optional(),
1350
+ lineItemAdded: /* @__PURE__ */ z.never().optional(),
1351
+ lineItemRemoved: /* @__PURE__ */ z.never().optional(),
1352
+ discountAdded: /* @__PURE__ */ z.never().optional(),
1353
+ discountRemoved: /* @__PURE__ */ z.never().optional(),
1354
+ additionalFeeRemoved: /* @__PURE__ */ z.never().optional(),
1355
+ totalPriceChanged: /* @__PURE__ */ z.never().optional(),
1356
+ additionalFeeAdded: /* @__PURE__ */ z.object({
1357
+ _id: /* @__PURE__ */ z.string().describe("Additional fee ID.").regex(
1338
1358
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1339
1359
  "Must be a valid GUID"
1340
1360
  ).optional(),
1341
- name: z.object({
1342
- original: z.string().describe(
1361
+ name: /* @__PURE__ */ z.object({
1362
+ original: /* @__PURE__ */ z.string().describe(
1343
1363
  "Value in site default language."
1344
1364
  ).min(1).optional(),
1345
- translated: z.string().describe("Translated value.").min(1).optional().nullable()
1365
+ translated: /* @__PURE__ */ z.string().describe("Translated value.").min(1).optional().nullable()
1346
1366
  }).describe("Additional fee name.").optional(),
1347
- totalAmount: z.object({
1348
- amount: z.string().describe("Amount.").optional(),
1349
- formattedAmount: z.string().describe(
1367
+ totalAmount: /* @__PURE__ */ z.object({
1368
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1369
+ formattedAmount: /* @__PURE__ */ z.string().describe(
1350
1370
  "Amount formatted with currency symbol."
1351
1371
  ).optional()
1352
1372
  }).describe("Additional fee amount.").optional()
@@ -1354,28 +1374,28 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
1354
1374
  "Additional fee was added to the contract."
1355
1375
  )
1356
1376
  }),
1357
- z.object({
1358
- lineItemChanged: z.never().optional(),
1359
- lineItemAdded: z.never().optional(),
1360
- lineItemRemoved: z.never().optional(),
1361
- discountAdded: z.never().optional(),
1362
- discountRemoved: z.never().optional(),
1363
- additionalFeeAdded: z.never().optional(),
1364
- totalPriceChanged: z.never().optional(),
1365
- additionalFeeRemoved: z.object({
1366
- _id: z.string().describe("Additional fee ID.").regex(
1377
+ /* @__PURE__ */ z.object({
1378
+ lineItemChanged: /* @__PURE__ */ z.never().optional(),
1379
+ lineItemAdded: /* @__PURE__ */ z.never().optional(),
1380
+ lineItemRemoved: /* @__PURE__ */ z.never().optional(),
1381
+ discountAdded: /* @__PURE__ */ z.never().optional(),
1382
+ discountRemoved: /* @__PURE__ */ z.never().optional(),
1383
+ additionalFeeAdded: /* @__PURE__ */ z.never().optional(),
1384
+ totalPriceChanged: /* @__PURE__ */ z.never().optional(),
1385
+ additionalFeeRemoved: /* @__PURE__ */ z.object({
1386
+ _id: /* @__PURE__ */ z.string().describe("Additional fee ID.").regex(
1367
1387
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1368
1388
  "Must be a valid GUID"
1369
1389
  ).optional(),
1370
- name: z.object({
1371
- original: z.string().describe(
1390
+ name: /* @__PURE__ */ z.object({
1391
+ original: /* @__PURE__ */ z.string().describe(
1372
1392
  "Value in site default language."
1373
1393
  ).min(1).optional(),
1374
- translated: z.string().describe("Translated value.").min(1).optional().nullable()
1394
+ translated: /* @__PURE__ */ z.string().describe("Translated value.").min(1).optional().nullable()
1375
1395
  }).describe("Additional fee name.").optional(),
1376
- totalAmount: z.object({
1377
- amount: z.string().describe("Amount.").optional(),
1378
- formattedAmount: z.string().describe(
1396
+ totalAmount: /* @__PURE__ */ z.object({
1397
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1398
+ formattedAmount: /* @__PURE__ */ z.string().describe(
1379
1399
  "Amount formatted with currency symbol."
1380
1400
  ).optional()
1381
1401
  }).describe("Additional fee amount.").optional()
@@ -1383,24 +1403,24 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
1383
1403
  "Additional fee was removed from the contract."
1384
1404
  )
1385
1405
  }),
1386
- z.object({
1387
- lineItemChanged: z.never().optional(),
1388
- lineItemAdded: z.never().optional(),
1389
- lineItemRemoved: z.never().optional(),
1390
- discountAdded: z.never().optional(),
1391
- discountRemoved: z.never().optional(),
1392
- additionalFeeAdded: z.never().optional(),
1393
- additionalFeeRemoved: z.never().optional(),
1394
- totalPriceChanged: z.object({
1395
- originalTotal: z.object({
1396
- amount: z.string().describe("Amount.").optional(),
1397
- formattedAmount: z.string().describe(
1406
+ /* @__PURE__ */ z.object({
1407
+ lineItemChanged: /* @__PURE__ */ z.never().optional(),
1408
+ lineItemAdded: /* @__PURE__ */ z.never().optional(),
1409
+ lineItemRemoved: /* @__PURE__ */ z.never().optional(),
1410
+ discountAdded: /* @__PURE__ */ z.never().optional(),
1411
+ discountRemoved: /* @__PURE__ */ z.never().optional(),
1412
+ additionalFeeAdded: /* @__PURE__ */ z.never().optional(),
1413
+ additionalFeeRemoved: /* @__PURE__ */ z.never().optional(),
1414
+ totalPriceChanged: /* @__PURE__ */ z.object({
1415
+ originalTotal: /* @__PURE__ */ z.object({
1416
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1417
+ formattedAmount: /* @__PURE__ */ z.string().describe(
1398
1418
  "Amount formatted with currency symbol."
1399
1419
  ).optional()
1400
1420
  }).describe("Total price before the commit.").optional(),
1401
- newTotal: z.object({
1402
- amount: z.string().describe("Amount.").optional(),
1403
- formattedAmount: z.string().describe(
1421
+ newTotal: /* @__PURE__ */ z.object({
1422
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1423
+ formattedAmount: /* @__PURE__ */ z.string().describe(
1404
1424
  "Amount formatted with currency symbol."
1405
1425
  ).optional()
1406
1426
  }).describe("Total price after the commit.").optional()
@@ -1409,15 +1429,17 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
1409
1429
  ])
1410
1430
  )
1411
1431
  ).max(100).optional(),
1412
- reason: z.string().describe(
1432
+ reason: /* @__PURE__ */ z.string().describe(
1413
1433
  "Reason for the edit, provided by the merchant (optional)."
1414
1434
  ).max(200).optional().nullable()
1415
1435
  }),
1416
- z.xor([
1417
- z.object({ contractTarget: z.never().optional() }),
1418
- z.object({
1419
- contractTarget: z.object({
1420
- nextCycleNumber: z.number().int().describe(
1436
+ /* @__PURE__ */ z.xor([
1437
+ /* @__PURE__ */ z.object({
1438
+ contractTarget: /* @__PURE__ */ z.never().optional()
1439
+ }),
1440
+ /* @__PURE__ */ z.object({
1441
+ contractTarget: /* @__PURE__ */ z.object({
1442
+ nextCycleNumber: /* @__PURE__ */ z.number().int().describe(
1421
1443
  "Cycle number of the next billing cycle (1-based). Set by the caller; returned by the server on read."
1422
1444
  ).optional().nullable()
1423
1445
  }).describe(
@@ -1435,24 +1457,26 @@ var GetSubscriptionContractResponse = /* @__PURE__ */ z.object({
1435
1457
  ).max(500).optional()
1436
1458
  });
1437
1459
  var QuerySubscriptionContractsRequest = /* @__PURE__ */ z.object({
1438
- query: z.intersection(
1439
- z.object({
1440
- filter: z.record(z.string(), z.any()).describe(
1460
+ query: /* @__PURE__ */ z.intersection(
1461
+ /* @__PURE__ */ z.object({
1462
+ filter: /* @__PURE__ */ z.record(/* @__PURE__ */ z.string(), /* @__PURE__ */ z.any()).describe(
1441
1463
  'Filter object in the following format:\n`"filter" : {\n"fieldName1": "value1",\n"fieldName2":{"$operator":"value2"}\n}`\nExample of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`\nLearn more about the [filter format](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-filter-section).'
1442
1464
  ).optional().nullable(),
1443
- sort: z.array(
1444
- z.object({
1445
- fieldName: z.string().describe("Name of the field to sort by.").max(512).optional(),
1446
- order: z.enum(["ASC", "DESC"]).optional()
1465
+ sort: /* @__PURE__ */ z.array(
1466
+ /* @__PURE__ */ z.object({
1467
+ fieldName: /* @__PURE__ */ z.string().describe("Name of the field to sort by.").max(512).optional(),
1468
+ order: /* @__PURE__ */ z.enum(["ASC", "DESC"]).optional()
1447
1469
  })
1448
1470
  ).max(5).optional()
1449
1471
  }),
1450
- z.xor([
1451
- z.object({ cursorPaging: z.never().optional() }),
1452
- z.object({
1453
- cursorPaging: z.object({
1454
- limit: z.number().int().describe("Maximum number of items to return in the results.").min(0).max(100).optional().nullable(),
1455
- cursor: z.string().describe(
1472
+ /* @__PURE__ */ z.xor([
1473
+ /* @__PURE__ */ z.object({
1474
+ cursorPaging: /* @__PURE__ */ z.never().optional()
1475
+ }),
1476
+ /* @__PURE__ */ z.object({
1477
+ cursorPaging: /* @__PURE__ */ z.object({
1478
+ limit: /* @__PURE__ */ z.number().int().describe("Maximum number of items to return in the results.").min(0).max(100).optional().nullable(),
1479
+ cursor: /* @__PURE__ */ z.string().describe(
1456
1480
  "Pointer to the next or previous page in the list of results.\n\nPass the relevant cursor token from the `pagingMetadata` object in the previous call's response.\nNot relevant for the first request."
1457
1481
  ).max(16e3).optional().nullable()
1458
1482
  }).describe(
@@ -1463,147 +1487,147 @@ var QuerySubscriptionContractsRequest = /* @__PURE__ */ z.object({
1463
1487
  ).describe("WQL expression.")
1464
1488
  });
1465
1489
  var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
1466
- subscriptionContracts: z.array(
1467
- z.object({
1468
- _id: z.string().describe("SubscriptionContract ID.").regex(
1490
+ subscriptionContracts: /* @__PURE__ */ z.array(
1491
+ /* @__PURE__ */ z.object({
1492
+ _id: /* @__PURE__ */ z.string().describe("SubscriptionContract ID.").regex(
1469
1493
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1470
1494
  "Must be a valid GUID"
1471
1495
  ).optional().nullable(),
1472
- revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
1496
+ revision: /* @__PURE__ */ z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
1473
1497
  "Revision number, which increments by 1 each time the SubscriptionContract is updated.\nTo prevent conflicting changes, the current revision must be passed when updating the SubscriptionContract.\n\nIgnored when creating a SubscriptionOrderContract."
1474
1498
  ).optional().nullable(),
1475
- _createdDate: z.date().describe(
1499
+ _createdDate: /* @__PURE__ */ z.date().describe(
1476
1500
  "Date and time the subscription contract was created in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format."
1477
1501
  ).optional().nullable(),
1478
- _updatedDate: z.date().describe(
1502
+ _updatedDate: /* @__PURE__ */ z.date().describe(
1479
1503
  "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."
1480
1504
  ).optional().nullable(),
1481
- description: z.string().describe(
1505
+ description: /* @__PURE__ */ z.string().describe(
1482
1506
  'Subscription option description. For example, `"1kg of selected coffee, once a month"`.'
1483
1507
  ).max(500).optional().nullable(),
1484
- subscriptionSettings: z.object({
1485
- frequency: z.enum(["UNDEFINED", "DAY", "WEEK", "MONTH", "YEAR"]).describe("Frequency of recurring payment.").optional(),
1486
- interval: z.number().int().describe(
1508
+ subscriptionSettings: /* @__PURE__ */ z.object({
1509
+ frequency: /* @__PURE__ */ z.enum(["UNDEFINED", "DAY", "WEEK", "MONTH", "YEAR"]).describe("Frequency of recurring payment.").optional(),
1510
+ interval: /* @__PURE__ */ z.number().int().describe(
1487
1511
  "Number of frequency units in a billing cycle. For example, frequency `MONTH` with interval `3` means billing every 3 months."
1488
1512
  ).min(1).max(3650).optional().nullable(),
1489
- autoRenewal: z.boolean().describe(
1513
+ autoRenewal: /* @__PURE__ */ z.boolean().describe(
1490
1514
  "Whether subscription is renewed automatically at the end of each period."
1491
1515
  ).optional(),
1492
- billingCycles: z.number().int().describe(
1516
+ billingCycles: /* @__PURE__ */ z.number().int().describe(
1493
1517
  "Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`."
1494
1518
  ).min(1).optional().nullable(),
1495
- enableCustomerCancellation: z.boolean().describe(
1519
+ enableCustomerCancellation: /* @__PURE__ */ z.boolean().describe(
1496
1520
  "Whether to allow the customer to cancel the subscription."
1497
1521
  ).optional(),
1498
- freeTrialPeriod: z.object({
1499
- frequency: z.enum(["UNDEFINED", "DAY", "WEEK", "MONTH", "YEAR"]).describe(
1522
+ freeTrialPeriod: /* @__PURE__ */ z.object({
1523
+ frequency: /* @__PURE__ */ z.enum(["UNDEFINED", "DAY", "WEEK", "MONTH", "YEAR"]).describe(
1500
1524
  "Frequency of period. Values: DAY, WEEK, MONTH, YEAR"
1501
1525
  ).optional(),
1502
- interval: z.number().int().describe(
1526
+ interval: /* @__PURE__ */ z.number().int().describe(
1503
1527
  "Number of frequency units in the free trial period. For example, frequency `MONTH` with interval `3` means a 3-month free trial."
1504
1528
  ).min(1).max(3650).optional()
1505
1529
  }).describe(
1506
1530
  "Period until first cycle starts. If None => no free trial"
1507
1531
  ).optional()
1508
1532
  }).describe("Subscription detailed information.").optional(),
1509
- lineItems: z.array(
1510
- z.object({
1511
- _id: z.string().describe("Line item ID.").optional(),
1512
- productName: z.object({
1513
- original: z.string().describe(
1533
+ lineItems: /* @__PURE__ */ z.array(
1534
+ /* @__PURE__ */ z.object({
1535
+ _id: /* @__PURE__ */ z.string().describe("Line item ID.").optional(),
1536
+ productName: /* @__PURE__ */ z.object({
1537
+ original: /* @__PURE__ */ z.string().describe(
1514
1538
  "__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).\n\nMin: 1 character.\nMax: 200 characters."
1515
1539
  ).min(1).max(200).optional(),
1516
- translated: z.string().describe(
1540
+ translated: /* @__PURE__ */ z.string().describe(
1517
1541
  "Item name translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
1518
1542
  ).min(1).max(400).optional().nullable()
1519
1543
  }).describe(
1520
1544
  "Item name.\n\n+ Stores - `product.name`\n+ Bookings - `service.info.name`\n+ Events - `ticket.name`"
1521
1545
  ).optional(),
1522
- catalogReference: z.object({
1523
- catalogItemId: z.string().describe(
1546
+ catalogReference: /* @__PURE__ */ z.object({
1547
+ catalogItemId: /* @__PURE__ */ z.string().describe(
1524
1548
  "ID of the item within the catalog it belongs to."
1525
1549
  ).min(1).max(36).optional(),
1526
- appId: z.string().describe(
1550
+ appId: /* @__PURE__ */ z.string().describe(
1527
1551
  'ID of the app providing the catalog.\n\nYou can get your app\'s ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).\n\nFor items from Wix catalogs, the following values always apply:\n+ Wix Stores: `"215238eb-22a5-4c36-9e7b-e7c08025e04e"`\n+ Wix Bookings: `"13d21c63-b5ec-5912-8397-c3a5ddb27a97"`\n+ Wix Restaurants: `"9a5d83fd-8570-482e-81ab-cfa88942ee60"`'
1528
1552
  ).min(1).optional(),
1529
- options: z.record(z.string(), z.any()).describe(
1553
+ options: /* @__PURE__ */ z.record(/* @__PURE__ */ z.string(), /* @__PURE__ */ z.any()).describe(
1530
1554
  "Additional item details in `key:value` pairs.\n\nUse this optional field for more specificity with item selection. The values of the `options` field differ depending on which catalog is providing the items.\n\nFor Wix Stores products, learn more about integrating with [Catalog V3](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)\nor [Catalog V1](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v1/catalog/e-commerce-integration), depending on [the version the site uses](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-versioning/introduction)."
1531
1555
  ).optional().nullable()
1532
1556
  }).describe(
1533
1557
  "References to the line item's origin catalog. Empty for custom line items."
1534
1558
  ).optional(),
1535
- quantity: z.number().int().describe("Line item quantity.").min(1).max(1e5).optional(),
1536
- totalDiscount: z.object({
1537
- amount: z.string().describe("Amount.").optional(),
1538
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1559
+ quantity: /* @__PURE__ */ z.number().int().describe("Line item quantity.").min(1).max(1e5).optional(),
1560
+ totalDiscount: /* @__PURE__ */ z.object({
1561
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1562
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1539
1563
  }).describe(
1540
1564
  "Total discount for this line item's entire quantity."
1541
1565
  ).optional(),
1542
- descriptionLines: z.array(
1543
- z.intersection(
1544
- z.object({
1545
- name: z.object({
1546
- original: z.string().describe(
1566
+ descriptionLines: /* @__PURE__ */ z.array(
1567
+ /* @__PURE__ */ z.intersection(
1568
+ /* @__PURE__ */ z.object({
1569
+ name: /* @__PURE__ */ z.object({
1570
+ original: /* @__PURE__ */ z.string().describe(
1547
1571
  "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)."
1548
1572
  ).max(100).optional(),
1549
- translated: z.string().describe(
1573
+ translated: /* @__PURE__ */ z.string().describe(
1550
1574
  "Description line name translated into the buyer's language.\n\nDefault: Same as `original`."
1551
1575
  ).max(200).optional().nullable()
1552
1576
  }).describe("Description line name.").optional()
1553
1577
  }),
1554
- z.xor([
1555
- z.object({
1556
- plainText: z.never().optional(),
1557
- colorInfo: z.never().optional()
1578
+ /* @__PURE__ */ z.xor([
1579
+ /* @__PURE__ */ z.object({
1580
+ plainText: /* @__PURE__ */ z.never().optional(),
1581
+ colorInfo: /* @__PURE__ */ z.never().optional()
1558
1582
  }),
1559
- z.object({
1560
- colorInfo: z.never().optional(),
1561
- plainText: z.object({
1562
- original: z.string().describe(
1583
+ /* @__PURE__ */ z.object({
1584
+ colorInfo: /* @__PURE__ */ z.never().optional(),
1585
+ plainText: /* @__PURE__ */ z.object({
1586
+ original: /* @__PURE__ */ z.string().describe(
1563
1587
  "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)."
1564
1588
  ).max(600).optional(),
1565
- translated: z.string().describe(
1589
+ translated: /* @__PURE__ */ z.string().describe(
1566
1590
  "Description line plain text value translated into the buyer's language.\n\nDefault: Same as `original`."
1567
1591
  ).max(600).optional().nullable()
1568
1592
  }).describe("Description line plain text value.")
1569
1593
  }),
1570
- z.object({
1571
- plainText: z.never().optional(),
1572
- colorInfo: z.object({
1573
- original: z.string().describe(
1594
+ /* @__PURE__ */ z.object({
1595
+ plainText: /* @__PURE__ */ z.never().optional(),
1596
+ colorInfo: /* @__PURE__ */ z.object({
1597
+ original: /* @__PURE__ */ z.string().describe(
1574
1598
  "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)."
1575
1599
  ).max(500).optional(),
1576
- translated: z.string().describe(
1600
+ translated: /* @__PURE__ */ z.string().describe(
1577
1601
  "Description line color name translated into the buyer's language.\n\nDefault: Same as `original`."
1578
1602
  ).max(500).optional().nullable(),
1579
- code: z.string().describe("HEX or RGB color code for display.").optional().nullable()
1603
+ code: /* @__PURE__ */ z.string().describe("HEX or RGB color code for display.").optional().nullable()
1580
1604
  }).describe("Description line color value.")
1581
1605
  })
1582
1606
  ])
1583
1607
  )
1584
1608
  ).min(0).max(20).optional(),
1585
- image: z.string().describe("Line item image.").optional(),
1586
- physicalProperties: z.object({
1587
- weight: z.number().describe(
1609
+ image: /* @__PURE__ */ z.string().describe("Line item image.").optional(),
1610
+ physicalProperties: /* @__PURE__ */ z.object({
1611
+ weight: /* @__PURE__ */ z.number().describe(
1588
1612
  "Line item weight. Measurement unit matches the weight unit specified in `weightUnit` in the request."
1589
1613
  ).optional().nullable(),
1590
- sku: z.string().describe(
1614
+ sku: /* @__PURE__ */ z.string().describe(
1591
1615
  "Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku)."
1592
1616
  ).max(40).optional().nullable(),
1593
- shippable: z.boolean().describe("Whether this line item is shippable.").optional()
1617
+ shippable: /* @__PURE__ */ z.boolean().describe("Whether this line item is shippable.").optional()
1594
1618
  }).describe(
1595
1619
  "Physical properties of the item. When relevant, contains information such as SKU and item weight."
1596
1620
  ).optional(),
1597
- itemType: z.intersection(
1598
- z.object({}),
1599
- z.xor([
1600
- z.object({
1601
- preset: z.never().optional(),
1602
- custom: z.never().optional()
1621
+ itemType: /* @__PURE__ */ z.intersection(
1622
+ /* @__PURE__ */ z.object({}),
1623
+ /* @__PURE__ */ z.xor([
1624
+ /* @__PURE__ */ z.object({
1625
+ preset: /* @__PURE__ */ z.never().optional(),
1626
+ custom: /* @__PURE__ */ z.never().optional()
1603
1627
  }),
1604
- z.object({
1605
- custom: z.never().optional(),
1606
- preset: z.enum([
1628
+ /* @__PURE__ */ z.object({
1629
+ custom: /* @__PURE__ */ z.never().optional(),
1630
+ preset: /* @__PURE__ */ z.enum([
1607
1631
  "UNRECOGNISED",
1608
1632
  "PHYSICAL",
1609
1633
  "DIGITAL",
@@ -1611,45 +1635,45 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
1611
1635
  "SERVICE"
1612
1636
  ]).describe("Preset item type.")
1613
1637
  }),
1614
- z.object({
1615
- preset: z.never().optional(),
1616
- custom: z.string().describe(
1638
+ /* @__PURE__ */ z.object({
1639
+ preset: /* @__PURE__ */ z.never().optional(),
1640
+ custom: /* @__PURE__ */ z.string().describe(
1617
1641
  "Custom item type. When none of the preset types are suitable, specifies the custom type."
1618
1642
  )
1619
1643
  })
1620
1644
  ])
1621
1645
  ).describe("Item type. Either a preset type or custom.").optional(),
1622
- fulfillerId: z.string().describe(
1646
+ fulfillerId: /* @__PURE__ */ z.string().describe(
1623
1647
  "Fulfiller ID. Field is empty when the line item is self-fulfilled.\nTo 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)."
1624
1648
  ).regex(
1625
1649
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1626
1650
  "Must be a valid GUID"
1627
1651
  ).optional().nullable(),
1628
- refundQuantity: z.number().int().describe("Number of items that were refunded.").min(0).max(1e5).optional().nullable(),
1629
- restockQuantity: z.number().int().describe(
1652
+ refundQuantity: /* @__PURE__ */ z.number().int().describe("Number of items that were refunded.").min(0).max(1e5).optional().nullable(),
1653
+ restockQuantity: /* @__PURE__ */ z.number().int().describe(
1630
1654
  "Number of items restocked.\n\nFor a per-location breakdown, see `restockLocations`."
1631
1655
  ).min(0).max(1e5).optional().nullable(),
1632
- price: z.object({
1633
- amount: z.string().describe("Amount.").optional(),
1634
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1656
+ price: /* @__PURE__ */ z.object({
1657
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1658
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1635
1659
  }).describe(
1636
1660
  "Line item price after line item discounts for display purposes."
1637
1661
  ).optional(),
1638
- priceBeforeDiscounts: z.object({
1639
- amount: z.string().describe("Amount.").optional(),
1640
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1662
+ priceBeforeDiscounts: /* @__PURE__ */ z.object({
1663
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1664
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1641
1665
  }).describe(
1642
1666
  "Line item price before line item discounts for display purposes. Defaults to `price` when not provided."
1643
1667
  ).optional(),
1644
- totalPriceBeforeTax: z.object({
1645
- amount: z.string().describe("Amount.").optional(),
1646
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1668
+ totalPriceBeforeTax: /* @__PURE__ */ z.object({
1669
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1670
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1647
1671
  }).describe("Total price after discounts, and before tax.").optional(),
1648
- totalPriceAfterTax: z.object({
1649
- amount: z.string().describe("Amount.").optional(),
1650
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1672
+ totalPriceAfterTax: /* @__PURE__ */ z.object({
1673
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1674
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1651
1675
  }).describe("Total price after all discounts and tax.").optional(),
1652
- paymentOption: z.enum([
1676
+ paymentOption: /* @__PURE__ */ z.enum([
1653
1677
  "FULL_PAYMENT_ONLINE",
1654
1678
  "FULL_PAYMENT_OFFLINE",
1655
1679
  "MEMBERSHIP",
@@ -1659,65 +1683,65 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
1659
1683
  ]).describe(
1660
1684
  "Type of selected payment option for current item.\n\nDefault: `FULL_PAYMENT_ONLINE`"
1661
1685
  ).optional(),
1662
- taxDetails: z.object({
1663
- taxableAmount: z.object({
1664
- amount: z.string().describe("Amount.").optional(),
1665
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1686
+ taxDetails: /* @__PURE__ */ z.object({
1687
+ taxableAmount: /* @__PURE__ */ z.object({
1688
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1689
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1666
1690
  }).describe("Taxable amount of this line item.").optional(),
1667
- taxRate: z.string().describe(
1691
+ taxRate: /* @__PURE__ */ z.string().describe(
1668
1692
  'Tax rate percentage, as a decimal numeral between 0 and 1. For example, `"0.13"`.'
1669
1693
  ).optional(),
1670
- totalTax: z.object({
1671
- amount: z.string().describe("Amount.").optional(),
1672
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1694
+ totalTax: /* @__PURE__ */ z.object({
1695
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1696
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1673
1697
  }).describe(
1674
1698
  "The calculated tax, based on the `taxableAmount` and `taxRate`."
1675
1699
  ).optional()
1676
1700
  }).describe(
1677
1701
  "Deprecated. Use `taxInfo` instead.\nThis field will be removed on September 30, 2024.\nTax details for this line item."
1678
1702
  ).optional(),
1679
- taxInfo: z.object({
1680
- taxAmount: z.object({
1681
- amount: z.string().describe("Amount.").optional(),
1682
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1703
+ taxInfo: /* @__PURE__ */ z.object({
1704
+ taxAmount: /* @__PURE__ */ z.object({
1705
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1706
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1683
1707
  }).describe(
1684
1708
  "Calculated tax, based on `taxable_amount` and `tax_rate`."
1685
1709
  ).optional(),
1686
- taxableAmount: z.object({
1687
- amount: z.string().describe("Amount.").optional(),
1688
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1710
+ taxableAmount: /* @__PURE__ */ z.object({
1711
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1712
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1689
1713
  }).describe("Amount for which tax is calculated.").optional(),
1690
- taxRate: z.string().describe("Tax rate %, as a decimal point.").optional().nullable(),
1691
- taxGroupId: z.string().describe("Tax group ID.").regex(
1714
+ taxRate: /* @__PURE__ */ z.string().describe("Tax rate %, as a decimal point.").optional().nullable(),
1715
+ taxGroupId: /* @__PURE__ */ z.string().describe("Tax group ID.").regex(
1692
1716
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1693
1717
  "Must be a valid GUID"
1694
1718
  ).optional().nullable(),
1695
- taxIncludedInPrice: z.boolean().describe(
1719
+ taxIncludedInPrice: /* @__PURE__ */ z.boolean().describe(
1696
1720
  "Indicates whether the price already includes tax."
1697
1721
  ).optional(),
1698
- taxBreakdown: z.array(
1699
- z.object({
1700
- jurisdiction: z.string().describe(
1722
+ taxBreakdown: /* @__PURE__ */ z.array(
1723
+ /* @__PURE__ */ z.object({
1724
+ jurisdiction: /* @__PURE__ */ z.string().describe(
1701
1725
  'Jurisdiction that taxes were calculated for. For example, "New York", or "Quebec".'
1702
1726
  ).max(200).optional().nullable(),
1703
- rate: z.string().describe(
1727
+ rate: /* @__PURE__ */ z.string().describe(
1704
1728
  "Tax rate used for this jurisdiction, as a decimal. For example, 10% tax is 0.1000."
1705
1729
  ).optional().nullable(),
1706
- taxAmount: z.object({
1707
- amount: z.string().describe("Amount.").optional(),
1708
- formattedAmount: z.string().describe(
1730
+ taxAmount: /* @__PURE__ */ z.object({
1731
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1732
+ formattedAmount: /* @__PURE__ */ z.string().describe(
1709
1733
  "Amount formatted with currency symbol."
1710
1734
  ).optional()
1711
1735
  }).describe(
1712
1736
  "Amount of tax calculated for this line item."
1713
1737
  ).optional(),
1714
- taxType: z.string().describe(
1738
+ taxType: /* @__PURE__ */ z.string().describe(
1715
1739
  `The type of tax that was calculated. Depends on the jurisdiction's tax laws. For example, "Sales Tax", "Income Tax", "Value Added Tax", etc.`
1716
1740
  ).max(200).optional().nullable(),
1717
- taxName: z.string().describe(
1741
+ taxName: /* @__PURE__ */ z.string().describe(
1718
1742
  'The name of the tax against which this tax amount was calculated. For example, "NY State Sales Tax", "Quebec GST", etc.\nThis name should be explicit enough to allow the merchant to understand what tax was calculated.'
1719
1743
  ).max(200).optional().nullable(),
1720
- jurisdictionType: z.enum([
1744
+ jurisdictionType: /* @__PURE__ */ z.enum([
1721
1745
  "UNDEFINED",
1722
1746
  "COUNTRY",
1723
1747
  "STATE",
@@ -1727,17 +1751,17 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
1727
1751
  ]).describe(
1728
1752
  "Type of jurisdiction that taxes were calculated for."
1729
1753
  ).optional(),
1730
- nonTaxableAmount: z.object({
1731
- amount: z.string().describe("Amount.").optional(),
1732
- formattedAmount: z.string().describe(
1754
+ nonTaxableAmount: /* @__PURE__ */ z.object({
1755
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1756
+ formattedAmount: /* @__PURE__ */ z.string().describe(
1733
1757
  "Amount formatted with currency symbol."
1734
1758
  ).optional()
1735
1759
  }).describe(
1736
1760
  "Non-taxable amount of the line item price."
1737
1761
  ).optional(),
1738
- taxableAmount: z.object({
1739
- amount: z.string().describe("Amount.").optional(),
1740
- formattedAmount: z.string().describe(
1762
+ taxableAmount: /* @__PURE__ */ z.object({
1763
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1764
+ formattedAmount: /* @__PURE__ */ z.string().describe(
1741
1765
  "Amount formatted with currency symbol."
1742
1766
  ).optional()
1743
1767
  }).describe("Taxable amount of the line item price.").optional()
@@ -1746,137 +1770,139 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
1746
1770
  }).describe(
1747
1771
  "Represents all the relevant tax details for a specific line item."
1748
1772
  ).optional(),
1749
- digitalFile: z.object({
1750
- fileId: z.string().describe("ID of the secure file in media.").min(1).max(100).optional(),
1751
- link: z.string().describe(
1773
+ digitalFile: /* @__PURE__ */ z.object({
1774
+ fileId: /* @__PURE__ */ z.string().describe("ID of the secure file in media.").min(1).max(100).optional(),
1775
+ link: /* @__PURE__ */ z.string().describe(
1752
1776
  "Link will exist after the digital links have been generated on the order."
1753
1777
  ).url().min(1).max(2e3).optional().nullable(),
1754
- expirationDate: z.date().describe("Link expiration time and date.").optional().nullable()
1778
+ expirationDate: /* @__PURE__ */ z.date().describe("Link expiration time and date.").optional().nullable()
1755
1779
  }).describe(
1756
1780
  "Digital file identifier, relevant only for items with type DIGITAL."
1757
1781
  ).optional(),
1758
- subscriptionInfo: z.object({
1759
- _id: z.string().describe("Subscription ID.").regex(
1782
+ subscriptionInfo: /* @__PURE__ */ z.object({
1783
+ _id: /* @__PURE__ */ z.string().describe("Subscription ID.").regex(
1760
1784
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1761
1785
  "Must be a valid GUID"
1762
1786
  ).optional().nullable(),
1763
- cycleNumber: z.number().int().describe(
1787
+ cycleNumber: /* @__PURE__ */ z.number().int().describe(
1764
1788
  "Subscription cycle. For example, if this order is for the 3rd cycle of a subscription, value will be `3`."
1765
1789
  ).min(0).optional(),
1766
- subscriptionOptionTitle: z.string().describe(
1790
+ subscriptionOptionTitle: /* @__PURE__ */ z.string().describe(
1767
1791
  'Subscription option title. For example, `"Monthly coffee Subscription"`.'
1768
1792
  ).min(0).max(150).optional(),
1769
- subscriptionOptionDescription: z.string().describe(
1793
+ subscriptionOptionDescription: /* @__PURE__ */ z.string().describe(
1770
1794
  'Subscription option description. For example, `"1kg of selected coffee, once a month"`.'
1771
1795
  ).max(500).optional().nullable(),
1772
- subscriptionSettings: z.object({
1773
- frequency: z.enum(["UNDEFINED", "DAY", "WEEK", "MONTH", "YEAR"]).describe("Frequency of recurring payment.").optional(),
1774
- interval: z.number().int().describe(
1796
+ subscriptionSettings: /* @__PURE__ */ z.object({
1797
+ frequency: /* @__PURE__ */ z.enum(["UNDEFINED", "DAY", "WEEK", "MONTH", "YEAR"]).describe("Frequency of recurring payment.").optional(),
1798
+ interval: /* @__PURE__ */ z.number().int().describe(
1775
1799
  "Number of frequency units in a billing cycle. For example, frequency `MONTH` with interval `3` means billing every 3 months."
1776
1800
  ).min(1).max(3650).optional().nullable(),
1777
- autoRenewal: z.boolean().describe(
1801
+ autoRenewal: /* @__PURE__ */ z.boolean().describe(
1778
1802
  "Whether subscription is renewed automatically at the end of each period."
1779
1803
  ).optional(),
1780
- billingCycles: z.number().int().describe(
1804
+ billingCycles: /* @__PURE__ */ z.number().int().describe(
1781
1805
  "Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`."
1782
1806
  ).min(1).optional().nullable(),
1783
- enableCustomerCancellation: z.boolean().describe(
1807
+ enableCustomerCancellation: /* @__PURE__ */ z.boolean().describe(
1784
1808
  "Whether to allow the customer to cancel the subscription."
1785
1809
  ).optional(),
1786
- freeTrialPeriod: z.object({
1787
- frequency: z.enum(["UNDEFINED", "DAY", "WEEK", "MONTH", "YEAR"]).describe(
1810
+ freeTrialPeriod: /* @__PURE__ */ z.object({
1811
+ frequency: /* @__PURE__ */ z.enum(["UNDEFINED", "DAY", "WEEK", "MONTH", "YEAR"]).describe(
1788
1812
  "Frequency of period. Values: DAY, WEEK, MONTH, YEAR"
1789
1813
  ).optional(),
1790
- interval: z.number().int().describe(
1814
+ interval: /* @__PURE__ */ z.number().int().describe(
1791
1815
  "Number of frequency units in the free trial period. For example, frequency `MONTH` with interval `3` means a 3-month free trial."
1792
1816
  ).min(1).max(3650).optional()
1793
1817
  }).describe(
1794
1818
  "Period until first cycle starts. If None => no free trial"
1795
1819
  ).optional()
1796
1820
  }).describe("Subscription detailed information.").optional(),
1797
- chargesDescription: z.string().describe(
1821
+ chargesDescription: /* @__PURE__ */ z.string().describe(
1798
1822
  "Description of the charges that will be applied for subscription."
1799
1823
  ).max(1e3).optional().nullable()
1800
1824
  }).describe("Subscription info.").optional(),
1801
- priceDescription: z.object({
1802
- original: z.string().describe(
1825
+ priceDescription: /* @__PURE__ */ z.object({
1826
+ original: /* @__PURE__ */ z.string().describe(
1803
1827
  "__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)."
1804
1828
  ).min(1).max(100).optional(),
1805
- translated: z.string().describe(
1829
+ translated: /* @__PURE__ */ z.string().describe(
1806
1830
  "Price description translated into the buyer's language.\n\nDefault: Same as `original`."
1807
1831
  ).min(1).max(100).optional().nullable()
1808
1832
  }).describe(
1809
1833
  'Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67".'
1810
1834
  ).optional(),
1811
- depositAmount: z.object({
1812
- amount: z.string().describe("Amount.").optional(),
1813
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1835
+ depositAmount: /* @__PURE__ */ z.object({
1836
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1837
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1814
1838
  }).describe(
1815
1839
  'Item\'s price amount to be charged during checkout. Relevant for items with a `paymentOption` value of `"DEPOSIT_ONLINE"`.'
1816
1840
  ).optional(),
1817
- locations: z.array(
1818
- z.object({
1819
- _id: z.string().describe("Location id in the associated owner app.").regex(
1841
+ locations: /* @__PURE__ */ z.array(
1842
+ /* @__PURE__ */ z.object({
1843
+ _id: /* @__PURE__ */ z.string().describe("Location id in the associated owner app.").regex(
1820
1844
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1821
1845
  "Must be a valid GUID"
1822
1846
  ).optional(),
1823
- appId: z.string().describe(
1847
+ appId: /* @__PURE__ */ z.string().describe(
1824
1848
  "Location owner app, if not provided then the site business info locations will be used."
1825
1849
  ).regex(
1826
1850
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1827
1851
  "Must be a valid GUID"
1828
1852
  ).optional().nullable(),
1829
- quantity: z.number().int().describe("Quantity for specific location.").min(1).max(1e5).optional(),
1830
- name: z.string().describe("Location name.").max(500).optional().nullable()
1853
+ quantity: /* @__PURE__ */ z.number().int().describe("Quantity for specific location.").min(1).max(1e5).optional(),
1854
+ name: /* @__PURE__ */ z.string().describe("Location name.").max(500).optional().nullable()
1831
1855
  })
1832
1856
  ).min(0).max(5).optional(),
1833
- lineItemPrice: z.object({
1834
- amount: z.string().describe("Amount.").optional(),
1835
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
1857
+ lineItemPrice: /* @__PURE__ */ z.object({
1858
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1859
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
1836
1860
  }).describe(
1837
1861
  "Total price **after** catalog discounts and line item discounts."
1838
1862
  ).optional(),
1839
- taxableAddress: z.intersection(
1840
- z.object({}),
1841
- z.xor([
1842
- z.object({ addressType: z.never().optional() }),
1843
- z.object({
1844
- addressType: z.enum(["BUSINESS", "BILLING", "SHIPPING"]).describe(
1863
+ taxableAddress: /* @__PURE__ */ z.intersection(
1864
+ /* @__PURE__ */ z.object({}),
1865
+ /* @__PURE__ */ z.xor([
1866
+ /* @__PURE__ */ z.object({
1867
+ addressType: /* @__PURE__ */ z.never().optional()
1868
+ }),
1869
+ /* @__PURE__ */ z.object({
1870
+ addressType: /* @__PURE__ */ z.enum(["BUSINESS", "BILLING", "SHIPPING"]).describe(
1845
1871
  "taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly."
1846
1872
  )
1847
1873
  })
1848
1874
  ])
1849
1875
  ).describe("Address used for tax calculation.").optional(),
1850
- priceUndetermined: z.boolean().describe(
1876
+ priceUndetermined: /* @__PURE__ */ z.boolean().describe(
1851
1877
  "Whether the price is not yet defined, and will be updated after the order is created.\n\nDefault: `false`"
1852
1878
  ).optional(),
1853
- fixedQuantity: z.boolean().describe(
1879
+ fixedQuantity: /* @__PURE__ */ z.boolean().describe(
1854
1880
  "Whether the line item quantity is fixed and cannot be changed.\n\nDefault: `false`"
1855
1881
  ).optional(),
1856
- decimalQuantity: z.intersection(
1857
- z.object({
1858
- value: z.string().describe(
1882
+ decimalQuantity: /* @__PURE__ */ z.intersection(
1883
+ /* @__PURE__ */ z.object({
1884
+ value: /* @__PURE__ */ z.string().describe(
1859
1885
  'The decimal quantity the buyer / merchant entered.\n\nString-encoded decimal. The exact value is preserved \u2014 no\nrounding, no conversion to an integer.\n\nExamples: "2.75", "1.5", "0.75".'
1860
1886
  ).optional(),
1861
- description: z.object({
1862
- original: z.string().describe(
1887
+ description: /* @__PURE__ */ z.object({
1888
+ original: /* @__PURE__ */ z.string().describe(
1863
1889
  "__Required.__ String in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n\nMin: 1 character.\nMax: 200 characters."
1864
1890
  ).min(1).max(200).optional(),
1865
- translated: z.string().describe(
1891
+ translated: /* @__PURE__ */ z.string().describe(
1866
1892
  "String translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
1867
1893
  ).min(1).max(400).optional().nullable()
1868
1894
  }).describe(
1869
1895
  'Human-readable, pre-formatted display string for the quantity. For example, "2.75 square meters of fake grass".\nAlways set alongside `value`; use this directly for display rather than composing your own string from `value` and `unit`.'
1870
1896
  ).optional()
1871
1897
  }),
1872
- z.xor([
1873
- z.object({
1874
- measurementUnit: z.never().optional(),
1875
- otherUnit: z.never().optional()
1898
+ /* @__PURE__ */ z.xor([
1899
+ /* @__PURE__ */ z.object({
1900
+ measurementUnit: /* @__PURE__ */ z.never().optional(),
1901
+ otherUnit: /* @__PURE__ */ z.never().optional()
1876
1902
  }),
1877
- z.object({
1878
- otherUnit: z.never().optional(),
1879
- measurementUnit: z.enum([
1903
+ /* @__PURE__ */ z.object({
1904
+ otherUnit: /* @__PURE__ */ z.never().optional(),
1905
+ measurementUnit: /* @__PURE__ */ z.enum([
1880
1906
  "UNSPECIFIED",
1881
1907
  "ML",
1882
1908
  "CL",
@@ -1903,9 +1929,9 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
1903
1929
  "Unit the value is expressed in, selected from the standard `measurementUnit` enum."
1904
1930
  )
1905
1931
  }),
1906
- z.object({
1907
- measurementUnit: z.never().optional(),
1908
- otherUnit: z.string().describe(
1932
+ /* @__PURE__ */ z.object({
1933
+ measurementUnit: /* @__PURE__ */ z.never().optional(),
1934
+ otherUnit: /* @__PURE__ */ z.string().describe(
1909
1935
  'Free-form unit name for standard units not in the\n`measurementUnit` enum (e.g. "hour", "minute", "session").'
1910
1936
  ).min(1).max(50)
1911
1937
  })
@@ -1913,47 +1939,53 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
1913
1939
  ).describe(
1914
1940
  "Decimal-quantity metadata. Set when the line represents a\nnon-integer purchase (e.g. 2.75 m\xB2 of fake grass).\n\nWhen set, the line item must have `fixedQuantity` = true and be set with `quantity` = 1.\nThe decimal value lives in `decimalQuantity.value`."
1915
1941
  ).optional(),
1916
- extendedFields: z.object({
1917
- namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
1942
+ extendedFields: /* @__PURE__ */ z.object({
1943
+ namespaces: /* @__PURE__ */ z.record(
1944
+ /* @__PURE__ */ z.string(),
1945
+ /* @__PURE__ */ z.record(
1946
+ /* @__PURE__ */ z.string(),
1947
+ /* @__PURE__ */ z.any()
1948
+ )
1949
+ ).describe(
1918
1950
  "Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\nThe value of each key is structured according to the schema defined when the extended fields were configured.\n\nYou can only access fields for which you have the appropriate permissions.\n\nLearn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields)."
1919
1951
  ).optional()
1920
1952
  }).describe(
1921
1953
  "Custom extended fields for the line item object.\n\n[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."
1922
1954
  ).optional(),
1923
- modifierGroups: z.array(
1924
- z.object({
1925
- _id: z.string().describe("Modifier group ID.").min(1).max(36).optional(),
1926
- name: z.object({
1927
- original: z.string().describe(
1955
+ modifierGroups: /* @__PURE__ */ z.array(
1956
+ /* @__PURE__ */ z.object({
1957
+ _id: /* @__PURE__ */ z.string().describe("Modifier group ID.").min(1).max(36).optional(),
1958
+ name: /* @__PURE__ */ z.object({
1959
+ original: /* @__PURE__ */ z.string().describe(
1928
1960
  "__Required.__ String in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n\nMin: 1 character.\nMax: 200 characters."
1929
1961
  ).min(1).max(200).optional(),
1930
- translated: z.string().describe(
1962
+ translated: /* @__PURE__ */ z.string().describe(
1931
1963
  "String translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
1932
1964
  ).min(1).max(400).optional().nullable()
1933
1965
  }).describe("Modifier group name.").optional(),
1934
- modifiers: z.array(
1935
- z.object({
1936
- _id: z.string().describe("Modifier ID.").min(1).max(36).optional(),
1937
- quantity: z.number().int().describe("The quantity of this modifier.").min(1).max(1e5).optional().nullable(),
1938
- label: z.object({
1939
- original: z.string().describe(
1966
+ modifiers: /* @__PURE__ */ z.array(
1967
+ /* @__PURE__ */ z.object({
1968
+ _id: /* @__PURE__ */ z.string().describe("Modifier ID.").min(1).max(36).optional(),
1969
+ quantity: /* @__PURE__ */ z.number().int().describe("The quantity of this modifier.").min(1).max(1e5).optional().nullable(),
1970
+ label: /* @__PURE__ */ z.object({
1971
+ original: /* @__PURE__ */ z.string().describe(
1940
1972
  "__Required.__ String in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n\nMin: 1 character.\nMax: 200 characters."
1941
1973
  ).min(1).max(200).optional(),
1942
- translated: z.string().describe(
1974
+ translated: /* @__PURE__ */ z.string().describe(
1943
1975
  "String translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
1944
1976
  ).min(1).max(400).optional().nullable()
1945
1977
  }).describe("Primary display label for the modifier.").optional(),
1946
- details: z.object({
1947
- original: z.string().describe(
1978
+ details: /* @__PURE__ */ z.object({
1979
+ original: /* @__PURE__ */ z.string().describe(
1948
1980
  "__Required.__ String in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n\nMin: 1 character.\nMax: 200 characters."
1949
1981
  ).min(1).max(200).optional(),
1950
- translated: z.string().describe(
1982
+ translated: /* @__PURE__ */ z.string().describe(
1951
1983
  "String translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
1952
1984
  ).min(1).max(400).optional().nullable()
1953
1985
  }).describe("Additional details.").optional(),
1954
- price: z.object({
1955
- amount: z.string().describe("Amount.").optional(),
1956
- formattedAmount: z.string().describe(
1986
+ price: /* @__PURE__ */ z.object({
1987
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
1988
+ formattedAmount: /* @__PURE__ */ z.string().describe(
1957
1989
  "Amount formatted with currency symbol."
1958
1990
  ).optional()
1959
1991
  }).describe("The price of the modifier.").optional()
@@ -1963,33 +1995,33 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
1963
1995
  ).max(10).optional()
1964
1996
  })
1965
1997
  ).min(1).max(100).optional(),
1966
- buyerInfo: z.intersection(
1967
- z.object({
1968
- contactId: z.string().describe(
1998
+ buyerInfo: /* @__PURE__ */ z.intersection(
1999
+ /* @__PURE__ */ z.object({
2000
+ contactId: /* @__PURE__ */ z.string().describe(
1969
2001
  "Contact ID. Automatically created if one doesn't exist. For more information, see [Contacts API](https://dev.wix.com/docs/api-reference/crm/members-contacts/contacts/contacts/contact-v4/introduction)."
1970
2002
  ).regex(
1971
2003
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1972
2004
  "Must be a valid GUID"
1973
2005
  ).optional().nullable(),
1974
- email: z.string().describe("Buyer's email address.").email().optional().nullable()
2006
+ email: /* @__PURE__ */ z.string().describe("Buyer's email address.").email().optional().nullable()
1975
2007
  }),
1976
- z.xor([
1977
- z.object({
1978
- visitorId: z.never().optional(),
1979
- memberId: z.never().optional()
2008
+ /* @__PURE__ */ z.xor([
2009
+ /* @__PURE__ */ z.object({
2010
+ visitorId: /* @__PURE__ */ z.never().optional(),
2011
+ memberId: /* @__PURE__ */ z.never().optional()
1980
2012
  }),
1981
- z.object({
1982
- memberId: z.never().optional(),
1983
- visitorId: z.string().describe(
2013
+ /* @__PURE__ */ z.object({
2014
+ memberId: /* @__PURE__ */ z.never().optional(),
2015
+ visitorId: /* @__PURE__ */ z.string().describe(
1984
2016
  "Visitor ID. Returned when the buyer isn't a logged-in site member."
1985
2017
  ).regex(
1986
2018
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
1987
2019
  "Must be a valid GUID"
1988
2020
  )
1989
2021
  }),
1990
- z.object({
1991
- visitorId: z.never().optional(),
1992
- memberId: z.string().describe(
2022
+ /* @__PURE__ */ z.object({
2023
+ visitorId: /* @__PURE__ */ z.never().optional(),
2024
+ memberId: /* @__PURE__ */ z.string().describe(
1993
2025
  "Member ID. Returned when the buyer is a logged-in site member."
1994
2026
  ).regex(
1995
2027
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
@@ -1998,95 +2030,95 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
1998
2030
  })
1999
2031
  ])
2000
2032
  ).describe("Buyer information.").optional(),
2001
- buyerLanguage: z.string().describe(
2033
+ buyerLanguage: /* @__PURE__ */ z.string().describe(
2002
2034
  "Language for communication with the buyer. Defaults to the site language.\nFor a site that supports multiple languages, this is the language the buyer selected."
2003
2035
  ).max(10).optional().nullable(),
2004
- weightUnit: z.enum(["UNSPECIFIED_WEIGHT_UNIT", "KG", "LB"]).describe("Weight measurement unit - defaults to site's weight unit.").optional(),
2005
- currency: z.string().describe(
2036
+ weightUnit: /* @__PURE__ */ z.enum(["UNSPECIFIED_WEIGHT_UNIT", "KG", "LB"]).describe("Weight measurement unit - defaults to site's weight unit.").optional(),
2037
+ currency: /* @__PURE__ */ z.string().describe(
2006
2038
  "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."
2007
2039
  ).optional().nullable(),
2008
- currencyConversionDetails: z.object({
2009
- originalCurrency: z.string().describe(
2040
+ currencyConversionDetails: /* @__PURE__ */ z.object({
2041
+ originalCurrency: /* @__PURE__ */ z.string().describe(
2010
2042
  "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.\n\nThis currency is used to calculate the pricing before conversion to the buyer's payment currency."
2011
2043
  ).optional().nullable(),
2012
- conversionRate: z.string().describe(
2044
+ conversionRate: /* @__PURE__ */ z.string().describe(
2013
2045
  "The rate used for converting the original currency to the currency used for payment.\n\nReturned only when a single rate produced every amount on the order.\nThis is the case for an order converted once at checkout."
2014
2046
  ).optional().nullable()
2015
2047
  }).describe(
2016
2048
  "Multi-currency information of the subscription. conversionRate may reflect updated exchange rate on created order per recurring cycle."
2017
2049
  ).optional(),
2018
- taxIncludedInPrices: z.boolean().describe(
2050
+ taxIncludedInPrices: /* @__PURE__ */ z.boolean().describe(
2019
2051
  "Whether tax is included in line item prices.\n\nDefault: `false`"
2020
2052
  ).optional(),
2021
- priceSummary: z.object({
2022
- subtotal: z.object({
2023
- amount: z.string().describe("Amount.").optional(),
2024
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2053
+ priceSummary: /* @__PURE__ */ z.object({
2054
+ subtotal: /* @__PURE__ */ z.object({
2055
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2056
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2025
2057
  }).describe(
2026
2058
  "Subtotal of all line items, before discounts and before tax."
2027
2059
  ).optional(),
2028
- shipping: z.object({
2029
- amount: z.string().describe("Amount.").optional(),
2030
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2060
+ shipping: /* @__PURE__ */ z.object({
2061
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2062
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2031
2063
  }).describe(
2032
2064
  "Total shipping price, before discounts and before tax."
2033
2065
  ).optional(),
2034
- tax: z.object({
2035
- amount: z.string().describe("Amount.").optional(),
2036
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2066
+ tax: /* @__PURE__ */ z.object({
2067
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2068
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2037
2069
  }).describe("Total tax applied to the order.").optional(),
2038
- discount: z.object({
2039
- amount: z.string().describe("Amount.").optional(),
2040
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2070
+ discount: /* @__PURE__ */ z.object({
2071
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2072
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2041
2073
  }).describe("Total discount amount applied to the order.").optional(),
2042
- total: z.object({
2043
- amount: z.string().describe("Amount.").optional(),
2044
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2074
+ total: /* @__PURE__ */ z.object({
2075
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2076
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2045
2077
  }).describe("Order's total price after discounts and tax.").optional(),
2046
- totalAdditionalFees: z.object({
2047
- amount: z.string().describe("Amount.").optional(),
2048
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2078
+ totalAdditionalFees: /* @__PURE__ */ z.object({
2079
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2080
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2049
2081
  }).describe("Total additional fees before tax.").optional()
2050
2082
  }).describe("Order price summary.").optional(),
2051
- platformFeeSummary: z.object({
2052
- total: z.object({
2053
- amount: z.string().describe("Amount.").optional(),
2054
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2083
+ platformFeeSummary: /* @__PURE__ */ z.object({
2084
+ total: /* @__PURE__ */ z.object({
2085
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2086
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2055
2087
  }).describe("Total sum of all platform fees.").optional(),
2056
- totalPassOn: z.object({
2057
- amount: z.string().describe("Amount.").optional(),
2058
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2088
+ totalPassOn: /* @__PURE__ */ z.object({
2089
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2090
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2059
2091
  }).describe(
2060
2092
  "Total amount of platform fees with `PASS_ON` charge type."
2061
2093
  ).optional(),
2062
- totalAbsorbed: z.object({
2063
- amount: z.string().describe("Amount.").optional(),
2064
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2094
+ totalAbsorbed: /* @__PURE__ */ z.object({
2095
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2096
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2065
2097
  }).describe(
2066
2098
  "Total amount of platform fees with `ABSORBED` charge type."
2067
2099
  ).optional(),
2068
- fees: z.array(
2069
- z.object({
2070
- name: z.object({
2071
- original: z.string().describe(
2100
+ fees: /* @__PURE__ */ z.array(
2101
+ /* @__PURE__ */ z.object({
2102
+ name: /* @__PURE__ */ z.object({
2103
+ original: /* @__PURE__ */ z.string().describe(
2072
2104
  "__Required.__ String in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope).\n\nMin: 1 character.\nMax: 200 characters."
2073
2105
  ).min(1).max(200).optional(),
2074
- translated: z.string().describe(
2106
+ translated: /* @__PURE__ */ z.string().describe(
2075
2107
  "String translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
2076
2108
  ).min(1).max(400).optional().nullable()
2077
2109
  }).describe("Platform fee name.").optional(),
2078
- amount: z.object({
2079
- amount: z.string().describe("Amount.").optional(),
2080
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2110
+ amount: /* @__PURE__ */ z.object({
2111
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2112
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2081
2113
  }).describe("Platform fee amount.").optional(),
2082
- lineItemId: z.string().describe(
2114
+ lineItemId: /* @__PURE__ */ z.string().describe(
2083
2115
  "ID of the line item the platform fee applies to."
2084
2116
  ).regex(
2085
2117
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2086
2118
  "Must be a valid GUID"
2087
2119
  ).optional(),
2088
- chargeType: z.enum(["PASS_ON", "ABSORBED"]).describe("Platform fee charge type.").optional(),
2089
- percentageRate: z.string().describe(
2120
+ chargeType: /* @__PURE__ */ z.enum(["PASS_ON", "ABSORBED"]).describe("Platform fee charge type.").optional(),
2121
+ percentageRate: /* @__PURE__ */ z.string().describe(
2090
2122
  "Percentage rate charged as platform fee.\nThe fee rate percentage expressed as a decimal fraction between 0 and 1. For example, `0.05` for 5%."
2091
2123
  ).optional()
2092
2124
  })
@@ -2094,26 +2126,26 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2094
2126
  }).describe(
2095
2127
  "Summary of platform fees for this subscription contract, including totals by charge type and a breakdown of individual fees."
2096
2128
  ).optional(),
2097
- billingInfo: z.object({
2098
- address: z.object({
2099
- streetAddress: z.object({
2100
- name: z.string().optional(),
2101
- number: z.string().optional()
2129
+ billingInfo: /* @__PURE__ */ z.object({
2130
+ address: /* @__PURE__ */ z.object({
2131
+ streetAddress: /* @__PURE__ */ z.object({
2132
+ name: /* @__PURE__ */ z.string().optional(),
2133
+ number: /* @__PURE__ */ z.string().optional()
2102
2134
  }).optional(),
2103
- city: z.string().optional().nullable(),
2104
- subdivision: z.string().optional().nullable(),
2105
- country: z.string().optional().nullable(),
2106
- postalCode: z.string().optional().nullable(),
2107
- addressLine2: z.string().optional().nullable()
2135
+ city: /* @__PURE__ */ z.string().optional().nullable(),
2136
+ subdivision: /* @__PURE__ */ z.string().optional().nullable(),
2137
+ country: /* @__PURE__ */ z.string().optional().nullable(),
2138
+ postalCode: /* @__PURE__ */ z.string().optional().nullable(),
2139
+ addressLine2: /* @__PURE__ */ z.string().optional().nullable()
2108
2140
  }).describe("Address.").optional(),
2109
- contactDetails: z.object({
2110
- firstName: z.string().describe("First name.").max(100).optional().nullable(),
2111
- lastName: z.string().describe("Last name.").max(100).optional().nullable(),
2112
- phone: z.string().describe("Phone number.").optional().nullable(),
2113
- company: z.string().describe("Company name.").max(1e3).optional().nullable(),
2114
- vatId: z.object({
2115
- _id: z.string().describe("Customer's tax ID.").optional(),
2116
- type: z.enum(["UNSPECIFIED", "CPF", "CNPJ"]).describe(
2141
+ contactDetails: /* @__PURE__ */ z.object({
2142
+ firstName: /* @__PURE__ */ z.string().describe("First name.").max(100).optional().nullable(),
2143
+ lastName: /* @__PURE__ */ z.string().describe("Last name.").max(100).optional().nullable(),
2144
+ phone: /* @__PURE__ */ z.string().describe("Phone number.").optional().nullable(),
2145
+ company: /* @__PURE__ */ z.string().describe("Company name.").max(1e3).optional().nullable(),
2146
+ vatId: /* @__PURE__ */ z.object({
2147
+ _id: /* @__PURE__ */ z.string().describe("Customer's tax ID.").optional(),
2148
+ type: /* @__PURE__ */ z.enum(["UNSPECIFIED", "CPF", "CNPJ"]).describe(
2117
2149
  "Tax type.\n\nSupported values:\n+ `CPF`: for individual tax payers\n+ `CNPJ`: for corporations"
2118
2150
  ).optional()
2119
2151
  }).describe(
@@ -2121,61 +2153,61 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2121
2153
  ).optional()
2122
2154
  }).describe("Contact details.").optional()
2123
2155
  }).describe("Billing address and contact details.").optional(),
2124
- shippingInfo: z.object({
2125
- carrierId: z.string().describe(
2156
+ shippingInfo: /* @__PURE__ */ z.object({
2157
+ carrierId: /* @__PURE__ */ z.string().describe(
2126
2158
  "App Def Id of external provider which was a source of shipping info"
2127
2159
  ).min(1).max(100).optional().nullable(),
2128
- code: z.string().describe(
2160
+ code: /* @__PURE__ */ z.string().describe(
2129
2161
  'Unique code (or ID) of selected shipping option. For example, `"usps_std_overnight"`.'
2130
2162
  ).min(1).max(100).optional().nullable(),
2131
- title: z.string().describe(
2163
+ title: /* @__PURE__ */ z.string().describe(
2132
2164
  'Shipping option title.\nFor example, `"USPS Standard Overnight Delivery"`, `"Standard"` or `"First-Class Package International"`.'
2133
2165
  ).max(250).optional(),
2134
- logistics: z.intersection(
2135
- z.object({
2136
- deliveryTime: z.string().describe(
2166
+ logistics: /* @__PURE__ */ z.intersection(
2167
+ /* @__PURE__ */ z.object({
2168
+ deliveryTime: /* @__PURE__ */ z.string().describe(
2137
2169
  'Expected delivery time in free text. For example, `"3-5 business days"`.'
2138
2170
  ).max(500).optional().nullable(),
2139
- instructions: z.string().describe(
2171
+ instructions: /* @__PURE__ */ z.string().describe(
2140
2172
  'Instructions for the carrier. For example, `"Please knock on the door. If unanswered, please call contact number."`.'
2141
2173
  ).max(1e3).optional().nullable(),
2142
- deliverByDate: z.date().describe(
2174
+ deliverByDate: /* @__PURE__ */ z.date().describe(
2143
2175
  "Deprecated - Latest expected delivery date and time in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format."
2144
2176
  ).optional().nullable(),
2145
- deliveryTimeSlot: z.object({
2146
- from: z.date().describe("Delivery slot starting time.").optional().nullable(),
2147
- to: z.date().describe("Delivery slot ending time.").optional().nullable()
2177
+ deliveryTimeSlot: /* @__PURE__ */ z.object({
2178
+ from: /* @__PURE__ */ z.date().describe("Delivery slot starting time.").optional().nullable(),
2179
+ to: /* @__PURE__ */ z.date().describe("Delivery slot ending time.").optional().nullable()
2148
2180
  }).describe(
2149
2181
  "Expected delivery time slot with start and end times."
2150
2182
  ).optional()
2151
2183
  }),
2152
- z.xor([
2153
- z.object({
2154
- shippingDestination: z.never().optional(),
2155
- pickupDetails: z.never().optional()
2184
+ /* @__PURE__ */ z.xor([
2185
+ /* @__PURE__ */ z.object({
2186
+ shippingDestination: /* @__PURE__ */ z.never().optional(),
2187
+ pickupDetails: /* @__PURE__ */ z.never().optional()
2156
2188
  }),
2157
- z.object({
2158
- pickupDetails: z.never().optional(),
2159
- shippingDestination: z.object({
2160
- address: z.object({
2161
- streetAddress: z.object({
2162
- name: z.string().optional(),
2163
- number: z.string().optional()
2189
+ /* @__PURE__ */ z.object({
2190
+ pickupDetails: /* @__PURE__ */ z.never().optional(),
2191
+ shippingDestination: /* @__PURE__ */ z.object({
2192
+ address: /* @__PURE__ */ z.object({
2193
+ streetAddress: /* @__PURE__ */ z.object({
2194
+ name: /* @__PURE__ */ z.string().optional(),
2195
+ number: /* @__PURE__ */ z.string().optional()
2164
2196
  }).optional(),
2165
- city: z.string().optional().nullable(),
2166
- subdivision: z.string().optional().nullable(),
2167
- country: z.string().optional().nullable(),
2168
- postalCode: z.string().optional().nullable(),
2169
- addressLine2: z.string().optional().nullable()
2197
+ city: /* @__PURE__ */ z.string().optional().nullable(),
2198
+ subdivision: /* @__PURE__ */ z.string().optional().nullable(),
2199
+ country: /* @__PURE__ */ z.string().optional().nullable(),
2200
+ postalCode: /* @__PURE__ */ z.string().optional().nullable(),
2201
+ addressLine2: /* @__PURE__ */ z.string().optional().nullable()
2170
2202
  }).describe("Address.").optional(),
2171
- contactDetails: z.object({
2172
- firstName: z.string().describe("First name.").max(100).optional().nullable(),
2173
- lastName: z.string().describe("Last name.").max(100).optional().nullable(),
2174
- phone: z.string().describe("Phone number.").optional().nullable(),
2175
- company: z.string().describe("Company name.").max(1e3).optional().nullable(),
2176
- vatId: z.object({
2177
- _id: z.string().describe("Customer's tax ID.").optional(),
2178
- type: z.enum(["UNSPECIFIED", "CPF", "CNPJ"]).describe(
2203
+ contactDetails: /* @__PURE__ */ z.object({
2204
+ firstName: /* @__PURE__ */ z.string().describe("First name.").max(100).optional().nullable(),
2205
+ lastName: /* @__PURE__ */ z.string().describe("Last name.").max(100).optional().nullable(),
2206
+ phone: /* @__PURE__ */ z.string().describe("Phone number.").optional().nullable(),
2207
+ company: /* @__PURE__ */ z.string().describe("Company name.").max(1e3).optional().nullable(),
2208
+ vatId: /* @__PURE__ */ z.object({
2209
+ _id: /* @__PURE__ */ z.string().describe("Customer's tax ID.").optional(),
2210
+ type: /* @__PURE__ */ z.enum(["UNSPECIFIED", "CPF", "CNPJ"]).describe(
2179
2211
  "Tax type.\n\nSupported values:\n+ `CPF`: for individual tax payers\n+ `CNPJ`: for corporations"
2180
2212
  ).optional()
2181
2213
  }).describe(
@@ -2186,101 +2218,101 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2186
2218
  "Shipping destination address and contact details. For pickup orders, this contains the pickup location address, not the recipient's address."
2187
2219
  )
2188
2220
  }),
2189
- z.object({
2190
- shippingDestination: z.never().optional(),
2191
- pickupDetails: z.object({
2192
- address: z.object({
2193
- streetAddress: z.object({
2194
- name: z.string().optional(),
2195
- number: z.string().optional()
2221
+ /* @__PURE__ */ z.object({
2222
+ shippingDestination: /* @__PURE__ */ z.never().optional(),
2223
+ pickupDetails: /* @__PURE__ */ z.object({
2224
+ address: /* @__PURE__ */ z.object({
2225
+ streetAddress: /* @__PURE__ */ z.object({
2226
+ name: /* @__PURE__ */ z.string().optional(),
2227
+ number: /* @__PURE__ */ z.string().optional()
2196
2228
  }).optional(),
2197
- city: z.string().optional().nullable(),
2198
- subdivision: z.string().optional().nullable(),
2199
- country: z.string().optional().nullable(),
2200
- postalCode: z.string().optional().nullable(),
2201
- addressLine2: z.string().optional().nullable()
2229
+ city: /* @__PURE__ */ z.string().optional().nullable(),
2230
+ subdivision: /* @__PURE__ */ z.string().optional().nullable(),
2231
+ country: /* @__PURE__ */ z.string().optional().nullable(),
2232
+ postalCode: /* @__PURE__ */ z.string().optional().nullable(),
2233
+ addressLine2: /* @__PURE__ */ z.string().optional().nullable()
2202
2234
  }).describe("Pickup address.").optional(),
2203
- pickupMethod: z.enum(["STORE_PICKUP", "PICKUP_POINT"]).describe("Pickup method").optional()
2235
+ pickupMethod: /* @__PURE__ */ z.enum(["STORE_PICKUP", "PICKUP_POINT"]).describe("Pickup method").optional()
2204
2236
  }).describe(
2205
2237
  "Pickup details for store pickup or pickup point orders."
2206
2238
  )
2207
2239
  })
2208
2240
  ])
2209
2241
  ).describe("Shipping logistics.").optional(),
2210
- cost: z.object({
2211
- price: z.object({
2212
- amount: z.string().describe("Amount.").optional(),
2213
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2242
+ cost: /* @__PURE__ */ z.object({
2243
+ price: /* @__PURE__ */ z.object({
2244
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2245
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2214
2246
  }).describe("Shipping price for display purposes.").optional(),
2215
- totalPriceBeforeTax: z.object({
2216
- amount: z.string().describe("Amount.").optional(),
2217
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2247
+ totalPriceBeforeTax: /* @__PURE__ */ z.object({
2248
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2249
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2218
2250
  }).describe(
2219
2251
  "Total price of shipping after discounts (when relevant), and before tax."
2220
2252
  ).optional(),
2221
- totalPriceAfterTax: z.object({
2222
- amount: z.string().describe("Amount.").optional(),
2223
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2253
+ totalPriceAfterTax: /* @__PURE__ */ z.object({
2254
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2255
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2224
2256
  }).describe(
2225
2257
  "Shipping price after all discounts (if any exist), and after tax."
2226
2258
  ).optional(),
2227
- taxDetails: z.object({
2228
- taxableAmount: z.object({
2229
- amount: z.string().describe("Amount.").optional(),
2230
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2259
+ taxDetails: /* @__PURE__ */ z.object({
2260
+ taxableAmount: /* @__PURE__ */ z.object({
2261
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2262
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2231
2263
  }).describe("Taxable amount of this line item.").optional(),
2232
- taxRate: z.string().describe(
2264
+ taxRate: /* @__PURE__ */ z.string().describe(
2233
2265
  'Tax rate percentage, as a decimal numeral between 0 and 1. For example, `"0.13"`.'
2234
2266
  ).optional(),
2235
- totalTax: z.object({
2236
- amount: z.string().describe("Amount.").optional(),
2237
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2267
+ totalTax: /* @__PURE__ */ z.object({
2268
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2269
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2238
2270
  }).describe(
2239
2271
  "The calculated tax, based on the `taxableAmount` and `taxRate`."
2240
2272
  ).optional()
2241
2273
  }).describe("Tax details.").optional(),
2242
- taxInfo: z.object({
2243
- taxAmount: z.object({
2244
- amount: z.string().describe("Amount.").optional(),
2245
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2274
+ taxInfo: /* @__PURE__ */ z.object({
2275
+ taxAmount: /* @__PURE__ */ z.object({
2276
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2277
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2246
2278
  }).describe(
2247
2279
  "Calculated tax, based on `taxable_amount` and `tax_rate`."
2248
2280
  ).optional(),
2249
- taxableAmount: z.object({
2250
- amount: z.string().describe("Amount.").optional(),
2251
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2281
+ taxableAmount: /* @__PURE__ */ z.object({
2282
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2283
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2252
2284
  }).describe("Amount for which tax is calculated.").optional(),
2253
- taxRate: z.string().describe("Tax rate %, as a decimal point.").optional().nullable(),
2254
- taxGroupId: z.string().describe("Tax group ID.").regex(
2285
+ taxRate: /* @__PURE__ */ z.string().describe("Tax rate %, as a decimal point.").optional().nullable(),
2286
+ taxGroupId: /* @__PURE__ */ z.string().describe("Tax group ID.").regex(
2255
2287
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2256
2288
  "Must be a valid GUID"
2257
2289
  ).optional().nullable(),
2258
- taxIncludedInPrice: z.boolean().describe(
2290
+ taxIncludedInPrice: /* @__PURE__ */ z.boolean().describe(
2259
2291
  "Indicates whether the price already includes tax."
2260
2292
  ).optional(),
2261
- taxBreakdown: z.array(
2262
- z.object({
2263
- jurisdiction: z.string().describe(
2293
+ taxBreakdown: /* @__PURE__ */ z.array(
2294
+ /* @__PURE__ */ z.object({
2295
+ jurisdiction: /* @__PURE__ */ z.string().describe(
2264
2296
  'Jurisdiction that taxes were calculated for. For example, "New York", or "Quebec".'
2265
2297
  ).max(200).optional().nullable(),
2266
- rate: z.string().describe(
2298
+ rate: /* @__PURE__ */ z.string().describe(
2267
2299
  "Tax rate used for this jurisdiction, as a decimal. For example, 10% tax is 0.1000."
2268
2300
  ).optional().nullable(),
2269
- taxAmount: z.object({
2270
- amount: z.string().describe("Amount.").optional(),
2271
- formattedAmount: z.string().describe(
2301
+ taxAmount: /* @__PURE__ */ z.object({
2302
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2303
+ formattedAmount: /* @__PURE__ */ z.string().describe(
2272
2304
  "Amount formatted with currency symbol."
2273
2305
  ).optional()
2274
2306
  }).describe(
2275
2307
  "Amount of tax calculated for this line item."
2276
2308
  ).optional(),
2277
- taxType: z.string().describe(
2309
+ taxType: /* @__PURE__ */ z.string().describe(
2278
2310
  `The type of tax that was calculated. Depends on the jurisdiction's tax laws. For example, "Sales Tax", "Income Tax", "Value Added Tax", etc.`
2279
2311
  ).max(200).optional().nullable(),
2280
- taxName: z.string().describe(
2312
+ taxName: /* @__PURE__ */ z.string().describe(
2281
2313
  'The name of the tax against which this tax amount was calculated. For example, "NY State Sales Tax", "Quebec GST", etc.\nThis name should be explicit enough to allow the merchant to understand what tax was calculated.'
2282
2314
  ).max(200).optional().nullable(),
2283
- jurisdictionType: z.enum([
2315
+ jurisdictionType: /* @__PURE__ */ z.enum([
2284
2316
  "UNDEFINED",
2285
2317
  "COUNTRY",
2286
2318
  "STATE",
@@ -2290,17 +2322,17 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2290
2322
  ]).describe(
2291
2323
  "Type of jurisdiction that taxes were calculated for."
2292
2324
  ).optional(),
2293
- nonTaxableAmount: z.object({
2294
- amount: z.string().describe("Amount.").optional(),
2295
- formattedAmount: z.string().describe(
2325
+ nonTaxableAmount: /* @__PURE__ */ z.object({
2326
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2327
+ formattedAmount: /* @__PURE__ */ z.string().describe(
2296
2328
  "Amount formatted with currency symbol."
2297
2329
  ).optional()
2298
2330
  }).describe(
2299
2331
  "Non-taxable amount of the line item price."
2300
2332
  ).optional(),
2301
- taxableAmount: z.object({
2302
- amount: z.string().describe("Amount.").optional(),
2303
- formattedAmount: z.string().describe(
2333
+ taxableAmount: /* @__PURE__ */ z.object({
2334
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2335
+ formattedAmount: /* @__PURE__ */ z.string().describe(
2304
2336
  "Amount formatted with currency symbol."
2305
2337
  ).optional()
2306
2338
  }).describe("Taxable amount of the line item price.").optional()
@@ -2309,111 +2341,111 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2309
2341
  }).describe(
2310
2342
  "Represents all the relevant tax details for a shipping."
2311
2343
  ).optional(),
2312
- discount: z.object({
2313
- amount: z.string().describe("Amount.").optional(),
2314
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2344
+ discount: /* @__PURE__ */ z.object({
2345
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2346
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2315
2347
  }).describe("Shipping discount before tax.").optional()
2316
2348
  }).describe("Shipping costs.").optional(),
2317
- region: z.object({
2318
- name: z.string().describe(
2349
+ region: /* @__PURE__ */ z.object({
2350
+ name: /* @__PURE__ */ z.string().describe(
2319
2351
  'Name of shipping region. For example, `"Metropolitan London"`, or `"Outer Melbourne suburbs"`.'
2320
2352
  ).max(100).optional().nullable()
2321
2353
  }).describe("Shipping region.").optional()
2322
2354
  }).describe("Shipping info and selected shipping option details.").optional(),
2323
- appliedDiscounts: z.array(
2324
- z.intersection(
2325
- z.object({
2326
- discountType: z.enum(["GLOBAL", "SPECIFIC_ITEMS", "SHIPPING"]).optional(),
2327
- lineItemIds: z.array(z.string()).min(0).max(300).optional(),
2328
- _id: z.string().describe("Discount ID.").regex(
2355
+ appliedDiscounts: /* @__PURE__ */ z.array(
2356
+ /* @__PURE__ */ z.intersection(
2357
+ /* @__PURE__ */ z.object({
2358
+ discountType: /* @__PURE__ */ z.enum(["GLOBAL", "SPECIFIC_ITEMS", "SHIPPING"]).optional(),
2359
+ lineItemIds: /* @__PURE__ */ z.array(/* @__PURE__ */ z.string()).min(0).max(300).optional(),
2360
+ _id: /* @__PURE__ */ z.string().describe("Discount ID.").regex(
2329
2361
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2330
2362
  "Must be a valid GUID"
2331
2363
  ).optional().nullable(),
2332
- lineItemDiscounts: z.array(
2333
- z.object({
2334
- _id: z.string().describe("Line item ID.").regex(
2364
+ lineItemDiscounts: /* @__PURE__ */ z.array(
2365
+ /* @__PURE__ */ z.object({
2366
+ _id: /* @__PURE__ */ z.string().describe("Line item ID.").regex(
2335
2367
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2336
2368
  "Must be a valid GUID"
2337
2369
  ).optional(),
2338
- totalDiscount: z.object({
2339
- amount: z.string().describe("Amount.").optional(),
2340
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2370
+ totalDiscount: /* @__PURE__ */ z.object({
2371
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2372
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2341
2373
  }).describe("Total discount amount for this line item.").optional()
2342
2374
  })
2343
2375
  ).max(300).optional()
2344
2376
  }),
2345
- z.xor([
2346
- z.object({
2347
- coupon: z.never().optional(),
2348
- merchantDiscount: z.never().optional(),
2349
- discountRule: z.never().optional()
2377
+ /* @__PURE__ */ z.xor([
2378
+ /* @__PURE__ */ z.object({
2379
+ coupon: /* @__PURE__ */ z.never().optional(),
2380
+ merchantDiscount: /* @__PURE__ */ z.never().optional(),
2381
+ discountRule: /* @__PURE__ */ z.never().optional()
2350
2382
  }),
2351
- z.object({
2352
- merchantDiscount: z.never().optional(),
2353
- discountRule: z.never().optional(),
2354
- coupon: z.object({
2355
- _id: z.string().describe("Coupon ID.").optional(),
2356
- code: z.string().describe("Coupon code.").optional(),
2357
- name: z.string().describe("Coupon name.").optional(),
2358
- amount: z.object({
2359
- amount: z.string().describe("Amount.").optional(),
2360
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2383
+ /* @__PURE__ */ z.object({
2384
+ merchantDiscount: /* @__PURE__ */ z.never().optional(),
2385
+ discountRule: /* @__PURE__ */ z.never().optional(),
2386
+ coupon: /* @__PURE__ */ z.object({
2387
+ _id: /* @__PURE__ */ z.string().describe("Coupon ID.").optional(),
2388
+ code: /* @__PURE__ */ z.string().describe("Coupon code.").optional(),
2389
+ name: /* @__PURE__ */ z.string().describe("Coupon name.").optional(),
2390
+ amount: /* @__PURE__ */ z.object({
2391
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2392
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2361
2393
  }).describe("Coupon value.").optional()
2362
2394
  }).describe("Coupon applied by the customer.")
2363
2395
  }),
2364
- z.object({
2365
- coupon: z.never().optional(),
2366
- discountRule: z.never().optional(),
2367
- merchantDiscount: z.intersection(
2368
- z.object({
2369
- amount: z.object({
2370
- amount: z.string().describe("Amount.").optional(),
2371
- formattedAmount: z.string().describe(
2396
+ /* @__PURE__ */ z.object({
2397
+ coupon: /* @__PURE__ */ z.never().optional(),
2398
+ discountRule: /* @__PURE__ */ z.never().optional(),
2399
+ merchantDiscount: /* @__PURE__ */ z.intersection(
2400
+ /* @__PURE__ */ z.object({
2401
+ amount: /* @__PURE__ */ z.object({
2402
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2403
+ formattedAmount: /* @__PURE__ */ z.string().describe(
2372
2404
  "Amount formatted with currency symbol."
2373
2405
  ).optional()
2374
2406
  }).describe("Discount amount.").optional()
2375
2407
  }),
2376
- z.xor([
2377
- z.object({
2378
- discountReason: z.never().optional(),
2379
- description: z.never().optional()
2408
+ /* @__PURE__ */ z.xor([
2409
+ /* @__PURE__ */ z.object({
2410
+ discountReason: /* @__PURE__ */ z.never().optional(),
2411
+ description: /* @__PURE__ */ z.never().optional()
2380
2412
  }),
2381
- z.object({
2382
- description: z.never().optional(),
2383
- discountReason: z.enum([
2413
+ /* @__PURE__ */ z.object({
2414
+ description: /* @__PURE__ */ z.never().optional(),
2415
+ discountReason: /* @__PURE__ */ z.enum([
2384
2416
  "UNSPECIFIED",
2385
2417
  "EXCHANGED_ITEMS",
2386
2418
  "BILLING_ADJUSTMENT"
2387
2419
  ]).describe("Predefined discount reason.")
2388
2420
  }),
2389
- z.object({
2390
- discountReason: z.never().optional(),
2391
- description: z.string().describe(
2421
+ /* @__PURE__ */ z.object({
2422
+ discountReason: /* @__PURE__ */ z.never().optional(),
2423
+ description: /* @__PURE__ */ z.string().describe(
2392
2424
  "Custom discount description as free text."
2393
2425
  ).max(200)
2394
2426
  })
2395
2427
  ])
2396
2428
  ).describe("Discount applied manually by the merchant.")
2397
2429
  }),
2398
- z.object({
2399
- coupon: z.never().optional(),
2400
- merchantDiscount: z.never().optional(),
2401
- discountRule: z.object({
2402
- _id: z.string().describe("Discount rule ID").regex(
2430
+ /* @__PURE__ */ z.object({
2431
+ coupon: /* @__PURE__ */ z.never().optional(),
2432
+ merchantDiscount: /* @__PURE__ */ z.never().optional(),
2433
+ discountRule: /* @__PURE__ */ z.object({
2434
+ _id: /* @__PURE__ */ z.string().describe("Discount rule ID").regex(
2403
2435
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2404
2436
  "Must be a valid GUID"
2405
2437
  ).optional(),
2406
- name: z.object({
2407
- original: z.string().describe(
2438
+ name: /* @__PURE__ */ z.object({
2439
+ original: /* @__PURE__ */ z.string().describe(
2408
2440
  "Original discount rule name (in site's default language)."
2409
2441
  ).min(1).max(256).optional(),
2410
- translated: z.string().describe(
2442
+ translated: /* @__PURE__ */ z.string().describe(
2411
2443
  "Translated discount rule name according to buyer language. Defaults to `original` when not provided."
2412
2444
  ).min(1).max(500).optional().nullable()
2413
2445
  }).describe("Discount rule name").optional(),
2414
- amount: z.object({
2415
- amount: z.string().describe("Amount.").optional(),
2416
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2446
+ amount: /* @__PURE__ */ z.object({
2447
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2448
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2417
2449
  }).describe("Discount value.").optional()
2418
2450
  }).describe(
2419
2451
  "Automatic discount applied by the system based on configured discount rules."
@@ -2422,8 +2454,8 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2422
2454
  ])
2423
2455
  )
2424
2456
  ).max(100).optional(),
2425
- channelInfo: z.object({
2426
- type: z.enum([
2457
+ channelInfo: /* @__PURE__ */ z.object({
2458
+ type: /* @__PURE__ */ z.enum([
2427
2459
  "UNSPECIFIED",
2428
2460
  "WEB",
2429
2461
  "POS",
@@ -2445,42 +2477,42 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2445
2477
  ]).describe(
2446
2478
  "Sales channel that submitted the order.\n\nWhen creating an order via the API to record an external order, use the channel type that matches the original source. If no matching type exists, use `OTHER_PLATFORM`."
2447
2479
  ).optional(),
2448
- externalOrderId: z.string().describe(
2480
+ externalOrderId: /* @__PURE__ */ z.string().describe(
2449
2481
  "Reference to an order ID from an external system. Relevant when recording orders from external platforms."
2450
2482
  ).max(100).optional().nullable(),
2451
- externalOrderUrl: z.string().describe(
2483
+ externalOrderUrl: /* @__PURE__ */ z.string().describe(
2452
2484
  "URL to the order in the external system. Relevant when recording orders from external platforms."
2453
2485
  ).max(300).optional().nullable()
2454
2486
  }).describe(
2455
2487
  "Information about the sales channel that submitted this order."
2456
2488
  ).optional(),
2457
- customFields: z.array(
2458
- z.object({
2459
- value: z.any().describe("Custom field value.").optional().nullable(),
2460
- title: z.string().describe("Custom field title.").min(1).max(500).optional(),
2461
- translatedTitle: z.string().describe("Translated custom field title.").min(1).max(500).optional().nullable()
2489
+ customFields: /* @__PURE__ */ z.array(
2490
+ /* @__PURE__ */ z.object({
2491
+ value: /* @__PURE__ */ z.any().describe("Custom field value.").optional().nullable(),
2492
+ title: /* @__PURE__ */ z.string().describe("Custom field title.").min(1).max(500).optional(),
2493
+ translatedTitle: /* @__PURE__ */ z.string().describe("Translated custom field title.").min(1).max(500).optional().nullable()
2462
2494
  })
2463
2495
  ).max(100).optional(),
2464
- recipientInfo: z.object({
2465
- address: z.object({
2466
- streetAddress: z.object({
2467
- name: z.string().optional(),
2468
- number: z.string().optional()
2496
+ recipientInfo: /* @__PURE__ */ z.object({
2497
+ address: /* @__PURE__ */ z.object({
2498
+ streetAddress: /* @__PURE__ */ z.object({
2499
+ name: /* @__PURE__ */ z.string().optional(),
2500
+ number: /* @__PURE__ */ z.string().optional()
2469
2501
  }).optional(),
2470
- city: z.string().optional().nullable(),
2471
- subdivision: z.string().optional().nullable(),
2472
- country: z.string().optional().nullable(),
2473
- postalCode: z.string().optional().nullable(),
2474
- addressLine2: z.string().optional().nullable()
2502
+ city: /* @__PURE__ */ z.string().optional().nullable(),
2503
+ subdivision: /* @__PURE__ */ z.string().optional().nullable(),
2504
+ country: /* @__PURE__ */ z.string().optional().nullable(),
2505
+ postalCode: /* @__PURE__ */ z.string().optional().nullable(),
2506
+ addressLine2: /* @__PURE__ */ z.string().optional().nullable()
2475
2507
  }).describe("Address.").optional(),
2476
- contactDetails: z.object({
2477
- firstName: z.string().describe("First name.").max(100).optional().nullable(),
2478
- lastName: z.string().describe("Last name.").max(100).optional().nullable(),
2479
- phone: z.string().describe("Phone number.").optional().nullable(),
2480
- company: z.string().describe("Company name.").max(1e3).optional().nullable(),
2481
- vatId: z.object({
2482
- _id: z.string().describe("Customer's tax ID.").optional(),
2483
- type: z.enum(["UNSPECIFIED", "CPF", "CNPJ"]).describe(
2508
+ contactDetails: /* @__PURE__ */ z.object({
2509
+ firstName: /* @__PURE__ */ z.string().describe("First name.").max(100).optional().nullable(),
2510
+ lastName: /* @__PURE__ */ z.string().describe("Last name.").max(100).optional().nullable(),
2511
+ phone: /* @__PURE__ */ z.string().describe("Phone number.").optional().nullable(),
2512
+ company: /* @__PURE__ */ z.string().describe("Company name.").max(1e3).optional().nullable(),
2513
+ vatId: /* @__PURE__ */ z.object({
2514
+ _id: /* @__PURE__ */ z.string().describe("Customer's tax ID.").optional(),
2515
+ type: /* @__PURE__ */ z.enum(["UNSPECIFIED", "CPF", "CNPJ"]).describe(
2484
2516
  "Tax type.\n\nSupported values:\n+ `CPF`: for individual tax payers\n+ `CNPJ`: for corporations"
2485
2517
  ).optional()
2486
2518
  }).describe(
@@ -2490,81 +2522,87 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2490
2522
  }).describe(
2491
2523
  "Order recipient address and contact details.\n\nThis field may differ from the address in `shippingInfo.logistics` when:\n+ The chosen shipping option is pickup point or store pickup.\n+ No shipping option is selected."
2492
2524
  ).optional(),
2493
- extendedFields: z.object({
2494
- namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
2525
+ extendedFields: /* @__PURE__ */ z.object({
2526
+ namespaces: /* @__PURE__ */ z.record(
2527
+ /* @__PURE__ */ z.string(),
2528
+ /* @__PURE__ */ z.record(
2529
+ /* @__PURE__ */ z.string(),
2530
+ /* @__PURE__ */ z.any()
2531
+ )
2532
+ ).describe(
2495
2533
  "Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\nThe value of each key is structured according to the schema defined when the extended fields were configured.\n\nYou can only access fields for which you have the appropriate permissions.\n\nLearn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields)."
2496
2534
  ).optional()
2497
2535
  }).describe(
2498
2536
  "Custom field data for the subscription contract object.\n\n[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."
2499
2537
  ).optional(),
2500
- title: z.string().describe(
2538
+ title: /* @__PURE__ */ z.string().describe(
2501
2539
  'Subscription option title. For example, `"Monthly coffee Subscription"`.'
2502
2540
  ).min(0).max(150).optional().nullable(),
2503
- additionalFees: z.array(
2504
- z.object({
2505
- code: z.string().describe("Additional fee's unique code for future processing.").min(1).max(100).optional().nullable(),
2506
- name: z.string().describe("Name of additional fee.").min(1).max(50).optional(),
2507
- price: z.object({
2508
- amount: z.string().describe("Amount.").optional(),
2509
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2541
+ additionalFees: /* @__PURE__ */ z.array(
2542
+ /* @__PURE__ */ z.object({
2543
+ code: /* @__PURE__ */ z.string().describe("Additional fee's unique code for future processing.").min(1).max(100).optional().nullable(),
2544
+ name: /* @__PURE__ */ z.string().describe("Name of additional fee.").min(1).max(50).optional(),
2545
+ price: /* @__PURE__ */ z.object({
2546
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2547
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2510
2548
  }).describe("Additional fee's price.").optional(),
2511
- taxDetails: z.object({
2512
- taxableAmount: z.object({
2513
- amount: z.string().describe("Amount.").optional(),
2514
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2549
+ taxDetails: /* @__PURE__ */ z.object({
2550
+ taxableAmount: /* @__PURE__ */ z.object({
2551
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2552
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2515
2553
  }).describe("Taxable amount of this line item.").optional(),
2516
- taxRate: z.string().describe(
2554
+ taxRate: /* @__PURE__ */ z.string().describe(
2517
2555
  'Tax rate percentage, as a decimal numeral between 0 and 1. For example, `"0.13"`.'
2518
2556
  ).optional(),
2519
- totalTax: z.object({
2520
- amount: z.string().describe("Amount.").optional(),
2521
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2557
+ totalTax: /* @__PURE__ */ z.object({
2558
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2559
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2522
2560
  }).describe(
2523
2561
  "The calculated tax, based on the `taxableAmount` and `taxRate`."
2524
2562
  ).optional()
2525
2563
  }).describe("Tax details.").optional(),
2526
- taxInfo: z.object({
2527
- taxAmount: z.object({
2528
- amount: z.string().describe("Amount.").optional(),
2529
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2564
+ taxInfo: /* @__PURE__ */ z.object({
2565
+ taxAmount: /* @__PURE__ */ z.object({
2566
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2567
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2530
2568
  }).describe(
2531
2569
  "Calculated tax, based on `taxable_amount` and `tax_rate`."
2532
2570
  ).optional(),
2533
- taxableAmount: z.object({
2534
- amount: z.string().describe("Amount.").optional(),
2535
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2571
+ taxableAmount: /* @__PURE__ */ z.object({
2572
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2573
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2536
2574
  }).describe("Amount for which tax is calculated.").optional(),
2537
- taxRate: z.string().describe("Tax rate %, as a decimal point.").optional().nullable(),
2538
- taxGroupId: z.string().describe("Tax group ID.").regex(
2575
+ taxRate: /* @__PURE__ */ z.string().describe("Tax rate %, as a decimal point.").optional().nullable(),
2576
+ taxGroupId: /* @__PURE__ */ z.string().describe("Tax group ID.").regex(
2539
2577
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2540
2578
  "Must be a valid GUID"
2541
2579
  ).optional().nullable(),
2542
- taxIncludedInPrice: z.boolean().describe(
2580
+ taxIncludedInPrice: /* @__PURE__ */ z.boolean().describe(
2543
2581
  "Indicates whether the price already includes tax."
2544
2582
  ).optional(),
2545
- taxBreakdown: z.array(
2546
- z.object({
2547
- jurisdiction: z.string().describe(
2583
+ taxBreakdown: /* @__PURE__ */ z.array(
2584
+ /* @__PURE__ */ z.object({
2585
+ jurisdiction: /* @__PURE__ */ z.string().describe(
2548
2586
  'Jurisdiction that taxes were calculated for. For example, "New York", or "Quebec".'
2549
2587
  ).max(200).optional().nullable(),
2550
- rate: z.string().describe(
2588
+ rate: /* @__PURE__ */ z.string().describe(
2551
2589
  "Tax rate used for this jurisdiction, as a decimal. For example, 10% tax is 0.1000."
2552
2590
  ).optional().nullable(),
2553
- taxAmount: z.object({
2554
- amount: z.string().describe("Amount.").optional(),
2555
- formattedAmount: z.string().describe(
2591
+ taxAmount: /* @__PURE__ */ z.object({
2592
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2593
+ formattedAmount: /* @__PURE__ */ z.string().describe(
2556
2594
  "Amount formatted with currency symbol."
2557
2595
  ).optional()
2558
2596
  }).describe(
2559
2597
  "Amount of tax calculated for this line item."
2560
2598
  ).optional(),
2561
- taxType: z.string().describe(
2599
+ taxType: /* @__PURE__ */ z.string().describe(
2562
2600
  `The type of tax that was calculated. Depends on the jurisdiction's tax laws. For example, "Sales Tax", "Income Tax", "Value Added Tax", etc.`
2563
2601
  ).max(200).optional().nullable(),
2564
- taxName: z.string().describe(
2602
+ taxName: /* @__PURE__ */ z.string().describe(
2565
2603
  'The name of the tax against which this tax amount was calculated. For example, "NY State Sales Tax", "Quebec GST", etc.\nThis name should be explicit enough to allow the merchant to understand what tax was calculated.'
2566
2604
  ).max(200).optional().nullable(),
2567
- jurisdictionType: z.enum([
2605
+ jurisdictionType: /* @__PURE__ */ z.enum([
2568
2606
  "UNDEFINED",
2569
2607
  "COUNTRY",
2570
2608
  "STATE",
@@ -2574,17 +2612,17 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2574
2612
  ]).describe(
2575
2613
  "Type of jurisdiction that taxes were calculated for."
2576
2614
  ).optional(),
2577
- nonTaxableAmount: z.object({
2578
- amount: z.string().describe("Amount.").optional(),
2579
- formattedAmount: z.string().describe(
2615
+ nonTaxableAmount: /* @__PURE__ */ z.object({
2616
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2617
+ formattedAmount: /* @__PURE__ */ z.string().describe(
2580
2618
  "Amount formatted with currency symbol."
2581
2619
  ).optional()
2582
2620
  }).describe(
2583
2621
  "Non-taxable amount of the line item price."
2584
2622
  ).optional(),
2585
- taxableAmount: z.object({
2586
- amount: z.string().describe("Amount.").optional(),
2587
- formattedAmount: z.string().describe(
2623
+ taxableAmount: /* @__PURE__ */ z.object({
2624
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2625
+ formattedAmount: /* @__PURE__ */ z.string().describe(
2588
2626
  "Amount formatted with currency symbol."
2589
2627
  ).optional()
2590
2628
  }).describe("Taxable amount of the line item price.").optional()
@@ -2593,36 +2631,38 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2593
2631
  }).describe(
2594
2632
  "Represents all the relevant tax details for additional fee."
2595
2633
  ).optional(),
2596
- providerAppId: z.string().describe("SPI implementer's `appId`.").regex(
2634
+ providerAppId: /* @__PURE__ */ z.string().describe("SPI implementer's `appId`.").regex(
2597
2635
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2598
2636
  "Must be a valid GUID"
2599
2637
  ).optional().nullable(),
2600
- priceBeforeTax: z.object({
2601
- amount: z.string().describe("Amount.").optional(),
2602
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2638
+ priceBeforeTax: /* @__PURE__ */ z.object({
2639
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2640
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2603
2641
  }).describe("Additional fee's price before tax.").optional(),
2604
- priceAfterTax: z.object({
2605
- amount: z.string().describe("Amount.").optional(),
2606
- formattedAmount: z.string().describe("Amount formatted with currency symbol.").optional()
2642
+ priceAfterTax: /* @__PURE__ */ z.object({
2643
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2644
+ formattedAmount: /* @__PURE__ */ z.string().describe("Amount formatted with currency symbol.").optional()
2607
2645
  }).describe("Additional fee's price after tax.").optional(),
2608
- _id: z.string().describe("Additional fee's id.").regex(
2646
+ _id: /* @__PURE__ */ z.string().describe("Additional fee's id.").regex(
2609
2647
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2610
2648
  "Must be a valid GUID"
2611
2649
  ).optional(),
2612
- lineItemIds: z.array(z.string()).optional(),
2613
- source: z.enum([
2650
+ lineItemIds: /* @__PURE__ */ z.array(/* @__PURE__ */ z.string()).optional(),
2651
+ source: /* @__PURE__ */ z.enum([
2614
2652
  "SERVICE_PLUGIN",
2615
2653
  "ITEM",
2616
2654
  "MANUAL",
2617
2655
  "SHIPPING",
2618
2656
  "PLATFORM"
2619
2657
  ]).describe("Specifies the entity that added the additional fee.").optional(),
2620
- taxableAddress: z.intersection(
2621
- z.object({}),
2622
- z.xor([
2623
- z.object({ addressType: z.never().optional() }),
2624
- z.object({
2625
- addressType: z.enum(["BUSINESS", "BILLING", "SHIPPING"]).describe(
2658
+ taxableAddress: /* @__PURE__ */ z.intersection(
2659
+ /* @__PURE__ */ z.object({}),
2660
+ /* @__PURE__ */ z.xor([
2661
+ /* @__PURE__ */ z.object({
2662
+ addressType: /* @__PURE__ */ z.never().optional()
2663
+ }),
2664
+ /* @__PURE__ */ z.object({
2665
+ addressType: /* @__PURE__ */ z.enum(["BUSINESS", "BILLING", "SHIPPING"]).describe(
2626
2666
  "taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly."
2627
2667
  )
2628
2668
  })
@@ -2632,33 +2672,33 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2632
2672
  ).optional()
2633
2673
  })
2634
2674
  ).max(100).optional(),
2635
- activities: z.array(
2636
- z.intersection(
2637
- z.object({
2638
- _id: z.string().describe("Activity ID.").regex(
2675
+ activities: /* @__PURE__ */ z.array(
2676
+ /* @__PURE__ */ z.intersection(
2677
+ /* @__PURE__ */ z.object({
2678
+ _id: /* @__PURE__ */ z.string().describe("Activity ID.").regex(
2639
2679
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2640
2680
  "Must be a valid GUID"
2641
2681
  ).optional(),
2642
- _createdDate: z.date().describe("When the activity occurred.").optional().nullable(),
2643
- author: z.intersection(
2644
- z.object({}),
2645
- z.xor([
2646
- z.object({
2647
- userId: z.never().optional(),
2648
- appId: z.never().optional()
2682
+ _createdDate: /* @__PURE__ */ z.date().describe("When the activity occurred.").optional().nullable(),
2683
+ author: /* @__PURE__ */ z.intersection(
2684
+ /* @__PURE__ */ z.object({}),
2685
+ /* @__PURE__ */ z.xor([
2686
+ /* @__PURE__ */ z.object({
2687
+ userId: /* @__PURE__ */ z.never().optional(),
2688
+ appId: /* @__PURE__ */ z.never().optional()
2649
2689
  }),
2650
- z.object({
2651
- appId: z.never().optional(),
2652
- userId: z.string().describe(
2690
+ /* @__PURE__ */ z.object({
2691
+ appId: /* @__PURE__ */ z.never().optional(),
2692
+ userId: /* @__PURE__ */ z.string().describe(
2653
2693
  "User ID. When the draft order was created by a Wix user."
2654
2694
  ).regex(
2655
2695
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2656
2696
  "Must be a valid GUID"
2657
2697
  )
2658
2698
  }),
2659
- z.object({
2660
- userId: z.never().optional(),
2661
- appId: z.string().describe(
2699
+ /* @__PURE__ */ z.object({
2700
+ userId: /* @__PURE__ */ z.never().optional(),
2701
+ appId: /* @__PURE__ */ z.string().describe(
2662
2702
  "App ID. When the draft order was created by an app."
2663
2703
  ).regex(
2664
2704
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
@@ -2667,14 +2707,16 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2667
2707
  })
2668
2708
  ])
2669
2709
  ).describe("Identity of the draft order's initiator.").optional(),
2670
- activityType: z.enum(["UNKNOWN_ACTIVITY_TYPE", "CHANGES_APPLIED"]).describe("Activity type.").optional()
2710
+ activityType: /* @__PURE__ */ z.enum(["UNKNOWN_ACTIVITY_TYPE", "CHANGES_APPLIED"]).describe("Activity type.").optional()
2671
2711
  }),
2672
- z.intersection(
2673
- z.xor([
2674
- z.object({ contractTarget: z.never().optional() }),
2675
- z.object({
2676
- contractTarget: z.object({
2677
- nextCycleNumber: z.number().int().describe(
2712
+ /* @__PURE__ */ z.intersection(
2713
+ /* @__PURE__ */ z.xor([
2714
+ /* @__PURE__ */ z.object({
2715
+ contractTarget: /* @__PURE__ */ z.never().optional()
2716
+ }),
2717
+ /* @__PURE__ */ z.object({
2718
+ contractTarget: /* @__PURE__ */ z.object({
2719
+ nextCycleNumber: /* @__PURE__ */ z.number().int().describe(
2678
2720
  "Cycle number of the next billing cycle (1-based). Set by the caller; returned by the server on read."
2679
2721
  ).optional().nullable()
2680
2722
  }).describe(
@@ -2682,63 +2724,65 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2682
2724
  )
2683
2725
  })
2684
2726
  ]),
2685
- z.xor([
2686
- z.object({ changesApplied: z.never().optional() }),
2687
- z.object({
2688
- changesApplied: z.intersection(
2689
- z.object({
2690
- draftSubscriptionContractId: z.string().describe(
2727
+ /* @__PURE__ */ z.xor([
2728
+ /* @__PURE__ */ z.object({
2729
+ changesApplied: /* @__PURE__ */ z.never().optional()
2730
+ }),
2731
+ /* @__PURE__ */ z.object({
2732
+ changesApplied: /* @__PURE__ */ z.intersection(
2733
+ /* @__PURE__ */ z.object({
2734
+ draftSubscriptionContractId: /* @__PURE__ */ z.string().describe(
2691
2735
  "ID of the DraftSubscriptionContract that was committed."
2692
2736
  ).regex(
2693
2737
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2694
2738
  "Must be a valid GUID"
2695
2739
  ).optional(),
2696
- changes: z.array(
2697
- z.intersection(
2698
- z.object({}),
2699
- z.xor([
2700
- z.object({
2701
- lineItemChanged: z.never().optional(),
2702
- lineItemAdded: z.never().optional(),
2703
- lineItemRemoved: z.never().optional(),
2704
- discountAdded: z.never().optional(),
2705
- discountRemoved: z.never().optional(),
2706
- additionalFeeAdded: z.never().optional(),
2707
- additionalFeeRemoved: z.never().optional(),
2708
- totalPriceChanged: z.never().optional()
2740
+ changes: /* @__PURE__ */ z.array(
2741
+ /* @__PURE__ */ z.intersection(
2742
+ /* @__PURE__ */ z.object({}),
2743
+ /* @__PURE__ */ z.xor([
2744
+ /* @__PURE__ */ z.object({
2745
+ lineItemChanged: /* @__PURE__ */ z.never().optional(),
2746
+ lineItemAdded: /* @__PURE__ */ z.never().optional(),
2747
+ lineItemRemoved: /* @__PURE__ */ z.never().optional(),
2748
+ discountAdded: /* @__PURE__ */ z.never().optional(),
2749
+ discountRemoved: /* @__PURE__ */ z.never().optional(),
2750
+ additionalFeeAdded: /* @__PURE__ */ z.never().optional(),
2751
+ additionalFeeRemoved: /* @__PURE__ */ z.never().optional(),
2752
+ totalPriceChanged: /* @__PURE__ */ z.never().optional()
2709
2753
  }),
2710
- z.object({
2711
- lineItemAdded: z.never().optional(),
2712
- lineItemRemoved: z.never().optional(),
2713
- discountAdded: z.never().optional(),
2714
- discountRemoved: z.never().optional(),
2715
- additionalFeeAdded: z.never().optional(),
2716
- additionalFeeRemoved: z.never().optional(),
2717
- totalPriceChanged: z.never().optional(),
2718
- lineItemChanged: z.object({
2719
- _id: z.string().describe("Line item ID.").regex(
2754
+ /* @__PURE__ */ z.object({
2755
+ lineItemAdded: /* @__PURE__ */ z.never().optional(),
2756
+ lineItemRemoved: /* @__PURE__ */ z.never().optional(),
2757
+ discountAdded: /* @__PURE__ */ z.never().optional(),
2758
+ discountRemoved: /* @__PURE__ */ z.never().optional(),
2759
+ additionalFeeAdded: /* @__PURE__ */ z.never().optional(),
2760
+ additionalFeeRemoved: /* @__PURE__ */ z.never().optional(),
2761
+ totalPriceChanged: /* @__PURE__ */ z.never().optional(),
2762
+ lineItemChanged: /* @__PURE__ */ z.object({
2763
+ _id: /* @__PURE__ */ z.string().describe("Line item ID.").regex(
2720
2764
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2721
2765
  "Must be a valid GUID"
2722
2766
  ).optional(),
2723
- name: z.object({
2724
- original: z.string().describe(
2767
+ name: /* @__PURE__ */ z.object({
2768
+ original: /* @__PURE__ */ z.string().describe(
2725
2769
  "__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).\n\nMin: 1 character.\nMax: 200 characters."
2726
2770
  ).min(1).max(200).optional(),
2727
- translated: z.string().describe(
2771
+ translated: /* @__PURE__ */ z.string().describe(
2728
2772
  "Item name translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
2729
2773
  ).min(1).max(400).optional().nullable()
2730
2774
  }).describe("Item name after change.").optional(),
2731
- quantity: z.object({
2732
- originalQuantity: z.number().int().describe(
2775
+ quantity: /* @__PURE__ */ z.object({
2776
+ originalQuantity: /* @__PURE__ */ z.number().int().describe(
2733
2777
  "Original item quantity before the change."
2734
2778
  ).min(0).max(1e6).optional(),
2735
- newQuantity: z.number().int().describe(
2779
+ newQuantity: /* @__PURE__ */ z.number().int().describe(
2736
2780
  "New item quantity after the change."
2737
2781
  ).min(0).max(1e6).optional(),
2738
- diff: z.number().int().describe(
2782
+ diff: /* @__PURE__ */ z.number().int().describe(
2739
2783
  "Difference between new and original quantities."
2740
2784
  ).min(1).max(1e6).optional(),
2741
- deltaType: z.enum([
2785
+ deltaType: /* @__PURE__ */ z.enum([
2742
2786
  "QUANTITY_INCREASED",
2743
2787
  "QUANTITY_DECREASED"
2744
2788
  ]).describe(
@@ -2747,84 +2791,84 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2747
2791
  }).describe("Item quantity change.").optional()
2748
2792
  }).describe("Line item was modified.")
2749
2793
  }),
2750
- z.object({
2751
- lineItemChanged: z.never().optional(),
2752
- lineItemRemoved: z.never().optional(),
2753
- discountAdded: z.never().optional(),
2754
- discountRemoved: z.never().optional(),
2755
- additionalFeeAdded: z.never().optional(),
2756
- additionalFeeRemoved: z.never().optional(),
2757
- totalPriceChanged: z.never().optional(),
2758
- lineItemAdded: z.object({
2759
- _id: z.string().describe("Line item ID.").regex(
2794
+ /* @__PURE__ */ z.object({
2795
+ lineItemChanged: /* @__PURE__ */ z.never().optional(),
2796
+ lineItemRemoved: /* @__PURE__ */ z.never().optional(),
2797
+ discountAdded: /* @__PURE__ */ z.never().optional(),
2798
+ discountRemoved: /* @__PURE__ */ z.never().optional(),
2799
+ additionalFeeAdded: /* @__PURE__ */ z.never().optional(),
2800
+ additionalFeeRemoved: /* @__PURE__ */ z.never().optional(),
2801
+ totalPriceChanged: /* @__PURE__ */ z.never().optional(),
2802
+ lineItemAdded: /* @__PURE__ */ z.object({
2803
+ _id: /* @__PURE__ */ z.string().describe("Line item ID.").regex(
2760
2804
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2761
2805
  "Must be a valid GUID"
2762
2806
  ).optional(),
2763
- name: z.object({
2764
- original: z.string().describe(
2807
+ name: /* @__PURE__ */ z.object({
2808
+ original: /* @__PURE__ */ z.string().describe(
2765
2809
  "__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).\n\nMin: 1 character.\nMax: 200 characters."
2766
2810
  ).min(1).max(200).optional(),
2767
- translated: z.string().describe(
2811
+ translated: /* @__PURE__ */ z.string().describe(
2768
2812
  "Item name translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
2769
2813
  ).min(1).max(400).optional().nullable()
2770
2814
  }).describe("Item name.").optional(),
2771
- quantity: z.number().int().describe(
2815
+ quantity: /* @__PURE__ */ z.number().int().describe(
2772
2816
  "Added or removed item quantity."
2773
2817
  ).min(1).max(1e6).optional()
2774
2818
  }).describe(
2775
2819
  "Line item was added to the contract."
2776
2820
  )
2777
2821
  }),
2778
- z.object({
2779
- lineItemChanged: z.never().optional(),
2780
- lineItemAdded: z.never().optional(),
2781
- discountAdded: z.never().optional(),
2782
- discountRemoved: z.never().optional(),
2783
- additionalFeeAdded: z.never().optional(),
2784
- additionalFeeRemoved: z.never().optional(),
2785
- totalPriceChanged: z.never().optional(),
2786
- lineItemRemoved: z.object({
2787
- _id: z.string().describe("Line item ID.").regex(
2822
+ /* @__PURE__ */ z.object({
2823
+ lineItemChanged: /* @__PURE__ */ z.never().optional(),
2824
+ lineItemAdded: /* @__PURE__ */ z.never().optional(),
2825
+ discountAdded: /* @__PURE__ */ z.never().optional(),
2826
+ discountRemoved: /* @__PURE__ */ z.never().optional(),
2827
+ additionalFeeAdded: /* @__PURE__ */ z.never().optional(),
2828
+ additionalFeeRemoved: /* @__PURE__ */ z.never().optional(),
2829
+ totalPriceChanged: /* @__PURE__ */ z.never().optional(),
2830
+ lineItemRemoved: /* @__PURE__ */ z.object({
2831
+ _id: /* @__PURE__ */ z.string().describe("Line item ID.").regex(
2788
2832
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2789
2833
  "Must be a valid GUID"
2790
2834
  ).optional(),
2791
- name: z.object({
2792
- original: z.string().describe(
2835
+ name: /* @__PURE__ */ z.object({
2836
+ original: /* @__PURE__ */ z.string().describe(
2793
2837
  "__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).\n\nMin: 1 character.\nMax: 200 characters."
2794
2838
  ).min(1).max(200).optional(),
2795
- translated: z.string().describe(
2839
+ translated: /* @__PURE__ */ z.string().describe(
2796
2840
  "Item name translated into the buyer's language.\n\nMin: 1 character.\nMax: 400 characters.\nDefault: Same as `original`."
2797
2841
  ).min(1).max(400).optional().nullable()
2798
2842
  }).describe("Item name.").optional(),
2799
- quantity: z.number().int().describe(
2843
+ quantity: /* @__PURE__ */ z.number().int().describe(
2800
2844
  "Added or removed item quantity."
2801
2845
  ).min(1).max(1e6).optional()
2802
2846
  }).describe(
2803
2847
  "Line item was removed from the contract."
2804
2848
  )
2805
2849
  }),
2806
- z.object({
2807
- lineItemChanged: z.never().optional(),
2808
- lineItemAdded: z.never().optional(),
2809
- lineItemRemoved: z.never().optional(),
2810
- discountRemoved: z.never().optional(),
2811
- additionalFeeAdded: z.never().optional(),
2812
- additionalFeeRemoved: z.never().optional(),
2813
- totalPriceChanged: z.never().optional(),
2814
- discountAdded: z.object({
2815
- _id: z.string().describe("Discount ID.").regex(
2850
+ /* @__PURE__ */ z.object({
2851
+ lineItemChanged: /* @__PURE__ */ z.never().optional(),
2852
+ lineItemAdded: /* @__PURE__ */ z.never().optional(),
2853
+ lineItemRemoved: /* @__PURE__ */ z.never().optional(),
2854
+ discountRemoved: /* @__PURE__ */ z.never().optional(),
2855
+ additionalFeeAdded: /* @__PURE__ */ z.never().optional(),
2856
+ additionalFeeRemoved: /* @__PURE__ */ z.never().optional(),
2857
+ totalPriceChanged: /* @__PURE__ */ z.never().optional(),
2858
+ discountAdded: /* @__PURE__ */ z.object({
2859
+ _id: /* @__PURE__ */ z.string().describe("Discount ID.").regex(
2816
2860
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2817
2861
  "Must be a valid GUID"
2818
2862
  ).optional(),
2819
- name: z.object({
2820
- original: z.string().describe(
2863
+ name: /* @__PURE__ */ z.object({
2864
+ original: /* @__PURE__ */ z.string().describe(
2821
2865
  "Value in site default language."
2822
2866
  ).min(1).optional(),
2823
- translated: z.string().describe("Translated value.").min(1).optional().nullable()
2867
+ translated: /* @__PURE__ */ z.string().describe("Translated value.").min(1).optional().nullable()
2824
2868
  }).describe("Discount name.").optional(),
2825
- totalAmount: z.object({
2826
- amount: z.string().describe("Amount.").optional(),
2827
- formattedAmount: z.string().describe(
2869
+ totalAmount: /* @__PURE__ */ z.object({
2870
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2871
+ formattedAmount: /* @__PURE__ */ z.string().describe(
2828
2872
  "Amount formatted with currency symbol."
2829
2873
  ).optional()
2830
2874
  }).describe("Discount amount.").optional()
@@ -2832,28 +2876,28 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2832
2876
  "Discount was added to the contract."
2833
2877
  )
2834
2878
  }),
2835
- z.object({
2836
- lineItemChanged: z.never().optional(),
2837
- lineItemAdded: z.never().optional(),
2838
- lineItemRemoved: z.never().optional(),
2839
- discountAdded: z.never().optional(),
2840
- additionalFeeAdded: z.never().optional(),
2841
- additionalFeeRemoved: z.never().optional(),
2842
- totalPriceChanged: z.never().optional(),
2843
- discountRemoved: z.object({
2844
- _id: z.string().describe("Discount ID.").regex(
2879
+ /* @__PURE__ */ z.object({
2880
+ lineItemChanged: /* @__PURE__ */ z.never().optional(),
2881
+ lineItemAdded: /* @__PURE__ */ z.never().optional(),
2882
+ lineItemRemoved: /* @__PURE__ */ z.never().optional(),
2883
+ discountAdded: /* @__PURE__ */ z.never().optional(),
2884
+ additionalFeeAdded: /* @__PURE__ */ z.never().optional(),
2885
+ additionalFeeRemoved: /* @__PURE__ */ z.never().optional(),
2886
+ totalPriceChanged: /* @__PURE__ */ z.never().optional(),
2887
+ discountRemoved: /* @__PURE__ */ z.object({
2888
+ _id: /* @__PURE__ */ z.string().describe("Discount ID.").regex(
2845
2889
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2846
2890
  "Must be a valid GUID"
2847
2891
  ).optional(),
2848
- name: z.object({
2849
- original: z.string().describe(
2892
+ name: /* @__PURE__ */ z.object({
2893
+ original: /* @__PURE__ */ z.string().describe(
2850
2894
  "Value in site default language."
2851
2895
  ).min(1).optional(),
2852
- translated: z.string().describe("Translated value.").min(1).optional().nullable()
2896
+ translated: /* @__PURE__ */ z.string().describe("Translated value.").min(1).optional().nullable()
2853
2897
  }).describe("Discount name.").optional(),
2854
- totalAmount: z.object({
2855
- amount: z.string().describe("Amount.").optional(),
2856
- formattedAmount: z.string().describe(
2898
+ totalAmount: /* @__PURE__ */ z.object({
2899
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2900
+ formattedAmount: /* @__PURE__ */ z.string().describe(
2857
2901
  "Amount formatted with currency symbol."
2858
2902
  ).optional()
2859
2903
  }).describe("Discount amount.").optional()
@@ -2861,28 +2905,28 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2861
2905
  "Discount was removed from the contract."
2862
2906
  )
2863
2907
  }),
2864
- z.object({
2865
- lineItemChanged: z.never().optional(),
2866
- lineItemAdded: z.never().optional(),
2867
- lineItemRemoved: z.never().optional(),
2868
- discountAdded: z.never().optional(),
2869
- discountRemoved: z.never().optional(),
2870
- additionalFeeRemoved: z.never().optional(),
2871
- totalPriceChanged: z.never().optional(),
2872
- additionalFeeAdded: z.object({
2873
- _id: z.string().describe("Additional fee ID.").regex(
2908
+ /* @__PURE__ */ z.object({
2909
+ lineItemChanged: /* @__PURE__ */ z.never().optional(),
2910
+ lineItemAdded: /* @__PURE__ */ z.never().optional(),
2911
+ lineItemRemoved: /* @__PURE__ */ z.never().optional(),
2912
+ discountAdded: /* @__PURE__ */ z.never().optional(),
2913
+ discountRemoved: /* @__PURE__ */ z.never().optional(),
2914
+ additionalFeeRemoved: /* @__PURE__ */ z.never().optional(),
2915
+ totalPriceChanged: /* @__PURE__ */ z.never().optional(),
2916
+ additionalFeeAdded: /* @__PURE__ */ z.object({
2917
+ _id: /* @__PURE__ */ z.string().describe("Additional fee ID.").regex(
2874
2918
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2875
2919
  "Must be a valid GUID"
2876
2920
  ).optional(),
2877
- name: z.object({
2878
- original: z.string().describe(
2921
+ name: /* @__PURE__ */ z.object({
2922
+ original: /* @__PURE__ */ z.string().describe(
2879
2923
  "Value in site default language."
2880
2924
  ).min(1).optional(),
2881
- translated: z.string().describe("Translated value.").min(1).optional().nullable()
2925
+ translated: /* @__PURE__ */ z.string().describe("Translated value.").min(1).optional().nullable()
2882
2926
  }).describe("Additional fee name.").optional(),
2883
- totalAmount: z.object({
2884
- amount: z.string().describe("Amount.").optional(),
2885
- formattedAmount: z.string().describe(
2927
+ totalAmount: /* @__PURE__ */ z.object({
2928
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2929
+ formattedAmount: /* @__PURE__ */ z.string().describe(
2886
2930
  "Amount formatted with currency symbol."
2887
2931
  ).optional()
2888
2932
  }).describe("Additional fee amount.").optional()
@@ -2890,28 +2934,28 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2890
2934
  "Additional fee was added to the contract."
2891
2935
  )
2892
2936
  }),
2893
- z.object({
2894
- lineItemChanged: z.never().optional(),
2895
- lineItemAdded: z.never().optional(),
2896
- lineItemRemoved: z.never().optional(),
2897
- discountAdded: z.never().optional(),
2898
- discountRemoved: z.never().optional(),
2899
- additionalFeeAdded: z.never().optional(),
2900
- totalPriceChanged: z.never().optional(),
2901
- additionalFeeRemoved: z.object({
2902
- _id: z.string().describe("Additional fee ID.").regex(
2937
+ /* @__PURE__ */ z.object({
2938
+ lineItemChanged: /* @__PURE__ */ z.never().optional(),
2939
+ lineItemAdded: /* @__PURE__ */ z.never().optional(),
2940
+ lineItemRemoved: /* @__PURE__ */ z.never().optional(),
2941
+ discountAdded: /* @__PURE__ */ z.never().optional(),
2942
+ discountRemoved: /* @__PURE__ */ z.never().optional(),
2943
+ additionalFeeAdded: /* @__PURE__ */ z.never().optional(),
2944
+ totalPriceChanged: /* @__PURE__ */ z.never().optional(),
2945
+ additionalFeeRemoved: /* @__PURE__ */ z.object({
2946
+ _id: /* @__PURE__ */ z.string().describe("Additional fee ID.").regex(
2903
2947
  /^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
2904
2948
  "Must be a valid GUID"
2905
2949
  ).optional(),
2906
- name: z.object({
2907
- original: z.string().describe(
2950
+ name: /* @__PURE__ */ z.object({
2951
+ original: /* @__PURE__ */ z.string().describe(
2908
2952
  "Value in site default language."
2909
2953
  ).min(1).optional(),
2910
- translated: z.string().describe("Translated value.").min(1).optional().nullable()
2954
+ translated: /* @__PURE__ */ z.string().describe("Translated value.").min(1).optional().nullable()
2911
2955
  }).describe("Additional fee name.").optional(),
2912
- totalAmount: z.object({
2913
- amount: z.string().describe("Amount.").optional(),
2914
- formattedAmount: z.string().describe(
2956
+ totalAmount: /* @__PURE__ */ z.object({
2957
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2958
+ formattedAmount: /* @__PURE__ */ z.string().describe(
2915
2959
  "Amount formatted with currency symbol."
2916
2960
  ).optional()
2917
2961
  }).describe("Additional fee amount.").optional()
@@ -2919,26 +2963,26 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2919
2963
  "Additional fee was removed from the contract."
2920
2964
  )
2921
2965
  }),
2922
- z.object({
2923
- lineItemChanged: z.never().optional(),
2924
- lineItemAdded: z.never().optional(),
2925
- lineItemRemoved: z.never().optional(),
2926
- discountAdded: z.never().optional(),
2927
- discountRemoved: z.never().optional(),
2928
- additionalFeeAdded: z.never().optional(),
2929
- additionalFeeRemoved: z.never().optional(),
2930
- totalPriceChanged: z.object({
2931
- originalTotal: z.object({
2932
- amount: z.string().describe("Amount.").optional(),
2933
- formattedAmount: z.string().describe(
2966
+ /* @__PURE__ */ z.object({
2967
+ lineItemChanged: /* @__PURE__ */ z.never().optional(),
2968
+ lineItemAdded: /* @__PURE__ */ z.never().optional(),
2969
+ lineItemRemoved: /* @__PURE__ */ z.never().optional(),
2970
+ discountAdded: /* @__PURE__ */ z.never().optional(),
2971
+ discountRemoved: /* @__PURE__ */ z.never().optional(),
2972
+ additionalFeeAdded: /* @__PURE__ */ z.never().optional(),
2973
+ additionalFeeRemoved: /* @__PURE__ */ z.never().optional(),
2974
+ totalPriceChanged: /* @__PURE__ */ z.object({
2975
+ originalTotal: /* @__PURE__ */ z.object({
2976
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2977
+ formattedAmount: /* @__PURE__ */ z.string().describe(
2934
2978
  "Amount formatted with currency symbol."
2935
2979
  ).optional()
2936
2980
  }).describe(
2937
2981
  "Total price before the commit."
2938
2982
  ).optional(),
2939
- newTotal: z.object({
2940
- amount: z.string().describe("Amount.").optional(),
2941
- formattedAmount: z.string().describe(
2983
+ newTotal: /* @__PURE__ */ z.object({
2984
+ amount: /* @__PURE__ */ z.string().describe("Amount.").optional(),
2985
+ formattedAmount: /* @__PURE__ */ z.string().describe(
2942
2986
  "Amount formatted with currency symbol."
2943
2987
  ).optional()
2944
2988
  }).describe(
@@ -2949,15 +2993,17 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2949
2993
  ])
2950
2994
  )
2951
2995
  ).max(100).optional(),
2952
- reason: z.string().describe(
2996
+ reason: /* @__PURE__ */ z.string().describe(
2953
2997
  "Reason for the edit, provided by the merchant (optional)."
2954
2998
  ).max(200).optional().nullable()
2955
2999
  }),
2956
- z.xor([
2957
- z.object({ contractTarget: z.never().optional() }),
2958
- z.object({
2959
- contractTarget: z.object({
2960
- nextCycleNumber: z.number().int().describe(
3000
+ /* @__PURE__ */ z.xor([
3001
+ /* @__PURE__ */ z.object({
3002
+ contractTarget: /* @__PURE__ */ z.never().optional()
3003
+ }),
3004
+ /* @__PURE__ */ z.object({
3005
+ contractTarget: /* @__PURE__ */ z.object({
3006
+ nextCycleNumber: /* @__PURE__ */ z.number().int().describe(
2961
3007
  "Cycle number of the next billing cycle (1-based). Set by the caller; returned by the server on read."
2962
3008
  ).optional().nullable()
2963
3009
  }).describe(
@@ -2975,19 +3021,19 @@ var QuerySubscriptionContractsResponse = /* @__PURE__ */ z.object({
2975
3021
  ).max(500).optional()
2976
3022
  })
2977
3023
  ).optional(),
2978
- pagingMetadata: z.object({
2979
- count: z.number().int().describe("Number of items returned in the response.").optional().nullable(),
2980
- cursors: z.object({
2981
- next: z.string().describe(
3024
+ pagingMetadata: /* @__PURE__ */ z.object({
3025
+ count: /* @__PURE__ */ z.number().int().describe("Number of items returned in the response.").optional().nullable(),
3026
+ cursors: /* @__PURE__ */ z.object({
3027
+ next: /* @__PURE__ */ z.string().describe(
2982
3028
  "Cursor string pointing to the next page in the list of results."
2983
3029
  ).max(16e3).optional().nullable(),
2984
- prev: z.string().describe(
3030
+ prev: /* @__PURE__ */ z.string().describe(
2985
3031
  "Cursor pointing to the previous page in the list of results."
2986
3032
  ).max(16e3).optional().nullable()
2987
3033
  }).describe(
2988
3034
  "Cursor strings that point to the next page, previous page, or both."
2989
3035
  ).optional(),
2990
- hasNext: z.boolean().describe(
3036
+ hasNext: /* @__PURE__ */ z.boolean().describe(
2991
3037
  "Whether there are more pages to retrieve following the current page.\n\n+ `true`: Another page of results can be retrieved.\n+ `false`: This is the last page."
2992
3038
  ).optional().nullable()
2993
3039
  }).describe("Paging metadata").optional()