@wix/auto_sdk_restaurants_item-modifier-groups 1.0.69 → 1.0.70

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,7 +1,9 @@
1
1
  "use strict";
2
+ var __create = Object.create;
2
3
  var __defProp = Object.defineProperty;
3
4
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
5
  var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __getProtoOf = Object.getPrototypeOf;
5
7
  var __hasOwnProp = Object.prototype.hasOwnProperty;
6
8
  var __export = (target, all) => {
7
9
  for (var name in all)
@@ -15,6 +17,14 @@ var __copyProps = (to, from, except, desc) => {
15
17
  }
16
18
  return to;
17
19
  };
20
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
25
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
+ mod
27
+ ));
18
28
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
29
 
20
30
  // index.typings.ts
@@ -506,6 +516,740 @@ function bulkDeleteModifierGroups(payload) {
506
516
 
507
517
  // src/restaurants-menus-v1-item-modifier-group-item-modifier-groups.universal.ts
508
518
  var import_transform_paths2 = require("@wix/sdk-runtime/transformations/transform-paths");
519
+
520
+ // src/restaurants-menus-v1-item-modifier-group-item-modifier-groups.schemas.ts
521
+ var z = __toESM(require("zod"));
522
+ var CreateModifierGroupRequest = z.object({
523
+ modifierGroup: z.object({
524
+ _id: z.string().describe("Modifier group ID.").regex(
525
+ /^[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}$/,
526
+ "Must be a valid GUID"
527
+ ).optional().nullable(),
528
+ revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
529
+ "Revision number, which increments by 1 each time the modifier group is updated. To prevent conflicting changes, the current revision must be passed when updating the modifier group. Ignored when creating a modifier group."
530
+ ).optional().nullable(),
531
+ _createdDate: z.date().describe("Date and time the modifier group was created.").optional().nullable(),
532
+ _updatedDate: z.date().describe("Date and time the modifier group was updated.").optional().nullable(),
533
+ name: z.string().describe("Modifier group name.").min(1).max(100),
534
+ modifiers: z.array(
535
+ z.object({
536
+ _id: z.string().describe("Item modifier ID.").regex(
537
+ /^[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}$/,
538
+ "Must be a valid GUID"
539
+ ).optional(),
540
+ preSelected: z.boolean().describe(
541
+ "Whether the item modifier is pre-selected.\nDefault: `false`."
542
+ ).optional().nullable(),
543
+ additionalChargeInfo: z.object({
544
+ additionalCharge: z.string().describe(
545
+ "Additional charge for the item modifier. A value of `0` means the item modifier is free."
546
+ ).optional().nullable()
547
+ }).describe("Item modifier price details.").optional()
548
+ })
549
+ ).min(0).max(500).optional(),
550
+ rule: z.object({
551
+ required: z.boolean().describe(
552
+ "Whether the items from the modifier group must be selected."
553
+ ).optional().nullable(),
554
+ minSelections: z.number().int().describe(
555
+ "Minimum number of item modifiers a site visitor must select. The value must be lower or equal to the available item modifiers in the group.\nDefault: `0`."
556
+ ).min(0).max(25).optional().nullable(),
557
+ maxSelections: z.number().int().describe(
558
+ "Maximum number of item modifiers a site visitor may select. Must be greater than or equal to the value of `minSelections`."
559
+ ).min(0).max(25).optional().nullable()
560
+ }).describe("Modifier group details.").optional(),
561
+ extendedFields: z.object({
562
+ namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
563
+ "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)."
564
+ ).optional()
565
+ }).describe("Extended fields.").optional(),
566
+ businessLocationIds: z.array(z.string()).max(100).optional()
567
+ }).describe("Modifier group details.")
568
+ });
569
+ var CreateModifierGroupResponse = z.object({
570
+ _id: z.string().describe("Modifier group ID.").regex(
571
+ /^[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}$/,
572
+ "Must be a valid GUID"
573
+ ).optional().nullable(),
574
+ revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
575
+ "Revision number, which increments by 1 each time the modifier group is updated. To prevent conflicting changes, the current revision must be passed when updating the modifier group. Ignored when creating a modifier group."
576
+ ).optional().nullable(),
577
+ _createdDate: z.date().describe("Date and time the modifier group was created.").optional().nullable(),
578
+ _updatedDate: z.date().describe("Date and time the modifier group was updated.").optional().nullable(),
579
+ name: z.string().describe("Modifier group name.").min(1).max(100).optional().nullable(),
580
+ modifiers: z.array(
581
+ z.object({
582
+ _id: z.string().describe("Item modifier ID.").regex(
583
+ /^[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}$/,
584
+ "Must be a valid GUID"
585
+ ).optional(),
586
+ preSelected: z.boolean().describe(
587
+ "Whether the item modifier is pre-selected.\nDefault: `false`."
588
+ ).optional().nullable(),
589
+ additionalChargeInfo: z.object({
590
+ additionalCharge: z.string().describe(
591
+ "Additional charge for the item modifier. A value of `0` means the item modifier is free."
592
+ ).optional().nullable()
593
+ }).describe("Item modifier price details.").optional()
594
+ })
595
+ ).min(0).max(500).optional(),
596
+ rule: z.object({
597
+ required: z.boolean().describe("Whether the items from the modifier group must be selected.").optional().nullable(),
598
+ minSelections: z.number().int().describe(
599
+ "Minimum number of item modifiers a site visitor must select. The value must be lower or equal to the available item modifiers in the group.\nDefault: `0`."
600
+ ).min(0).max(25).optional().nullable(),
601
+ maxSelections: z.number().int().describe(
602
+ "Maximum number of item modifiers a site visitor may select. Must be greater than or equal to the value of `minSelections`."
603
+ ).min(0).max(25).optional().nullable()
604
+ }).describe("Modifier group details.").optional(),
605
+ extendedFields: z.object({
606
+ namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
607
+ "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)."
608
+ ).optional()
609
+ }).describe("Extended fields.").optional(),
610
+ businessLocationIds: z.array(z.string()).max(100).optional()
611
+ });
612
+ var GetModifierGroupRequest = z.object({
613
+ modifierGroupId: z.string().describe("Modifier group ID.").regex(
614
+ /^[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}$/,
615
+ "Must be a valid GUID"
616
+ )
617
+ });
618
+ var GetModifierGroupResponse = z.object({
619
+ _id: z.string().describe("Modifier group ID.").regex(
620
+ /^[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}$/,
621
+ "Must be a valid GUID"
622
+ ).optional().nullable(),
623
+ revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
624
+ "Revision number, which increments by 1 each time the modifier group is updated. To prevent conflicting changes, the current revision must be passed when updating the modifier group. Ignored when creating a modifier group."
625
+ ).optional().nullable(),
626
+ _createdDate: z.date().describe("Date and time the modifier group was created.").optional().nullable(),
627
+ _updatedDate: z.date().describe("Date and time the modifier group was updated.").optional().nullable(),
628
+ name: z.string().describe("Modifier group name.").min(1).max(100).optional().nullable(),
629
+ modifiers: z.array(
630
+ z.object({
631
+ _id: z.string().describe("Item modifier ID.").regex(
632
+ /^[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}$/,
633
+ "Must be a valid GUID"
634
+ ).optional(),
635
+ preSelected: z.boolean().describe(
636
+ "Whether the item modifier is pre-selected.\nDefault: `false`."
637
+ ).optional().nullable(),
638
+ additionalChargeInfo: z.object({
639
+ additionalCharge: z.string().describe(
640
+ "Additional charge for the item modifier. A value of `0` means the item modifier is free."
641
+ ).optional().nullable()
642
+ }).describe("Item modifier price details.").optional()
643
+ })
644
+ ).min(0).max(500).optional(),
645
+ rule: z.object({
646
+ required: z.boolean().describe("Whether the items from the modifier group must be selected.").optional().nullable(),
647
+ minSelections: z.number().int().describe(
648
+ "Minimum number of item modifiers a site visitor must select. The value must be lower or equal to the available item modifiers in the group.\nDefault: `0`."
649
+ ).min(0).max(25).optional().nullable(),
650
+ maxSelections: z.number().int().describe(
651
+ "Maximum number of item modifiers a site visitor may select. Must be greater than or equal to the value of `minSelections`."
652
+ ).min(0).max(25).optional().nullable()
653
+ }).describe("Modifier group details.").optional(),
654
+ extendedFields: z.object({
655
+ namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
656
+ "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)."
657
+ ).optional()
658
+ }).describe("Extended fields.").optional(),
659
+ businessLocationIds: z.array(z.string()).max(100).optional()
660
+ });
661
+ var ListModifierGroupsRequest = z.object({
662
+ options: z.object({
663
+ modifierGroupIds: z.array(z.string()).max(500).optional(),
664
+ paging: z.object({
665
+ limit: z.number().int().describe("Number of items to load.").min(0).max(500).optional().nullable(),
666
+ cursor: z.string().describe(
667
+ "Pointer to the next or previous page in the list of results.\n\nYou can get the relevant cursor token\nfrom the `pagingMetadata` object in the previous call's response.\nNot relevant for the first request."
668
+ ).optional().nullable()
669
+ }).describe("The metadata of the paginated results.").optional()
670
+ }).optional()
671
+ });
672
+ var ListModifierGroupsResponse = z.object({
673
+ modifierGroups: z.array(
674
+ z.object({
675
+ _id: z.string().describe("Modifier group ID.").regex(
676
+ /^[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}$/,
677
+ "Must be a valid GUID"
678
+ ).optional().nullable(),
679
+ revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
680
+ "Revision number, which increments by 1 each time the modifier group is updated. To prevent conflicting changes, the current revision must be passed when updating the modifier group. Ignored when creating a modifier group."
681
+ ).optional().nullable(),
682
+ _createdDate: z.date().describe("Date and time the modifier group was created.").optional().nullable(),
683
+ _updatedDate: z.date().describe("Date and time the modifier group was updated.").optional().nullable(),
684
+ name: z.string().describe("Modifier group name.").min(1).max(100).optional().nullable(),
685
+ modifiers: z.array(
686
+ z.object({
687
+ _id: z.string().describe("Item modifier ID.").regex(
688
+ /^[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}$/,
689
+ "Must be a valid GUID"
690
+ ).optional(),
691
+ preSelected: z.boolean().describe(
692
+ "Whether the item modifier is pre-selected.\nDefault: `false`."
693
+ ).optional().nullable(),
694
+ additionalChargeInfo: z.object({
695
+ additionalCharge: z.string().describe(
696
+ "Additional charge for the item modifier. A value of `0` means the item modifier is free."
697
+ ).optional().nullable()
698
+ }).describe("Item modifier price details.").optional()
699
+ })
700
+ ).min(0).max(500).optional(),
701
+ rule: z.object({
702
+ required: z.boolean().describe(
703
+ "Whether the items from the modifier group must be selected."
704
+ ).optional().nullable(),
705
+ minSelections: z.number().int().describe(
706
+ "Minimum number of item modifiers a site visitor must select. The value must be lower or equal to the available item modifiers in the group.\nDefault: `0`."
707
+ ).min(0).max(25).optional().nullable(),
708
+ maxSelections: z.number().int().describe(
709
+ "Maximum number of item modifiers a site visitor may select. Must be greater than or equal to the value of `minSelections`."
710
+ ).min(0).max(25).optional().nullable()
711
+ }).describe("Modifier group details.").optional(),
712
+ extendedFields: z.object({
713
+ namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
714
+ "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)."
715
+ ).optional()
716
+ }).describe("Extended fields.").optional(),
717
+ businessLocationIds: z.array(z.string()).max(100).optional()
718
+ })
719
+ ).optional(),
720
+ metadata: z.object({
721
+ count: z.number().int().describe("Number of items returned in the response.").optional().nullable(),
722
+ cursors: z.object({
723
+ next: z.string().describe("Cursor pointing to next page in the list of results.").optional().nullable(),
724
+ prev: z.string().describe(
725
+ "Cursor pointing to previous page in the list of results."
726
+ ).optional().nullable()
727
+ }).describe("Offset that was requested.").optional(),
728
+ hasNext: z.boolean().describe(
729
+ "Indicates if there are more results after the current page.\nIf `true`, another page of results can be retrieved.\nIf `false`, this is the last page."
730
+ ).optional().nullable()
731
+ }).describe("The metadata of the paginated results.").optional()
732
+ });
733
+ var QueryModifierGroupsRequest = z.object({
734
+ query: z.object({
735
+ filter: z.object({
736
+ _id: z.object({
737
+ $eq: z.string(),
738
+ $in: z.array(z.string()),
739
+ $ne: z.string(),
740
+ $nin: z.array(z.string())
741
+ }).partial().strict().optional(),
742
+ _createdDate: z.object({
743
+ $eq: z.string(),
744
+ $gt: z.string(),
745
+ $gte: z.string(),
746
+ $lt: z.string(),
747
+ $lte: z.string(),
748
+ $ne: z.string()
749
+ }).partial().strict().optional(),
750
+ _updatedDate: z.object({
751
+ $eq: z.string(),
752
+ $gt: z.string(),
753
+ $gte: z.string(),
754
+ $lt: z.string(),
755
+ $lte: z.string(),
756
+ $ne: z.string()
757
+ }).partial().strict().optional(),
758
+ "modifiers._id": z.object({
759
+ $hasSome: z.array(z.string()),
760
+ $in: z.array(z.string()),
761
+ $nin: z.array(z.string())
762
+ }).partial().strict().optional(),
763
+ "modifiers.preSelected": z.object({ $eq: z.boolean(), $ne: z.boolean() }).partial().strict().optional(),
764
+ "rule.minSelections": z.object({ $eq: z.number(), $ne: z.number() }).partial().strict().optional(),
765
+ "rule.maxSelections": z.object({ $eq: z.number(), $ne: z.number() }).partial().strict().optional(),
766
+ modifiers: z.object({ $exists: z.boolean() }).partial().strict().optional(),
767
+ "rule.required": z.object({
768
+ $eq: z.boolean(),
769
+ $in: z.array(z.boolean()),
770
+ $ne: z.boolean(),
771
+ $nin: z.array(z.boolean())
772
+ }).partial().strict().optional(),
773
+ rule: z.object({ $exists: z.boolean() }).partial().strict().optional(),
774
+ name: z.object({
775
+ $eq: z.string(),
776
+ $in: z.array(z.string()),
777
+ $ne: z.string(),
778
+ $nin: z.array(z.string()),
779
+ $startsWith: z.string()
780
+ }).partial().strict().optional(),
781
+ $and: z.array(z.any()).optional(),
782
+ $or: z.array(z.any()).optional(),
783
+ $not: z.any().optional()
784
+ }).strict().optional(),
785
+ sort: z.array(z.object({})).optional()
786
+ }).catchall(z.any()).describe("Query options.")
787
+ });
788
+ var QueryModifierGroupsResponse = z.object({
789
+ modifierGroups: z.array(
790
+ z.object({
791
+ _id: z.string().describe("Modifier group ID.").regex(
792
+ /^[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}$/,
793
+ "Must be a valid GUID"
794
+ ).optional().nullable(),
795
+ revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
796
+ "Revision number, which increments by 1 each time the modifier group is updated. To prevent conflicting changes, the current revision must be passed when updating the modifier group. Ignored when creating a modifier group."
797
+ ).optional().nullable(),
798
+ _createdDate: z.date().describe("Date and time the modifier group was created.").optional().nullable(),
799
+ _updatedDate: z.date().describe("Date and time the modifier group was updated.").optional().nullable(),
800
+ name: z.string().describe("Modifier group name.").min(1).max(100).optional().nullable(),
801
+ modifiers: z.array(
802
+ z.object({
803
+ _id: z.string().describe("Item modifier ID.").regex(
804
+ /^[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}$/,
805
+ "Must be a valid GUID"
806
+ ).optional(),
807
+ preSelected: z.boolean().describe(
808
+ "Whether the item modifier is pre-selected.\nDefault: `false`."
809
+ ).optional().nullable(),
810
+ additionalChargeInfo: z.object({
811
+ additionalCharge: z.string().describe(
812
+ "Additional charge for the item modifier. A value of `0` means the item modifier is free."
813
+ ).optional().nullable()
814
+ }).describe("Item modifier price details.").optional()
815
+ })
816
+ ).min(0).max(500).optional(),
817
+ rule: z.object({
818
+ required: z.boolean().describe(
819
+ "Whether the items from the modifier group must be selected."
820
+ ).optional().nullable(),
821
+ minSelections: z.number().int().describe(
822
+ "Minimum number of item modifiers a site visitor must select. The value must be lower or equal to the available item modifiers in the group.\nDefault: `0`."
823
+ ).min(0).max(25).optional().nullable(),
824
+ maxSelections: z.number().int().describe(
825
+ "Maximum number of item modifiers a site visitor may select. Must be greater than or equal to the value of `minSelections`."
826
+ ).min(0).max(25).optional().nullable()
827
+ }).describe("Modifier group details.").optional(),
828
+ extendedFields: z.object({
829
+ namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
830
+ "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)."
831
+ ).optional()
832
+ }).describe("Extended fields.").optional(),
833
+ businessLocationIds: z.array(z.string()).max(100).optional()
834
+ })
835
+ ).optional(),
836
+ pagingMetadata: z.object({
837
+ count: z.number().int().describe("Number of items returned in the response.").optional().nullable(),
838
+ cursors: z.object({
839
+ next: z.string().describe("Cursor pointing to next page in the list of results.").optional().nullable(),
840
+ prev: z.string().describe(
841
+ "Cursor pointing to previous page in the list of results."
842
+ ).optional().nullable()
843
+ }).describe("Offset that was requested.").optional(),
844
+ hasNext: z.boolean().describe(
845
+ "Indicates if there are more results after the current page.\nIf `true`, another page of results can be retrieved.\nIf `false`, this is the last page."
846
+ ).optional().nullable()
847
+ }).describe("Metadata of the paginated results.").optional()
848
+ });
849
+ var CountModifierGroupsRequest = z.object({
850
+ options: z.object({
851
+ filter: z.record(z.string(), z.any()).describe("Filter for counting modifier groups.").optional().nullable()
852
+ }).optional()
853
+ });
854
+ var CountModifierGroupsResponse = z.object({
855
+ count: z.number().int().describe("Counted modifier groups.").optional()
856
+ });
857
+ var UpdateModifierGroupRequest = z.object({
858
+ _id: z.string().describe("Modifier group ID.").regex(
859
+ /^[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}$/,
860
+ "Must be a valid GUID"
861
+ ),
862
+ modifierGroup: z.object({
863
+ _id: z.string().describe("Modifier group ID.").regex(
864
+ /^[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}$/,
865
+ "Must be a valid GUID"
866
+ ).optional().nullable(),
867
+ revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
868
+ "Revision number, which increments by 1 each time the modifier group is updated. To prevent conflicting changes, the current revision must be passed when updating the modifier group. Ignored when creating a modifier group."
869
+ ),
870
+ _createdDate: z.date().describe("Date and time the modifier group was created.").optional().nullable(),
871
+ _updatedDate: z.date().describe("Date and time the modifier group was updated.").optional().nullable(),
872
+ name: z.string().describe("Modifier group name.").min(1).max(100).optional().nullable(),
873
+ modifiers: z.array(
874
+ z.object({
875
+ _id: z.string().describe("Item modifier ID.").regex(
876
+ /^[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}$/,
877
+ "Must be a valid GUID"
878
+ ).optional(),
879
+ preSelected: z.boolean().describe(
880
+ "Whether the item modifier is pre-selected.\nDefault: `false`."
881
+ ).optional().nullable(),
882
+ additionalChargeInfo: z.object({
883
+ additionalCharge: z.string().describe(
884
+ "Additional charge for the item modifier. A value of `0` means the item modifier is free."
885
+ ).optional().nullable()
886
+ }).describe("Item modifier price details.").optional()
887
+ })
888
+ ).min(0).max(500).optional(),
889
+ rule: z.object({
890
+ required: z.boolean().describe(
891
+ "Whether the items from the modifier group must be selected."
892
+ ).optional().nullable(),
893
+ minSelections: z.number().int().describe(
894
+ "Minimum number of item modifiers a site visitor must select. The value must be lower or equal to the available item modifiers in the group.\nDefault: `0`."
895
+ ).min(0).max(25).optional().nullable(),
896
+ maxSelections: z.number().int().describe(
897
+ "Maximum number of item modifiers a site visitor may select. Must be greater than or equal to the value of `minSelections`."
898
+ ).min(0).max(25).optional().nullable()
899
+ }).describe("Modifier group details.").optional(),
900
+ extendedFields: z.object({
901
+ namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
902
+ "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)."
903
+ ).optional()
904
+ }).describe("Extended fields.").optional(),
905
+ businessLocationIds: z.array(z.string()).max(100).optional()
906
+ }).describe("Modifier group to update.")
907
+ });
908
+ var UpdateModifierGroupResponse = z.object({
909
+ _id: z.string().describe("Modifier group ID.").regex(
910
+ /^[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}$/,
911
+ "Must be a valid GUID"
912
+ ).optional().nullable(),
913
+ revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
914
+ "Revision number, which increments by 1 each time the modifier group is updated. To prevent conflicting changes, the current revision must be passed when updating the modifier group. Ignored when creating a modifier group."
915
+ ).optional().nullable(),
916
+ _createdDate: z.date().describe("Date and time the modifier group was created.").optional().nullable(),
917
+ _updatedDate: z.date().describe("Date and time the modifier group was updated.").optional().nullable(),
918
+ name: z.string().describe("Modifier group name.").min(1).max(100).optional().nullable(),
919
+ modifiers: z.array(
920
+ z.object({
921
+ _id: z.string().describe("Item modifier ID.").regex(
922
+ /^[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}$/,
923
+ "Must be a valid GUID"
924
+ ).optional(),
925
+ preSelected: z.boolean().describe(
926
+ "Whether the item modifier is pre-selected.\nDefault: `false`."
927
+ ).optional().nullable(),
928
+ additionalChargeInfo: z.object({
929
+ additionalCharge: z.string().describe(
930
+ "Additional charge for the item modifier. A value of `0` means the item modifier is free."
931
+ ).optional().nullable()
932
+ }).describe("Item modifier price details.").optional()
933
+ })
934
+ ).min(0).max(500).optional(),
935
+ rule: z.object({
936
+ required: z.boolean().describe("Whether the items from the modifier group must be selected.").optional().nullable(),
937
+ minSelections: z.number().int().describe(
938
+ "Minimum number of item modifiers a site visitor must select. The value must be lower or equal to the available item modifiers in the group.\nDefault: `0`."
939
+ ).min(0).max(25).optional().nullable(),
940
+ maxSelections: z.number().int().describe(
941
+ "Maximum number of item modifiers a site visitor may select. Must be greater than or equal to the value of `minSelections`."
942
+ ).min(0).max(25).optional().nullable()
943
+ }).describe("Modifier group details.").optional(),
944
+ extendedFields: z.object({
945
+ namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
946
+ "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)."
947
+ ).optional()
948
+ }).describe("Extended fields.").optional(),
949
+ businessLocationIds: z.array(z.string()).max(100).optional()
950
+ });
951
+ var DeleteModifierGroupRequest = z.object({
952
+ modifierGroupId: z.string().describe("Modifier group ID.").regex(
953
+ /^[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}$/,
954
+ "Must be a valid GUID"
955
+ )
956
+ });
957
+ var DeleteModifierGroupResponse = z.object({});
958
+ var BulkCreateModifierGroupsRequest = z.object({
959
+ modifierGroups: z.array(
960
+ z.object({
961
+ _id: z.string().describe("Modifier group ID.").regex(
962
+ /^[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}$/,
963
+ "Must be a valid GUID"
964
+ ).optional().nullable(),
965
+ revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
966
+ "Revision number, which increments by 1 each time the modifier group is updated. To prevent conflicting changes, the current revision must be passed when updating the modifier group. Ignored when creating a modifier group."
967
+ ).optional().nullable(),
968
+ _createdDate: z.date().describe("Date and time the modifier group was created.").optional().nullable(),
969
+ _updatedDate: z.date().describe("Date and time the modifier group was updated.").optional().nullable(),
970
+ name: z.string().describe("Modifier group name.").min(1).max(100).optional().nullable(),
971
+ modifiers: z.array(
972
+ z.object({
973
+ _id: z.string().describe("Item modifier ID.").regex(
974
+ /^[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}$/,
975
+ "Must be a valid GUID"
976
+ ).optional(),
977
+ preSelected: z.boolean().describe(
978
+ "Whether the item modifier is pre-selected.\nDefault: `false`."
979
+ ).optional().nullable(),
980
+ additionalChargeInfo: z.object({
981
+ additionalCharge: z.string().describe(
982
+ "Additional charge for the item modifier. A value of `0` means the item modifier is free."
983
+ ).optional().nullable()
984
+ }).describe("Item modifier price details.").optional()
985
+ })
986
+ ).min(0).max(500).optional(),
987
+ rule: z.object({
988
+ required: z.boolean().describe(
989
+ "Whether the items from the modifier group must be selected."
990
+ ).optional().nullable(),
991
+ minSelections: z.number().int().describe(
992
+ "Minimum number of item modifiers a site visitor must select. The value must be lower or equal to the available item modifiers in the group.\nDefault: `0`."
993
+ ).min(0).max(25).optional().nullable(),
994
+ maxSelections: z.number().int().describe(
995
+ "Maximum number of item modifiers a site visitor may select. Must be greater than or equal to the value of `minSelections`."
996
+ ).min(0).max(25).optional().nullable()
997
+ }).describe("Modifier group details.").optional(),
998
+ extendedFields: z.object({
999
+ namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
1000
+ "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)."
1001
+ ).optional()
1002
+ }).describe("Extended fields.").optional(),
1003
+ businessLocationIds: z.array(z.string()).max(100).optional()
1004
+ })
1005
+ ).max(100),
1006
+ options: z.object({
1007
+ returnEntity: z.boolean().describe(
1008
+ "Whether to receive the created modifier groups in the response."
1009
+ ).optional()
1010
+ }).optional()
1011
+ });
1012
+ var BulkCreateModifierGroupsResponse = z.object({
1013
+ results: z.array(
1014
+ z.object({
1015
+ itemMetadata: z.object({
1016
+ _id: z.string().describe(
1017
+ "Item ID. Should always be available, unless it's impossible (for example, when failing to create an item)."
1018
+ ).optional().nullable(),
1019
+ originalIndex: z.number().int().describe(
1020
+ "Index of the item within the request array. Allows for correlation between request and response items."
1021
+ ).optional(),
1022
+ success: z.boolean().describe(
1023
+ "Whether the requested action was successful for this item. When `false`, the `error` field is populated."
1024
+ ).optional(),
1025
+ error: z.object({
1026
+ code: z.string().describe("Error code.").optional(),
1027
+ description: z.string().describe("Description of the error.").optional(),
1028
+ data: z.record(z.string(), z.any()).describe("Data related to the error.").optional().nullable()
1029
+ }).describe("Details about the error in case of failure.").optional()
1030
+ }).describe("Metadata for group modifier creation.").optional(),
1031
+ modifierGroup: z.object({
1032
+ _id: z.string().describe("Modifier group ID.").regex(
1033
+ /^[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}$/,
1034
+ "Must be a valid GUID"
1035
+ ).optional().nullable(),
1036
+ revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
1037
+ "Revision number, which increments by 1 each time the modifier group is updated. To prevent conflicting changes, the current revision must be passed when updating the modifier group. Ignored when creating a modifier group."
1038
+ ).optional().nullable(),
1039
+ _createdDate: z.date().describe("Date and time the modifier group was created.").optional().nullable(),
1040
+ _updatedDate: z.date().describe("Date and time the modifier group was updated.").optional().nullable(),
1041
+ name: z.string().describe("Modifier group name.").min(1).max(100).optional().nullable(),
1042
+ modifiers: z.array(
1043
+ z.object({
1044
+ _id: z.string().describe("Item modifier ID.").regex(
1045
+ /^[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}$/,
1046
+ "Must be a valid GUID"
1047
+ ).optional(),
1048
+ preSelected: z.boolean().describe(
1049
+ "Whether the item modifier is pre-selected.\nDefault: `false`."
1050
+ ).optional().nullable(),
1051
+ additionalChargeInfo: z.object({
1052
+ additionalCharge: z.string().describe(
1053
+ "Additional charge for the item modifier. A value of `0` means the item modifier is free."
1054
+ ).optional().nullable()
1055
+ }).describe("Item modifier price details.").optional()
1056
+ })
1057
+ ).min(0).max(500).optional(),
1058
+ rule: z.object({
1059
+ required: z.boolean().describe(
1060
+ "Whether the items from the modifier group must be selected."
1061
+ ).optional().nullable(),
1062
+ minSelections: z.number().int().describe(
1063
+ "Minimum number of item modifiers a site visitor must select. The value must be lower or equal to the available item modifiers in the group.\nDefault: `0`."
1064
+ ).min(0).max(25).optional().nullable(),
1065
+ maxSelections: z.number().int().describe(
1066
+ "Maximum number of item modifiers a site visitor may select. Must be greater than or equal to the value of `minSelections`."
1067
+ ).min(0).max(25).optional().nullable()
1068
+ }).describe("Modifier group details.").optional(),
1069
+ extendedFields: z.object({
1070
+ namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
1071
+ "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)."
1072
+ ).optional()
1073
+ }).describe("Extended fields.").optional(),
1074
+ businessLocationIds: z.array(z.string()).max(100).optional()
1075
+ }).describe("Created modifier group.").optional()
1076
+ })
1077
+ ).optional(),
1078
+ bulkActionMetadata: z.object({
1079
+ totalSuccesses: z.number().int().describe("Number of items that were successfully processed.").optional(),
1080
+ totalFailures: z.number().int().describe("Number of items that couldn't be processed.").optional(),
1081
+ undetailedFailures: z.number().int().describe(
1082
+ "Number of failures without details because detailed failure threshold was exceeded."
1083
+ ).optional()
1084
+ }).describe("Metadata for the API call.").optional()
1085
+ });
1086
+ var BulkUpdateModifierGroupsRequest = z.object({
1087
+ modifierGroups: z.array(
1088
+ z.object({
1089
+ modifierGroup: z.object({
1090
+ _id: z.string().describe("Modifier group ID.").regex(
1091
+ /^[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}$/,
1092
+ "Must be a valid GUID"
1093
+ ),
1094
+ revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
1095
+ "Revision number, which increments by 1 each time the modifier group is updated. To prevent conflicting changes, the current revision must be passed when updating the modifier group. Ignored when creating a modifier group."
1096
+ ),
1097
+ _createdDate: z.date().describe("Date and time the modifier group was created.").optional().nullable(),
1098
+ _updatedDate: z.date().describe("Date and time the modifier group was updated.").optional().nullable(),
1099
+ name: z.string().describe("Modifier group name.").min(1).max(100).optional().nullable(),
1100
+ modifiers: z.array(
1101
+ z.object({
1102
+ _id: z.string().describe("Item modifier ID.").regex(
1103
+ /^[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}$/,
1104
+ "Must be a valid GUID"
1105
+ ).optional(),
1106
+ preSelected: z.boolean().describe(
1107
+ "Whether the item modifier is pre-selected.\nDefault: `false`."
1108
+ ).optional().nullable(),
1109
+ additionalChargeInfo: z.object({
1110
+ additionalCharge: z.string().describe(
1111
+ "Additional charge for the item modifier. A value of `0` means the item modifier is free."
1112
+ ).optional().nullable()
1113
+ }).describe("Item modifier price details.").optional()
1114
+ })
1115
+ ).min(0).max(500).optional(),
1116
+ rule: z.object({
1117
+ required: z.boolean().describe(
1118
+ "Whether the items from the modifier group must be selected."
1119
+ ).optional().nullable(),
1120
+ minSelections: z.number().int().describe(
1121
+ "Minimum number of item modifiers a site visitor must select. The value must be lower or equal to the available item modifiers in the group.\nDefault: `0`."
1122
+ ).min(0).max(25).optional().nullable(),
1123
+ maxSelections: z.number().int().describe(
1124
+ "Maximum number of item modifiers a site visitor may select. Must be greater than or equal to the value of `minSelections`."
1125
+ ).min(0).max(25).optional().nullable()
1126
+ }).describe("Modifier group details.").optional(),
1127
+ extendedFields: z.object({
1128
+ namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
1129
+ "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)."
1130
+ ).optional()
1131
+ }).describe("Extended fields.").optional(),
1132
+ businessLocationIds: z.array(z.string()).max(100).optional()
1133
+ }).describe("Modifier group to update.").optional(),
1134
+ mask: z.array(z.string()).optional()
1135
+ })
1136
+ ).min(1).max(100),
1137
+ options: z.object({
1138
+ returnEntity: z.boolean().describe(
1139
+ "Whether to receive the updated modifier groups in the response."
1140
+ ).optional()
1141
+ }).optional()
1142
+ });
1143
+ var BulkUpdateModifierGroupsResponse = z.object({
1144
+ results: z.array(
1145
+ z.object({
1146
+ itemMetadata: z.object({
1147
+ _id: z.string().describe(
1148
+ "Item ID. Should always be available, unless it's impossible (for example, when failing to create an item)."
1149
+ ).optional().nullable(),
1150
+ originalIndex: z.number().int().describe(
1151
+ "Index of the item within the request array. Allows for correlation between request and response items."
1152
+ ).optional(),
1153
+ success: z.boolean().describe(
1154
+ "Whether the requested action was successful for this item. When `false`, the `error` field is populated."
1155
+ ).optional(),
1156
+ error: z.object({
1157
+ code: z.string().describe("Error code.").optional(),
1158
+ description: z.string().describe("Description of the error.").optional(),
1159
+ data: z.record(z.string(), z.any()).describe("Data related to the error.").optional().nullable()
1160
+ }).describe("Details about the error in case of failure.").optional()
1161
+ }).describe("Metadata for group modifier update.").optional(),
1162
+ modifierGroup: z.object({
1163
+ _id: z.string().describe("Modifier group ID.").regex(
1164
+ /^[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}$/,
1165
+ "Must be a valid GUID"
1166
+ ).optional().nullable(),
1167
+ revision: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe(
1168
+ "Revision number, which increments by 1 each time the modifier group is updated. To prevent conflicting changes, the current revision must be passed when updating the modifier group. Ignored when creating a modifier group."
1169
+ ).optional().nullable(),
1170
+ _createdDate: z.date().describe("Date and time the modifier group was created.").optional().nullable(),
1171
+ _updatedDate: z.date().describe("Date and time the modifier group was updated.").optional().nullable(),
1172
+ name: z.string().describe("Modifier group name.").min(1).max(100).optional().nullable(),
1173
+ modifiers: z.array(
1174
+ z.object({
1175
+ _id: z.string().describe("Item modifier ID.").regex(
1176
+ /^[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}$/,
1177
+ "Must be a valid GUID"
1178
+ ).optional(),
1179
+ preSelected: z.boolean().describe(
1180
+ "Whether the item modifier is pre-selected.\nDefault: `false`."
1181
+ ).optional().nullable(),
1182
+ additionalChargeInfo: z.object({
1183
+ additionalCharge: z.string().describe(
1184
+ "Additional charge for the item modifier. A value of `0` means the item modifier is free."
1185
+ ).optional().nullable()
1186
+ }).describe("Item modifier price details.").optional()
1187
+ })
1188
+ ).min(0).max(500).optional(),
1189
+ rule: z.object({
1190
+ required: z.boolean().describe(
1191
+ "Whether the items from the modifier group must be selected."
1192
+ ).optional().nullable(),
1193
+ minSelections: z.number().int().describe(
1194
+ "Minimum number of item modifiers a site visitor must select. The value must be lower or equal to the available item modifiers in the group.\nDefault: `0`."
1195
+ ).min(0).max(25).optional().nullable(),
1196
+ maxSelections: z.number().int().describe(
1197
+ "Maximum number of item modifiers a site visitor may select. Must be greater than or equal to the value of `minSelections`."
1198
+ ).min(0).max(25).optional().nullable()
1199
+ }).describe("Modifier group details.").optional(),
1200
+ extendedFields: z.object({
1201
+ namespaces: z.record(z.string(), z.record(z.string(), z.any())).describe(
1202
+ "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)."
1203
+ ).optional()
1204
+ }).describe("Extended fields.").optional(),
1205
+ businessLocationIds: z.array(z.string()).max(100).optional()
1206
+ }).describe(
1207
+ "Updated modifier group. Only returned if `returnEntity` is set to `true`."
1208
+ ).optional()
1209
+ })
1210
+ ).min(1).max(100).optional(),
1211
+ bulkActionMetadata: z.object({
1212
+ totalSuccesses: z.number().int().describe("Number of items that were successfully processed.").optional(),
1213
+ totalFailures: z.number().int().describe("Number of items that couldn't be processed.").optional(),
1214
+ undetailedFailures: z.number().int().describe(
1215
+ "Number of failures without details because detailed failure threshold was exceeded."
1216
+ ).optional()
1217
+ }).describe("Metadata for the API call.").optional()
1218
+ });
1219
+ var BulkDeleteModifierGroupsRequest = z.object({
1220
+ ids: z.array(z.string()).max(200)
1221
+ });
1222
+ var BulkDeleteModifierGroupsResponse = z.object({
1223
+ results: z.array(
1224
+ z.object({
1225
+ itemMetadata: z.object({
1226
+ _id: z.string().describe(
1227
+ "Item ID. Should always be available, unless it's impossible (for example, when failing to create an item)."
1228
+ ).optional().nullable(),
1229
+ originalIndex: z.number().int().describe(
1230
+ "Index of the item within the request array. Allows for correlation between request and response items."
1231
+ ).optional(),
1232
+ success: z.boolean().describe(
1233
+ "Whether the requested action was successful for this item. When `false`, the `error` field is populated."
1234
+ ).optional(),
1235
+ error: z.object({
1236
+ code: z.string().describe("Error code.").optional(),
1237
+ description: z.string().describe("Description of the error.").optional(),
1238
+ data: z.record(z.string(), z.any()).describe("Data related to the error.").optional().nullable()
1239
+ }).describe("Details about the error in case of failure.").optional()
1240
+ }).describe("Metadata for group modifier deletion.").optional()
1241
+ })
1242
+ ).optional(),
1243
+ bulkActionMetadata: z.object({
1244
+ totalSuccesses: z.number().int().describe("Number of items that were successfully processed.").optional(),
1245
+ totalFailures: z.number().int().describe("Number of items that couldn't be processed.").optional(),
1246
+ undetailedFailures: z.number().int().describe(
1247
+ "Number of failures without details because detailed failure threshold was exceeded."
1248
+ ).optional()
1249
+ }).describe("Metadata for the API call.").optional()
1250
+ });
1251
+
1252
+ // src/restaurants-menus-v1-item-modifier-group-item-modifier-groups.universal.ts
509
1253
  var import_query_builder_utils = require("@wix/sdk-runtime/query-builder-utils");
