@wix/auto_sdk_stores_customizations-v-3 1.0.80 → 1.0.81

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 (41) hide show
  1. package/build/cjs/index.d.ts +36 -3
  2. package/build/cjs/index.js.map +1 -1
  3. package/build/cjs/index.typings.d.ts +55 -3
  4. package/build/cjs/index.typings.js.map +1 -1
  5. package/build/cjs/meta.d.ts +12 -2
  6. package/build/cjs/meta.js +1 -0
  7. package/build/cjs/meta.js.map +1 -1
  8. package/build/cjs/schemas.d.ts +166 -1
  9. package/build/cjs/schemas.js +314 -25
  10. package/build/cjs/schemas.js.map +1 -1
  11. package/build/es/index.d.mts +36 -3
  12. package/build/es/index.mjs.map +1 -1
  13. package/build/es/index.typings.d.mts +55 -3
  14. package/build/es/index.typings.mjs.map +1 -1
  15. package/build/es/meta.d.mts +12 -2
  16. package/build/es/meta.mjs +1 -0
  17. package/build/es/meta.mjs.map +1 -1
  18. package/build/es/schemas.d.mts +166 -1
  19. package/build/es/schemas.mjs +310 -25
  20. package/build/es/schemas.mjs.map +1 -1
  21. package/build/internal/cjs/index.d.ts +0 -4
  22. package/build/internal/cjs/index.js.map +1 -1
  23. package/build/internal/cjs/index.typings.d.ts +3 -5
  24. package/build/internal/cjs/index.typings.js.map +1 -1
  25. package/build/internal/cjs/meta.d.ts +12 -2
  26. package/build/internal/cjs/meta.js +1 -0
  27. package/build/internal/cjs/meta.js.map +1 -1
  28. package/build/internal/cjs/schemas.d.ts +166 -1
  29. package/build/internal/cjs/schemas.js +314 -25
  30. package/build/internal/cjs/schemas.js.map +1 -1
  31. package/build/internal/es/index.d.mts +0 -4
  32. package/build/internal/es/index.mjs.map +1 -1
  33. package/build/internal/es/index.typings.d.mts +3 -5
  34. package/build/internal/es/index.typings.mjs.map +1 -1
  35. package/build/internal/es/meta.d.mts +12 -2
  36. package/build/internal/es/meta.mjs +1 -0
  37. package/build/internal/es/meta.mjs.map +1 -1
  38. package/build/internal/es/schemas.d.mts +166 -1
  39. package/build/internal/es/schemas.mjs +310 -25
  40. package/build/internal/es/schemas.mjs.map +1 -1
  41. package/package.json +2 -2
@@ -61,7 +61,10 @@ var CreateCustomizationRequest = z.object({
61
61
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
62
62
  defaultAddedPrice: z.string().describe(
63
63
  "Default amount added to a product's price when this customization is assigned to a modifier."
64
- ).optional().nullable()
64
+ ).optional().nullable(),
65
+ displayImage: z.string().describe(
66
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
67
+ ).optional()
65
68
  }),
66
69
  z.xor([
67
70
  z.object({ colorCode: z.never().optional() }),
@@ -142,7 +145,10 @@ var CreateCustomizationResponse = z.intersection(
142
145
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
143
146
  defaultAddedPrice: z.string().describe(
144
147
  "Default amount added to a product's price when this customization is assigned to a modifier."
145
- ).optional().nullable()
148
+ ).optional().nullable(),
149
+ displayImage: z.string().describe(
150
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
151
+ ).optional()
146
152
  }),
147
153
  z.xor([
148
154
  z.object({ colorCode: z.never().optional() }),
@@ -166,7 +172,7 @@ var GetCustomizationRequest = z.object({
166
172
  "Must be a valid GUID"
167
173
  ),
168
174
  options: z.object({
169
- fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT"])).max(100).optional()
175
+ fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT", "CHOICE_DISPLAY_IMAGE"])).max(100).optional()
170
176
  }).optional()
171
177
  });
172
178
  var GetCustomizationResponse = z.intersection(
@@ -231,7 +237,10 @@ var GetCustomizationResponse = z.intersection(
231
237
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
232
238
  defaultAddedPrice: z.string().describe(
233
239
  "Default amount added to a product's price when this customization is assigned to a modifier."
234
- ).optional().nullable()
240
+ ).optional().nullable(),
241
+ displayImage: z.string().describe(
242
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
243
+ ).optional()
235
244
  }),
