@wix/auto_sdk_stores_customizations-v-3 1.0.92 → 1.0.94

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.
@@ -1,1226 +0,0 @@
1
- "use strict";
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __export = (target, all) => {
7
- for (var name in all)
8
- __defProp(target, name, { get: all[name], enumerable: true });
9
- };
10
- var __copyProps = (to, from, except, desc) => {
11
- if (from && typeof from === "object" || typeof from === "function") {
12
- for (let key of __getOwnPropNames(from))
13
- if (!__hasOwnProp.call(to, key) && key !== except)
14
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
- }
16
- return to;
17
- };
18
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
-
20
- // meta.ts
21
- var meta_exports = {};
22
- __export(meta_exports, {
23
- ChoiceSortStrategyOriginal: () => ChoiceSortStrategy,
24
- ChoiceTypeOriginal: () => ChoiceType,
25
- CustomizationRenderTypeOriginal: () => CustomizationRenderType,
26
- CustomizationTypeOriginal: () => CustomizationType,
27
- RequestedFieldsOriginal: () => RequestedFields,
28
- SortOrderOriginal: () => SortOrder,
29
- WebhookIdentityTypeOriginal: () => WebhookIdentityType,
30
- addCustomizationChoices: () => addCustomizationChoices2,
31
- bulkAddCustomizationChoices: () => bulkAddCustomizationChoices2,
32
- bulkCreateCustomizations: () => bulkCreateCustomizations2,
33
- bulkUpdateCustomizations: () => bulkUpdateCustomizations2,
34
- countCustomizations: () => countCustomizations2,
35
- createCustomization: () => createCustomization2,
36
- deleteCustomization: () => deleteCustomization2,
37
- getCustomization: () => getCustomization2,
38
- queryCustomizations: () => queryCustomizations2,
39
- removeCustomizationChoices: () => removeCustomizationChoices2,
40
- reorderCustomizationChoices: () => reorderCustomizationChoices2,
41
- setCustomizationChoices: () => setCustomizationChoices2,
42
- updateCustomization: () => updateCustomization2,
43
- updateCustomizationChoices: () => updateCustomizationChoices2
44
- });
45
- module.exports = __toCommonJS(meta_exports);
46
-
47
- // src/stores-catalog-v3-customization-customizations-v-3.http.ts
48
- var import_rest_modules = require("@wix/sdk-runtime/rest-modules");
49
- var import_float = require("@wix/sdk-runtime/transformations/float");
50
- var import_float2 = require("@wix/sdk-runtime/transformations/float");
51
- var import_timestamp = require("@wix/sdk-runtime/transformations/timestamp");
52
- var import_timestamp2 = require("@wix/sdk-runtime/transformations/timestamp");
53
- var import_field_mask = require("@wix/sdk-runtime/transformations/field-mask");
54
- var import_transform_paths = require("@wix/sdk-runtime/transformations/transform-paths");
55
- var import_rest_modules2 = require("@wix/sdk-runtime/rest-modules");
56
- function resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl(opts) {
57
- const domainToMappings = {
58
- "manage._base_domain_": [
59
- {
60
- srcPath: "/customization",
61
- destPath: ""
62
- }
63
- ],
64
- "www.wixapis.com": [
65
- {
66
- srcPath: "/stores/v3/customizations",
67
- destPath: "/v3/customizations"
68
- },
69
- {
70
- srcPath: "/stores/v3/bulk/customizations",
71
- destPath: "/v3/bulk/customizations"
72
- }
73
- ],
74
- "editor._base_domain_": [
75
- {
76
- srcPath: "/_api/customization",
77
- destPath: ""
78
- }
79
- ],
80
- "blocks._base_domain_": [
81
- {
82
- srcPath: "/_api/customization",
83
- destPath: ""
84
- }
85
- ],
86
- "create.editorx": [
87
- {
88
- srcPath: "/_api/customization",
89
- destPath: ""
90
- }
91
- ],
92
- _: [
93
- {
94
- srcPath: "/_api/customization",
95
- destPath: ""
96
- }
97
- ],
98
- "*.dev.wix-code.com": [
99
- {
100
- srcPath: "/_api/customization",
101
- destPath: ""
102
- }
103
- ]
104
- };
105
- return (0, import_rest_modules2.resolveUrl)(Object.assign(opts, { domainToMappings }));
106
- }
107
- var PACKAGE_NAME = "@wix/auto_sdk_stores_customizations-v-3";
108
- function createCustomization(payload) {
109
- function __createCustomization({ host }) {
110
- const serializedData = (0, import_transform_paths.transformPaths)(payload, [
111
- {
112
- transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
113
- paths: [
114
- { path: "customization.createdDate" },
115
- { path: "customization.updatedDate" },
116
- {
117
- path: "customization.choicesSettings.choices.image.urlExpirationDate"
118
- },
119
- {
120
- path: "customization.choicesSettings.choices.displayImage.urlExpirationDate"
121
- }
122
- ]
123
- },
124
- {
125
- transformFn: import_float.transformSDKFloatToRESTFloat,
126
- paths: [
127
- { path: "customization.choicesSettings.choices.image.focalPoint.x" },
128
- { path: "customization.choicesSettings.choices.image.focalPoint.y" }
129
- ]
130
- }
131
- ]);
132
- const metadata = {
133
- entityFqdn: "wix.stores.catalog.v3.customization",
134
- method: "POST",
135
- methodFqn: "wix.stores.catalog.customization.v3.CustomizationService.CreateCustomization",
136
- packageName: PACKAGE_NAME,
137
- migrationOptions: {
138
- optInTransformResponse: true
139
- },
140
- url: resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl({
141
- protoPath: "/v3/customizations",
142
- data: serializedData,
143
- host
144
- }),
145
- data: serializedData,
146
- transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
147
- {
148
- transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
149
- paths: [
150
- { path: "customization.createdDate" },
151
- { path: "customization.updatedDate" },
152
- {
153
- path: "customization.choicesSettings.choices.image.urlExpirationDate"
154
- },
155
- {
156
- path: "customization.choicesSettings.choices.displayImage.urlExpirationDate"
157
- }
158
- ]
159
- },
160
- {
161
- transformFn: import_float2.transformRESTFloatToSDKFloat,
162
- paths: [
163
- {
164
- path: "customization.choicesSettings.choices.image.focalPoint.x"
165
- },
166
- {
167
- path: "customization.choicesSettings.choices.image.focalPoint.y"
168
- }
169
- ]
170
- }
171
- ])
172
- };
173
- return metadata;
174
- }
175
- return __createCustomization;
176
- }
177
- function getCustomization(payload) {
178
- function __getCustomization({ host }) {
179
- const metadata = {
180
- entityFqdn: "wix.stores.catalog.v3.customization",
181
- method: "GET",
182
- methodFqn: "wix.stores.catalog.customization.v3.CustomizationService.GetCustomization",
183
- packageName: PACKAGE_NAME,
184
- migrationOptions: {
185
- optInTransformResponse: true
186
- },
187
- url: resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl({
188
- protoPath: "/v3/customizations/{customizationId}",
189
- data: payload,
190
- host
191
- }),
192
- params: (0, import_rest_modules.toURLSearchParams)(payload),
193
- transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
194
- {
195
- transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
196
- paths: [
197
- { path: "customization.createdDate" },
198
- { path: "customization.updatedDate" },
199
- {
200
- path: "customization.choicesSettings.choices.image.urlExpirationDate"
201
- },
202
- {
203
- path: "customization.choicesSettings.choices.displayImage.urlExpirationDate"
204
- }
205
- ]
206
- },
207
- {
208
- transformFn: import_float2.transformRESTFloatToSDKFloat,
209
- paths: [
210
- {
211
- path: "customization.choicesSettings.choices.image.focalPoint.x"
212
- },
213
- {
214
- path: "customization.choicesSettings.choices.image.focalPoint.y"
215
- }
216
- ]
217
- }
218
- ])
219
- };
220
- return metadata;
221
- }
222
- return __getCustomization;
223
- }
224
- function updateCustomization(payload) {
225
- function __updateCustomization({ host }) {
226
- const serializedData = (0, import_transform_paths.transformPaths)(payload, [
227
- {
228
- transformFn: import_field_mask.transformSDKFieldMaskToRESTFieldMask,
229
- paths: [{ path: "fieldMask" }]
230
- },
231
- {
232
- transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
233
- paths: [
234
- { path: "customization.createdDate" },
235
- { path: "customization.updatedDate" },
236
- {
237
- path: "customization.choicesSettings.choices.image.urlExpirationDate"
238
- },
239
- {
240
- path: "customization.choicesSettings.choices.displayImage.urlExpirationDate"
241
- }
242
- ]
243
- },
244
- {
245
- transformFn: import_float.transformSDKFloatToRESTFloat,
246
- paths: [
247
- { path: "customization.choicesSettings.choices.image.focalPoint.x" },
248
- { path: "customization.choicesSettings.choices.image.focalPoint.y" }
249
- ]
250
- }
251
- ]);
252
- const metadata = {
253
- entityFqdn: "wix.stores.catalog.v3.customization",
254
- method: "PATCH",
255
- methodFqn: "wix.stores.catalog.customization.v3.CustomizationService.UpdateCustomization",
256
- packageName: PACKAGE_NAME,
257
- migrationOptions: {
258
- optInTransformResponse: true
259
- },
260
- url: resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl({
261
- protoPath: "/v3/customizations/{customization.id}",
262
- data: serializedData,
263
- host
264
- }),
265
- data: serializedData,
266
- transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
267
- {
268
- transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
269
- paths: [
270
- { path: "customization.createdDate" },
271
- { path: "customization.updatedDate" },
272
- {
273
- path: "customization.choicesSettings.choices.image.urlExpirationDate"
274
- },
275
- {
276
- path: "customization.choicesSettings.choices.displayImage.urlExpirationDate"
277
- }
278
- ]
279
- },
280
- {
281
- transformFn: import_float2.transformRESTFloatToSDKFloat,
282
- paths: [
283
- {
284
- path: "customization.choicesSettings.choices.image.focalPoint.x"
285
- },
286
- {
287
- path: "customization.choicesSettings.choices.image.focalPoint.y"
288
- }
289
- ]
290
- }
291
- ])
292
- };
293
- return metadata;
294
- }
295
- return __updateCustomization;
296
- }
297
- function deleteCustomization(payload) {
298
- function __deleteCustomization({ host }) {
299
- const metadata = {
300
- entityFqdn: "wix.stores.catalog.v3.customization",
301
- method: "DELETE",
302
- methodFqn: "wix.stores.catalog.customization.v3.CustomizationService.DeleteCustomization",
303
- packageName: PACKAGE_NAME,
304
- migrationOptions: {
305
- optInTransformResponse: true
306
- },
307
- url: resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl({
308
- protoPath: "/v3/customizations/{customizationId}",
309
- data: payload,
310
- host
311
- }),
312
- params: (0, import_rest_modules.toURLSearchParams)(payload)
313
- };
314
- return metadata;
315
- }
316
- return __deleteCustomization;
317
- }
318
- function queryCustomizations(payload) {
319
- function __queryCustomizations({ host }) {
320
- const metadata = {
321
- entityFqdn: "wix.stores.catalog.v3.customization",
322
- method: "GET",
323
- methodFqn: "wix.stores.catalog.customization.v3.CustomizationService.QueryCustomizations",
324
- packageName: PACKAGE_NAME,
325
- migrationOptions: {
326
- optInTransformResponse: true
327
- },
328
- url: resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl({
329
- protoPath: "/v3/customizations/query",
330
- data: payload,
331
- host
332
- }),
333
- params: (0, import_rest_modules.toURLSearchParams)(payload, true),
334
- transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
335
- {
336
- transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
337
- paths: [
338
- { path: "customizations.createdDate" },
339
- { path: "customizations.updatedDate" },
340
- {
341
- path: "customizations.choicesSettings.choices.image.urlExpirationDate"
342
- },
343
- {
344
- path: "customizations.choicesSettings.choices.displayImage.urlExpirationDate"
345
- }
346
- ]
347
- },
348
- {
349
- transformFn: import_float2.transformRESTFloatToSDKFloat,
350
- paths: [
351
- {
352
- path: "customizations.choicesSettings.choices.image.focalPoint.x"
353
- },
354
- {
355
- path: "customizations.choicesSettings.choices.image.focalPoint.y"
356
- }
357
- ]
358
- }
359
- ]),
360
- fallback: [
361
- {
362
- method: "POST",
363
- url: resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl({
364
- protoPath: "/v3/customizations/query",
365
- data: payload,
366
- host
367
- }),
368
- data: payload
369
- }
370
- ]
371
- };
372
- return metadata;
373
- }
374
- return __queryCustomizations;
375
- }
376
- function countCustomizations(payload) {
377
- function __countCustomizations({ host }) {
378
- const metadata = {
379
- entityFqdn: "wix.stores.catalog.v3.customization",
380
- method: "POST",
381
- methodFqn: "wix.stores.catalog.customization.v3.CustomizationService.CountCustomizations",
382
- packageName: PACKAGE_NAME,
383
- migrationOptions: {
384
- optInTransformResponse: true
385
- },
386
- url: resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl({
387
- protoPath: "/v3/customizations/count",
388
- data: payload,
389
- host
390
- }),
391
- data: payload
392
- };
393
- return metadata;
394
- }
395
- return __countCustomizations;
396
- }
397
- function bulkCreateCustomizations(payload) {
398
- function __bulkCreateCustomizations({ host }) {
399
- const serializedData = (0, import_transform_paths.transformPaths)(payload, [
400
- {
401
- transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
402
- paths: [
403
- { path: "customizations.createdDate" },
404
- { path: "customizations.updatedDate" },
405
- {
406
- path: "customizations.choicesSettings.choices.image.urlExpirationDate"
407
- },
408
- {
409
- path: "customizations.choicesSettings.choices.displayImage.urlExpirationDate"
410
- }
411
- ]
412
- },
413
- {
414
- transformFn: import_float.transformSDKFloatToRESTFloat,
415
- paths: [
416
- { path: "customizations.choicesSettings.choices.image.focalPoint.x" },
417
- { path: "customizations.choicesSettings.choices.image.focalPoint.y" }
418
- ]
419
- }
420
- ]);
421
- const metadata = {
422
- entityFqdn: "wix.stores.catalog.v3.customization",
423
- method: "POST",
424
- methodFqn: "wix.stores.catalog.customization.v3.CustomizationService.BulkCreateCustomizations",
425
- packageName: PACKAGE_NAME,
426
- migrationOptions: {
427
- optInTransformResponse: true
428
- },
429
- url: resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl({
430
- protoPath: "/v3/bulk/customizations/create",
431
- data: serializedData,
432
- host
433
- }),
434
- data: serializedData,
435
- transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
436
- {
437
- transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
438
- paths: [
439
- { path: "results.customization.createdDate" },
440
- { path: "results.customization.updatedDate" },
441
- {
442
- path: "results.customization.choicesSettings.choices.image.urlExpirationDate"
443
- },
444
- {
445
- path: "results.customization.choicesSettings.choices.displayImage.urlExpirationDate"
446
- }
447
- ]
448
- },
449
- {
450
- transformFn: import_float2.transformRESTFloatToSDKFloat,
451
- paths: [
452
- {
453
- path: "results.customization.choicesSettings.choices.image.focalPoint.x"
454
- },
455
- {
456
- path: "results.customization.choicesSettings.choices.image.focalPoint.y"
457
- }
458
- ]
459
- }
460
- ])
461
- };
462
- return metadata;
463
- }
464
- return __bulkCreateCustomizations;
465
- }
466
- function addCustomizationChoices(payload) {
467
- function __addCustomizationChoices({ host }) {
468
- const serializedData = (0, import_transform_paths.transformPaths)(payload, [
469
- {
470
- transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
471
- paths: [
472
- { path: "choices.image.urlExpirationDate" },
473
- { path: "choices.displayImage.urlExpirationDate" }
474
- ]
475
- },
476
- {
477
- transformFn: import_float.transformSDKFloatToRESTFloat,
478
- paths: [
479
- { path: "choices.image.focalPoint.x" },
480
- { path: "choices.image.focalPoint.y" }
481
- ]
482
- }
483
- ]);
484
- const metadata = {
485
- entityFqdn: "wix.stores.catalog.v3.customization",
486
- method: "POST",
487
- methodFqn: "wix.stores.catalog.customization.v3.CustomizationService.AddCustomizationChoices",
488
- packageName: PACKAGE_NAME,
489
- migrationOptions: {
490
- optInTransformResponse: true
491
- },
492
- url: resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl({
493
- protoPath: "/v3/customizations/{customizationId}/add-choices",
494
- data: serializedData,
495
- host
496
- }),
497
- data: serializedData,
498
- transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
499
- {
500
- transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
501
- paths: [
502
- { path: "customization.createdDate" },
503
- { path: "customization.updatedDate" },
504
- {
505
- path: "customization.choicesSettings.choices.image.urlExpirationDate"
506
- },
507
- {
508
- path: "customization.choicesSettings.choices.displayImage.urlExpirationDate"
509
- }
510
- ]
511
- },
512
- {
513
- transformFn: import_float2.transformRESTFloatToSDKFloat,
514
- paths: [
515
- {
516
- path: "customization.choicesSettings.choices.image.focalPoint.x"
517
- },
518
- {
519
- path: "customization.choicesSettings.choices.image.focalPoint.y"
520
- }
521
- ]
522
- }
523
- ])
524
- };
525
- return metadata;
526
- }
527
- return __addCustomizationChoices;
528
- }
529
- function setCustomizationChoices(payload) {
530
- function __setCustomizationChoices({ host }) {
531
- const serializedData = (0, import_transform_paths.transformPaths)(payload, [
532
- {
533
- transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
534
- paths: [
535
- { path: "choices.image.urlExpirationDate" },
536
- { path: "choices.displayImage.urlExpirationDate" }
537
- ]
538
- },
539
- {
540
- transformFn: import_float.transformSDKFloatToRESTFloat,
541
- paths: [
542
- { path: "choices.image.focalPoint.x" },
543
- { path: "choices.image.focalPoint.y" }
544
- ]
545
- }
546
- ]);
547
- const metadata = {
548
- entityFqdn: "wix.stores.catalog.v3.customization",
549
- method: "POST",
550
- methodFqn: "wix.stores.catalog.customization.v3.CustomizationService.SetCustomizationChoices",
551
- packageName: PACKAGE_NAME,
552
- migrationOptions: {
553
- optInTransformResponse: true
554
- },
555
- url: resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl({
556
- protoPath: "/v3/customizations/{customizationId}/set-choices",
557
- data: serializedData,
558
- host
559
- }),
560
- data: serializedData,
561
- transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
562
- {
563
- transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
564
- paths: [
565
- { path: "customization.createdDate" },
566
- { path: "customization.updatedDate" },
567
- {
568
- path: "customization.choicesSettings.choices.image.urlExpirationDate"
569
- },
570
- {
571
- path: "customization.choicesSettings.choices.displayImage.urlExpirationDate"
572
- }
573
- ]
574
- },
575
- {
576
- transformFn: import_float2.transformRESTFloatToSDKFloat,
577
- paths: [
578
- {
579
- path: "customization.choicesSettings.choices.image.focalPoint.x"
580
- },
581
- {
582
- path: "customization.choicesSettings.choices.image.focalPoint.y"
583
- }
584
- ]
585
- }
586
- ])
587
- };
588
- return metadata;
589
- }
590
- return __setCustomizationChoices;
591
- }
592
- function removeCustomizationChoices(payload) {
593
- function __removeCustomizationChoices({ host }) {
594
- const metadata = {
595
- entityFqdn: "wix.stores.catalog.v3.customization",
596
- method: "POST",
597
- methodFqn: "wix.stores.catalog.customization.v3.CustomizationService.RemoveCustomizationChoices",
598
- packageName: PACKAGE_NAME,
599
- migrationOptions: {
600
- optInTransformResponse: true
601
- },
602
- url: resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl({
603
- protoPath: "/v3/customizations/{customizationId}/remove-choices",
604
- data: payload,
605
- host
606
- }),
607
- data: payload,
608
- transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
609
- {
610
- transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
611
- paths: [
612
- { path: "customization.createdDate" },
613
- { path: "customization.updatedDate" },
614
- {
615
- path: "customization.choicesSettings.choices.image.urlExpirationDate"
616
- },
617
- {
618
- path: "customization.choicesSettings.choices.displayImage.urlExpirationDate"
619
- }
620
- ]
621
- },
622
- {
623
- transformFn: import_float2.transformRESTFloatToSDKFloat,
624
- paths: [
625
- {
626
- path: "customization.choicesSettings.choices.image.focalPoint.x"
627
- },
628
- {
629
- path: "customization.choicesSettings.choices.image.focalPoint.y"
630
- }
631
- ]
632
- }
633
- ])
634
- };
635
- return metadata;
636
- }
637
- return __removeCustomizationChoices;
638
- }
639
- function updateCustomizationChoices(payload) {
640
- function __updateCustomizationChoices({ host }) {
641
- const serializedData = (0, import_transform_paths.transformPaths)(payload, [
642
- {
643
- transformFn: import_field_mask.transformSDKFieldMaskToRESTFieldMask,
644
- paths: [{ path: "choices.fieldMask" }]
645
- },
646
- {
647
- transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
648
- paths: [
649
- { path: "choices.choice.image.urlExpirationDate" },
650
- { path: "choices.choice.displayImage.urlExpirationDate" }
651
- ]
652
- },
653
- {
654
- transformFn: import_float.transformSDKFloatToRESTFloat,
655
- paths: [
656
- { path: "choices.choice.image.focalPoint.x" },
657
- { path: "choices.choice.image.focalPoint.y" }
658
- ]
659
- }
660
- ]);
661
- const metadata = {
662
- entityFqdn: "wix.stores.catalog.v3.customization",
663
- method: "POST",
664
- methodFqn: "wix.stores.catalog.customization.v3.CustomizationService.UpdateCustomizationChoices",
665
- packageName: PACKAGE_NAME,
666
- migrationOptions: {
667
- optInTransformResponse: true
668
- },
669
- url: resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl({
670
- protoPath: "/v3/customizations/{customizationId}/update-choices",
671
- data: serializedData,
672
- host
673
- }),
674
- data: serializedData,
675
- transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
676
- {
677
- transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
678
- paths: [
679
- { path: "customization.createdDate" },
680
- { path: "customization.updatedDate" },
681
- {
682
- path: "customization.choicesSettings.choices.image.urlExpirationDate"
683
- },
684
- {
685
- path: "customization.choicesSettings.choices.displayImage.urlExpirationDate"
686
- }
687
- ]
688
- },
689
- {
690
- transformFn: import_float2.transformRESTFloatToSDKFloat,
691
- paths: [
692
- {
693
- path: "customization.choicesSettings.choices.image.focalPoint.x"
694
- },
695
- {
696
- path: "customization.choicesSettings.choices.image.focalPoint.y"
697
- }
698
- ]
699
- }
700
- ])
701
- };
702
- return metadata;
703
- }
704
- return __updateCustomizationChoices;
705
- }
706
- function reorderCustomizationChoices(payload) {
707
- function __reorderCustomizationChoices({ host }) {
708
- const metadata = {
709
- entityFqdn: "wix.stores.catalog.v3.customization",
710
- method: "POST",
711
- methodFqn: "wix.stores.catalog.customization.v3.CustomizationService.ReorderCustomizationChoices",
712
- packageName: PACKAGE_NAME,
713
- migrationOptions: {
714
- optInTransformResponse: true
715
- },
716
- url: resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl({
717
- protoPath: "/v3/customizations/{customizationId}/reorder-choices",
718
- data: payload,
719
- host
720
- }),
721
- data: payload,
722
- transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
723
- {
724
- transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
725
- paths: [
726
- { path: "customization.createdDate" },
727
- { path: "customization.updatedDate" },
728
- {
729
- path: "customization.choicesSettings.choices.image.urlExpirationDate"
730
- },
731
- {
732
- path: "customization.choicesSettings.choices.displayImage.urlExpirationDate"
733
- }
734
- ]
735
- },
736
- {
737
- transformFn: import_float2.transformRESTFloatToSDKFloat,
738
- paths: [
739
- {
740
- path: "customization.choicesSettings.choices.image.focalPoint.x"
741
- },
742
- {
743
- path: "customization.choicesSettings.choices.image.focalPoint.y"
744
- }
745
- ]
746
- }
747
- ])
748
- };
749
- return metadata;
750
- }
751
- return __reorderCustomizationChoices;
752
- }
753
- function bulkAddCustomizationChoices(payload) {
754
- function __bulkAddCustomizationChoices({ host }) {
755
- const serializedData = (0, import_transform_paths.transformPaths)(payload, [
756
- {
757
- transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
758
- paths: [
759
- { path: "customizationsChoices.choices.image.urlExpirationDate" },
760
- {
761
- path: "customizationsChoices.choices.displayImage.urlExpirationDate"
762
- }
763
- ]
764
- },
765
- {
766
- transformFn: import_float.transformSDKFloatToRESTFloat,
767
- paths: [
768
- { path: "customizationsChoices.choices.image.focalPoint.x" },
769
- { path: "customizationsChoices.choices.image.focalPoint.y" }
770
- ]
771
- }
772
- ]);
773
- const metadata = {
774
- entityFqdn: "wix.stores.catalog.v3.customization",
775
- method: "POST",
776
- methodFqn: "wix.stores.catalog.customization.v3.CustomizationService.BulkAddCustomizationChoices",
777
- packageName: PACKAGE_NAME,
778
- migrationOptions: {
779
- optInTransformResponse: true
780
- },
781
- url: resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl({
782
- protoPath: "/v3/bulk/customizations/add-choices",
783
- data: serializedData,
784
- host
785
- }),
786
- data: serializedData,
787
- transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
788
- {
789
- transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
790
- paths: [
791
- { path: "results.customization.createdDate" },
792
- { path: "results.customization.updatedDate" },
793
- {
794
- path: "results.customization.choicesSettings.choices.image.urlExpirationDate"
795
- },
796
- {
797
- path: "results.customization.choicesSettings.choices.displayImage.urlExpirationDate"
798
- }
799
- ]
800
- },
801
- {
802
- transformFn: import_float2.transformRESTFloatToSDKFloat,
803
- paths: [
804
- {
805
- path: "results.customization.choicesSettings.choices.image.focalPoint.x"
806
- },
807
- {
808
- path: "results.customization.choicesSettings.choices.image.focalPoint.y"
809
- }
810
- ]
811
- }
812
- ])
813
- };
814
- return metadata;
815
- }
816
- return __bulkAddCustomizationChoices;
817
- }
818
- function bulkUpdateCustomizations(payload) {
819
- function __bulkUpdateCustomizations({ host }) {
820
- const serializedData = (0, import_transform_paths.transformPaths)(payload, [
821
- {
822
- transformFn: import_field_mask.transformSDKFieldMaskToRESTFieldMask,
823
- paths: [{ path: "customizations.fieldMask" }]
824
- },
825
- {
826
- transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
827
- paths: [
828
- { path: "customizations.customization.createdDate" },
829
- { path: "customizations.customization.updatedDate" },
830
- {
831
- path: "customizations.customization.choicesSettings.choices.image.urlExpirationDate"
832
- },
833
- {
834
- path: "customizations.customization.choicesSettings.choices.displayImage.urlExpirationDate"
835
- }
836
- ]
837
- },
838
- {
839
- transformFn: import_float.transformSDKFloatToRESTFloat,
840
- paths: [
841
- {
842
- path: "customizations.customization.choicesSettings.choices.image.focalPoint.x"
843
- },
844
- {
845
- path: "customizations.customization.choicesSettings.choices.image.focalPoint.y"
846
- }
847
- ]
848
- }
849
- ]);
850
- const metadata = {
851
- entityFqdn: "wix.stores.catalog.v3.customization",
852
- method: "POST",
853
- methodFqn: "wix.stores.catalog.customization.v3.CustomizationService.BulkUpdateCustomizations",
854
- packageName: PACKAGE_NAME,
855
- migrationOptions: {
856
- optInTransformResponse: true
857
- },
858
- url: resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl({
859
- protoPath: "/v3/bulk/customizations/update",
860
- data: serializedData,
861
- host
862
- }),
863
- data: serializedData,
864
- transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
865
- {
866
- transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
867
- paths: [
868
- { path: "results.customization.createdDate" },
869
- { path: "results.customization.updatedDate" },
870
- {
871
- path: "results.customization.choicesSettings.choices.image.urlExpirationDate"
872
- },
873
- {
874
- path: "results.customization.choicesSettings.choices.displayImage.urlExpirationDate"
875
- }
876
- ]
877
- },
878
- {
879
- transformFn: import_float2.transformRESTFloatToSDKFloat,
880
- paths: [
881
- {
882
- path: "results.customization.choicesSettings.choices.image.focalPoint.x"
883
- },
884
- {
885
- path: "results.customization.choicesSettings.choices.image.focalPoint.y"
886
- }
887
- ]
888
- }
889
- ])
890
- };
891
- return metadata;
892
- }
893
- return __bulkUpdateCustomizations;
894
- }
895
-
896
- // src/stores-catalog-v3-customization-customizations-v-3.types.ts
897
- var CustomizationType = /* @__PURE__ */ ((CustomizationType2) => {
898
- CustomizationType2["PRODUCT_OPTION"] = "PRODUCT_OPTION";
899
- CustomizationType2["MODIFIER"] = "MODIFIER";
900
- return CustomizationType2;
901
- })(CustomizationType || {});
902
- var CustomizationRenderType = /* @__PURE__ */ ((CustomizationRenderType2) => {
903
- CustomizationRenderType2["FREE_TEXT"] = "FREE_TEXT";
904
- CustomizationRenderType2["TEXT_CHOICES"] = "TEXT_CHOICES";
905
- CustomizationRenderType2["SWATCH_CHOICES"] = "SWATCH_CHOICES";
906
- return CustomizationRenderType2;
907
- })(CustomizationRenderType || {});
908
- var ChoiceType = /* @__PURE__ */ ((ChoiceType2) => {
909
- ChoiceType2["CHOICE_TEXT"] = "CHOICE_TEXT";
910
- ChoiceType2["ONE_COLOR"] = "ONE_COLOR";
911
- ChoiceType2["MULTIPLE_COLORS"] = "MULTIPLE_COLORS";
912
- ChoiceType2["IMAGE"] = "IMAGE";
913
- return ChoiceType2;
914
- })(ChoiceType || {});
915
- var ChoiceSortStrategy = /* @__PURE__ */ ((ChoiceSortStrategy2) => {
916
- ChoiceSortStrategy2["DEFAULT"] = "DEFAULT";
917
- ChoiceSortStrategy2["BY_NAME"] = "BY_NAME";
918
- ChoiceSortStrategy2["BY_PRODUCT_COUNT"] = "BY_PRODUCT_COUNT";
919
- ChoiceSortStrategy2["MANUAL"] = "MANUAL";
920
- return ChoiceSortStrategy2;
921
- })(ChoiceSortStrategy || {});
922
- var RequestedFields = /* @__PURE__ */ ((RequestedFields2) => {
923
- RequestedFields2["ASSIGNED_PRODUCTS_COUNT"] = "ASSIGNED_PRODUCTS_COUNT";
924
- RequestedFields2["CHOICE_DISPLAY_IMAGE"] = "CHOICE_DISPLAY_IMAGE";
925
- return RequestedFields2;
926
- })(RequestedFields || {});
927
- var SortOrder = /* @__PURE__ */ ((SortOrder2) => {
928
- SortOrder2["ASC"] = "ASC";
929
- SortOrder2["DESC"] = "DESC";
930
- return SortOrder2;
931
- })(SortOrder || {});
932
- var WebhookIdentityType = /* @__PURE__ */ ((WebhookIdentityType2) => {
933
- WebhookIdentityType2["UNKNOWN"] = "UNKNOWN";
934
- WebhookIdentityType2["ANONYMOUS_VISITOR"] = "ANONYMOUS_VISITOR";
935
- WebhookIdentityType2["MEMBER"] = "MEMBER";
936
- WebhookIdentityType2["WIX_USER"] = "WIX_USER";
937
- WebhookIdentityType2["APP"] = "APP";
938
- return WebhookIdentityType2;
939
- })(WebhookIdentityType || {});
940
-
941
- // src/stores-catalog-v3-customization-customizations-v-3.meta.ts
942
- function createCustomization2() {
943
- const payload = {};
944
- const getRequestOptions = createCustomization(payload);
945
- const getUrl = (context) => {
946
- const { url } = getRequestOptions(context);
947
- return url;
948
- };
949
- return {
950
- getUrl,
951
- httpMethod: "POST",
952
- path: "/v3/customizations",
953
- pathParams: {},
954
- __requestType: null,
955
- __originalRequestType: null,
956
- __responseType: null,
957
- __originalResponseType: null
958
- };
959
- }
960
- function getCustomization2() {
961
- const payload = { customizationId: ":customizationId" };
962
- const getRequestOptions = getCustomization(payload);
963
- const getUrl = (context) => {
964
- const { url } = getRequestOptions(context);
965
- return url;
966
- };
967
- return {
968
- getUrl,
969
- httpMethod: "GET",
970
- path: "/v3/customizations/{customizationId}",
971
- pathParams: { customizationId: "customizationId" },
972
- __requestType: null,
973
- __originalRequestType: null,
974
- __responseType: null,
975
- __originalResponseType: null
976
- };
977
- }
978
- function updateCustomization2() {
979
- const payload = { customization: { id: ":customizationId" } };
980
- const getRequestOptions = updateCustomization(payload);
981
- const getUrl = (context) => {
982
- const { url } = getRequestOptions(context);
983
- return url;
984
- };
985
- return {
986
- getUrl,
987
- httpMethod: "PATCH",
988
- path: "/v3/customizations/{customization.id}",
989
- pathParams: { customizationId: "customizationId" },
990
- __requestType: null,
991
- __originalRequestType: null,
992
- __responseType: null,
993
- __originalResponseType: null
994
- };
995
- }
996
- function deleteCustomization2() {
997
- const payload = { customizationId: ":customizationId" };
998
- const getRequestOptions = deleteCustomization(payload);
999
- const getUrl = (context) => {
1000
- const { url } = getRequestOptions(context);
1001
- return url;
1002
- };
1003
- return {
1004
- getUrl,
1005
- httpMethod: "DELETE",
1006
- path: "/v3/customizations/{customizationId}",
1007
- pathParams: { customizationId: "customizationId" },
1008
- __requestType: null,
1009
- __originalRequestType: null,
1010
- __responseType: null,
1011
- __originalResponseType: null
1012
- };
1013
- }
1014
- function queryCustomizations2() {
1015
- const payload = {};
1016
- const getRequestOptions = queryCustomizations(payload);
1017
- const getUrl = (context) => {
1018
- const { url } = getRequestOptions(context);
1019
- return url;
1020
- };
1021
- return {
1022
- getUrl,
1023
- httpMethod: "GET",
1024
- path: "/v3/customizations/query",
1025
- pathParams: {},
1026
- __requestType: null,
1027
- __originalRequestType: null,
1028
- __responseType: null,
1029
- __originalResponseType: null
1030
- };
1031
- }
1032
- function countCustomizations2() {
1033
- const payload = {};
1034
- const getRequestOptions = countCustomizations(payload);
1035
- const getUrl = (context) => {
1036
- const { url } = getRequestOptions(context);
1037
- return url;
1038
- };
1039
- return {
1040
- getUrl,
1041
- httpMethod: "POST",
1042
- path: "/v3/customizations/count",
1043
- pathParams: {},
1044
- __requestType: null,
1045
- __originalRequestType: null,
1046
- __responseType: null,
1047
- __originalResponseType: null
1048
- };
1049
- }
1050
- function bulkCreateCustomizations2() {
1051
- const payload = {};
1052
- const getRequestOptions = bulkCreateCustomizations(payload);
1053
- const getUrl = (context) => {
1054
- const { url } = getRequestOptions(context);
1055
- return url;
1056
- };
1057
- return {
1058
- getUrl,
1059
- httpMethod: "POST",
1060
- path: "/v3/bulk/customizations/create",
1061
- pathParams: {},
1062
- __requestType: null,
1063
- __originalRequestType: null,
1064
- __responseType: null,
1065
- __originalResponseType: null
1066
- };
1067
- }
1068
- function addCustomizationChoices2() {
1069
- const payload = { customizationId: ":customizationId" };
1070
- const getRequestOptions = addCustomizationChoices(payload);
1071
- const getUrl = (context) => {
1072
- const { url } = getRequestOptions(context);
1073
- return url;
1074
- };
1075
- return {
1076
- getUrl,
1077
- httpMethod: "POST",
1078
- path: "/v3/customizations/{customizationId}/add-choices",
1079
- pathParams: { customizationId: "customizationId" },
1080
- __requestType: null,
1081
- __originalRequestType: null,
1082
- __responseType: null,
1083
- __originalResponseType: null
1084
- };
1085
- }
1086
- function setCustomizationChoices2() {
1087
- const payload = { customizationId: ":customizationId" };
1088
- const getRequestOptions = setCustomizationChoices(payload);
1089
- const getUrl = (context) => {
1090
- const { url } = getRequestOptions(context);
1091
- return url;
1092
- };
1093
- return {
1094
- getUrl,
1095
- httpMethod: "POST",
1096
- path: "/v3/customizations/{customizationId}/set-choices",
1097
- pathParams: { customizationId: "customizationId" },
1098
- __requestType: null,
1099
- __originalRequestType: null,
1100
- __responseType: null,
1101
- __originalResponseType: null
1102
- };
1103
- }
1104
- function removeCustomizationChoices2() {
1105
- const payload = { customizationId: ":customizationId" };
1106
- const getRequestOptions = removeCustomizationChoices(
1107
- payload
1108
- );
1109
- const getUrl = (context) => {
1110
- const { url } = getRequestOptions(context);
1111
- return url;
1112
- };
1113
- return {
1114
- getUrl,
1115
- httpMethod: "POST",
1116
- path: "/v3/customizations/{customizationId}/remove-choices",
1117
- pathParams: { customizationId: "customizationId" },
1118
- __requestType: null,
1119
- __originalRequestType: null,
1120
- __responseType: null,
1121
- __originalResponseType: null
1122
- };
1123
- }
1124
- function updateCustomizationChoices2() {
1125
- const payload = { customizationId: ":customizationId" };
1126
- const getRequestOptions = updateCustomizationChoices(
1127
- payload
1128
- );
1129
- const getUrl = (context) => {
1130
- const { url } = getRequestOptions(context);
1131
- return url;
1132
- };
1133
- return {
1134
- getUrl,
1135
- httpMethod: "POST",
1136
- path: "/v3/customizations/{customizationId}/update-choices",
1137
- pathParams: { customizationId: "customizationId" },
1138
- __requestType: null,
1139
- __originalRequestType: null,
1140
- __responseType: null,
1141
- __originalResponseType: null
1142
- };
1143
- }
1144
- function reorderCustomizationChoices2() {
1145
- const payload = { customizationId: ":customizationId" };
1146
- const getRequestOptions = reorderCustomizationChoices(
1147
- payload
1148
- );
1149
- const getUrl = (context) => {
1150
- const { url } = getRequestOptions(context);
1151
- return url;
1152
- };
1153
- return {
1154
- getUrl,
1155
- httpMethod: "POST",
1156
- path: "/v3/customizations/{customizationId}/reorder-choices",
1157
- pathParams: { customizationId: "customizationId" },
1158
- __requestType: null,
1159
- __originalRequestType: null,
1160
- __responseType: null,
1161
- __originalResponseType: null
1162
- };
1163
- }
1164
- function bulkAddCustomizationChoices2() {
1165
- const payload = {};
1166
- const getRequestOptions = bulkAddCustomizationChoices(
1167
- payload
1168
- );
1169
- const getUrl = (context) => {
1170
- const { url } = getRequestOptions(context);
1171
- return url;
1172
- };
1173
- return {
1174
- getUrl,
1175
- httpMethod: "POST",
1176
- path: "/v3/bulk/customizations/add-choices",
1177
- pathParams: {},
1178
- __requestType: null,
1179
- __originalRequestType: null,
1180
- __responseType: null,
1181
- __originalResponseType: null
1182
- };
1183
- }
1184
- function bulkUpdateCustomizations2() {
1185
- const payload = {};
1186
- const getRequestOptions = bulkUpdateCustomizations(payload);
1187
- const getUrl = (context) => {
1188
- const { url } = getRequestOptions(context);
1189
- return url;
1190
- };
1191
- return {
1192
- getUrl,
1193
- httpMethod: "POST",
1194
- path: "/v3/bulk/customizations/update",
1195
- pathParams: {},
1196
- __requestType: null,
1197
- __originalRequestType: null,
1198
- __responseType: null,
1199
- __originalResponseType: null
1200
- };
1201
- }
1202
- // Annotate the CommonJS export names for ESM import in node:
1203
- 0 && (module.exports = {
1204
- ChoiceSortStrategyOriginal,
1205
- ChoiceTypeOriginal,
1206
- CustomizationRenderTypeOriginal,
1207
- CustomizationTypeOriginal,
1208
- RequestedFieldsOriginal,
1209
- SortOrderOriginal,
1210
- WebhookIdentityTypeOriginal,
1211
- addCustomizationChoices,
1212
- bulkAddCustomizationChoices,
1213
- bulkCreateCustomizations,
1214
- bulkUpdateCustomizations,
1215
- countCustomizations,
1216
- createCustomization,
1217
- deleteCustomization,
1218
- getCustomization,
1219
- queryCustomizations,
1220
- removeCustomizationChoices,
1221
- reorderCustomizationChoices,
1222
- setCustomizationChoices,
1223
- updateCustomization,
1224
- updateCustomizationChoices
1225
- });
1226
- //# sourceMappingURL=meta.js.map