510
1254
  var SortOrder = /* @__PURE__ */ ((SortOrder2) => {
511
1255
  SortOrder2["ASC"] = "ASC";
@@ -521,7 +1265,10 @@ var WebhookIdentityType = /* @__PURE__ */ ((WebhookIdentityType2) => {
521
1265
  return WebhookIdentityType2;
522
1266
  })(WebhookIdentityType || {});
523
1267
  async function createModifierGroup2(modifierGroup) {
524
- const { httpClient, sideEffects } = arguments[1];
1268
+ const { httpClient, sideEffects, validateRequestSchema } = arguments[1];
1269
+ if (validateRequestSchema) {
1270
+ CreateModifierGroupRequest.parse({ modifierGroup });
1271
+ }
525
1272
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
526
1273
  modifierGroup
527
1274
  });
@@ -548,7 +1295,10 @@ async function createModifierGroup2(modifierGroup) {
548
1295
  }
549
1296
  }
550
1297
  async function getModifierGroup2(modifierGroupId) {
551
- const { httpClient, sideEffects } = arguments[1];
1298
+ const { httpClient, sideEffects, validateRequestSchema } = arguments[1];
1299
+ if (validateRequestSchema) {
1300
+ GetModifierGroupRequest.parse({ modifierGroupId });
1301
+ }
552
1302
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
553
1303
  modifierGroupId
554
1304
  });