236
245
  z.xor([
237
246
  z.object({ colorCode: z.never().optional() }),
@@ -311,7 +320,10 @@ var UpdateCustomizationRequest = z.object({
311
320
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
312
321
  defaultAddedPrice: z.string().describe(
313
322
  "Default amount added to a product's price when this customization is assigned to a modifier."
314
- ).optional().nullable()
323
+ ).optional().nullable(),
324
+ displayImage: z.string().describe(
325
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
326
+ ).optional()
315
327
  }),
316
328
  z.xor([
317
329
  z.object({ colorCode: z.never().optional() }),
@@ -330,7 +342,7 @@ var UpdateCustomizationRequest = z.object({
330
342
  ])
331
343
  ).describe("Customization to update."),
332
344
  options: z.object({
333
- fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT"])).max(100).optional()
345
+ fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT", "CHOICE_DISPLAY_IMAGE"])).max(100).optional()
334
346
  }).optional()
335
347
  });
336
348
  var UpdateCustomizationResponse = z.intersection(
@@ -395,7 +407,10 @@ var UpdateCustomizationResponse = z.intersection(
395
407
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
396
408
  defaultAddedPrice: z.string().describe(
397
409
  "Default amount added to a product's price when this customization is assigned to a modifier."
398
- ).optional().nullable()
410
+ ).optional().nullable(),
411
+ displayImage: z.string().describe(
412
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
413
+ ).optional()
399
414
  }),
400
415
  z.xor([
401
416
  z.object({ colorCode: z.never().optional() }),
@@ -519,7 +534,7 @@ var QueryCustomizationsRequest = z.object({
519
534
  ).optional()
520
535
  }).catchall(z.any()).describe("Query options."),
521
536
  options: z.object({
522
- fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT"])).max(100).optional()
537
+ fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT", "CHOICE_DISPLAY_IMAGE"])).max(100).optional()
523
538
  }).optional()
524
539
  });