@@ -573,7 +1323,10 @@ async function getModifierGroup2(modifierGroupId) {
573
1323
  }
574
1324
  }
575
1325
  async function listModifierGroups2(options) {
576
- const { httpClient, sideEffects } = arguments[1];
1326
+ const { httpClient, sideEffects, validateRequestSchema } = arguments[1];
1327
+ if (validateRequestSchema) {
1328
+ ListModifierGroupsRequest.parse({ options });
1329
+ }
577
1330
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
578
1331
  modifierGroupIds: options?.modifierGroupIds,
579
1332
  paging: options?.paging
@@ -651,7 +1404,10 @@ function queryModifierGroups2() {
651
1404
  });
652
1405
  }
653
1406
  async function typedQueryModifierGroups(query) {
654
- const { httpClient, sideEffects } = arguments[1];
1407
+ const { httpClient, sideEffects, validateRequestSchema } = arguments[1];
1408
+ if (validateRequestSchema) {
1409
+ QueryModifierGroupsRequest.parse({ query });
1410
+ }
655
1411
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ query });
656
1412
  const reqOpts = queryModifierGroups(
657
1413
  payload
@@ -681,7 +1437,10 @@ var utils = {
681
1437
  }
682
1438
  };
683
1439
  async function countModifierGroups2(options) {
684
- const { httpClient, sideEffects } = arguments[1];
1440
+ const { httpClient, sideEffects, validateRequestSchema } = arguments[1];
1441
+ if (validateRequestSchema) {
1442
+ CountModifierGroupsRequest.parse({ options });
1443
+ }
685
1444
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
686
1445
  filter: options?.filter
687
1446
  });
@@ -708,7 +1467,10 @@ async function countModifierGroups2(options) {
708
1467
  }
709
1468
  }
710
1469
  async function updateModifierGroup2(_id, modifierGroup) {
711
- const { httpClient, sideEffects } = arguments[2];
1470
+ const { httpClient, sideEffects, validateRequestSchema } = arguments[2];
1471
+ if (validateRequestSchema) {
1472
+ UpdateModifierGroupRequest.parse({ _id, modifierGroup });
1473
+ }
712
1474
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
713
1475
  modifierGroup: { ...modifierGroup, id: _id }
714
1476
  });
@@ -735,7 +1497,10 @@ async function updateModifierGroup2(_id, modifierGroup) {
735
1497
  }
736
1498
  }
737
1499
  async function deleteModifierGroup2(modifierGroupId) {
738
- const { httpClient, sideEffects } = arguments[1];
1500
+ const { httpClient, sideEffects, validateRequestSchema } = arguments[1];
1501
+ if (validateRequestSchema) {
1502
+ DeleteModifierGroupRequest.parse({ modifierGroupId });
1503
+ }
739
1504
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
740
1505
  modifierGroupId
741
1506
  });
@@ -761,7 +1526,10 @@ async function deleteModifierGroup2(modifierGroupId) {
761
1526
  }