525
540
  var QueryCustomizationsResponse = z.object({
@@ -588,7 +603,10 @@ var QueryCustomizationsResponse = z.object({
588
603
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
589
604
  defaultAddedPrice: z.string().describe(
590
605
  "Default amount added to a product's price when this customization is assigned to a modifier."
591
- ).optional().nullable()
606
+ ).optional().nullable(),
607
+ displayImage: z.string().describe(
608
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
609
+ ).optional()
592
610
  }),
593
611
  z.xor([
594
612
  z.object({ colorCode: z.never().optional() }),
@@ -686,7 +704,10 @@ var BulkCreateCustomizationsRequest = z.object({
686
704
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
687
705
  defaultAddedPrice: z.string().describe(
688
706
  "Default amount added to a product's price when this customization is assigned to a modifier."
689
- ).optional().nullable()
707
+ ).optional().nullable(),
708
+ displayImage: z.string().describe(
709
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
710
+ ).optional()
690
711
  }),
691
712
  z.xor([
692
713
  z.object({ colorCode: z.never().optional() }),
@@ -794,7 +815,10 @@ var BulkCreateCustomizationsResponse = z.object({
794
815
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
795
816
  defaultAddedPrice: z.string().describe(
796
817
  "Default amount added to a product's price when this customization is assigned to a modifier."
797
- ).optional().nullable()
818
+ ).optional().nullable(),
819
+ displayImage: z.string().describe(
820
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
821
+ ).optional()
798
822
  }),
799
823
  z.xor([
800
824
  z.object({ colorCode: z.never().optional() }),
@@ -843,7 +867,10 @@ var AddCustomizationChoicesRequest = z.object({
843
867
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
844
868
  defaultAddedPrice: z.string().describe(
845
869
  "Default amount added to a product's price when this customization is assigned to a modifier."
846
- ).optional().nullable()
870
+ ).optional().nullable(),
871
+ displayImage: z.string().describe(
872
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
873
+ ).optional()
847
874
  }),
848
875
  z.xor([
849
876
  z.object({ colorCode: z.never().optional() }),
@@ -856,7 +883,7 @@ var AddCustomizationChoicesRequest = z.object({
856
883
  )
857
884
  ).min(1).max(100),
858
885
  options: z.object({
859
- fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT"])).max(100).optional()
886
+ fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT", "CHOICE_DISPLAY_IMAGE"])).max(100).optional()
860
887
  }).optional()
861
888
  });
862
889
  var AddCustomizationChoicesResponse = z.object({
@@ -924,7 +951,10 @@ var AddCustomizationChoicesResponse = z.object({
924
951
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
925
952
  defaultAddedPrice: z.string().describe(
926
953
  "Default amount added to a product's price when this customization is assigned to a modifier."
927
- ).optional().nullable()
954
+ ).optional().nullable(),
955
+ displayImage: z.string().describe(
956
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
957
+ ).optional()
928
958
  }),
929
959
  z.xor([
930
960
  z.object({ colorCode: z.never().optional() }),
@@ -962,7 +992,10 @@ var SetCustomizationChoicesRequest = z.object({
962
992
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
963
993
  defaultAddedPrice: z.string().describe(
964
994
  "Default amount added to a product's price when this customization is assigned to a modifier."
965
- ).optional().nullable()
995
+ ).optional().nullable(),
996
+ displayImage: z.string().describe(
997
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
998
+ ).optional()
966
999
  }),
967
1000
  z.xor([
968
1001
  z.object({ colorCode: z.never().optional() }),
@@ -975,7 +1008,7 @@ var SetCustomizationChoicesRequest = z.object({
975
1008
  )
976
1009
  ).min(1).max(200),
977
1010
  options: z.object({
978
- fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT"])).max(100).optional()
1011
+ fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT", "CHOICE_DISPLAY_IMAGE"])).max(100).optional()
979
1012
  }).optional()
980
1013
  });
981
1014
  var SetCustomizationChoicesResponse = z.object({
@@ -1043,7 +1076,10 @@ var SetCustomizationChoicesResponse = z.object({
1043
1076
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
1044
1077
  defaultAddedPrice: z.string().describe(
1045
1078
  "Default amount added to a product's price when this customization is assigned to a modifier."
1046
- ).optional().nullable()
1079
+ ).optional().nullable(),
1080
+ displayImage: z.string().describe(
1081
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
1082
+ ).optional()
1047
1083
  }),
1048
1084
  z.xor([
1049
1085
  z.object({ colorCode: z.never().optional() }),
@@ -1070,7 +1106,7 @@ var RemoveCustomizationChoicesRequest = z.object({
1070
1106
  choiceIds: z.array(z.string()).min(1).max(100),
1071
1107
  options: z.object({
1072
1108
  revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe("Customization revision.").optional(),
1073
- fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT"])).max(100).optional()
1109
+ fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT", "CHOICE_DISPLAY_IMAGE"])).max(100).optional()
1074
1110
  }).optional()
1075
1111
  });
1076
1112
  var RemoveCustomizationChoicesResponse = z.object({
@@ -1138,7 +1174,240 @@ var RemoveCustomizationChoicesResponse = z.object({
1138
1174
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
1139
1175
  defaultAddedPrice: z.string().describe(
1140
1176
  "Default amount added to a product's price when this customization is assigned to a modifier."
1141
- ).optional().nullable()
1177
+ ).optional().nullable(),
1178
+ displayImage: z.string().describe(
1179
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
1180
+ ).optional()
1181
+ }),
1182
+ z.xor([
1183
+ z.object({ colorCode: z.never().optional() }),
1184
+ z.object({
1185
+ colorCode: z.string().describe(
1186
+ "Color code in HEX format, [as described by MDN](https://developer.mozilla.org/en-US/docs/Web/CSS/hex-color)."
1187
+ ).min(3).max(20)
1188
+ })
1189
+ ])
1190
+ )
1191
+ ).min(1).max(200).optional()
1192
+ }).describe(
1193
+ "Choices settings.\n\n> **Note:** Must be passed along with `customizationRenderType` of `SWATCH_CHOICES` and `TEXT_CHOICES`."
1194
+ )
1195
+ })
1196
+ ])
1197
+ ).describe("Updated customization.").optional()
1198
+ });
1199
+ var UpdateCustomizationChoicesRequest = z.object({
1200
+ customizationId: z.string().describe("Customization ID.").regex(
1201
+ /^[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}$/,
1202
+ "Must be a valid GUID"
1203
+ ),
1204
+ revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
1205
+ "Revision number, which increments by 1 each time the customization is updated.\nTo prevent conflicting changes,\nthe current revision must be passed when updating the customization."
1206
+ ),
1207
+ options: z.object({
1208
+ choices: z.array(
1209
+ z.object({
1210
+ choice: z.intersection(
1211
+ z.object({
1212
+ _id: z.string().describe("Choice ID.").regex(
1213
+ /^[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}$/,
1214
+ "Must be a valid GUID"
1215
+ ).optional(),
1216
+ choiceType: z.enum(["CHOICE_TEXT", "ONE_COLOR"]).optional(),
1217
+ key: z.string().describe(
1218
+ "A read-only identifier generated from the choice name.\n\nUse `key` in the `catalogReference.options` object when [integrating Catalog V3 with eCommerce APIs](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)."
1219
+ ).min(1).max(50).optional().nullable(),
1220
+ name: z.string().describe("Choice name.").min(1).max(50).optional(),
1221
+ defaultAddedPrice: z.string().describe(
1222
+ "Default amount added to a product's price when this customization is assigned to a modifier."
1223
+ ).optional().nullable(),
1224
+ displayImage: z.string().describe(
1225
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
1226
+ ).optional()
1227
+ }),
1228
+ z.xor([
1229
+ z.object({ colorCode: z.never().optional() }),
1230
+ z.object({
1231
+ colorCode: z.string().describe(
1232
+ "Color code in HEX format, [as described by MDN](https://developer.mozilla.org/en-US/docs/Web/CSS/hex-color)."
1233
+ ).min(3).max(20)
1234
+ })
1235
+ ])
1236
+ ).describe("Choice to update.")
1237
+ })
1238
+ ).min(1).max(100),
1239
+ fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT", "CHOICE_DISPLAY_IMAGE"])).max(100).optional()
1240
+ })
1241
+ });
1242
+ var UpdateCustomizationChoicesResponse = z.object({
1243
+ customization: z.intersection(
1244
+ z.object({
1245
+ _id: z.string().describe("Customization ID.").min(1).max(36).optional().nullable(),
1246
+ revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
1247
+ "Revision number, which increments by 1 each time the customization is updated.\nTo prevent conflicting changes,\nthe current revision must be passed when updating the customization.\n\nIgnored when creating a customization."
1248
+ ).optional().nullable(),
1249
+ _createdDate: z.date().describe("Date and time the customization was created.").optional().nullable(),
1250
+ _updatedDate: z.date().describe("Date and time the customization was updated.").optional().nullable(),
1251
+ key: z.string().describe(
1252
+ "A read-only identifier generated from the customization name.\n\nUse `key` in the `catalogReference.options` object when [integrating Catalog V3 with eCommerce APIs](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)."
1253
+ ).min(1).max(50).optional().nullable(),
1254
+ name: z.string().describe(
1255
+ 'Customization name for options (for example, `"color"`, `"size"`) and modifiers (for example, `"greeting card"`).'
1256
+ ).min(1).max(50).optional(),
1257
+ customizationType: z.enum(["PRODUCT_OPTION", "MODIFIER"]).describe("Customization type.").optional(),
1258
+ customizationRenderType: z.enum(["FREE_TEXT", "TEXT_CHOICES", "SWATCH_CHOICES"]).describe(
1259
+ "Customization render type.\n\nDefines how the customization will be displayed in the storefront."
1260
+ ).optional(),
1261
+ assignedProductsCount: z.number().int().describe(
1262
+ 'Number of products this customization is assigned to.\n> **Note:** Returned only when you pass `"ASSIGNED_PRODUCTS_COUNT"` to the `fields` array in Customizations API requests.'
1263
+ ).optional().nullable()
1264
+ }),
1265
+ z.xor([
1266
+ z.object({
1267
+ freeTextInput: z.never().optional(),
1268
+ choicesSettings: z.never().optional()
1269
+ }),
1270
+ z.object({
1271
+ choicesSettings: z.never().optional(),
1272
+ freeTextInput: z.object({
1273
+ minCharCount: z.number().int().describe("Minimum text character length.").optional(),
1274
+ maxCharCount: z.number().int().describe("Maximum text character length.").max(500).optional(),
1275
+ defaultAddedPrice: z.string().describe(
1276
+ "Default amount added to a product's price when this choice is assigned to a modifier."
1277
+ ).optional().nullable(),
1278
+ title: z.string().describe(
1279
+ "Title to display to customer for their free-text input."
1280
+ ).min(1).max(100).optional(),
1281
+ key: z.string().describe(
1282
+ "A read-only identifier generated from the title.\n\nUse `key` in the `catalogReference.options` object when [integrating Catalog V3 with eCommerce APIs](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)."
1283
+ ).min(1).max(150).optional().nullable()
1284
+ }).describe(
1285
+ "Free text input settings.\n\n> **Note:** To be passed along with `customizationRenderType: FREE_TEXT`."
1286
+ )
1287
+ }),
1288
+ z.object({
1289
+ freeTextInput: z.never().optional(),
1290
+ choicesSettings: z.object({
1291
+ choices: z.array(
1292
+ z.intersection(
1293
+ z.object({
1294
+ _id: z.string().describe("Choice ID.").regex(
1295
+ /^[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}$/,
1296
+ "Must be a valid GUID"
1297
+ ).optional(),
1298
+ choiceType: z.enum(["CHOICE_TEXT", "ONE_COLOR"]).describe(
1299
+ "Choice type.\n\n> **Notes:**\n> + For `customizationRenderType: SWATCH_CHOICES`, the supported `choiceType` value is: `ONE_COLOR`.\n> + For a `customizationRenderType` of `TEXT_CHOICES`, the supported `choiceType` value is: `CHOICE_TEXT`."
1300
+ ).optional(),
1301
+ key: z.string().describe(
1302
+ "A read-only identifier generated from the choice name.\n\nUse `key` in the `catalogReference.options` object when [integrating Catalog V3 with eCommerce APIs](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)."
1303
+ ).min(1).max(50).optional().nullable(),
1304
+ name: z.string().describe("Choice name.").min(1).max(50).optional(),
1305
+ defaultAddedPrice: z.string().describe(
1306
+ "Default amount added to a product's price when this customization is assigned to a modifier."
1307
+ ).optional().nullable(),
1308
+ displayImage: z.string().describe(
1309
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
1310
+ ).optional()
1311
+ }),
1312
+ z.xor([
1313
+ z.object({ colorCode: z.never().optional() }),
1314
+ z.object({
1315
+ colorCode: z.string().describe(
1316
+ "Color code in HEX format, [as described by MDN](https://developer.mozilla.org/en-US/docs/Web/CSS/hex-color)."
1317
+ ).min(3).max(20)
1318
+ })
1319
+ ])
1320
+ )
1321
+ ).min(1).max(200).optional()
1322
+ }).describe(
1323
+ "Choices settings.\n\n> **Note:** Must be passed along with `customizationRenderType` of `SWATCH_CHOICES` and `TEXT_CHOICES`."
1324
+ )
1325
+ })
1326
+ ])
1327
+ ).describe("Updated customization.").optional()
1328
+ });
1329
+ var ReorderCustomizationChoicesRequest = z.object({
1330
+ customizationId: z.string().describe("Customization ID.").regex(
1331
+ /^[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}$/,
1332
+ "Must be a valid GUID"
1333
+ ),
1334
+ revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
1335
+ "Revision number, which increments by 1 each time the customization is updated. To prevent conflicting changes, the current revision must be passed when updating the customization."
1336
+ ),
1337
+ options: z.object({
1338
+ choiceIds: z.array(z.string()).min(1).max(200),
1339
+ fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT", "CHOICE_DISPLAY_IMAGE"])).max(100).optional()
1340
+ })
1341
+ });
1342
+ var ReorderCustomizationChoicesResponse = z.object({
1343
+ customization: z.intersection(
1344
+ z.object({
1345
+ _id: z.string().describe("Customization ID.").min(1).max(36).optional().nullable(),
1346
+ revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
1347
+ "Revision number, which increments by 1 each time the customization is updated.\nTo prevent conflicting changes,\nthe current revision must be passed when updating the customization.\n\nIgnored when creating a customization."
1348
+ ).optional().nullable(),
1349
+ _createdDate: z.date().describe("Date and time the customization was created.").optional().nullable(),
1350
+ _updatedDate: z.date().describe("Date and time the customization was updated.").optional().nullable(),
1351
+ key: z.string().describe(
1352
+ "A read-only identifier generated from the customization name.\n\nUse `key` in the `catalogReference.options` object when [integrating Catalog V3 with eCommerce APIs](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)."
1353
+ ).min(1).max(50).optional().nullable(),
1354
+ name: z.string().describe(
1355
+ 'Customization name for options (for example, `"color"`, `"size"`) and modifiers (for example, `"greeting card"`).'
1356
+ ).min(1).max(50).optional(),
1357
+ customizationType: z.enum(["PRODUCT_OPTION", "MODIFIER"]).describe("Customization type.").optional(),
1358
+ customizationRenderType: z.enum(["FREE_TEXT", "TEXT_CHOICES", "SWATCH_CHOICES"]).describe(
1359
+ "Customization render type.\n\nDefines how the customization will be displayed in the storefront."
1360
+ ).optional(),
1361
+ assignedProductsCount: z.number().int().describe(
1362
+ 'Number of products this customization is assigned to.\n> **Note:** Returned only when you pass `"ASSIGNED_PRODUCTS_COUNT"` to the `fields` array in Customizations API requests.'
1363
+ ).optional().nullable()
1364
+ }),
1365
+ z.xor([
1366
+ z.object({
1367
+ freeTextInput: z.never().optional(),
1368
+ choicesSettings: z.never().optional()
1369
+ }),
1370
+ z.object({
1371
+ choicesSettings: z.never().optional(),
1372
+ freeTextInput: z.object({
1373
+ minCharCount: z.number().int().describe("Minimum text character length.").optional(),
1374
+ maxCharCount: z.number().int().describe("Maximum text character length.").max(500).optional(),
1375
+ defaultAddedPrice: z.string().describe(
1376
+ "Default amount added to a product's price when this choice is assigned to a modifier."
1377
+ ).optional().nullable(),
1378
+ title: z.string().describe(
1379
+ "Title to display to customer for their free-text input."
1380
+ ).min(1).max(100).optional(),
1381
+ key: z.string().describe(
1382
+ "A read-only identifier generated from the title.\n\nUse `key` in the `catalogReference.options` object when [integrating Catalog V3 with eCommerce APIs](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)."
1383
+ ).min(1).max(150).optional().nullable()
1384
+ }).describe(
1385
+ "Free text input settings.\n\n> **Note:** To be passed along with `customizationRenderType: FREE_TEXT`."
1386
+ )
1387
+ }),
1388
+ z.object({
1389
+ freeTextInput: z.never().optional(),
1390
+ choicesSettings: z.object({
1391
+ choices: z.array(
1392
+ z.intersection(
1393
+ z.object({
1394
+ _id: z.string().describe("Choice ID.").regex(
1395
+ /^[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}$/,
1396
+ "Must be a valid GUID"
1397
+ ).optional(),
1398
+ choiceType: z.enum(["CHOICE_TEXT", "ONE_COLOR"]).describe(
1399
+ "Choice type.\n\n> **Notes:**\n> + For `customizationRenderType: SWATCH_CHOICES`, the supported `choiceType` value is: `ONE_COLOR`.\n> + For a `customizationRenderType` of `TEXT_CHOICES`, the supported `choiceType` value is: `CHOICE_TEXT`."
1400
+ ).optional(),
1401
+ key: z.string().describe(
1402
+ "A read-only identifier generated from the choice name.\n\nUse `key` in the `catalogReference.options` object when [integrating Catalog V3 with eCommerce APIs](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)."
1403
+ ).min(1).max(50).optional().nullable(),
1404
+ name: z.string().describe("Choice name.").min(1).max(50).optional(),
1405
+ defaultAddedPrice: z.string().describe(
1406
+ "Default amount added to a product's price when this customization is assigned to a modifier."
1407
+ ).optional().nullable(),
1408
+ displayImage: z.string().describe(
1409
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
1410
+ ).optional()
1142
1411
  }),
1143
1412
  z.xor([
1144
1413
  z.object({ colorCode: z.never().optional() }),
@@ -1175,7 +1444,10 @@ var BulkAddCustomizationChoicesRequest = z.object({
1175
1444
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
1176
1445
  defaultAddedPrice: z.string().describe(
1177
1446
  "Default amount added to a product's price when this customization is assigned to a modifier."
1178
- ).optional().nullable()
1447
+ ).optional().nullable(),
1448
+ displayImage: z.string().describe(
1449
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
1450
+ ).optional()
1179
1451
  }),
1180
1452
  z.xor([
1181
1453
  z.object({ colorCode: z.never().optional() }),
@@ -1193,7 +1465,7 @@ var BulkAddCustomizationChoicesRequest = z.object({
1193
1465
  returnEntity: z.boolean().describe(
1194
1466
  "Whether to return the full customization entities in the response.\n\nDefault: `false`"
1195
1467
  ).optional(),
1196
- fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT"])).max(100).optional()
1468
+ fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT", "CHOICE_DISPLAY_IMAGE"])).max(100).optional()
1197
1469
  }).optional()
1198
1470
  });
1199
1471
  var BulkAddCustomizationChoicesResponse = z.object({
@@ -1279,7 +1551,10 @@ var BulkAddCustomizationChoicesResponse = z.object({
1279
1551
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
1280
1552
  defaultAddedPrice: z.string().describe(
1281
1553
  "Default amount added to a product's price when this customization is assigned to a modifier."
1282
- ).optional().nullable()
1554
+ ).optional().nullable(),
1555
+ displayImage: z.string().describe(
1556
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
1557
+ ).optional()
1283
1558
  }),
1284
1559
  z.xor([
1285
1560
  z.object({ colorCode: z.never().optional() }),
@@ -1372,7 +1647,10 @@ var BulkUpdateCustomizationsRequest = z.object({
1372
1647
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
1373
1648
  defaultAddedPrice: z.string().describe(
1374
1649
  "Default amount added to a product's price when this customization is assigned to a modifier."
1375
- ).optional().nullable()
1650
+ ).optional().nullable(),
1651
+ displayImage: z.string().describe(
1652
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
1653
+ ).optional()
1376
1654
  }),
1377
1655
  z.xor([
1378
1656
  z.object({ colorCode: z.never().optional() }),
@@ -1396,7 +1674,7 @@ var BulkUpdateCustomizationsRequest = z.object({
1396
1674
  returnEntity: z.boolean().describe(
1397
1675
  "Whether to return the full customization entities in the response.\n\nDefault: `false`"
1398
1676
  ).optional(),
1399
- fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT"])).max(100).optional()
1677
+ fields: z.array(z.enum(["ASSIGNED_PRODUCTS_COUNT", "CHOICE_DISPLAY_IMAGE"])).max(100).optional()
1400
1678
  }).optional()
1401
1679
  });
1402
1680
  var BulkUpdateCustomizationsResponse = z.object({
@@ -1482,7 +1760,10 @@ var BulkUpdateCustomizationsResponse = z.object({
1482
1760
  name: z.string().describe("Choice name.").min(1).max(50).optional(),
1483
1761
  defaultAddedPrice: z.string().describe(
1484
1762
  "Default amount added to a product's price when this customization is assigned to a modifier."
1485
- ).optional().nullable()
1763
+ ).optional().nullable(),
1764
+ displayImage: z.string().describe(
1765
+ "Optional image displayed alongside a ONE_COLOR choice in the storefront.\nOnly valid for ONE_COLOR choices; not populated for other choice types."
1766
+ ).optional()
1486
1767
  }),
1487
1768
  z.xor([
1488
1769
  z.object({ colorCode: z.never().optional() }),
@@ -1531,8 +1812,12 @@ export {
1531
1812
  QueryCustomizationsResponse,
1532
1813
  RemoveCustomizationChoicesRequest,
1533
1814
  RemoveCustomizationChoicesResponse,
1815
+ ReorderCustomizationChoicesRequest,
1816
+ ReorderCustomizationChoicesResponse,
1534
1817
  SetCustomizationChoicesRequest,
1535
1818
  SetCustomizationChoicesResponse,
1819
+ UpdateCustomizationChoicesRequest,
1820
+ UpdateCustomizationChoicesResponse,
1536
1821
  UpdateCustomizationRequest,
1537
1822
  UpdateCustomizationResponse
1538
1823
  };