762
1527
  }
763
1528
  async function bulkCreateModifierGroups2(modifierGroups, options) {
764
- const { httpClient, sideEffects } = arguments[2];
1529
+ const { httpClient, sideEffects, validateRequestSchema } = arguments[2];
1530
+ if (validateRequestSchema) {
1531
+ BulkCreateModifierGroupsRequest.parse({ modifierGroups, options });
1532
+ }
765
1533
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
766
1534
  modifierGroups,
767
1535
  returnEntity: options?.returnEntity
@@ -792,7 +1560,10 @@ async function bulkCreateModifierGroups2(modifierGroups, options) {
792
1560
  }
793
1561
  }
794
1562
  async function bulkUpdateModifierGroups2(modifierGroups, options) {
795
- const { httpClient, sideEffects } = arguments[2];
1563
+ const { httpClient, sideEffects, validateRequestSchema } = arguments[2];
1564
+ if (validateRequestSchema) {
1565
+ BulkUpdateModifierGroupsRequest.parse({ modifierGroups, options });
1566
+ }
796
1567
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
797
1568
  modifierGroups,
798
1569
  returnEntity: options?.returnEntity
@@ -823,7 +1594,10 @@ async function bulkUpdateModifierGroups2(modifierGroups, options) {
823
1594
  }
824
1595
  }
825
1596
  async function bulkDeleteModifierGroups2(ids) {
826
- const { httpClient, sideEffects } = arguments[1];
1597
+ const { httpClient, sideEffects, validateRequestSchema } = arguments[1];
1598
+ if (validateRequestSchema) {
1599
+ BulkDeleteModifierGroupsRequest.parse({ ids });
1600
+ }
827
1601
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ ids });
828
1602
  const reqOpts = bulkDeleteModifierGroups(
829
1603
  payload