@walkeros/core 4.1.0-next-1778668930820 → 4.1.0

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.
package/dist/dev.d.mts CHANGED
@@ -191,14 +191,6 @@ declare const BaseContextConfig: z.ZodObject<{
191
191
  config: z.ZodOptional<z.ZodUnknown>;
192
192
  env: z.ZodOptional<z.ZodUnknown>;
193
193
  }, z.core.$strip>;
194
- /**
195
- * BatchConfig - Batch processing configuration
196
- * Used in: Mapping.Rule
197
- */
198
- declare const BatchConfig: z.ZodObject<{
199
- batch: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
200
- batched: z.ZodOptional<z.ZodOptional<z.ZodUnknown>>;
201
- }, z.core.$strip>;
202
194
  /**
203
195
  * ProcessingControlConfig - Processing control flags
204
196
  * Used in: Mapping.Rule
@@ -583,7 +575,11 @@ declare const RuleSchema: z.ZodObject<{
583
575
  condition: z.ZodOptional<z.ZodString>;
584
576
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
585
577
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
586
- batch: z.ZodOptional<z.ZodNumber>;
578
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
579
+ wait: z.ZodOptional<z.ZodNumber>;
580
+ size: z.ZodOptional<z.ZodNumber>;
581
+ age: z.ZodOptional<z.ZodNumber>;
582
+ }, z.core.$strip>]>>;
587
583
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
588
584
  ignore: z.ZodOptional<z.ZodBoolean>;
589
585
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -615,7 +611,11 @@ declare const RulesSchema: z.ZodRecord<z.ZodString, z.ZodOptional<z.ZodRecord<z.
615
611
  condition: z.ZodOptional<z.ZodString>;
616
612
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
617
613
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
618
- batch: z.ZodOptional<z.ZodNumber>;
614
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
615
+ wait: z.ZodOptional<z.ZodNumber>;
616
+ size: z.ZodOptional<z.ZodNumber>;
617
+ age: z.ZodOptional<z.ZodNumber>;
618
+ }, z.core.$strip>]>>;
619
619
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
620
620
  ignore: z.ZodOptional<z.ZodBoolean>;
621
621
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -626,7 +626,11 @@ declare const RulesSchema: z.ZodRecord<z.ZodString, z.ZodOptional<z.ZodRecord<z.
626
626
  condition: z.ZodOptional<z.ZodString>;
627
627
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
628
628
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
629
- batch: z.ZodOptional<z.ZodNumber>;
629
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
630
+ wait: z.ZodOptional<z.ZodNumber>;
631
+ size: z.ZodOptional<z.ZodNumber>;
632
+ age: z.ZodOptional<z.ZodNumber>;
633
+ }, z.core.$strip>]>>;
630
634
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
631
635
  ignore: z.ZodOptional<z.ZodBoolean>;
632
636
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -652,7 +656,11 @@ declare const ConfigSchema$6: z.ZodObject<{
652
656
  condition: z.ZodOptional<z.ZodString>;
653
657
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
654
658
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
655
- batch: z.ZodOptional<z.ZodNumber>;
659
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
660
+ wait: z.ZodOptional<z.ZodNumber>;
661
+ size: z.ZodOptional<z.ZodNumber>;
662
+ age: z.ZodOptional<z.ZodNumber>;
663
+ }, z.core.$strip>]>>;
656
664
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
657
665
  ignore: z.ZodOptional<z.ZodBoolean>;
658
666
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -663,7 +671,11 @@ declare const ConfigSchema$6: z.ZodObject<{
663
671
  condition: z.ZodOptional<z.ZodString>;
664
672
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
665
673
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
666
- batch: z.ZodOptional<z.ZodNumber>;
674
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
675
+ wait: z.ZodOptional<z.ZodNumber>;
676
+ size: z.ZodOptional<z.ZodNumber>;
677
+ age: z.ZodOptional<z.ZodNumber>;
678
+ }, z.core.$strip>]>>;
667
679
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
668
680
  ignore: z.ZodOptional<z.ZodBoolean>;
669
681
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -682,7 +694,11 @@ declare const ResultSchema$1: z.ZodObject<{
682
694
  condition: z.ZodOptional<z.ZodString>;
683
695
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
684
696
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
685
- batch: z.ZodOptional<z.ZodNumber>;
697
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
698
+ wait: z.ZodOptional<z.ZodNumber>;
699
+ size: z.ZodOptional<z.ZodNumber>;
700
+ age: z.ZodOptional<z.ZodNumber>;
701
+ }, z.core.$strip>]>>;
686
702
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
687
703
  ignore: z.ZodOptional<z.ZodBoolean>;
688
704
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -767,7 +783,11 @@ declare const ConfigSchema$5: z.ZodObject<{
767
783
  condition: z.ZodOptional<z.ZodString>;
768
784
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
769
785
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
770
- batch: z.ZodOptional<z.ZodNumber>;
786
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
787
+ wait: z.ZodOptional<z.ZodNumber>;
788
+ size: z.ZodOptional<z.ZodNumber>;
789
+ age: z.ZodOptional<z.ZodNumber>;
790
+ }, z.core.$strip>]>>;
771
791
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
772
792
  ignore: z.ZodOptional<z.ZodBoolean>;
773
793
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -778,7 +798,11 @@ declare const ConfigSchema$5: z.ZodObject<{
778
798
  condition: z.ZodOptional<z.ZodString>;
779
799
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
780
800
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
781
- batch: z.ZodOptional<z.ZodNumber>;
801
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
802
+ wait: z.ZodOptional<z.ZodNumber>;
803
+ size: z.ZodOptional<z.ZodNumber>;
804
+ age: z.ZodOptional<z.ZodNumber>;
805
+ }, z.core.$strip>]>>;
782
806
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
783
807
  ignore: z.ZodOptional<z.ZodBoolean>;
784
808
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -811,6 +835,13 @@ declare const ConfigSchema$5: z.ZodObject<{
811
835
  }, z.core.$strip>>;
812
836
  disabled: z.ZodOptional<z.ZodBoolean>;
813
837
  mock: z.ZodOptional<z.ZodUnknown>;
838
+ queueMax: z.ZodOptional<z.ZodNumber>;
839
+ dlqMax: z.ZodOptional<z.ZodNumber>;
840
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
841
+ wait: z.ZodOptional<z.ZodNumber>;
842
+ size: z.ZodOptional<z.ZodNumber>;
843
+ age: z.ZodOptional<z.ZodNumber>;
844
+ }, z.core.$strip>]>>;
814
845
  }, z.core.$strip>;
815
846
  /**
816
847
  * PartialConfig - Config with all fields optional
@@ -835,7 +866,11 @@ declare const PartialConfigSchema$3: z.ZodObject<{
835
866
  condition: z.ZodOptional<z.ZodString>;
836
867
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
837
868
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
838
- batch: z.ZodOptional<z.ZodNumber>;
869
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
870
+ wait: z.ZodOptional<z.ZodNumber>;
871
+ size: z.ZodOptional<z.ZodNumber>;
872
+ age: z.ZodOptional<z.ZodNumber>;
873
+ }, z.core.$strip>]>>;
839
874
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
840
875
  ignore: z.ZodOptional<z.ZodBoolean>;
841
876
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -846,7 +881,11 @@ declare const PartialConfigSchema$3: z.ZodObject<{
846
881
  condition: z.ZodOptional<z.ZodString>;
847
882
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
848
883
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
849
- batch: z.ZodOptional<z.ZodNumber>;
884
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
885
+ wait: z.ZodOptional<z.ZodNumber>;
886
+ size: z.ZodOptional<z.ZodNumber>;
887
+ age: z.ZodOptional<z.ZodNumber>;
888
+ }, z.core.$strip>]>>;
850
889
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
851
890
  ignore: z.ZodOptional<z.ZodBoolean>;
852
891
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -879,6 +918,13 @@ declare const PartialConfigSchema$3: z.ZodObject<{
879
918
  }, z.core.$strip>>>;
880
919
  disabled: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
881
920
  mock: z.ZodOptional<z.ZodOptional<z.ZodUnknown>>;
921
+ queueMax: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
922
+ dlqMax: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
923
+ batch: z.ZodOptional<z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
924
+ wait: z.ZodOptional<z.ZodNumber>;
925
+ size: z.ZodOptional<z.ZodNumber>;
926
+ age: z.ZodOptional<z.ZodNumber>;
927
+ }, z.core.$strip>]>>>;
882
928
  }, z.core.$strip>;
883
929
  /**
884
930
  * Policy - Processing policy rules
@@ -911,7 +957,11 @@ declare const ContextSchema: z.ZodObject<{
911
957
  condition: z.ZodOptional<z.ZodString>;
912
958
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
913
959
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
914
- batch: z.ZodOptional<z.ZodNumber>;
960
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
961
+ wait: z.ZodOptional<z.ZodNumber>;
962
+ size: z.ZodOptional<z.ZodNumber>;
963
+ age: z.ZodOptional<z.ZodNumber>;
964
+ }, z.core.$strip>]>>;
915
965
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
916
966
  ignore: z.ZodOptional<z.ZodBoolean>;
917
967
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -922,7 +972,11 @@ declare const ContextSchema: z.ZodObject<{
922
972
  condition: z.ZodOptional<z.ZodString>;
923
973
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
924
974
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
925
- batch: z.ZodOptional<z.ZodNumber>;
975
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
976
+ wait: z.ZodOptional<z.ZodNumber>;
977
+ size: z.ZodOptional<z.ZodNumber>;
978
+ age: z.ZodOptional<z.ZodNumber>;
979
+ }, z.core.$strip>]>>;
926
980
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
927
981
  ignore: z.ZodOptional<z.ZodBoolean>;
928
982
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -955,6 +1009,13 @@ declare const ContextSchema: z.ZodObject<{
955
1009
  }, z.core.$strip>>;
956
1010
  disabled: z.ZodOptional<z.ZodBoolean>;
957
1011
  mock: z.ZodOptional<z.ZodUnknown>;
1012
+ queueMax: z.ZodOptional<z.ZodNumber>;
1013
+ dlqMax: z.ZodOptional<z.ZodNumber>;
1014
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1015
+ wait: z.ZodOptional<z.ZodNumber>;
1016
+ size: z.ZodOptional<z.ZodNumber>;
1017
+ age: z.ZodOptional<z.ZodNumber>;
1018
+ }, z.core.$strip>]>>;
958
1019
  }, z.core.$strip>;
959
1020
  data: z.ZodOptional<z.ZodUnion<readonly [z.ZodUnknown, z.ZodArray<z.ZodUnknown>]>>;
960
1021
  env: z.ZodUnknown;
@@ -981,7 +1042,11 @@ declare const PushContextSchema$1: z.ZodObject<{
981
1042
  condition: z.ZodOptional<z.ZodString>;
982
1043
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
983
1044
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
984
- batch: z.ZodOptional<z.ZodNumber>;
1045
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1046
+ wait: z.ZodOptional<z.ZodNumber>;
1047
+ size: z.ZodOptional<z.ZodNumber>;
1048
+ age: z.ZodOptional<z.ZodNumber>;
1049
+ }, z.core.$strip>]>>;
985
1050
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
986
1051
  ignore: z.ZodOptional<z.ZodBoolean>;
987
1052
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -992,7 +1057,11 @@ declare const PushContextSchema$1: z.ZodObject<{
992
1057
  condition: z.ZodOptional<z.ZodString>;
993
1058
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
994
1059
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
995
- batch: z.ZodOptional<z.ZodNumber>;
1060
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1061
+ wait: z.ZodOptional<z.ZodNumber>;
1062
+ size: z.ZodOptional<z.ZodNumber>;
1063
+ age: z.ZodOptional<z.ZodNumber>;
1064
+ }, z.core.$strip>]>>;
996
1065
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
997
1066
  ignore: z.ZodOptional<z.ZodBoolean>;
998
1067
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1025,6 +1094,13 @@ declare const PushContextSchema$1: z.ZodObject<{
1025
1094
  }, z.core.$strip>>;
1026
1095
  disabled: z.ZodOptional<z.ZodBoolean>;
1027
1096
  mock: z.ZodOptional<z.ZodUnknown>;
1097
+ queueMax: z.ZodOptional<z.ZodNumber>;
1098
+ dlqMax: z.ZodOptional<z.ZodNumber>;
1099
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1100
+ wait: z.ZodOptional<z.ZodNumber>;
1101
+ size: z.ZodOptional<z.ZodNumber>;
1102
+ age: z.ZodOptional<z.ZodNumber>;
1103
+ }, z.core.$strip>]>>;
1028
1104
  }, z.core.$strip>;
1029
1105
  data: z.ZodOptional<z.ZodUnion<readonly [z.ZodUnknown, z.ZodArray<z.ZodUnknown>]>>;
1030
1106
  env: z.ZodUnknown;
@@ -1035,7 +1111,11 @@ declare const PushContextSchema$1: z.ZodObject<{
1035
1111
  condition: z.ZodOptional<z.ZodString>;
1036
1112
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1037
1113
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1038
- batch: z.ZodOptional<z.ZodNumber>;
1114
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1115
+ wait: z.ZodOptional<z.ZodNumber>;
1116
+ size: z.ZodOptional<z.ZodNumber>;
1117
+ age: z.ZodOptional<z.ZodNumber>;
1118
+ }, z.core.$strip>]>>;
1039
1119
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1040
1120
  ignore: z.ZodOptional<z.ZodBoolean>;
1041
1121
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1063,7 +1143,11 @@ declare const PushBatchContextSchema: z.ZodObject<{
1063
1143
  condition: z.ZodOptional<z.ZodString>;
1064
1144
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1065
1145
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1066
- batch: z.ZodOptional<z.ZodNumber>;
1146
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1147
+ wait: z.ZodOptional<z.ZodNumber>;
1148
+ size: z.ZodOptional<z.ZodNumber>;
1149
+ age: z.ZodOptional<z.ZodNumber>;
1150
+ }, z.core.$strip>]>>;
1067
1151
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1068
1152
  ignore: z.ZodOptional<z.ZodBoolean>;
1069
1153
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1074,7 +1158,11 @@ declare const PushBatchContextSchema: z.ZodObject<{
1074
1158
  condition: z.ZodOptional<z.ZodString>;
1075
1159
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1076
1160
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1077
- batch: z.ZodOptional<z.ZodNumber>;
1161
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1162
+ wait: z.ZodOptional<z.ZodNumber>;
1163
+ size: z.ZodOptional<z.ZodNumber>;
1164
+ age: z.ZodOptional<z.ZodNumber>;
1165
+ }, z.core.$strip>]>>;
1078
1166
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1079
1167
  ignore: z.ZodOptional<z.ZodBoolean>;
1080
1168
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1107,6 +1195,13 @@ declare const PushBatchContextSchema: z.ZodObject<{
1107
1195
  }, z.core.$strip>>;
1108
1196
  disabled: z.ZodOptional<z.ZodBoolean>;
1109
1197
  mock: z.ZodOptional<z.ZodUnknown>;
1198
+ queueMax: z.ZodOptional<z.ZodNumber>;
1199
+ dlqMax: z.ZodOptional<z.ZodNumber>;
1200
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1201
+ wait: z.ZodOptional<z.ZodNumber>;
1202
+ size: z.ZodOptional<z.ZodNumber>;
1203
+ age: z.ZodOptional<z.ZodNumber>;
1204
+ }, z.core.$strip>]>>;
1110
1205
  }, z.core.$strip>;
1111
1206
  data: z.ZodOptional<z.ZodUnion<readonly [z.ZodUnknown, z.ZodArray<z.ZodUnknown>]>>;
1112
1207
  env: z.ZodUnknown;
@@ -1117,7 +1212,11 @@ declare const PushBatchContextSchema: z.ZodObject<{
1117
1212
  condition: z.ZodOptional<z.ZodString>;
1118
1213
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1119
1214
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1120
- batch: z.ZodOptional<z.ZodNumber>;
1215
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1216
+ wait: z.ZodOptional<z.ZodNumber>;
1217
+ size: z.ZodOptional<z.ZodNumber>;
1218
+ age: z.ZodOptional<z.ZodNumber>;
1219
+ }, z.core.$strip>]>>;
1121
1220
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1122
1221
  ignore: z.ZodOptional<z.ZodBoolean>;
1123
1222
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1185,7 +1284,11 @@ declare const PushEventSchema: z.ZodObject<{
1185
1284
  condition: z.ZodOptional<z.ZodString>;
1186
1285
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1187
1286
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1188
- batch: z.ZodOptional<z.ZodNumber>;
1287
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1288
+ wait: z.ZodOptional<z.ZodNumber>;
1289
+ size: z.ZodOptional<z.ZodNumber>;
1290
+ age: z.ZodOptional<z.ZodNumber>;
1291
+ }, z.core.$strip>]>>;
1189
1292
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1190
1293
  ignore: z.ZodOptional<z.ZodBoolean>;
1191
1294
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1253,7 +1356,11 @@ declare const PushEventsSchema: z.ZodArray<z.ZodObject<{
1253
1356
  condition: z.ZodOptional<z.ZodString>;
1254
1357
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1255
1358
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1256
- batch: z.ZodOptional<z.ZodNumber>;
1359
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1360
+ wait: z.ZodOptional<z.ZodNumber>;
1361
+ size: z.ZodOptional<z.ZodNumber>;
1362
+ age: z.ZodOptional<z.ZodNumber>;
1363
+ }, z.core.$strip>]>>;
1257
1364
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1258
1365
  ignore: z.ZodOptional<z.ZodBoolean>;
1259
1366
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1324,7 +1431,11 @@ declare const BatchSchema: z.ZodObject<{
1324
1431
  condition: z.ZodOptional<z.ZodString>;
1325
1432
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1326
1433
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1327
- batch: z.ZodOptional<z.ZodNumber>;
1434
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1435
+ wait: z.ZodOptional<z.ZodNumber>;
1436
+ size: z.ZodOptional<z.ZodNumber>;
1437
+ age: z.ZodOptional<z.ZodNumber>;
1438
+ }, z.core.$strip>]>>;
1328
1439
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1329
1440
  ignore: z.ZodOptional<z.ZodBoolean>;
1330
1441
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1359,7 +1470,11 @@ declare const InstanceSchema$2: z.ZodObject<{
1359
1470
  condition: z.ZodOptional<z.ZodString>;
1360
1471
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1361
1472
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1362
- batch: z.ZodOptional<z.ZodNumber>;
1473
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1474
+ wait: z.ZodOptional<z.ZodNumber>;
1475
+ size: z.ZodOptional<z.ZodNumber>;
1476
+ age: z.ZodOptional<z.ZodNumber>;
1477
+ }, z.core.$strip>]>>;
1363
1478
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1364
1479
  ignore: z.ZodOptional<z.ZodBoolean>;
1365
1480
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1370,7 +1485,11 @@ declare const InstanceSchema$2: z.ZodObject<{
1370
1485
  condition: z.ZodOptional<z.ZodString>;
1371
1486
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1372
1487
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1373
- batch: z.ZodOptional<z.ZodNumber>;
1488
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1489
+ wait: z.ZodOptional<z.ZodNumber>;
1490
+ size: z.ZodOptional<z.ZodNumber>;
1491
+ age: z.ZodOptional<z.ZodNumber>;
1492
+ }, z.core.$strip>]>>;
1374
1493
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1375
1494
  ignore: z.ZodOptional<z.ZodBoolean>;
1376
1495
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1403,6 +1522,13 @@ declare const InstanceSchema$2: z.ZodObject<{
1403
1522
  }, z.core.$strip>>;
1404
1523
  disabled: z.ZodOptional<z.ZodBoolean>;
1405
1524
  mock: z.ZodOptional<z.ZodUnknown>;
1525
+ queueMax: z.ZodOptional<z.ZodNumber>;
1526
+ dlqMax: z.ZodOptional<z.ZodNumber>;
1527
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1528
+ wait: z.ZodOptional<z.ZodNumber>;
1529
+ size: z.ZodOptional<z.ZodNumber>;
1530
+ age: z.ZodOptional<z.ZodNumber>;
1531
+ }, z.core.$strip>]>>;
1406
1532
  }, z.core.$strip>;
1407
1533
  queue: z.ZodOptional<z.ZodArray<z.ZodObject<{
1408
1534
  name: z.ZodString;
@@ -1535,7 +1661,11 @@ declare const InitSchema$1: z.ZodObject<{
1535
1661
  condition: z.ZodOptional<z.ZodString>;
1536
1662
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1537
1663
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1538
- batch: z.ZodOptional<z.ZodNumber>;
1664
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1665
+ wait: z.ZodOptional<z.ZodNumber>;
1666
+ size: z.ZodOptional<z.ZodNumber>;
1667
+ age: z.ZodOptional<z.ZodNumber>;
1668
+ }, z.core.$strip>]>>;
1539
1669
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1540
1670
  ignore: z.ZodOptional<z.ZodBoolean>;
1541
1671
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1546,7 +1676,11 @@ declare const InitSchema$1: z.ZodObject<{
1546
1676
  condition: z.ZodOptional<z.ZodString>;
1547
1677
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1548
1678
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1549
- batch: z.ZodOptional<z.ZodNumber>;
1679
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1680
+ wait: z.ZodOptional<z.ZodNumber>;
1681
+ size: z.ZodOptional<z.ZodNumber>;
1682
+ age: z.ZodOptional<z.ZodNumber>;
1683
+ }, z.core.$strip>]>>;
1550
1684
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1551
1685
  ignore: z.ZodOptional<z.ZodBoolean>;
1552
1686
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1579,6 +1713,13 @@ declare const InitSchema$1: z.ZodObject<{
1579
1713
  }, z.core.$strip>>;
1580
1714
  disabled: z.ZodOptional<z.ZodBoolean>;
1581
1715
  mock: z.ZodOptional<z.ZodUnknown>;
1716
+ queueMax: z.ZodOptional<z.ZodNumber>;
1717
+ dlqMax: z.ZodOptional<z.ZodNumber>;
1718
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1719
+ wait: z.ZodOptional<z.ZodNumber>;
1720
+ size: z.ZodOptional<z.ZodNumber>;
1721
+ age: z.ZodOptional<z.ZodNumber>;
1722
+ }, z.core.$strip>]>>;
1582
1723
  }, z.core.$strip>;
1583
1724
  queue: z.ZodOptional<z.ZodArray<z.ZodObject<{
1584
1725
  name: z.ZodString;
@@ -1705,7 +1846,11 @@ declare const InitSchema$1: z.ZodObject<{
1705
1846
  condition: z.ZodOptional<z.ZodString>;
1706
1847
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1707
1848
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1708
- batch: z.ZodOptional<z.ZodNumber>;
1849
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1850
+ wait: z.ZodOptional<z.ZodNumber>;
1851
+ size: z.ZodOptional<z.ZodNumber>;
1852
+ age: z.ZodOptional<z.ZodNumber>;
1853
+ }, z.core.$strip>]>>;
1709
1854
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1710
1855
  ignore: z.ZodOptional<z.ZodBoolean>;
1711
1856
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1716,7 +1861,11 @@ declare const InitSchema$1: z.ZodObject<{
1716
1861
  condition: z.ZodOptional<z.ZodString>;
1717
1862
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1718
1863
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1719
- batch: z.ZodOptional<z.ZodNumber>;
1864
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1865
+ wait: z.ZodOptional<z.ZodNumber>;
1866
+ size: z.ZodOptional<z.ZodNumber>;
1867
+ age: z.ZodOptional<z.ZodNumber>;
1868
+ }, z.core.$strip>]>>;
1720
1869
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1721
1870
  ignore: z.ZodOptional<z.ZodBoolean>;
1722
1871
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1749,6 +1898,13 @@ declare const InitSchema$1: z.ZodObject<{
1749
1898
  }, z.core.$strip>>>;
1750
1899
  disabled: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
1751
1900
  mock: z.ZodOptional<z.ZodOptional<z.ZodUnknown>>;
1901
+ queueMax: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
1902
+ dlqMax: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
1903
+ batch: z.ZodOptional<z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1904
+ wait: z.ZodOptional<z.ZodNumber>;
1905
+ size: z.ZodOptional<z.ZodNumber>;
1906
+ age: z.ZodOptional<z.ZodNumber>;
1907
+ }, z.core.$strip>]>>>;
1752
1908
  }, z.core.$strip>>;
1753
1909
  env: z.ZodOptional<z.ZodUnknown>;
1754
1910
  }, z.core.$strip>;
@@ -1773,7 +1929,11 @@ declare const InitDestinationsSchema: z.ZodRecord<z.ZodString, z.ZodObject<{
1773
1929
  condition: z.ZodOptional<z.ZodString>;
1774
1930
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1775
1931
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1776
- batch: z.ZodOptional<z.ZodNumber>;
1932
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1933
+ wait: z.ZodOptional<z.ZodNumber>;
1934
+ size: z.ZodOptional<z.ZodNumber>;
1935
+ age: z.ZodOptional<z.ZodNumber>;
1936
+ }, z.core.$strip>]>>;
1777
1937
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1778
1938
  ignore: z.ZodOptional<z.ZodBoolean>;
1779
1939
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1784,7 +1944,11 @@ declare const InitDestinationsSchema: z.ZodRecord<z.ZodString, z.ZodObject<{
1784
1944
  condition: z.ZodOptional<z.ZodString>;
1785
1945
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1786
1946
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1787
- batch: z.ZodOptional<z.ZodNumber>;
1947
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1948
+ wait: z.ZodOptional<z.ZodNumber>;
1949
+ size: z.ZodOptional<z.ZodNumber>;
1950
+ age: z.ZodOptional<z.ZodNumber>;
1951
+ }, z.core.$strip>]>>;
1788
1952
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1789
1953
  ignore: z.ZodOptional<z.ZodBoolean>;
1790
1954
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1817,6 +1981,13 @@ declare const InitDestinationsSchema: z.ZodRecord<z.ZodString, z.ZodObject<{
1817
1981
  }, z.core.$strip>>;
1818
1982
  disabled: z.ZodOptional<z.ZodBoolean>;
1819
1983
  mock: z.ZodOptional<z.ZodUnknown>;
1984
+ queueMax: z.ZodOptional<z.ZodNumber>;
1985
+ dlqMax: z.ZodOptional<z.ZodNumber>;
1986
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
1987
+ wait: z.ZodOptional<z.ZodNumber>;
1988
+ size: z.ZodOptional<z.ZodNumber>;
1989
+ age: z.ZodOptional<z.ZodNumber>;
1990
+ }, z.core.$strip>]>>;
1820
1991
  }, z.core.$strip>;
1821
1992
  queue: z.ZodOptional<z.ZodArray<z.ZodObject<{
1822
1993
  name: z.ZodString;
@@ -1943,7 +2114,11 @@ declare const InitDestinationsSchema: z.ZodRecord<z.ZodString, z.ZodObject<{
1943
2114
  condition: z.ZodOptional<z.ZodString>;
1944
2115
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1945
2116
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1946
- batch: z.ZodOptional<z.ZodNumber>;
2117
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
2118
+ wait: z.ZodOptional<z.ZodNumber>;
2119
+ size: z.ZodOptional<z.ZodNumber>;
2120
+ age: z.ZodOptional<z.ZodNumber>;
2121
+ }, z.core.$strip>]>>;
1947
2122
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1948
2123
  ignore: z.ZodOptional<z.ZodBoolean>;
1949
2124
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1954,7 +2129,11 @@ declare const InitDestinationsSchema: z.ZodRecord<z.ZodString, z.ZodObject<{
1954
2129
  condition: z.ZodOptional<z.ZodString>;
1955
2130
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
1956
2131
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
1957
- batch: z.ZodOptional<z.ZodNumber>;
2132
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
2133
+ wait: z.ZodOptional<z.ZodNumber>;
2134
+ size: z.ZodOptional<z.ZodNumber>;
2135
+ age: z.ZodOptional<z.ZodNumber>;
2136
+ }, z.core.$strip>]>>;
1958
2137
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
1959
2138
  ignore: z.ZodOptional<z.ZodBoolean>;
1960
2139
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -1987,6 +2166,13 @@ declare const InitDestinationsSchema: z.ZodRecord<z.ZodString, z.ZodObject<{
1987
2166
  }, z.core.$strip>>>;
1988
2167
  disabled: z.ZodOptional<z.ZodOptional<z.ZodBoolean>>;
1989
2168
  mock: z.ZodOptional<z.ZodOptional<z.ZodUnknown>>;
2169
+ queueMax: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
2170
+ dlqMax: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
2171
+ batch: z.ZodOptional<z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
2172
+ wait: z.ZodOptional<z.ZodNumber>;
2173
+ size: z.ZodOptional<z.ZodNumber>;
2174
+ age: z.ZodOptional<z.ZodNumber>;
2175
+ }, z.core.$strip>]>>>;
1990
2176
  }, z.core.$strip>>;
1991
2177
  env: z.ZodOptional<z.ZodUnknown>;
1992
2178
  }, z.core.$strip>>;
@@ -2010,7 +2196,11 @@ declare const DestinationsSchema$1: z.ZodRecord<z.ZodString, z.ZodObject<{
2010
2196
  condition: z.ZodOptional<z.ZodString>;
2011
2197
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
2012
2198
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
2013
- batch: z.ZodOptional<z.ZodNumber>;
2199
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
2200
+ wait: z.ZodOptional<z.ZodNumber>;
2201
+ size: z.ZodOptional<z.ZodNumber>;
2202
+ age: z.ZodOptional<z.ZodNumber>;
2203
+ }, z.core.$strip>]>>;
2014
2204
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
2015
2205
  ignore: z.ZodOptional<z.ZodBoolean>;
2016
2206
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -2021,7 +2211,11 @@ declare const DestinationsSchema$1: z.ZodRecord<z.ZodString, z.ZodObject<{
2021
2211
  condition: z.ZodOptional<z.ZodString>;
2022
2212
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
2023
2213
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
2024
- batch: z.ZodOptional<z.ZodNumber>;
2214
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
2215
+ wait: z.ZodOptional<z.ZodNumber>;
2216
+ size: z.ZodOptional<z.ZodNumber>;
2217
+ age: z.ZodOptional<z.ZodNumber>;
2218
+ }, z.core.$strip>]>>;
2025
2219
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
2026
2220
  ignore: z.ZodOptional<z.ZodBoolean>;
2027
2221
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -2054,6 +2248,13 @@ declare const DestinationsSchema$1: z.ZodRecord<z.ZodString, z.ZodObject<{
2054
2248
  }, z.core.$strip>>;
2055
2249
  disabled: z.ZodOptional<z.ZodBoolean>;
2056
2250
  mock: z.ZodOptional<z.ZodUnknown>;
2251
+ queueMax: z.ZodOptional<z.ZodNumber>;
2252
+ dlqMax: z.ZodOptional<z.ZodNumber>;
2253
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
2254
+ wait: z.ZodOptional<z.ZodNumber>;
2255
+ size: z.ZodOptional<z.ZodNumber>;
2256
+ age: z.ZodOptional<z.ZodNumber>;
2257
+ }, z.core.$strip>]>>;
2057
2258
  }, z.core.$strip>;
2058
2259
  queue: z.ZodOptional<z.ZodArray<z.ZodObject<{
2059
2260
  name: z.ZodString;
@@ -2410,6 +2611,7 @@ declare const ConfigSchema$4: z.ZodObject<{
2410
2611
  }>]>>;
2411
2612
  handler: z.ZodOptional<z.ZodAny>;
2412
2613
  }, z.core.$strip>>;
2614
+ queueMax: z.ZodOptional<z.ZodNumber>;
2413
2615
  }, z.core.$strip>;
2414
2616
  /**
2415
2617
  * SessionData - Session state management
@@ -2459,6 +2661,7 @@ declare const InitConfigSchema: z.ZodObject<{
2459
2661
  }>]>>;
2460
2662
  handler: z.ZodOptional<z.ZodAny>;
2461
2663
  }, z.core.$strip>>>;
2664
+ queueMax: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
2462
2665
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
2463
2666
  user: z.ZodOptional<z.ZodIntersection<z.ZodRecord<z.ZodString, z.ZodOptional<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>, z.ZodObject<{
2464
2667
  id: z.ZodOptional<z.ZodString>;
@@ -2510,7 +2713,11 @@ declare const PushContextSchema: z.ZodObject<{
2510
2713
  condition: z.ZodOptional<z.ZodString>;
2511
2714
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
2512
2715
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
2513
- batch: z.ZodOptional<z.ZodNumber>;
2716
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
2717
+ wait: z.ZodOptional<z.ZodNumber>;
2718
+ size: z.ZodOptional<z.ZodNumber>;
2719
+ age: z.ZodOptional<z.ZodNumber>;
2720
+ }, z.core.$strip>]>>;
2514
2721
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
2515
2722
  ignore: z.ZodOptional<z.ZodBoolean>;
2516
2723
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -2521,7 +2728,11 @@ declare const PushContextSchema: z.ZodObject<{
2521
2728
  condition: z.ZodOptional<z.ZodString>;
2522
2729
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
2523
2730
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
2524
- batch: z.ZodOptional<z.ZodNumber>;
2731
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
2732
+ wait: z.ZodOptional<z.ZodNumber>;
2733
+ size: z.ZodOptional<z.ZodNumber>;
2734
+ age: z.ZodOptional<z.ZodNumber>;
2735
+ }, z.core.$strip>]>>;
2525
2736
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
2526
2737
  ignore: z.ZodOptional<z.ZodBoolean>;
2527
2738
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -2583,6 +2794,7 @@ declare const InstanceSchema$1: z.ZodObject<{
2583
2794
  }>]>>;
2584
2795
  handler: z.ZodOptional<z.ZodAny>;
2585
2796
  }, z.core.$strip>>;
2797
+ queueMax: z.ZodOptional<z.ZodNumber>;
2586
2798
  }, z.core.$strip>;
2587
2799
  consent: z.ZodRecord<z.ZodString, z.ZodBoolean>;
2588
2800
  custom: z.ZodRecord<z.ZodString, z.ZodOptional<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
@@ -2770,7 +2982,11 @@ declare const ConfigSchema$3: z.ZodObject<{
2770
2982
  condition: z.ZodOptional<z.ZodString>;
2771
2983
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
2772
2984
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
2773
- batch: z.ZodOptional<z.ZodNumber>;
2985
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
2986
+ wait: z.ZodOptional<z.ZodNumber>;
2987
+ size: z.ZodOptional<z.ZodNumber>;
2988
+ age: z.ZodOptional<z.ZodNumber>;
2989
+ }, z.core.$strip>]>>;
2774
2990
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
2775
2991
  ignore: z.ZodOptional<z.ZodBoolean>;
2776
2992
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -2781,7 +2997,11 @@ declare const ConfigSchema$3: z.ZodObject<{
2781
2997
  condition: z.ZodOptional<z.ZodString>;
2782
2998
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
2783
2999
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
2784
- batch: z.ZodOptional<z.ZodNumber>;
3000
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
3001
+ wait: z.ZodOptional<z.ZodNumber>;
3002
+ size: z.ZodOptional<z.ZodNumber>;
3003
+ age: z.ZodOptional<z.ZodNumber>;
3004
+ }, z.core.$strip>]>>;
2785
3005
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
2786
3006
  ignore: z.ZodOptional<z.ZodBoolean>;
2787
3007
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -2829,7 +3049,11 @@ declare const PartialConfigSchema$2: z.ZodObject<{
2829
3049
  condition: z.ZodOptional<z.ZodString>;
2830
3050
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
2831
3051
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
2832
- batch: z.ZodOptional<z.ZodNumber>;
3052
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
3053
+ wait: z.ZodOptional<z.ZodNumber>;
3054
+ size: z.ZodOptional<z.ZodNumber>;
3055
+ age: z.ZodOptional<z.ZodNumber>;
3056
+ }, z.core.$strip>]>>;
2833
3057
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
2834
3058
  ignore: z.ZodOptional<z.ZodBoolean>;
2835
3059
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -2840,7 +3064,11 @@ declare const PartialConfigSchema$2: z.ZodObject<{
2840
3064
  condition: z.ZodOptional<z.ZodString>;
2841
3065
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
2842
3066
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
2843
- batch: z.ZodOptional<z.ZodNumber>;
3067
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
3068
+ wait: z.ZodOptional<z.ZodNumber>;
3069
+ size: z.ZodOptional<z.ZodNumber>;
3070
+ age: z.ZodOptional<z.ZodNumber>;
3071
+ }, z.core.$strip>]>>;
2844
3072
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
2845
3073
  ignore: z.ZodOptional<z.ZodBoolean>;
2846
3074
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -2904,7 +3132,11 @@ declare const InstanceSchema: z.ZodObject<{
2904
3132
  condition: z.ZodOptional<z.ZodString>;
2905
3133
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
2906
3134
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
2907
- batch: z.ZodOptional<z.ZodNumber>;
3135
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
3136
+ wait: z.ZodOptional<z.ZodNumber>;
3137
+ size: z.ZodOptional<z.ZodNumber>;
3138
+ age: z.ZodOptional<z.ZodNumber>;
3139
+ }, z.core.$strip>]>>;
2908
3140
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
2909
3141
  ignore: z.ZodOptional<z.ZodBoolean>;
2910
3142
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -2915,7 +3147,11 @@ declare const InstanceSchema: z.ZodObject<{
2915
3147
  condition: z.ZodOptional<z.ZodString>;
2916
3148
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
2917
3149
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
2918
- batch: z.ZodOptional<z.ZodNumber>;
3150
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
3151
+ wait: z.ZodOptional<z.ZodNumber>;
3152
+ size: z.ZodOptional<z.ZodNumber>;
3153
+ age: z.ZodOptional<z.ZodNumber>;
3154
+ }, z.core.$strip>]>>;
2919
3155
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
2920
3156
  ignore: z.ZodOptional<z.ZodBoolean>;
2921
3157
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -2988,7 +3224,11 @@ declare const InitSourceSchema: z.ZodObject<{
2988
3224
  condition: z.ZodOptional<z.ZodString>;
2989
3225
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
2990
3226
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
2991
- batch: z.ZodOptional<z.ZodNumber>;
3227
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
3228
+ wait: z.ZodOptional<z.ZodNumber>;
3229
+ size: z.ZodOptional<z.ZodNumber>;
3230
+ age: z.ZodOptional<z.ZodNumber>;
3231
+ }, z.core.$strip>]>>;
2992
3232
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
2993
3233
  ignore: z.ZodOptional<z.ZodBoolean>;
2994
3234
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -2999,7 +3239,11 @@ declare const InitSourceSchema: z.ZodObject<{
2999
3239
  condition: z.ZodOptional<z.ZodString>;
3000
3240
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
3001
3241
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
3002
- batch: z.ZodOptional<z.ZodNumber>;
3242
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
3243
+ wait: z.ZodOptional<z.ZodNumber>;
3244
+ size: z.ZodOptional<z.ZodNumber>;
3245
+ age: z.ZodOptional<z.ZodNumber>;
3246
+ }, z.core.$strip>]>>;
3003
3247
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
3004
3248
  ignore: z.ZodOptional<z.ZodBoolean>;
3005
3249
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -3053,7 +3297,11 @@ declare const InitSourcesSchema: z.ZodRecord<z.ZodString, z.ZodObject<{
3053
3297
  condition: z.ZodOptional<z.ZodString>;
3054
3298
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
3055
3299
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
3056
- batch: z.ZodOptional<z.ZodNumber>;
3300
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
3301
+ wait: z.ZodOptional<z.ZodNumber>;
3302
+ size: z.ZodOptional<z.ZodNumber>;
3303
+ age: z.ZodOptional<z.ZodNumber>;
3304
+ }, z.core.$strip>]>>;
3057
3305
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
3058
3306
  ignore: z.ZodOptional<z.ZodBoolean>;
3059
3307
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -3064,7 +3312,11 @@ declare const InitSourcesSchema: z.ZodRecord<z.ZodString, z.ZodObject<{
3064
3312
  condition: z.ZodOptional<z.ZodString>;
3065
3313
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
3066
3314
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
3067
- batch: z.ZodOptional<z.ZodNumber>;
3315
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
3316
+ wait: z.ZodOptional<z.ZodNumber>;
3317
+ size: z.ZodOptional<z.ZodNumber>;
3318
+ age: z.ZodOptional<z.ZodNumber>;
3319
+ }, z.core.$strip>]>>;
3068
3320
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
3069
3321
  ignore: z.ZodOptional<z.ZodBoolean>;
3070
3322
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -3180,7 +3432,11 @@ declare const ConfigSchema$2: z.ZodObject<{
3180
3432
  condition: z.ZodOptional<z.ZodString>;
3181
3433
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
3182
3434
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
3183
- batch: z.ZodOptional<z.ZodNumber>;
3435
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
3436
+ wait: z.ZodOptional<z.ZodNumber>;
3437
+ size: z.ZodOptional<z.ZodNumber>;
3438
+ age: z.ZodOptional<z.ZodNumber>;
3439
+ }, z.core.$strip>]>>;
3184
3440
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
3185
3441
  ignore: z.ZodOptional<z.ZodBoolean>;
3186
3442
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -3191,7 +3447,11 @@ declare const ConfigSchema$2: z.ZodObject<{
3191
3447
  condition: z.ZodOptional<z.ZodString>;
3192
3448
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
3193
3449
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
3194
- batch: z.ZodOptional<z.ZodNumber>;
3450
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
3451
+ wait: z.ZodOptional<z.ZodNumber>;
3452
+ size: z.ZodOptional<z.ZodNumber>;
3453
+ age: z.ZodOptional<z.ZodNumber>;
3454
+ }, z.core.$strip>]>>;
3195
3455
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
3196
3456
  ignore: z.ZodOptional<z.ZodBoolean>;
3197
3457
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -3243,7 +3503,11 @@ declare const PartialConfigSchema$1: z.ZodObject<{
3243
3503
  condition: z.ZodOptional<z.ZodString>;
3244
3504
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
3245
3505
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
3246
- batch: z.ZodOptional<z.ZodNumber>;
3506
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
3507
+ wait: z.ZodOptional<z.ZodNumber>;
3508
+ size: z.ZodOptional<z.ZodNumber>;
3509
+ age: z.ZodOptional<z.ZodNumber>;
3510
+ }, z.core.$strip>]>>;
3247
3511
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
3248
3512
  ignore: z.ZodOptional<z.ZodBoolean>;
3249
3513
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -3254,7 +3518,11 @@ declare const PartialConfigSchema$1: z.ZodObject<{
3254
3518
  condition: z.ZodOptional<z.ZodString>;
3255
3519
  consent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
3256
3520
  policy: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
3257
- batch: z.ZodOptional<z.ZodNumber>;
3521
+ batch: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
3522
+ wait: z.ZodOptional<z.ZodNumber>;
3523
+ size: z.ZodOptional<z.ZodNumber>;
3524
+ age: z.ZodOptional<z.ZodNumber>;
3525
+ }, z.core.$strip>]>>;
3258
3526
  include: z.ZodOptional<z.ZodArray<z.ZodString>>;
3259
3527
  ignore: z.ZodOptional<z.ZodBoolean>;
3260
3528
  silent: z.ZodOptional<z.ZodBoolean>;
@@ -3383,8 +3651,10 @@ declare const BundleSchema: z.ZodObject<{
3383
3651
  * Inline code schema for embedding JavaScript functions in JSON configs.
3384
3652
  *
3385
3653
  * @remarks
3386
- * Enables custom sources, transformers, destinations, and stores without
3387
- * npm packages. The `push` function is required; `type` and `init` are optional.
3654
+ * Object-only inline code block. Enables custom sources, transformers,
3655
+ * destinations, and stores without npm packages. The `push` function is
3656
+ * required; `type` and `init` are optional. To select a named export from
3657
+ * a package, use the step's `import` field instead.
3388
3658
  *
3389
3659
  * @example
3390
3660
  * ```json
@@ -3476,11 +3746,12 @@ declare const ValidateSchema: z.ZodObject<{
3476
3746
  */
3477
3747
  declare const SourceSchema: z.ZodObject<{
3478
3748
  package: z.ZodOptional<z.ZodString>;
3479
- code: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
3749
+ code: z.ZodOptional<z.ZodObject<{
3480
3750
  push: z.ZodString;
3481
3751
  type: z.ZodOptional<z.ZodString>;
3482
3752
  init: z.ZodOptional<z.ZodString>;
3483
- }, z.core.$strip>]>>;
3753
+ }, z.core.$strip>>;
3754
+ import: z.ZodOptional<z.ZodString>;
3484
3755
  config: z.ZodOptional<z.ZodObject<{
3485
3756
  setup: z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodRecord<z.ZodString, z.ZodUnknown>]>>;
3486
3757
  }, z.core.$loose>>;
@@ -3529,11 +3800,12 @@ declare const SourceSchema: z.ZodObject<{
3529
3800
  */
3530
3801
  declare const TransformerSchema: z.ZodObject<{
3531
3802
  package: z.ZodOptional<z.ZodString>;
3532
- code: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
3803
+ code: z.ZodOptional<z.ZodObject<{
3533
3804
  push: z.ZodString;
3534
3805
  type: z.ZodOptional<z.ZodString>;
3535
3806
  init: z.ZodOptional<z.ZodString>;
3536
- }, z.core.$strip>]>>;
3807
+ }, z.core.$strip>>;
3808
+ import: z.ZodOptional<z.ZodString>;
3537
3809
  config: z.ZodOptional<z.ZodUnknown>;
3538
3810
  env: z.ZodOptional<z.ZodUnknown>;
3539
3811
  before: z.ZodOptional<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
@@ -3579,11 +3851,12 @@ declare const TransformerSchema: z.ZodObject<{
3579
3851
  */
3580
3852
  declare const DestinationSchema: z.ZodObject<{
3581
3853
  package: z.ZodOptional<z.ZodString>;
3582
- code: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
3854
+ code: z.ZodOptional<z.ZodObject<{
3583
3855
  push: z.ZodString;
3584
3856
  type: z.ZodOptional<z.ZodString>;
3585
3857
  init: z.ZodOptional<z.ZodString>;
3586
- }, z.core.$strip>]>>;
3858
+ }, z.core.$strip>>;
3859
+ import: z.ZodOptional<z.ZodString>;
3587
3860
  config: z.ZodOptional<z.ZodObject<{
3588
3861
  setup: z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodRecord<z.ZodString, z.ZodUnknown>]>>;
3589
3862
  }, z.core.$loose>>;
@@ -3635,15 +3908,24 @@ declare const DestinationSchema: z.ZodObject<{
3635
3908
  */
3636
3909
  declare const StoreSchema: z.ZodObject<{
3637
3910
  package: z.ZodOptional<z.ZodString>;
3638
- code: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
3911
+ code: z.ZodOptional<z.ZodObject<{
3639
3912
  push: z.ZodString;
3640
3913
  type: z.ZodOptional<z.ZodString>;
3641
3914
  init: z.ZodOptional<z.ZodString>;
3642
- }, z.core.$strip>]>>;
3915
+ }, z.core.$strip>>;
3916
+ import: z.ZodOptional<z.ZodString>;
3643
3917
  config: z.ZodOptional<z.ZodObject<{
3644
3918
  setup: z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodRecord<z.ZodString, z.ZodUnknown>]>>;
3645
3919
  }, z.core.$loose>>;
3646
3920
  env: z.ZodOptional<z.ZodUnknown>;
3921
+ cache: z.ZodOptional<z.ZodObject<{
3922
+ store: z.ZodOptional<z.ZodString>;
3923
+ namespace: z.ZodOptional<z.ZodString>;
3924
+ rules: z.ZodArray<z.ZodObject<{
3925
+ match: z.ZodOptional<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
3926
+ ttl: z.ZodNumber;
3927
+ }, z.core.$strict>>;
3928
+ }, z.core.$strict>>;
3647
3929
  variables: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3648
3930
  examples: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
3649
3931
  title: z.ZodOptional<z.ZodString>;
@@ -3748,11 +4030,12 @@ declare const FlowSchema: z.ZodObject<{
3748
4030
  }, z.core.$strip>>;
3749
4031
  sources: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
3750
4032
  package: z.ZodOptional<z.ZodString>;
3751
- code: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
4033
+ code: z.ZodOptional<z.ZodObject<{
3752
4034
  push: z.ZodString;
3753
4035
  type: z.ZodOptional<z.ZodString>;
3754
4036
  init: z.ZodOptional<z.ZodString>;
3755
- }, z.core.$strip>]>>;
4037
+ }, z.core.$strip>>;
4038
+ import: z.ZodOptional<z.ZodString>;
3756
4039
  config: z.ZodOptional<z.ZodObject<{
3757
4040
  setup: z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodRecord<z.ZodString, z.ZodUnknown>]>>;
3758
4041
  }, z.core.$loose>>;
@@ -3798,11 +4081,12 @@ declare const FlowSchema: z.ZodObject<{
3798
4081
  }, z.core.$strip>>>;
3799
4082
  destinations: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
3800
4083
  package: z.ZodOptional<z.ZodString>;
3801
- code: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
4084
+ code: z.ZodOptional<z.ZodObject<{
3802
4085
  push: z.ZodString;
3803
4086
  type: z.ZodOptional<z.ZodString>;
3804
4087
  init: z.ZodOptional<z.ZodString>;
3805
- }, z.core.$strip>]>>;
4088
+ }, z.core.$strip>>;
4089
+ import: z.ZodOptional<z.ZodString>;
3806
4090
  config: z.ZodOptional<z.ZodObject<{
3807
4091
  setup: z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodRecord<z.ZodString, z.ZodUnknown>]>>;
3808
4092
  }, z.core.$loose>>;
@@ -3847,11 +4131,12 @@ declare const FlowSchema: z.ZodObject<{
3847
4131
  }, z.core.$strip>>>;
3848
4132
  transformers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
3849
4133
  package: z.ZodOptional<z.ZodString>;
3850
- code: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
4134
+ code: z.ZodOptional<z.ZodObject<{
3851
4135
  push: z.ZodString;
3852
4136
  type: z.ZodOptional<z.ZodString>;
3853
4137
  init: z.ZodOptional<z.ZodString>;
3854
- }, z.core.$strip>]>>;
4138
+ }, z.core.$strip>>;
4139
+ import: z.ZodOptional<z.ZodString>;
3855
4140
  config: z.ZodOptional<z.ZodUnknown>;
3856
4141
  env: z.ZodOptional<z.ZodUnknown>;
3857
4142
  before: z.ZodOptional<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
@@ -3894,15 +4179,24 @@ declare const FlowSchema: z.ZodObject<{
3894
4179
  }, z.core.$strip>>>;
3895
4180
  stores: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
3896
4181
  package: z.ZodOptional<z.ZodString>;
3897
- code: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
4182
+ code: z.ZodOptional<z.ZodObject<{
3898
4183
  push: z.ZodString;
3899
4184
  type: z.ZodOptional<z.ZodString>;
3900
4185
  init: z.ZodOptional<z.ZodString>;
3901
- }, z.core.$strip>]>>;
4186
+ }, z.core.$strip>>;
4187
+ import: z.ZodOptional<z.ZodString>;
3902
4188
  config: z.ZodOptional<z.ZodObject<{
3903
4189
  setup: z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodRecord<z.ZodString, z.ZodUnknown>]>>;
3904
4190
  }, z.core.$loose>>;
3905
4191
  env: z.ZodOptional<z.ZodUnknown>;
4192
+ cache: z.ZodOptional<z.ZodObject<{
4193
+ store: z.ZodOptional<z.ZodString>;
4194
+ namespace: z.ZodOptional<z.ZodString>;
4195
+ rules: z.ZodArray<z.ZodObject<{
4196
+ match: z.ZodOptional<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
4197
+ ttl: z.ZodNumber;
4198
+ }, z.core.$strict>>;
4199
+ }, z.core.$strict>>;
3906
4200
  variables: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3907
4201
  examples: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
3908
4202
  title: z.ZodOptional<z.ZodString>;
@@ -3965,11 +4259,12 @@ declare const JsonSchema$1: z.ZodObject<{
3965
4259
  }, z.core.$strip>>;
3966
4260
  sources: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
3967
4261
  package: z.ZodOptional<z.ZodString>;
3968
- code: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
4262
+ code: z.ZodOptional<z.ZodObject<{
3969
4263
  push: z.ZodString;
3970
4264
  type: z.ZodOptional<z.ZodString>;
3971
4265
  init: z.ZodOptional<z.ZodString>;
3972
- }, z.core.$strip>]>>;
4266
+ }, z.core.$strip>>;
4267
+ import: z.ZodOptional<z.ZodString>;
3973
4268
  config: z.ZodOptional<z.ZodObject<{
3974
4269
  setup: z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodRecord<z.ZodString, z.ZodUnknown>]>>;
3975
4270
  }, z.core.$loose>>;
@@ -4015,11 +4310,12 @@ declare const JsonSchema$1: z.ZodObject<{
4015
4310
  }, z.core.$strip>>>;
4016
4311
  destinations: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
4017
4312
  package: z.ZodOptional<z.ZodString>;
4018
- code: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
4313
+ code: z.ZodOptional<z.ZodObject<{
4019
4314
  push: z.ZodString;
4020
4315
  type: z.ZodOptional<z.ZodString>;
4021
4316
  init: z.ZodOptional<z.ZodString>;
4022
- }, z.core.$strip>]>>;
4317
+ }, z.core.$strip>>;
4318
+ import: z.ZodOptional<z.ZodString>;
4023
4319
  config: z.ZodOptional<z.ZodObject<{
4024
4320
  setup: z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodRecord<z.ZodString, z.ZodUnknown>]>>;
4025
4321
  }, z.core.$loose>>;
@@ -4064,11 +4360,12 @@ declare const JsonSchema$1: z.ZodObject<{
4064
4360
  }, z.core.$strip>>>;
4065
4361
  transformers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
4066
4362
  package: z.ZodOptional<z.ZodString>;
4067
- code: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
4363
+ code: z.ZodOptional<z.ZodObject<{
4068
4364
  push: z.ZodString;
4069
4365
  type: z.ZodOptional<z.ZodString>;
4070
4366
  init: z.ZodOptional<z.ZodString>;
4071
- }, z.core.$strip>]>>;
4367
+ }, z.core.$strip>>;
4368
+ import: z.ZodOptional<z.ZodString>;
4072
4369
  config: z.ZodOptional<z.ZodUnknown>;
4073
4370
  env: z.ZodOptional<z.ZodUnknown>;
4074
4371
  before: z.ZodOptional<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
@@ -4111,15 +4408,24 @@ declare const JsonSchema$1: z.ZodObject<{
4111
4408
  }, z.core.$strip>>>;
4112
4409
  stores: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
4113
4410
  package: z.ZodOptional<z.ZodString>;
4114
- code: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
4411
+ code: z.ZodOptional<z.ZodObject<{
4115
4412
  push: z.ZodString;
4116
4413
  type: z.ZodOptional<z.ZodString>;
4117
4414
  init: z.ZodOptional<z.ZodString>;
4118
- }, z.core.$strip>]>>;
4415
+ }, z.core.$strip>>;
4416
+ import: z.ZodOptional<z.ZodString>;
4119
4417
  config: z.ZodOptional<z.ZodObject<{
4120
4418
  setup: z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodRecord<z.ZodString, z.ZodUnknown>]>>;
4121
4419
  }, z.core.$loose>>;
4122
4420
  env: z.ZodOptional<z.ZodUnknown>;
4421
+ cache: z.ZodOptional<z.ZodObject<{
4422
+ store: z.ZodOptional<z.ZodString>;
4423
+ namespace: z.ZodOptional<z.ZodString>;
4424
+ rules: z.ZodArray<z.ZodObject<{
4425
+ match: z.ZodOptional<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
4426
+ ttl: z.ZodNumber;
4427
+ }, z.core.$strict>>;
4428
+ }, z.core.$strict>>;
4123
4429
  variables: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4124
4430
  examples: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
4125
4431
  title: z.ZodOptional<z.ZodString>;
@@ -4187,11 +4493,12 @@ declare function safeParseConfig(data: unknown): z.ZodSafeParseResult<{
4187
4493
  } | undefined;
4188
4494
  sources?: Record<string, {
4189
4495
  package?: string | undefined;
4190
- code?: string | {
4496
+ code?: {
4191
4497
  push: string;
4192
4498
  type?: string | undefined;
4193
4499
  init?: string | undefined;
4194
4500
  } | undefined;
4501
+ import?: string | undefined;
4195
4502
  config?: {
4196
4503
  [x: string]: unknown;
4197
4504
  setup?: boolean | Record<string, unknown> | undefined;
@@ -4233,11 +4540,12 @@ declare function safeParseConfig(data: unknown): z.ZodSafeParseResult<{
4233
4540
  }> | undefined;
4234
4541
  destinations?: Record<string, {
4235
4542
  package?: string | undefined;
4236
- code?: string | {
4543
+ code?: {
4237
4544
  push: string;
4238
4545
  type?: string | undefined;
4239
4546
  init?: string | undefined;
4240
4547
  } | undefined;
4548
+ import?: string | undefined;
4241
4549
  config?: {
4242
4550
  [x: string]: unknown;
4243
4551
  setup?: boolean | Record<string, unknown> | undefined;
@@ -4278,11 +4586,12 @@ declare function safeParseConfig(data: unknown): z.ZodSafeParseResult<{
4278
4586
  }> | undefined;
4279
4587
  transformers?: Record<string, {
4280
4588
  package?: string | undefined;
4281
- code?: string | {
4589
+ code?: {
4282
4590
  push: string;
4283
4591
  type?: string | undefined;
4284
4592
  init?: string | undefined;
4285
4593
  } | undefined;
4594
+ import?: string | undefined;
4286
4595
  config?: unknown;
4287
4596
  env?: unknown;
4288
4597
  before?: unknown;
@@ -4320,16 +4629,25 @@ declare function safeParseConfig(data: unknown): z.ZodSafeParseResult<{
4320
4629
  }> | undefined;
4321
4630
  stores?: Record<string, {
4322
4631
  package?: string | undefined;
4323
- code?: string | {
4632
+ code?: {
4324
4633
  push: string;
4325
4634
  type?: string | undefined;
4326
4635
  init?: string | undefined;
4327
4636
  } | undefined;
4637
+ import?: string | undefined;
4328
4638
  config?: {
4329
4639
  [x: string]: unknown;
4330
4640
  setup?: boolean | Record<string, unknown> | undefined;
4331
4641
  } | undefined;
4332
4642
  env?: unknown;
4643
+ cache?: {
4644
+ rules: {
4645
+ ttl: number;
4646
+ match?: unknown;
4647
+ }[];
4648
+ store?: string | undefined;
4649
+ namespace?: string | undefined;
4650
+ } | undefined;
4333
4651
  variables?: Record<string, unknown> | undefined;
4334
4652
  examples?: Record<string, {
4335
4653
  title?: string | undefined;
@@ -4387,11 +4705,12 @@ declare function safeParseFlow(data: unknown): z.ZodSafeParseResult<{
4387
4705
  } | undefined;
4388
4706
  sources?: Record<string, {
4389
4707
  package?: string | undefined;
4390
- code?: string | {
4708
+ code?: {
4391
4709
  push: string;
4392
4710
  type?: string | undefined;
4393
4711
  init?: string | undefined;
4394
4712
  } | undefined;
4713
+ import?: string | undefined;
4395
4714
  config?: {
4396
4715
  [x: string]: unknown;
4397
4716
  setup?: boolean | Record<string, unknown> | undefined;
@@ -4433,11 +4752,12 @@ declare function safeParseFlow(data: unknown): z.ZodSafeParseResult<{
4433
4752
  }> | undefined;
4434
4753
  destinations?: Record<string, {
4435
4754
  package?: string | undefined;
4436
- code?: string | {
4755
+ code?: {
4437
4756
  push: string;
4438
4757
  type?: string | undefined;
4439
4758
  init?: string | undefined;
4440
4759
  } | undefined;
4760
+ import?: string | undefined;
4441
4761
  config?: {
4442
4762
  [x: string]: unknown;
4443
4763
  setup?: boolean | Record<string, unknown> | undefined;
@@ -4478,11 +4798,12 @@ declare function safeParseFlow(data: unknown): z.ZodSafeParseResult<{
4478
4798
  }> | undefined;
4479
4799
  transformers?: Record<string, {
4480
4800
  package?: string | undefined;
4481
- code?: string | {
4801
+ code?: {
4482
4802
  push: string;
4483
4803
  type?: string | undefined;
4484
4804
  init?: string | undefined;
4485
4805
  } | undefined;
4806
+ import?: string | undefined;
4486
4807
  config?: unknown;
4487
4808
  env?: unknown;
4488
4809
  before?: unknown;
@@ -4520,16 +4841,25 @@ declare function safeParseFlow(data: unknown): z.ZodSafeParseResult<{
4520
4841
  }> | undefined;
4521
4842
  stores?: Record<string, {
4522
4843
  package?: string | undefined;
4523
- code?: string | {
4844
+ code?: {
4524
4845
  push: string;
4525
4846
  type?: string | undefined;
4526
4847
  init?: string | undefined;
4527
4848
  } | undefined;
4849
+ import?: string | undefined;
4528
4850
  config?: {
4529
4851
  [x: string]: unknown;
4530
4852
  setup?: boolean | Record<string, unknown> | undefined;
4531
4853
  } | undefined;
4532
4854
  env?: unknown;
4855
+ cache?: {
4856
+ rules: {
4857
+ ttl: number;
4858
+ match?: unknown;
4859
+ }[];
4860
+ store?: string | undefined;
4861
+ namespace?: string | undefined;
4862
+ } | undefined;
4533
4863
  variables?: Record<string, unknown> | undefined;
4534
4864
  examples?: Record<string, {
4535
4865
  title?: string | undefined;
@@ -4587,11 +4917,12 @@ declare const configJsonSchema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<
4587
4917
  }, z.core.$strip>>;
4588
4918
  sources: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
4589
4919
  package: z.ZodOptional<z.ZodString>;
4590
- code: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
4920
+ code: z.ZodOptional<z.ZodObject<{
4591
4921
  push: z.ZodString;
4592
4922
  type: z.ZodOptional<z.ZodString>;
4593
4923
  init: z.ZodOptional<z.ZodString>;
4594
- }, z.core.$strip>]>>;
4924
+ }, z.core.$strip>>;
4925
+ import: z.ZodOptional<z.ZodString>;
4595
4926
  config: z.ZodOptional<z.ZodObject<{
4596
4927
  setup: z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodRecord<z.ZodString, z.ZodUnknown>]>>;
4597
4928
  }, z.core.$loose>>;
@@ -4637,11 +4968,12 @@ declare const configJsonSchema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<
4637
4968
  }, z.core.$strip>>>;
4638
4969
  destinations: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
4639
4970
  package: z.ZodOptional<z.ZodString>;
4640
- code: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
4971
+ code: z.ZodOptional<z.ZodObject<{
4641
4972
  push: z.ZodString;
4642
4973
  type: z.ZodOptional<z.ZodString>;
4643
4974
  init: z.ZodOptional<z.ZodString>;
4644
- }, z.core.$strip>]>>;
4975
+ }, z.core.$strip>>;
4976
+ import: z.ZodOptional<z.ZodString>;
4645
4977
  config: z.ZodOptional<z.ZodObject<{
4646
4978
  setup: z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodRecord<z.ZodString, z.ZodUnknown>]>>;
4647
4979
  }, z.core.$loose>>;
@@ -4686,11 +5018,12 @@ declare const configJsonSchema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<
4686
5018
  }, z.core.$strip>>>;
4687
5019
  transformers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
4688
5020
  package: z.ZodOptional<z.ZodString>;
4689
- code: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
5021
+ code: z.ZodOptional<z.ZodObject<{
4690
5022
  push: z.ZodString;
4691
5023
  type: z.ZodOptional<z.ZodString>;
4692
5024
  init: z.ZodOptional<z.ZodString>;
4693
- }, z.core.$strip>]>>;
5025
+ }, z.core.$strip>>;
5026
+ import: z.ZodOptional<z.ZodString>;
4694
5027
  config: z.ZodOptional<z.ZodUnknown>;
4695
5028
  env: z.ZodOptional<z.ZodUnknown>;
4696
5029
  before: z.ZodOptional<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
@@ -4733,15 +5066,24 @@ declare const configJsonSchema: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<
4733
5066
  }, z.core.$strip>>>;
4734
5067
  stores: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
4735
5068
  package: z.ZodOptional<z.ZodString>;
4736
- code: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
5069
+ code: z.ZodOptional<z.ZodObject<{
4737
5070
  push: z.ZodString;
4738
5071
  type: z.ZodOptional<z.ZodString>;
4739
5072
  init: z.ZodOptional<z.ZodString>;
4740
- }, z.core.$strip>]>>;
5073
+ }, z.core.$strip>>;
5074
+ import: z.ZodOptional<z.ZodString>;
4741
5075
  config: z.ZodOptional<z.ZodObject<{
4742
5076
  setup: z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodRecord<z.ZodString, z.ZodUnknown>]>>;
4743
5077
  }, z.core.$loose>>;
4744
5078
  env: z.ZodOptional<z.ZodUnknown>;
5079
+ cache: z.ZodOptional<z.ZodObject<{
5080
+ store: z.ZodOptional<z.ZodString>;
5081
+ namespace: z.ZodOptional<z.ZodString>;
5082
+ rules: z.ZodArray<z.ZodObject<{
5083
+ match: z.ZodOptional<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
5084
+ ttl: z.ZodNumber;
5085
+ }, z.core.$strict>>;
5086
+ }, z.core.$strict>>;
4745
5087
  variables: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
4746
5088
  examples: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
4747
5089
  title: z.ZodOptional<z.ZodString>;
@@ -4798,6 +5140,15 @@ declare const contractRuleJsonSchema: z.core.ZodStandardJSONSchemaPayload<z.ZodT
4798
5140
  * JSON Schema for the named Contract map (Flow.Contract).
4799
5141
  */
4800
5142
  declare const contractJsonSchema: z.core.ZodStandardJSONSchemaPayload<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
5143
+ /**
5144
+ * JSON Schema for the step-level Validate config (Flow.Validate).
5145
+ */
5146
+ declare const validateJsonSchema: z.core.ZodStandardJSONSchemaPayload<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
5147
+ /**
5148
+ * JSON Schema for the entity-action keyed Validate events map
5149
+ * (Flow.ValidateEvents). Shares its shape with Contract `events`.
5150
+ */
5151
+ declare const validateEventsJsonSchema: z.core.ZodStandardJSONSchemaPayload<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
4801
5152
 
4802
5153
  declare const flow_BundlePackageSchema: typeof BundlePackageSchema;
4803
5154
  declare const flow_BundleSchema: typeof BundleSchema;
@@ -4833,8 +5184,10 @@ declare const flow_safeParseFlow: typeof safeParseFlow;
4833
5184
  declare const flow_sourceJsonSchema: typeof sourceJsonSchema;
4834
5185
  declare const flow_storeJsonSchema: typeof storeJsonSchema;
4835
5186
  declare const flow_transformerJsonSchema: typeof transformerJsonSchema;
5187
+ declare const flow_validateEventsJsonSchema: typeof validateEventsJsonSchema;
5188
+ declare const flow_validateJsonSchema: typeof validateJsonSchema;
4836
5189
  declare namespace flow {
4837
- export { flow_BundlePackageSchema as BundlePackageSchema, flow_BundleSchema as BundleSchema, CodeSchema$1 as CodeSchema, flow_ConfigSchema as ConfigSchema, flow_ContractActionsSchema as ContractActionsSchema, flow_ContractEventsSchema as ContractEventsSchema, flow_ContractRuleSchema as ContractRuleSchema, flow_ContractSchema as ContractSchema, flow_ContractSchemaEntry as ContractSchemaEntry, flow_DestinationSchema as DestinationSchema, flow_FlowSchema as FlowSchema, JsonSchema$1 as JsonSchema, flow_JsonSchemaSchema as JsonSchemaSchema, flow_SettingsSchema as SettingsSchema, flow_SourceSchema as SourceSchema, flow_StepExampleSchema as StepExampleSchema, flow_StepExamplesSchema as StepExamplesSchema, flow_StoreSchema as StoreSchema, flow_TransformerSchema as TransformerSchema, flow_TriggerDescriptorSchema as TriggerDescriptorSchema, flow_ValidateEventsSchema as ValidateEventsSchema, flow_ValidateSchema as ValidateSchema, flow_VariablesSchema as VariablesSchema, flow_configJsonSchema as configJsonSchema, flow_contractJsonSchema as contractJsonSchema, flow_contractRuleJsonSchema as contractRuleJsonSchema, flow_destinationJsonSchema as destinationJsonSchema, flow_flowConfigJsonSchema as flowConfigJsonSchema, flow_flowJsonSchema as flowJsonSchema, flow_parseConfig as parseConfig, flow_parseFlow as parseFlow, flow_safeParseConfig as safeParseConfig, flow_safeParseFlow as safeParseFlow, flow_sourceJsonSchema as sourceJsonSchema, flow_storeJsonSchema as storeJsonSchema, flow_transformerJsonSchema as transformerJsonSchema };
5190
+ export { flow_BundlePackageSchema as BundlePackageSchema, flow_BundleSchema as BundleSchema, CodeSchema$1 as CodeSchema, flow_ConfigSchema as ConfigSchema, flow_ContractActionsSchema as ContractActionsSchema, flow_ContractEventsSchema as ContractEventsSchema, flow_ContractRuleSchema as ContractRuleSchema, flow_ContractSchema as ContractSchema, flow_ContractSchemaEntry as ContractSchemaEntry, flow_DestinationSchema as DestinationSchema, flow_FlowSchema as FlowSchema, JsonSchema$1 as JsonSchema, flow_JsonSchemaSchema as JsonSchemaSchema, flow_SettingsSchema as SettingsSchema, flow_SourceSchema as SourceSchema, flow_StepExampleSchema as StepExampleSchema, flow_StepExamplesSchema as StepExamplesSchema, flow_StoreSchema as StoreSchema, flow_TransformerSchema as TransformerSchema, flow_TriggerDescriptorSchema as TriggerDescriptorSchema, flow_ValidateEventsSchema as ValidateEventsSchema, flow_ValidateSchema as ValidateSchema, flow_VariablesSchema as VariablesSchema, flow_configJsonSchema as configJsonSchema, flow_contractJsonSchema as contractJsonSchema, flow_contractRuleJsonSchema as contractRuleJsonSchema, flow_destinationJsonSchema as destinationJsonSchema, flow_flowConfigJsonSchema as flowConfigJsonSchema, flow_flowJsonSchema as flowJsonSchema, flow_parseConfig as parseConfig, flow_parseFlow as parseFlow, flow_safeParseConfig as safeParseConfig, flow_safeParseFlow as safeParseFlow, flow_sourceJsonSchema as sourceJsonSchema, flow_storeJsonSchema as storeJsonSchema, flow_transformerJsonSchema as transformerJsonSchema, flow_validateEventsJsonSchema as validateEventsJsonSchema, flow_validateJsonSchema as validateJsonSchema };
4838
5191
  }
4839
5192
 
4840
5193
  /**
@@ -4936,28 +5289,87 @@ declare namespace utilities {
4936
5289
  }
4937
5290
 
4938
5291
  /**
4939
- * CacheRule — a single caching rule for a pipeline step.
5292
+ * EventCacheRule — a single caching rule for an event-context pipeline step
5293
+ * (sources, transformers, destinations).
4940
5294
  *
4941
- * Mirrors: types/cache.ts → CacheRule
5295
+ * Mirrors: types/cache.ts → EventCacheRule
4942
5296
  *
4943
- * - match: MatchExpression or '*' wildcard
4944
- * - key: array of dot-path strings used to build the cache key
4945
- * - ttl: time-to-live in seconds (must be positive)
4946
- * - update: optional record of response mutations applied on cache hit
5297
+ * - match: MatchExpression omit for always-match.
5298
+ * - key: array of dot-path strings used to compose the cache key from event fields.
5299
+ * - ttl: time-to-live in seconds (positive).
5300
+ * - update: optional record of response mutations applied on cache hit.
4947
5301
  */
4948
- declare const CacheRuleSchema: z.ZodObject<{
5302
+ declare const EventCacheRuleSchema: z.ZodObject<{
4949
5303
  match: z.ZodOptional<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
4950
5304
  key: z.ZodArray<z.ZodString>;
4951
5305
  ttl: z.ZodNumber;
4952
5306
  update: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
4953
5307
  }, z.core.$strip>;
4954
5308
  /**
4955
- * Cache — top-level cache configuration for a pipeline step.
5309
+ * EventCache — top-level cache configuration for an event-context pipeline step.
5310
+ *
5311
+ * Mirrors: types/cache.ts → Cache<EventCacheRule>
5312
+ */
5313
+ declare const EventCacheSchema: z.ZodObject<{
5314
+ stop: z.ZodOptional<z.ZodBoolean>;
5315
+ store: z.ZodOptional<z.ZodString>;
5316
+ namespace: z.ZodOptional<z.ZodString>;
5317
+ rules: z.ZodArray<z.ZodObject<{
5318
+ match: z.ZodOptional<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
5319
+ key: z.ZodArray<z.ZodString>;
5320
+ ttl: z.ZodNumber;
5321
+ update: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
5322
+ }, z.core.$strip>>;
5323
+ }, z.core.$strip>;
5324
+ /**
5325
+ * StoreCacheRule — a single caching rule applied at the store boundary.
5326
+ *
5327
+ * Mirrors: types/cache.ts → StoreCacheRule
5328
+ *
5329
+ * The caller (store wrapper) provides the cache key, so `key` is not allowed
5330
+ * here. There is no event to mutate, so `update` is rejected.
5331
+ *
5332
+ * - match: optional MatchExpression evaluated against `{ key, value? }`.
5333
+ * - ttl: time-to-live in seconds (positive).
5334
+ *
5335
+ * `.strict()` rejects unknown keys so footguns surface at validation time.
5336
+ */
5337
+ declare const StoreCacheRuleSchema: z.ZodObject<{
5338
+ match: z.ZodOptional<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
5339
+ ttl: z.ZodNumber;
5340
+ }, z.core.$strict>;
5341
+ /**
5342
+ * StoreCache — top-level cache configuration for a store wrapper.
4956
5343
  *
4957
- * Mirrors: types/cache.ts → Cache
5344
+ * Mirrors: types/cache.ts → Cache<StoreCacheRule>
4958
5345
  *
4959
- * - store: optional store ID for persistent caching ($store.storeId wiring)
4960
- * - rules: at least one CacheRule is required
5346
+ * Differences from EventCache:
5347
+ * - No `stop` field (read-through always falls through on miss).
5348
+ * - `namespace` rejects `""` (empty namespace collapses keys across stores
5349
+ * sharing `__cache` and re-introduces collisions).
5350
+ * - Rules use StoreCacheRuleSchema (no `key`, no `update`).
5351
+ */
5352
+ declare const StoreCacheSchema: z.ZodObject<{
5353
+ store: z.ZodOptional<z.ZodString>;
5354
+ namespace: z.ZodOptional<z.ZodString>;
5355
+ rules: z.ZodArray<z.ZodObject<{
5356
+ match: z.ZodOptional<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
5357
+ ttl: z.ZodNumber;
5358
+ }, z.core.$strict>>;
5359
+ }, z.core.$strict>;
5360
+ /**
5361
+ * @deprecated Use {@link EventCacheRuleSchema}. Kept for one cycle to avoid
5362
+ * breaking external callers.
5363
+ */
5364
+ declare const CacheRuleSchema: z.ZodObject<{
5365
+ match: z.ZodOptional<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
5366
+ key: z.ZodArray<z.ZodString>;
5367
+ ttl: z.ZodNumber;
5368
+ update: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>>;
5369
+ }, z.core.$strip>;
5370
+ /**
5371
+ * @deprecated Use {@link EventCacheSchema}. Kept for one cycle to avoid
5372
+ * breaking external callers.
4961
5373
  */
4962
5374
  declare const CacheSchema: z.ZodObject<{
4963
5375
  stop: z.ZodOptional<z.ZodBoolean>;
@@ -4973,19 +5385,23 @@ declare const CacheSchema: z.ZodObject<{
4973
5385
 
4974
5386
  declare const cache_CacheRuleSchema: typeof CacheRuleSchema;
4975
5387
  declare const cache_CacheSchema: typeof CacheSchema;
5388
+ declare const cache_EventCacheRuleSchema: typeof EventCacheRuleSchema;
5389
+ declare const cache_EventCacheSchema: typeof EventCacheSchema;
5390
+ declare const cache_StoreCacheRuleSchema: typeof StoreCacheRuleSchema;
5391
+ declare const cache_StoreCacheSchema: typeof StoreCacheSchema;
4976
5392
  declare namespace cache {
4977
- export { cache_CacheRuleSchema as CacheRuleSchema, cache_CacheSchema as CacheSchema };
5393
+ export { cache_CacheRuleSchema as CacheRuleSchema, cache_CacheSchema as CacheSchema, cache_EventCacheRuleSchema as EventCacheRuleSchema, cache_EventCacheSchema as EventCacheSchema, cache_StoreCacheRuleSchema as StoreCacheRuleSchema, cache_StoreCacheSchema as StoreCacheSchema };
4978
5394
  }
4979
5395
 
4980
5396
  declare const MatchExpressionSchema: z.ZodType;
4981
5397
  declare const RouteSchema: z.ZodType;
4982
- declare const RouteSpecSchema: z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>;
5398
+ declare const RouteWithoutManySchema: z.ZodType;
4983
5399
 
4984
5400
  declare const matcher_MatchExpressionSchema: typeof MatchExpressionSchema;
4985
5401
  declare const matcher_RouteSchema: typeof RouteSchema;
4986
- declare const matcher_RouteSpecSchema: typeof RouteSpecSchema;
5402
+ declare const matcher_RouteWithoutManySchema: typeof RouteWithoutManySchema;
4987
5403
  declare namespace matcher {
4988
- export { matcher_MatchExpressionSchema as MatchExpressionSchema, matcher_RouteSchema as RouteSchema, matcher_RouteSpecSchema as RouteSpecSchema };
5404
+ export { matcher_MatchExpressionSchema as MatchExpressionSchema, matcher_RouteSchema as RouteSchema, matcher_RouteWithoutManySchema as RouteWithoutManySchema };
4989
5405
  }
4990
5406
 
4991
5407
  declare const CodeSchema: z.ZodObject<{
@@ -5296,7 +5712,6 @@ type JSONSchema = Record<string, unknown>;
5296
5712
  declare function zodToSchema(schema: z.ZodTypeAny): JSONSchema;
5297
5713
 
5298
5714
  declare const index_BaseContextConfig: typeof BaseContextConfig;
5299
- declare const index_BatchConfig: typeof BatchConfig;
5300
5715
  declare const index_CacheRuleSchema: typeof CacheRuleSchema;
5301
5716
  declare const index_CacheSchema: typeof CacheSchema;
5302
5717
  declare const index_ClickIdEntrySchema: typeof ClickIdEntrySchema;
@@ -5311,6 +5726,8 @@ declare const index_DeepPartialEventSchema: typeof DeepPartialEventSchema;
5311
5726
  declare const index_DestinationsMapConfig: typeof DestinationsMapConfig;
5312
5727
  declare const index_EntitiesSchema: typeof EntitiesSchema;
5313
5728
  declare const index_EntitySchema: typeof EntitySchema;
5729
+ declare const index_EventCacheRuleSchema: typeof EventCacheRuleSchema;
5730
+ declare const index_EventCacheSchema: typeof EventCacheSchema;
5314
5731
  declare const index_EventSchema: typeof EventSchema;
5315
5732
  declare const index_FlowSchema: typeof FlowSchema;
5316
5733
  declare const index_GenericEnvConfig: typeof GenericEnvConfig;
@@ -5344,15 +5761,19 @@ declare const index_RequiredBoolean: typeof RequiredBoolean;
5344
5761
  declare const index_RequiredNumber: typeof RequiredNumber;
5345
5762
  declare const index_RequiredString: typeof RequiredString;
5346
5763
  declare const index_RouteSchema: typeof RouteSchema;
5347
- declare const index_RouteSpecSchema: typeof RouteSpecSchema;
5764
+ declare const index_RouteWithoutManySchema: typeof RouteWithoutManySchema;
5348
5765
  declare const index_RuleSchema: typeof RuleSchema;
5349
5766
  declare const index_RulesSchema: typeof RulesSchema;
5350
5767
  declare const index_RuntimeInstanceConfig: typeof RuntimeInstanceConfig;
5351
5768
  declare const index_SetSchema: typeof SetSchema;
5352
5769
  declare const index_SourceTypeSchema: typeof SourceTypeSchema;
5353
5770
  declare const index_SourcesMapConfig: typeof SourcesMapConfig;
5771
+ declare const index_StoreCacheRuleSchema: typeof StoreCacheRuleSchema;
5772
+ declare const index_StoreCacheSchema: typeof StoreCacheSchema;
5354
5773
  declare const index_Timestamp: typeof Timestamp;
5355
5774
  declare const index_UserSchema: typeof UserSchema;
5775
+ declare const index_ValidateEventsSchema: typeof ValidateEventsSchema;
5776
+ declare const index_ValidateSchema: typeof ValidateSchema;
5356
5777
  type index_ValidationIssue = ValidationIssue;
5357
5778
  type index_ValidationResult = ValidationResult;
5358
5779
  declare const index_ValueConfigSchema: typeof ValueConfigSchema;
@@ -5394,13 +5815,15 @@ declare const index_sourceTypeJsonSchema: typeof sourceTypeJsonSchema;
5394
5815
  declare const index_storeJsonSchema: typeof storeJsonSchema;
5395
5816
  declare const index_transformerJsonSchema: typeof transformerJsonSchema;
5396
5817
  declare const index_userJsonSchema: typeof userJsonSchema;
5818
+ declare const index_validateEventsJsonSchema: typeof validateEventsJsonSchema;
5397
5819
  declare const index_validateFlowConfig: typeof validateFlowConfig;
5820
+ declare const index_validateJsonSchema: typeof validateJsonSchema;
5398
5821
  declare const index_valueConfigJsonSchema: typeof valueConfigJsonSchema;
5399
5822
  declare const index_valueJsonSchema: typeof valueJsonSchema;
5400
5823
  declare const index_z: typeof z;
5401
5824
  declare const index_zodToSchema: typeof zodToSchema;
5402
5825
  declare namespace index {
5403
- export { index_BaseContextConfig as BaseContextConfig, index_BatchConfig as BatchConfig, index_CacheRuleSchema as CacheRuleSchema, index_CacheSchema as CacheSchema, cache as CacheSchemas, index_ClickIdEntrySchema as ClickIdEntrySchema, index_CodeSchema as CodeSchema, collector as CollectorSchemas, index_ConsentSchema as ConsentSchema, index_ContractActionsSchema as ContractActionsSchema, index_ContractRuleSchema as ContractRuleSchema, index_ContractSchema as ContractSchema, index_ContractSchemaEntry as ContractSchemaEntry, index_Counter as Counter, index_DeepPartialEventSchema as DeepPartialEventSchema, destination as DestinationSchemas, index_DestinationsMapConfig as DestinationsMapConfig, index_EntitiesSchema as EntitiesSchema, index_EntitySchema as EntitySchema, index_EventSchema as EventSchema, BundlePackageSchema as FlowBundlePackageSchema, BundleSchema as FlowBundleSchema, CodeSchema$1 as FlowCodeSchema, ConfigSchema as FlowConfigSchema, DestinationSchema as FlowDestinationSchema, JsonSchema$1 as FlowJsonSchema, index_FlowSchema as FlowSchema, flow as FlowSchemas, SourceSchema as FlowSourceSchema, StoreSchema as FlowStoreSchema, TransformerSchema as FlowTransformerSchema, index_GenericEnvConfig as GenericEnvConfig, index_GenericSettingsConfig as GenericSettingsConfig, index_HandlersConfig as HandlersConfig, index_HintSchema as HintSchema, index_HintsSchema as HintsSchema, index_IdConfig as IdConfig, index_Identifier as Identifier, InitConfig$1 as InitConfig, type index_IntelliSenseContext as IntelliSenseContext, type index_JSONSchema as JSONSchema, index_LoggerConfigSchema as LoggerConfigSchema, index_LoggerHandlerSchema as LoggerHandlerSchema, index_LoopSchema as LoopSchema, index_MapSchema as MapSchema, ResultSchema$1 as MappingResultSchema, mapping as MappingSchemas, index_MatchExpressionSchema as MatchExpressionSchema, matcher as MatcherSchemas, index_OptionalPrimitiveValue as OptionalPrimitiveValue, index_OrderedPropertiesSchema as OrderedPropertiesSchema, type index_PackageInfo as PackageInfo, index_PartialEventSchema as PartialEventSchema, index_PolicySchema as PolicySchema, index_PrimaryConfig as PrimaryConfig, index_PrimitiveValue as PrimitiveValue, index_ProcessingControlConfig as ProcessingControlConfig, index_PropertiesSchema as PropertiesSchema, type index_PropertyDef as PropertyDef, index_PropertySchema as PropertySchema, index_PropertyTypeSchema as PropertyTypeSchema, index_QueueConfig as QueueConfig, index_RequiredBoolean as RequiredBoolean, index_RequiredNumber as RequiredNumber, index_RequiredString as RequiredString, index_RouteSchema as RouteSchema, index_RouteSpecSchema as RouteSpecSchema, index_RuleSchema as RuleSchema, index_RulesSchema as RulesSchema, index_RuntimeInstanceConfig as RuntimeInstanceConfig, index_SetSchema as SetSchema, SourceSchema$1 as SourceSchema, source as SourceSchemas, index_SourceTypeSchema as SourceTypeSchema, index_SourcesMapConfig as SourcesMapConfig, store as StoreSchemas, index_Timestamp as Timestamp, transformer as TransformerSchemas, index_UserSchema as UserSchema, utilities as UtilitySchemas, type index_ValidationIssue as ValidationIssue, type index_ValidationResult as ValidationResult, index_ValueConfigSchema as ValueConfigSchema, index_ValueSchema as ValueSchema, index_ValuesSchema as ValuesSchema, index_VerboseConfig as VerboseConfig, walkeros as WalkerOSSchemas, index_configJsonSchema as configJsonSchema, index_consentJsonSchema as consentJsonSchema, index_contractJsonSchema as contractJsonSchema, index_contractRuleJsonSchema as contractRuleJsonSchema, index_createArraySchema as createArraySchema, index_createConsentConfig as createConsentConfig, index_createDataTransformationConfig as createDataTransformationConfig, index_createEnumSchema as createEnumSchema, index_createMappingRulesConfig as createMappingRulesConfig, index_createObjectSchema as createObjectSchema, index_createPolicyConfig as createPolicyConfig, index_createTupleSchema as createTupleSchema, index_destinationJsonSchema as destinationJsonSchema, index_entityJsonSchema as entityJsonSchema, index_eventJsonSchema as eventJsonSchema, index_flowConfigJsonSchema as flowConfigJsonSchema, index_flowJsonSchema as flowJsonSchema, index_loopJsonSchema as loopJsonSchema, index_mapJsonSchema as mapJsonSchema, index_orderedPropertiesJsonSchema as orderedPropertiesJsonSchema, index_parseConfig as parseConfig, index_parseFlow as parseFlow, index_partialEventJsonSchema as partialEventJsonSchema, index_policyJsonSchema as policyJsonSchema, index_propertiesJsonSchema as propertiesJsonSchema, index_ruleJsonSchema as ruleJsonSchema, index_rulesJsonSchema as rulesJsonSchema, index_safeParseConfig as safeParseConfig, index_safeParseFlow as safeParseFlow, index_setJsonSchema as setJsonSchema, index_sourceJsonSchema as sourceJsonSchema, index_sourceTypeJsonSchema as sourceTypeJsonSchema, index_storeJsonSchema as storeJsonSchema, index_transformerJsonSchema as transformerJsonSchema, index_userJsonSchema as userJsonSchema, index_validateFlowConfig as validateFlowConfig, index_valueConfigJsonSchema as valueConfigJsonSchema, index_valueJsonSchema as valueJsonSchema, index_z as z, index_zodToSchema as zodToSchema };
5826
+ export { index_BaseContextConfig as BaseContextConfig, index_CacheRuleSchema as CacheRuleSchema, index_CacheSchema as CacheSchema, cache as CacheSchemas, index_ClickIdEntrySchema as ClickIdEntrySchema, index_CodeSchema as CodeSchema, collector as CollectorSchemas, index_ConsentSchema as ConsentSchema, index_ContractActionsSchema as ContractActionsSchema, index_ContractRuleSchema as ContractRuleSchema, index_ContractSchema as ContractSchema, index_ContractSchemaEntry as ContractSchemaEntry, index_Counter as Counter, index_DeepPartialEventSchema as DeepPartialEventSchema, destination as DestinationSchemas, index_DestinationsMapConfig as DestinationsMapConfig, index_EntitiesSchema as EntitiesSchema, index_EntitySchema as EntitySchema, index_EventCacheRuleSchema as EventCacheRuleSchema, index_EventCacheSchema as EventCacheSchema, index_EventSchema as EventSchema, BundlePackageSchema as FlowBundlePackageSchema, BundleSchema as FlowBundleSchema, CodeSchema$1 as FlowCodeSchema, ConfigSchema as FlowConfigSchema, DestinationSchema as FlowDestinationSchema, JsonSchema$1 as FlowJsonSchema, index_FlowSchema as FlowSchema, flow as FlowSchemas, SourceSchema as FlowSourceSchema, StoreSchema as FlowStoreSchema, TransformerSchema as FlowTransformerSchema, index_GenericEnvConfig as GenericEnvConfig, index_GenericSettingsConfig as GenericSettingsConfig, index_HandlersConfig as HandlersConfig, index_HintSchema as HintSchema, index_HintsSchema as HintsSchema, index_IdConfig as IdConfig, index_Identifier as Identifier, InitConfig$1 as InitConfig, type index_IntelliSenseContext as IntelliSenseContext, type index_JSONSchema as JSONSchema, index_LoggerConfigSchema as LoggerConfigSchema, index_LoggerHandlerSchema as LoggerHandlerSchema, index_LoopSchema as LoopSchema, index_MapSchema as MapSchema, ResultSchema$1 as MappingResultSchema, mapping as MappingSchemas, index_MatchExpressionSchema as MatchExpressionSchema, matcher as MatcherSchemas, index_OptionalPrimitiveValue as OptionalPrimitiveValue, index_OrderedPropertiesSchema as OrderedPropertiesSchema, type index_PackageInfo as PackageInfo, index_PartialEventSchema as PartialEventSchema, index_PolicySchema as PolicySchema, index_PrimaryConfig as PrimaryConfig, index_PrimitiveValue as PrimitiveValue, index_ProcessingControlConfig as ProcessingControlConfig, index_PropertiesSchema as PropertiesSchema, type index_PropertyDef as PropertyDef, index_PropertySchema as PropertySchema, index_PropertyTypeSchema as PropertyTypeSchema, index_QueueConfig as QueueConfig, index_RequiredBoolean as RequiredBoolean, index_RequiredNumber as RequiredNumber, index_RequiredString as RequiredString, index_RouteSchema as RouteSchema, index_RouteWithoutManySchema as RouteWithoutManySchema, index_RuleSchema as RuleSchema, index_RulesSchema as RulesSchema, index_RuntimeInstanceConfig as RuntimeInstanceConfig, index_SetSchema as SetSchema, SourceSchema$1 as SourceSchema, source as SourceSchemas, index_SourceTypeSchema as SourceTypeSchema, index_SourcesMapConfig as SourcesMapConfig, index_StoreCacheRuleSchema as StoreCacheRuleSchema, index_StoreCacheSchema as StoreCacheSchema, store as StoreSchemas, index_Timestamp as Timestamp, transformer as TransformerSchemas, index_UserSchema as UserSchema, utilities as UtilitySchemas, index_ValidateEventsSchema as ValidateEventsSchema, index_ValidateSchema as ValidateSchema, type index_ValidationIssue as ValidationIssue, type index_ValidationResult as ValidationResult, index_ValueConfigSchema as ValueConfigSchema, index_ValueSchema as ValueSchema, index_ValuesSchema as ValuesSchema, index_VerboseConfig as VerboseConfig, walkeros as WalkerOSSchemas, index_configJsonSchema as configJsonSchema, index_consentJsonSchema as consentJsonSchema, index_contractJsonSchema as contractJsonSchema, index_contractRuleJsonSchema as contractRuleJsonSchema, index_createArraySchema as createArraySchema, index_createConsentConfig as createConsentConfig, index_createDataTransformationConfig as createDataTransformationConfig, index_createEnumSchema as createEnumSchema, index_createMappingRulesConfig as createMappingRulesConfig, index_createObjectSchema as createObjectSchema, index_createPolicyConfig as createPolicyConfig, index_createTupleSchema as createTupleSchema, index_destinationJsonSchema as destinationJsonSchema, index_entityJsonSchema as entityJsonSchema, index_eventJsonSchema as eventJsonSchema, index_flowConfigJsonSchema as flowConfigJsonSchema, index_flowJsonSchema as flowJsonSchema, index_loopJsonSchema as loopJsonSchema, index_mapJsonSchema as mapJsonSchema, index_orderedPropertiesJsonSchema as orderedPropertiesJsonSchema, index_parseConfig as parseConfig, index_parseFlow as parseFlow, index_partialEventJsonSchema as partialEventJsonSchema, index_policyJsonSchema as policyJsonSchema, index_propertiesJsonSchema as propertiesJsonSchema, index_ruleJsonSchema as ruleJsonSchema, index_rulesJsonSchema as rulesJsonSchema, index_safeParseConfig as safeParseConfig, index_safeParseFlow as safeParseFlow, index_setJsonSchema as setJsonSchema, index_sourceJsonSchema as sourceJsonSchema, index_sourceTypeJsonSchema as sourceTypeJsonSchema, index_storeJsonSchema as storeJsonSchema, index_transformerJsonSchema as transformerJsonSchema, index_userJsonSchema as userJsonSchema, index_validateEventsJsonSchema as validateEventsJsonSchema, index_validateFlowConfig as validateFlowConfig, index_validateJsonSchema as validateJsonSchema, index_valueConfigJsonSchema as valueConfigJsonSchema, index_valueJsonSchema as valueJsonSchema, index_z as z, index_zodToSchema as zodToSchema };
5404
5827
  }
5405
5828
 
5406
5829
  type PackageType = 'source' | 'destination' | 'transformer' | 'store';
@@ -5410,32 +5833,6 @@ interface PackageSchemas {
5410
5833
  }
5411
5834
  declare function mergeConfigSchema(type: PackageType, packageSchemas: PackageSchemas): Record<string, unknown>;
5412
5835
 
5413
- /**
5414
- * Structural JSON Schema type. Kept dep-free (no `ajv` import in core)
5415
- * so the runtime graph of any consumer of `@walkeros/core` does not pull
5416
- * AJV transitively.
5417
- */
5418
- type JsonSchema = Record<string, unknown>;
5419
- /**
5420
- * Entity-action keyed event validation schemas.
5421
- * Wildcard fallback semantic: entity.action → entity.* → *.action → *.*.
5422
- */
5423
- type ValidateEvents = Record<string, Record<string, JsonSchema>>;
5424
- /**
5425
- * Step-level validation primitive. Declares validation intent for a source,
5426
- * transformer, or destination: a `format` toggle, entity-action keyed schemas,
5427
- * and/or a generic JSON Schema for the full input. Declarative only,
5428
- * consumers (CLI tooling, MCP, custom runners) decide whether and how to enforce.
5429
- */
5430
- interface Validate$1 {
5431
- /** Validate the full `WalkerOS.Event` structural shape. */
5432
- format?: boolean;
5433
- /** Entity-action keyed JSON Schemas. */
5434
- events?: ValidateEvents;
5435
- /** Generic JSON Schema for the full input. */
5436
- schema?: JsonSchema;
5437
- }
5438
-
5439
5836
  type MatchExpression = MatchCondition | {
5440
5837
  and: MatchExpression[];
5441
5838
  } | {
@@ -5449,6 +5846,101 @@ interface MatchCondition {
5449
5846
  }
5450
5847
  type MatchOperator = 'eq' | 'contains' | 'prefix' | 'suffix' | 'regex' | 'gt' | 'lt' | 'exists';
5451
5848
 
5849
+ /**
5850
+ * Shared mapping configuration interface.
5851
+ * Used by both Source.Config and Destination.Config.
5852
+ */
5853
+ interface Config$7<T = unknown> {
5854
+ consent?: Consent;
5855
+ data?: Value | Values;
5856
+ include?: string[];
5857
+ mapping?: Rules<Rule<T>>;
5858
+ policy?: Policy$1;
5859
+ }
5860
+ interface Policy$1 {
5861
+ [key: string]: Value;
5862
+ }
5863
+ interface Rules<T = Rule> {
5864
+ [entity: string]: Record<string, T | Array<T>> | undefined;
5865
+ }
5866
+ interface Rule<Settings = unknown> {
5867
+ /**
5868
+ * Batch scheduling for this event mapping. A bare number is the
5869
+ * debounce `wait` window (legacy form). Object form supports `wait`
5870
+ * (debounce ms), `size` (count cap), and `age` (max ms since first
5871
+ * entry). Destination-level `config.batch` provides upper bounds
5872
+ * applied at scheduler creation; mapping-level values override
5873
+ * destination-level for matched events.
5874
+ */
5875
+ batch?: number | BatchOptions;
5876
+ condition?: Condition;
5877
+ consent?: Consent;
5878
+ settings?: Settings;
5879
+ data?: Data$1;
5880
+ include?: string[];
5881
+ ignore?: boolean;
5882
+ silent?: boolean;
5883
+ name?: string;
5884
+ policy?: Policy$1;
5885
+ }
5886
+ type Data$1 = Value | Values;
5887
+ type Value = ValueType | Array<ValueType>;
5888
+ type Values = Array<Value>;
5889
+ type ValueType = string | ValueConfig;
5890
+ interface ValueConfig {
5891
+ condition?: Condition;
5892
+ consent?: Consent;
5893
+ fn?: Fn$3;
5894
+ key?: string;
5895
+ loop?: Loop;
5896
+ map?: Map;
5897
+ set?: Value[];
5898
+ validate?: Validate$1;
5899
+ value?: PropertyType;
5900
+ }
5901
+ interface Context$5 {
5902
+ event: DeepPartialEvent;
5903
+ /** The surrounding mapping config: a Value (value-level) or a Rule (rule-level). */
5904
+ mapping: Value | Rule;
5905
+ collector: Instance$5;
5906
+ logger: Instance$3;
5907
+ consent?: Consent;
5908
+ }
5909
+ type Fn$3 = (value: unknown, context: Context$5) => PromiseOrValue<Property | unknown>;
5910
+ type Condition = (value: unknown, context: Context$5) => PromiseOrValue<boolean>;
5911
+ type Validate$1 = (value: unknown, context: Context$5) => PromiseOrValue<boolean>;
5912
+ type Loop = [Value, Value];
5913
+ type Map = {
5914
+ [key: string]: Value;
5915
+ };
5916
+
5917
+ interface BaseCacheRule {
5918
+ /**
5919
+ * Optional match expression. Omitted means always-match.
5920
+ */
5921
+ match?: MatchExpression;
5922
+ ttl: number;
5923
+ }
5924
+ interface EventCacheRule extends BaseCacheRule {
5925
+ key: string[];
5926
+ update?: Record<string, Value>;
5927
+ }
5928
+ interface StoreCacheRule extends BaseCacheRule {
5929
+ }
5930
+ type CacheRule = EventCacheRule | StoreCacheRule;
5931
+ interface Cache<R extends CacheRule = CacheRule> {
5932
+ /**
5933
+ * Stop the chain on cache HIT (default: false). When true, skip remaining steps and return cached value.
5934
+ */
5935
+ stop?: boolean;
5936
+ store?: string;
5937
+ /**
5938
+ * Optional key prefix written to the store. When absent, cache keys are written directly. Same store + same key + same namespace = same cache entry.
5939
+ */
5940
+ namespace?: string;
5941
+ rules: R[];
5942
+ }
5943
+
5452
5944
  /**
5453
5945
  * Options for responding to an HTTP request.
5454
5946
  * Same interface for web and server — sources implement the handler.
@@ -5494,10 +5986,19 @@ interface Ingest {
5494
5986
  _meta: IngestMeta;
5495
5987
  }
5496
5988
 
5989
+ /**
5990
+ * Drop counters at a single step. Each buffer is optional: a step kind
5991
+ * may have only `queue` (collector), only `dlq`, both (destinations
5992
+ * today), or neither. Counts are monotonic.
5993
+ */
5994
+ interface DroppedCounters {
5995
+ queue?: number;
5996
+ dlq?: number;
5997
+ }
5497
5998
  /**
5498
5999
  * Core collector configuration interface
5499
6000
  */
5500
- interface Config$7 {
6001
+ interface Config$6 {
5501
6002
  /** Whether to run collector automatically */
5502
6003
  run?: boolean;
5503
6004
  /** Static global properties even on a new run */
@@ -5505,12 +6006,17 @@ interface Config$7 {
5505
6006
  /** Static session data even on a new run */
5506
6007
  sessionStatic: Partial<SessionData>;
5507
6008
  /** Logger configuration */
5508
- logger?: Config$5;
6009
+ logger?: Config$4;
6010
+ /**
6011
+ * Maximum number of events retained in `collector.queue` for late-registered
6012
+ * destination backfill. Overflow drops oldest (FIFO). Default 1000.
6013
+ */
6014
+ queueMax?: number;
5509
6015
  }
5510
6016
  /**
5511
6017
  * Initialization configuration that extends Config with initial state
5512
6018
  */
5513
- interface InitConfig extends Partial<Config$7> {
6019
+ interface InitConfig extends Partial<Config$6> {
5514
6020
  /** Initial consent state */
5515
6021
  consent?: Consent;
5516
6022
  /** Initial user data */
@@ -5549,6 +6055,16 @@ interface Status {
5549
6055
  failed: number;
5550
6056
  sources: Record<string, SourceStatus>;
5551
6057
  destinations: Record<string, DestinationStatus>;
6058
+ /**
6059
+ * Monotonic counts of events dropped due to buffer caps, keyed by
6060
+ * stepId. See `stepId()` for key construction.
6061
+ *
6062
+ * Examples:
6063
+ * - `dropped["collector"]?.queue`: collector replay buffer drops
6064
+ * - `dropped["destination.ga4"]?.queue`: ga4's consent-denied buffer drops
6065
+ * - `dropped["destination.ga4"]?.dlq`: ga4's dead-letter queue drops
6066
+ */
6067
+ dropped: Record<string, DroppedCounters>;
5552
6068
  }
5553
6069
  interface SourceStatus {
5554
6070
  count: number;
@@ -5560,6 +6076,17 @@ interface DestinationStatus {
5560
6076
  failed: number;
5561
6077
  lastAt?: number;
5562
6078
  duration: number;
6079
+ /** Current size of the destination's queuePush buffer (point-in-time). */
6080
+ queuePushSize: number;
6081
+ /** Current size of the destination's DLQ (point-in-time). */
6082
+ dlqSize: number;
6083
+ /**
6084
+ * Number of events buffered in batch scheduler windows but not yet
6085
+ * delivered to `pushBatch`. Incremented on enqueue, decremented on
6086
+ * flush (whether the flush succeeds or fails). Operators read this
6087
+ * to spot batches that never drain.
6088
+ */
6089
+ inFlightBatch?: number;
5563
6090
  }
5564
6091
  interface Sources {
5565
6092
  [id: string]: Instance$1;
@@ -5581,7 +6108,7 @@ interface PushOptions {
5581
6108
  id?: string;
5582
6109
  ingest?: Ingest;
5583
6110
  respond?: RespondFn;
5584
- mapping?: Config;
6111
+ mapping?: Config$7;
5585
6112
  preChain?: string[];
5586
6113
  include?: string[];
5587
6114
  exclude?: string[];
@@ -5596,11 +6123,17 @@ interface PushFn$1 {
5596
6123
  * Command function signature - handles walker commands only
5597
6124
  */
5598
6125
  interface CommandFn {
5599
- (command: 'config', config: Partial<Config$7>): Promise<PushResult>;
6126
+ (command: 'config', config: Partial<Config$6>): Promise<PushResult>;
5600
6127
  (command: 'consent', consent: Consent): Promise<PushResult>;
5601
- <T extends Types$4>(command: 'destination', destination: Init$3<T> | Instance$4<T>, config?: Config$6<T>): Promise<PushResult>;
5602
- <K extends keyof Functions>(command: 'hook', name: K, hookFn: Functions[K]): Promise<PushResult>;
5603
- (command: 'on', type: Types$3, rules: SingleOrArray<Subscription>): Promise<PushResult>;
6128
+ <T extends Types$4>(command: 'destination', init: Init$3<T>): Promise<PushResult>;
6129
+ <K extends keyof Functions>(command: 'hook', init: {
6130
+ name: K;
6131
+ fn: Functions[K];
6132
+ }): Promise<PushResult>;
6133
+ (command: 'on', init: {
6134
+ type: Types$3;
6135
+ rules: SingleOrArray<Subscription>;
6136
+ }): Promise<PushResult>;
5604
6137
  (command: 'user', user: User): Promise<PushResult>;
5605
6138
  (command: 'run', runState?: {
5606
6139
  consent?: Consent;
@@ -5608,13 +6141,13 @@ interface CommandFn {
5608
6141
  globals?: Properties;
5609
6142
  custom?: Properties;
5610
6143
  }): Promise<PushResult>;
5611
- (command: string, data?: unknown, options?: unknown): Promise<PushResult>;
6144
+ (command: string, data?: unknown): Promise<PushResult>;
5612
6145
  }
5613
6146
  interface Instance$5 {
5614
6147
  push: PushFn$1;
5615
6148
  command: CommandFn;
5616
6149
  allowed: boolean;
5617
- config: Config$7;
6150
+ config: Config$6;
5618
6151
  consent: Consent;
5619
6152
  custom: Properties;
5620
6153
  sources: Sources;
@@ -5647,6 +6180,32 @@ interface Base<C = unknown, E = unknown> {
5647
6180
  env: E;
5648
6181
  }
5649
6182
 
6183
+ /**
6184
+ * Structural JSON Schema type. Kept dep-free (no `ajv` import in core)
6185
+ * so the runtime graph of any consumer of `@walkeros/core` does not pull
6186
+ * AJV transitively.
6187
+ */
6188
+ type JsonSchema = Record<string, unknown>;
6189
+ /**
6190
+ * Entity-action keyed event validation schemas.
6191
+ * Wildcard fallback semantic: entity.action → entity.* → *.action → *.*.
6192
+ */
6193
+ type ValidateEvents = Record<string, Record<string, JsonSchema>>;
6194
+ /**
6195
+ * Step-level validation primitive. Declares validation intent for a source,
6196
+ * transformer, or destination: a `format` toggle, entity-action keyed schemas,
6197
+ * and/or a generic JSON Schema for the full input. Declarative only,
6198
+ * consumers (CLI tooling, MCP, custom runners) decide whether and how to enforce.
6199
+ */
6200
+ interface Validate {
6201
+ /** Validate the full `WalkerOS.Event` structural shape. */
6202
+ format?: boolean;
6203
+ /** Entity-action keyed JSON Schemas. */
6204
+ events?: ValidateEvents;
6205
+ /** Generic JSON Schema for the full input. */
6206
+ schema?: JsonSchema;
6207
+ }
6208
+
5650
6209
  /**
5651
6210
  * Shared context for one-shot lifecycle hooks (setup, destroy).
5652
6211
  * No event pipeline machinery — just config, env, logger, and id.
@@ -5708,7 +6267,7 @@ type Mapping$1<T extends TypesGeneric$3 = Types$4> = T['mapping'];
5708
6267
  type Env$3<T extends TypesGeneric$3 = Types$4> = T['env'];
5709
6268
  type SetupOptions$2<T extends TypesGeneric$3 = Types$4> = T['setup'];
5710
6269
  interface Instance$4<T extends TypesGeneric$3 = Types$4> {
5711
- config: Config$6<T>;
6270
+ config: Config$5<T>;
5712
6271
  queuePush?: Events;
5713
6272
  queueOn?: Array<{
5714
6273
  type: Types$3;
@@ -5718,14 +6277,14 @@ interface Instance$4<T extends TypesGeneric$3 = Types$4> {
5718
6277
  batches?: BatchRegistry<Mapping$1<T>>;
5719
6278
  type?: string;
5720
6279
  env?: Env$3<T>;
5721
- setup?: SetupFn<Config$6<T>, Env$3<T>>;
6280
+ setup?: SetupFn<Config$5<T>, Env$3<T>>;
5722
6281
  init?: InitFn$1<T>;
5723
6282
  push: PushFn<T>;
5724
6283
  pushBatch?: PushBatchFn<T>;
5725
6284
  on?: OnFn;
5726
- destroy?: DestroyFn<Config$6<T>, Env$3<T>>;
6285
+ destroy?: DestroyFn<Config$5<T>, Env$3<T>>;
5727
6286
  }
5728
- interface Config$6<T extends TypesGeneric$3 = Types$4> {
6287
+ interface Config$5<T extends TypesGeneric$3 = Types$4> {
5729
6288
  /** Required consent states to push events; queues events when not granted. */
5730
6289
  consent?: Consent;
5731
6290
  /** Implementation-specific configuration passed to the init function. */
@@ -5743,11 +6302,11 @@ interface Config$6<T extends TypesGeneric$3 = Types$4> {
5743
6302
  /** Whether to load external scripts (e.g., gtag.js); destination-specific behavior. */
5744
6303
  loadScript?: boolean;
5745
6304
  /** Logger configuration (level, handler) to override the collector's defaults. */
5746
- logger?: Config$5;
6305
+ logger?: Config$4;
5747
6306
  /** Entity-action rules to filter, rename, transform, and batch events for this destination. */
5748
6307
  mapping?: Rules<Rule<Mapping$1<T>>>;
5749
6308
  /** Pre-processing rules applied to all events before mapping; modifies events in-place. */
5750
- policy?: Policy$1;
6309
+ policy?: Policy;
5751
6310
  /** Whether to queue events when consent is not granted; defaults to true. */
5752
6311
  queue?: boolean;
5753
6312
  /** Defer destination initialization until these collector events fire (e.g., `['consent']`). */
@@ -5758,28 +6317,61 @@ interface Config$6<T extends TypesGeneric$3 = Types$4> {
5758
6317
  */
5759
6318
  setup?: boolean | SetupOptions$2<T>;
5760
6319
  /** Transformer chain to run after collector processing but before this destination. */
5761
- before?: RouteSpec;
6320
+ before?: Route;
5762
6321
  /** Transformer chain to run after destination push completes. Push response available at ingest._response. */
5763
- next?: RouteSpec;
6322
+ next?: Route;
5764
6323
  /** Cache configuration for deduplication (step-level: skip push on HIT). */
5765
6324
  cache?: Cache;
5766
6325
  /** Completely skip this destination — no init, no push, no queuing. */
5767
6326
  disabled?: boolean;
5768
6327
  /** Return this value instead of calling push(). Uses !== undefined check to support falsy values. */
5769
6328
  mock?: unknown;
6329
+ /**
6330
+ * Maximum number of consent-denied events retained in `queuePush` for
6331
+ * this destination. Overflow drops oldest (FIFO). Default 1000.
6332
+ */
6333
+ queueMax?: number;
6334
+ /**
6335
+ * Maximum number of failed-push entries retained in `dlq` for this
6336
+ * destination. Overflow drops oldest (FIFO). Default 100.
6337
+ */
6338
+ dlqMax?: number;
6339
+ /**
6340
+ * Per-destination batch upper bounds. Supplements the mapping-level
6341
+ * `batch` setting on individual rules. A bare number is treated as
6342
+ * the debounce `wait` window (legacy compat).
6343
+ *
6344
+ * - `wait`: debounce window in ms; the timer resets on every push.
6345
+ * - `size`: hard count cap; flush immediately when entries reach this number. Default 1000 when batching is enabled.
6346
+ * - `age`: time since the first entry of the current window. Forces a flush even if pushes keep arriving. Default 30000 (30s).
6347
+ */
6348
+ batch?: number | BatchOptions;
5770
6349
  }
5771
- interface Policy$1 {
6350
+ /**
6351
+ * Batch scheduling options. Used at both the mapping-rule layer
6352
+ * (`Mapping.Rule.batch`) and the destination-config layer
6353
+ * (`Destination.Config.batch`). Same shape at both layers.
6354
+ */
6355
+ interface BatchOptions {
6356
+ /** Debounce window in ms. Timer resets on every push. */
6357
+ wait?: number;
6358
+ /** Hard count cap. Flushes immediately at this size. */
6359
+ size?: number;
6360
+ /** Hard age cap in ms since first entry of current window. */
6361
+ age?: number;
6362
+ }
6363
+ interface Policy {
5772
6364
  [key: string]: Value;
5773
6365
  }
5774
6366
  type Code<T extends TypesGeneric$3 = Types$4> = Instance$4<T>;
5775
6367
  type Init$3<T extends TypesGeneric$3 = Types$4> = {
5776
6368
  code: Code<T>;
5777
- config?: Partial<Config$6<T>>;
6369
+ config?: Partial<Config$5<T>>;
5778
6370
  env?: Partial<Env$3<T>>;
5779
- before?: RouteSpec;
5780
- next?: RouteSpec;
6371
+ before?: Route;
6372
+ next?: Route;
5781
6373
  cache?: Cache;
5782
- validate?: Validate$1;
6374
+ validate?: Validate;
5783
6375
  };
5784
6376
  interface InitDestinations {
5785
6377
  [key: string]: Init$3<any>;
@@ -5788,34 +6380,55 @@ interface InitDestinations {
5788
6380
  * Context provided to destination functions.
5789
6381
  * Extends base context with destination-specific properties.
5790
6382
  */
5791
- interface Context$5<T extends TypesGeneric$3 = Types$4> extends Base<Config$6<T>, Env$3<T>> {
6383
+ interface Context$4<T extends TypesGeneric$3 = Types$4> extends Base<Config$5<T>, Env$3<T>> {
5792
6384
  id: string;
5793
- data?: Data$1;
6385
+ data?: Data;
5794
6386
  }
5795
- interface PushContext<T extends TypesGeneric$3 = Types$4> extends Context$5<T> {
6387
+ interface PushContext<T extends TypesGeneric$3 = Types$4> extends Context$4<T> {
5796
6388
  ingest: Ingest;
5797
6389
  rule?: Rule<Mapping$1<T>>;
5798
6390
  }
5799
- interface PushBatchContext<T extends TypesGeneric$3 = Types$4> extends Context$5<T> {
6391
+ interface PushBatchContext<T extends TypesGeneric$3 = Types$4> extends Context$4<T> {
5800
6392
  ingest: Ingest;
5801
6393
  rule?: Rule<Mapping$1<T>>;
5802
6394
  }
5803
- type InitFn$1<T extends TypesGeneric$3 = Types$4> = (context: Context$5<T>) => PromiseOrValue<void | false | Config$6<T>>;
6395
+ type InitFn$1<T extends TypesGeneric$3 = Types$4> = (context: Context$4<T>) => PromiseOrValue<void | false | Config$5<T>>;
5804
6396
  type PushFn<T extends TypesGeneric$3 = Types$4> = (event: Event, context: PushContext<T>) => PromiseOrValue<void | unknown>;
5805
6397
  type PushBatchFn<T extends TypesGeneric$3 = Types$4> = (batch: Batch<Mapping$1<T>>, context: PushBatchContext<T>) => void;
6398
+ interface BatchEntry<Mapping = unknown> {
6399
+ event: Event;
6400
+ ingest?: Ingest;
6401
+ respond?: RespondFn;
6402
+ rule?: Rule<Mapping>;
6403
+ data?: Data;
6404
+ }
5806
6405
  interface Batch<Mapping> {
5807
6406
  key: string;
6407
+ /**
6408
+ * Per-event entries carrying per-event ingest, respond, rule, and data.
6409
+ * Destinations needing per-event metadata should read this instead of
6410
+ * (or in addition to) `events` and `data`.
6411
+ */
6412
+ entries: BatchEntry<Mapping>[];
6413
+ /** Derived view: events from `entries`. Kept for back-compat. */
5808
6414
  events: Events;
5809
- data: Array<Data$1>;
6415
+ /** Derived view: data from `entries`. Kept for back-compat. */
6416
+ data: Array<Data>;
5810
6417
  mapping?: Rule<Mapping>;
5811
6418
  }
5812
6419
  interface BatchRegistry<Mapping> {
5813
6420
  [mappingKey: string]: {
5814
6421
  batched: Batch<Mapping>;
5815
6422
  batchFn: () => void;
6423
+ /**
6424
+ * Force a flush of the current batch immediately. Used by shutdown
6425
+ * drain and by tests for deterministic flushing without timer
6426
+ * advancement. Resolves after the underlying `pushBatch` settles.
6427
+ */
6428
+ flush: () => Promise<void>;
5816
6429
  };
5817
6430
  }
5818
- type Data$1 = Property | undefined | Array<Property | undefined>;
6431
+ type Data = Property | undefined | Array<Property | undefined>;
5819
6432
  interface Ref {
5820
6433
  type: string;
5821
6434
  data?: unknown;
@@ -5828,16 +6441,22 @@ interface EventFn<R = Promise<PushResult>> {
5828
6441
  (event: string): R;
5829
6442
  (event: string, data: Properties): R;
5830
6443
  }
5831
- interface Fn$3<R = Promise<PushResult>, Config = unknown> extends EventFn<R>, WalkerCommands<R, Config> {
6444
+ interface Fn$2<R = Promise<PushResult>, Config = unknown> extends EventFn<R>, WalkerCommands<R, Config> {
5832
6445
  }
5833
6446
  interface WalkerCommands<R = Promise<PushResult>, Config = unknown> {
5834
6447
  (event: 'walker config', config: Partial<Config>): R;
5835
6448
  (event: 'walker consent', consent: Consent): R;
5836
- <T extends Types$4>(event: 'walker destination', destination: Init$3<T> | Instance$4<T>, config?: Config$6<T>): R;
5837
- <K extends keyof Functions>(event: 'walker hook', name: K, hookFn: Functions[K]): R;
5838
- (event: 'walker on', type: Types$3, rules: SingleOrArray<Subscription>): R;
6449
+ <T extends Types$4>(event: 'walker destination', init: Init$3<T>): R;
6450
+ <K extends keyof Functions>(event: 'walker hook', init: {
6451
+ name: K;
6452
+ fn: Functions[K];
6453
+ }): R;
6454
+ (event: 'walker on', init: {
6455
+ type: Types$3;
6456
+ rules: SingleOrArray<Subscription>;
6457
+ }): R;
5839
6458
  (event: 'walker user', user: User): R;
5840
- (event: 'walker run', runState: {
6459
+ (event: 'walker run', runState?: {
5841
6460
  consent?: Consent;
5842
6461
  user?: User;
5843
6462
  globals?: Properties;
@@ -5942,7 +6561,7 @@ interface Instance$3 {
5942
6561
  /**
5943
6562
  * Logger configuration options
5944
6563
  */
5945
- interface Config$5 {
6564
+ interface Config$4 {
5946
6565
  /**
5947
6566
  * Minimum log level to display
5948
6567
  * @default Level.ERROR
@@ -5958,7 +6577,7 @@ interface Config$5 {
5958
6577
  }
5959
6578
 
5960
6579
  /** Collector state mapping for the `on` actions. */
5961
- type Config$4 = {
6580
+ type Config$3 = {
5962
6581
  config?: Array<GenericFn>;
5963
6582
  consent?: Array<ConsentRule>;
5964
6583
  custom?: Array<GenericFn>;
@@ -5969,25 +6588,25 @@ type Config$4 = {
5969
6588
  user?: Array<UserFn>;
5970
6589
  };
5971
6590
  /** Allow arbitrary string events via `(string & {})`. */
5972
- type Types$3 = keyof Config$4 | (string & {});
6591
+ type Types$3 = keyof Config$3 | (string & {});
5973
6592
  /**
5974
6593
  * Context provided to every `on` callback.
5975
6594
  * Same posture as Mapping.Context: collector + logger only;
5976
6595
  * subscriptions are a collector-level concern, not a stage-level one.
5977
6596
  */
5978
- interface Context$4 {
6597
+ interface Context$3 {
5979
6598
  collector: Instance$5;
5980
6599
  logger: Instance$3;
5981
6600
  }
5982
6601
  /** Unified subscription callback shape. */
5983
- type Fn$2<TData = unknown> = (data: TData, context: Context$4) => PromiseOrValue<void>;
6602
+ type Fn$1<TData = unknown> = (data: TData, context: Context$3) => PromiseOrValue<void>;
5984
6603
  /** Typed-data variants for readability and IntelliSense. All reduce to Fn<TData>. */
5985
- type ConsentFn = Fn$2<Consent>;
5986
- type GenericFn = Fn$2<unknown>;
5987
- type ReadyFn = Fn$2<void>;
5988
- type RunFn = Fn$2<void>;
5989
- type SessionFn = Fn$2<SessionData | undefined>;
5990
- type UserFn = Fn$2<User>;
6604
+ type ConsentFn = Fn$1<Consent>;
6605
+ type GenericFn = Fn$1<unknown>;
6606
+ type ReadyFn = Fn$1<void>;
6607
+ type RunFn = Fn$1<void>;
6608
+ type SessionFn = Fn$1<SessionData | undefined>;
6609
+ type UserFn = Fn$1<User>;
5991
6610
  /**
5992
6611
  * Consent rule: a record of `{ [consentKey]: ConsentFn }`.
5993
6612
  * Only the consent action uses this shape (per-key handler dispatch).
@@ -6012,42 +6631,52 @@ interface OnConfig {
6012
6631
  * Destination `on` handler: receives the action type and a destination context.
6013
6632
  * Already context-style; kept for compatibility with the destination interface.
6014
6633
  */
6015
- type OnFn<T extends TypesGeneric$3 = Types$4> = (type: Types$3, context: Context$5<T>) => PromiseOrValue<void>;
6634
+ type OnFn<T extends TypesGeneric$3 = Types$4> = (type: Types$3, context: Context$4<T>) => PromiseOrValue<void>;
6016
6635
 
6017
6636
  /**
6018
6637
  * Unified route grammar for Flow v4. A `Route` is one of:
6019
- * - a string transformer ID (`"redact"`)
6638
+ * - a transformer ID string (`"redact"`)
6020
6639
  * - a sequence of routes (`["a", "b", "c"]` — sugar for chained `.next`)
6021
6640
  * - a `RouteConfig` — a gated / dispatching node.
6022
6641
  *
6023
- * `RouteConfig` is a disjoint union: a single config may set either `next`,
6024
- * `case`, or neither (pure gate), but never more than one operator.
6642
+ * `RouteConfig` is a disjoint union set exactly one of `next`, `one`,
6643
+ * `many`, or neither (pure gate). The disjointness is enforced by `never`
6644
+ * sibling properties at the type level and `z.strictObject` at the schema
6645
+ * level.
6025
6646
  *
6026
- * The `branch` operator from the design plan is intentionally absent until
6027
- * `docs/plans/2026-05-12-route-branch-semantics-design.md` resolves.
6647
+ * Operators:
6648
+ * - `next`: single continuation.
6649
+ * - `one`: first-match dispatch (walk entries, first whose match passes wins).
6650
+ * - `many`: all-match terminal fan-out (every matching entry spawns an
6651
+ * independent flow; main chain terminates here). Restricted to
6652
+ * pre-collector positions (source.next, transformer.next, transformer.before).
6028
6653
  */
6029
6654
  type Route = string | Route[] | RouteConfig;
6030
- type RouteConfig = RouteNextConfig | RouteCaseConfig | RouteGateConfig;
6655
+ type RouteConfig = RouteNextConfig | RouteOneConfig | RouteManyConfig | RouteGateConfig;
6031
6656
  interface RouteNextConfig {
6032
6657
  match?: MatchExpression;
6033
6658
  next: Route;
6034
- case?: never;
6659
+ one?: never;
6660
+ many?: never;
6661
+ }
6662
+ interface RouteOneConfig {
6663
+ match?: MatchExpression;
6664
+ one: Route[];
6665
+ next?: never;
6666
+ many?: never;
6035
6667
  }
6036
- interface RouteCaseConfig {
6668
+ interface RouteManyConfig {
6037
6669
  match?: MatchExpression;
6038
- case: Route[];
6670
+ many: Route[];
6039
6671
  next?: never;
6672
+ one?: never;
6040
6673
  }
6041
6674
  interface RouteGateConfig {
6042
6675
  match: MatchExpression;
6043
6676
  next?: never;
6044
- case?: never;
6677
+ one?: never;
6678
+ many?: never;
6045
6679
  }
6046
- /**
6047
- * Backward-compatible alias. New code should use `Route` directly.
6048
- * Kept for compatibility with existing imports across the codebase.
6049
- */
6050
- type RouteSpec = Route;
6051
6680
  /**
6052
6681
  * Base environment interface for walkerOS transformers.
6053
6682
  *
@@ -6088,13 +6717,13 @@ type Env$2<T extends TypesGeneric$2 = Types$2> = T['env'];
6088
6717
  /**
6089
6718
  * Transformer configuration.
6090
6719
  */
6091
- interface Config$3<T extends TypesGeneric$2 = Types$2> {
6720
+ interface Config$2<T extends TypesGeneric$2 = Types$2> {
6092
6721
  settings?: InitSettings$2<T>;
6093
6722
  env?: Env$2<T>;
6094
6723
  id?: string;
6095
- logger?: Config$5;
6096
- before?: RouteSpec;
6097
- next?: RouteSpec;
6724
+ logger?: Config$4;
6725
+ before?: Route;
6726
+ next?: Route;
6098
6727
  cache?: Cache;
6099
6728
  init?: boolean;
6100
6729
  disabled?: boolean;
@@ -6117,13 +6746,13 @@ interface Config$3<T extends TypesGeneric$2 = Types$2> {
6117
6746
  * `mapping[].data`, `silent`) are ignored at this position with a
6118
6747
  * one-time warning.
6119
6748
  */
6120
- mapping?: Config;
6749
+ mapping?: Config$7;
6121
6750
  }
6122
6751
  /**
6123
6752
  * Context provided to transformer functions.
6124
6753
  * Extends base context with transformer-specific properties.
6125
6754
  */
6126
- interface Context$3<T extends TypesGeneric$2 = Types$2> extends Base<Config$3<T>, Env$2<T>> {
6755
+ interface Context$2<T extends TypesGeneric$2 = Types$2> extends Base<Config$2<T>, Env$2<T>> {
6127
6756
  id: string;
6128
6757
  ingest: Ingest;
6129
6758
  }
@@ -6138,7 +6767,7 @@ interface Context$3<T extends TypesGeneric$2 = Types$2> extends Base<Config$3<T>
6138
6767
  interface Result<E = DeepPartialEvent> {
6139
6768
  event?: E;
6140
6769
  respond?: RespondFn;
6141
- next?: RouteSpec;
6770
+ next?: Route;
6142
6771
  }
6143
6772
  /**
6144
6773
  * The main transformer function.
@@ -6153,7 +6782,7 @@ interface Result<E = DeepPartialEvent> {
6153
6782
  * @returns void - continue with current event unchanged (passthrough)
6154
6783
  * @returns false - stop chain, cancel further processing
6155
6784
  */
6156
- type Fn$1<T extends TypesGeneric$2 = Types$2, E = DeepPartialEvent> = (event: E, context: Context$3<T>) => PromiseOrValue<Result<E> | Result<E>[] | false | void>;
6785
+ type Fn<T extends TypesGeneric$2 = Types$2, E = DeepPartialEvent> = (event: E, context: Context$2<T>) => PromiseOrValue<Result<E> | Result<E>[] | false | void>;
6157
6786
  /**
6158
6787
  * Optional initialization function.
6159
6788
  * Called once before first push.
@@ -6163,22 +6792,22 @@ type Fn$1<T extends TypesGeneric$2 = Types$2, E = DeepPartialEvent> = (event: E,
6163
6792
  * @returns false - initialization failed, skip this transformer
6164
6793
  * @returns Config<T> - return updated config
6165
6794
  */
6166
- type InitFn<T extends TypesGeneric$2 = Types$2> = (context: Context$3<T>) => PromiseOrValue<void | false | Config$3<T>>;
6795
+ type InitFn<T extends TypesGeneric$2 = Types$2> = (context: Context$2<T>) => PromiseOrValue<void | false | Config$2<T>>;
6167
6796
  /**
6168
6797
  * Transformer instance returned by Init function.
6169
6798
  */
6170
6799
  interface Instance$2<T extends TypesGeneric$2 = Types$2> {
6171
6800
  type: string;
6172
- config: Config$3<T>;
6173
- push: Fn$1<T>;
6801
+ config: Config$2<T>;
6802
+ push: Fn<T>;
6174
6803
  init?: InitFn<T>;
6175
- destroy?: DestroyFn<Config$3<T>, Env$2<T>>;
6804
+ destroy?: DestroyFn<Config$2<T>, Env$2<T>>;
6176
6805
  }
6177
6806
  /**
6178
6807
  * Transformer initialization function.
6179
6808
  * Creates a transformer instance from context.
6180
6809
  */
6181
- type Init$2<T extends TypesGeneric$2 = Types$2> = (context: Context$3<Types$2<Partial<Settings$1<T>>, Env$2<T>, InitSettings$2<T>>>) => Instance$2<T> | Promise<Instance$2<T>>;
6810
+ type Init$2<T extends TypesGeneric$2 = Types$2> = (context: Context$2<Types$2<Partial<Settings$1<T>>, Env$2<T>, InitSettings$2<T>>>) => Instance$2<T> | Promise<Instance$2<T>>;
6182
6811
  /**
6183
6812
  * Configuration for initializing a transformer.
6184
6813
  * Used in collector registration.
@@ -6193,16 +6822,16 @@ type InitTransformer<T extends TypesGeneric$2 = Types$2> = {
6193
6822
  *
6194
6823
  * Validation: an entry without `code` must declare at least one of
6195
6824
  * `package`, `before`, `next`, `cache`, `mapping`. Enforced by
6196
- * `validateTransformerEntry` in `@walkeros/core`.
6825
+ * `validateStepEntry` in `@walkeros/core`.
6197
6826
  */
6198
6827
  code?: Init$2<T>;
6199
- config?: Partial<Config$3<T>>;
6828
+ config?: Partial<Config$2<T>>;
6200
6829
  env?: Partial<Env$2<T>>;
6201
- before?: RouteSpec;
6202
- next?: RouteSpec;
6830
+ before?: Route;
6831
+ next?: Route;
6203
6832
  cache?: Cache;
6204
- mapping?: Config;
6205
- validate?: Validate$1;
6833
+ mapping?: Config$7;
6834
+ validate?: Validate;
6206
6835
  };
6207
6836
  /**
6208
6837
  * Transformers configuration for collector.
@@ -6223,7 +6852,7 @@ interface BaseEnv$1 {
6223
6852
  push: PushFn$1;
6224
6853
  command: CommandFn;
6225
6854
  sources?: Sources;
6226
- elb: Fn$3;
6855
+ elb: Fn$2;
6227
6856
  logger: Instance$3;
6228
6857
  }
6229
6858
  /**
@@ -6237,7 +6866,7 @@ interface BaseEnv$1 {
6237
6866
  * @template I - InitSettings configuration type (user input)
6238
6867
  * @template U - Setup options type (provisioning options for `walkeros setup`)
6239
6868
  */
6240
- interface Types$1<S = unknown, M = unknown, P = Fn$3, E = BaseEnv$1, I = S, U = unknown> {
6869
+ interface Types$1<S = unknown, M = unknown, P = Fn$2, E = BaseEnv$1, I = S, U = unknown> {
6241
6870
  settings: S;
6242
6871
  initSettings: I;
6243
6872
  mapping: M;
@@ -6261,7 +6890,7 @@ type Mapping<T extends TypesGeneric$1 = Types$1> = T['mapping'];
6261
6890
  type Push<T extends TypesGeneric$1 = Types$1> = T['push'];
6262
6891
  type Env$1<T extends TypesGeneric$1 = Types$1> = T['env'];
6263
6892
  type SetupOptions$1<T extends TypesGeneric$1 = Types$1> = T['setup'];
6264
- interface Config$2<T extends TypesGeneric$1 = Types$1> extends Config<Mapping<T>> {
6893
+ interface Config$1<T extends TypesGeneric$1 = Types$1> extends Config$7<Mapping<T>> {
6265
6894
  /** Implementation-specific configuration passed to the init function. */
6266
6895
  settings?: InitSettings$1<T>;
6267
6896
  /** Runtime dependencies injected by the collector (push, command, logger, etc.). */
@@ -6269,7 +6898,7 @@ interface Config$2<T extends TypesGeneric$1 = Types$1> extends Config<Mapping<T>
6269
6898
  /** Source identifier; defaults to the InitSources object key. */
6270
6899
  id?: string;
6271
6900
  /** Logger configuration (level, handler) to override the collector's defaults. */
6272
- logger?: Config$5;
6901
+ logger?: Config$4;
6273
6902
  /** Mark as primary source; its push function becomes the exported `elb` from startFlow. */
6274
6903
  primary?: boolean;
6275
6904
  /** Defer source initialization until these collector events fire (e.g., `['consent']`). */
@@ -6291,7 +6920,7 @@ interface Config$2<T extends TypesGeneric$1 = Types$1> extends Config<Mapping<T>
6291
6920
  * origin: 'req.headers.origin'
6292
6921
  * }
6293
6922
  */
6294
- ingest?: Data;
6923
+ ingest?: Data$1;
6295
6924
  /** Completely skip this source — no init, no event capture. */
6296
6925
  disabled?: boolean;
6297
6926
  /**
@@ -6304,10 +6933,10 @@ interface Config$2<T extends TypesGeneric$1 = Types$1> extends Config<Mapping<T>
6304
6933
  }
6305
6934
  interface Instance$1<T extends TypesGeneric$1 = Types$1> {
6306
6935
  type: string;
6307
- config: Config$2<T>;
6308
- setup?: SetupFn<Config$2<T>, Env$1<T>>;
6936
+ config: Config$1<T>;
6937
+ setup?: SetupFn<Config$1<T>, Env$1<T>>;
6309
6938
  push: Push<T>;
6310
- destroy?: DestroyFn<Config$2<T>, Env$1<T>>;
6939
+ destroy?: DestroyFn<Config$1<T>, Env$1<T>>;
6311
6940
  on?(event: Types$3, context?: unknown): void | boolean | Promise<void | boolean>;
6312
6941
  /**
6313
6942
  * Optional setup hook. Called by the collector eagerly after all source
@@ -6327,33 +6956,67 @@ interface Instance$1<T extends TypesGeneric$1 = Types$1> {
6327
6956
  data: unknown;
6328
6957
  }>;
6329
6958
  }
6959
+ /**
6960
+ * Per-scope environment passed to the body of `Source.Context.withScope`.
6961
+ *
6962
+ * Each call to `withScope` builds a fresh `ScopeEnv` whose `push` captures
6963
+ * the per-scope `ingest` and `respond`. Concurrent scopes cannot crosstalk:
6964
+ * each one carries its own ingest and respond all the way through the
6965
+ * pipeline. Server sources MUST use `withScope` per inbound request; sources
6966
+ * with a single logical scope (browser tab lifetime, dataLayer) may skip it
6967
+ * and use the factory-scope `env.push` directly.
6968
+ */
6969
+ type ScopeEnv<T extends TypesGeneric$1 = Types$1> = Env$1<T> & {
6970
+ /** Per-scope push: captures the scope's ingest and respond for this call. */
6971
+ push: PushFn$1;
6972
+ /** Ingest metadata extracted from the raw scope input (if config.ingest is set). */
6973
+ ingest: Ingest;
6974
+ /** Respond function bound to this scope (undefined for scopes without a response). */
6975
+ respond?: RespondFn;
6976
+ };
6330
6977
  /**
6331
6978
  * Context provided to source init function.
6332
6979
  * Extends base context with source-specific properties.
6333
6980
  */
6334
- interface Context$2<T extends TypesGeneric$1 = Types$1> extends Base<Partial<Config$2<T>>, Env$1<T>> {
6981
+ interface Context$1<T extends TypesGeneric$1 = Types$1> extends Base<Partial<Config$1<T>>, Env$1<T>> {
6335
6982
  id: string;
6336
6983
  /**
6337
- * Sets ingest metadata for the current request.
6338
- * Extracts values from the raw request using config.ingest mapping.
6339
- * The extracted data is passed through to transformers and destinations.
6984
+ * Bind ingest and respond to a single scope of work (e.g. one inbound
6985
+ * HTTP request, one queue message). Builds a fresh `Ingest` from the
6986
+ * raw input via `config.ingest` mapping, wires the per-scope `respond`,
6987
+ * and invokes `body(scopeEnv)` with a push function that captures both.
6340
6988
  *
6341
- * @param value - Raw request object (Express req, Lambda event, etc.)
6989
+ * Server sources call this once per inbound request:
6990
+ *
6991
+ * ```ts
6992
+ * await context.withScope(req, createRespond(sender), async (env) => {
6993
+ * await env.push(parsedData);
6994
+ * });
6995
+ * ```
6996
+ *
6997
+ * Browser sources with a single tab-lifetime scope may skip `withScope`
6998
+ * and use `env.push` directly.
6999
+ *
7000
+ * @param rawScope - Raw input for `config.ingest` mapping (Express req,
7001
+ * Lambda event, fetch Request, etc.). Pass `undefined` if no ingest
7002
+ * mapping applies.
7003
+ * @param respond - Per-scope respond function, or `undefined` if the
7004
+ * scope produces no response.
7005
+ * @param body - Async callback receiving the per-scope env.
7006
+ * @returns The body's return value.
6342
7007
  */
6343
- setIngest: (value: unknown) => Promise<void>;
6344
- /** Sets respond function for the current request. Called by source per-request. */
6345
- setRespond: (fn: RespondFn | undefined) => void;
7008
+ withScope: <R>(rawScope: unknown, respond: RespondFn | undefined, body: (env: ScopeEnv<T>) => Promise<R>) => Promise<R>;
6346
7009
  }
6347
- type Init$1<T extends TypesGeneric$1 = Types$1> = (context: Context$2<T>) => Instance$1<T> | Promise<Instance$1<T>>;
7010
+ type Init$1<T extends TypesGeneric$1 = Types$1> = (context: Context$1<T>) => Instance$1<T> | Promise<Instance$1<T>>;
6348
7011
  type InitSource<T extends TypesGeneric$1 = Types$1> = {
6349
7012
  code: Init$1<T>;
6350
- config?: Partial<Config$2<T>>;
7013
+ config?: Partial<Config$1<T>>;
6351
7014
  env?: Partial<Env$1<T>>;
6352
7015
  primary?: boolean;
6353
- next?: RouteSpec;
6354
- before?: RouteSpec;
7016
+ next?: Route;
7017
+ before?: Route;
6355
7018
  cache?: Cache;
6356
- validate?: Validate$1;
7019
+ validate?: Validate;
6357
7020
  };
6358
7021
  /**
6359
7022
  * Sources configuration for collector.
@@ -6382,18 +7045,18 @@ type Settings<T extends TypesGeneric = Types> = T['settings'];
6382
7045
  type InitSettings<T extends TypesGeneric = Types> = T['initSettings'];
6383
7046
  type Env<T extends TypesGeneric = Types> = T['env'];
6384
7047
  type SetupOptions<T extends TypesGeneric = Types> = T['setup'];
6385
- interface Config$1<T extends TypesGeneric = Types> {
7048
+ interface Config<T extends TypesGeneric = Types> {
6386
7049
  settings?: InitSettings<T>;
6387
7050
  env?: Env<T>;
6388
7051
  id?: string;
6389
- logger?: Config$5;
7052
+ logger?: Config$4;
6390
7053
  /**
6391
7054
  * Provisioning options for `walkeros setup`. `boolean | object`.
6392
7055
  * Triggered only by explicit CLI invocation; never automatic.
6393
7056
  */
6394
7057
  setup?: boolean | SetupOptions<T>;
6395
7058
  }
6396
- interface Context$1<T extends TypesGeneric = Types> extends Base<Config$1<T>, Env<T>> {
7059
+ interface Context<T extends TypesGeneric = Types> extends Base<Config<T>, Env<T>> {
6397
7060
  id: string;
6398
7061
  }
6399
7062
  type GetFn<T = unknown> = (key: string) => T | undefined | Promise<T | undefined>;
@@ -6401,17 +7064,17 @@ type SetFn<T = unknown> = (key: string, value: T, ttl?: number) => void | Promis
6401
7064
  type DeleteFn = (key: string) => void | Promise<void>;
6402
7065
  interface Instance<T extends TypesGeneric = Types> {
6403
7066
  type: string;
6404
- config: Config$1<T>;
7067
+ config: Config<T>;
6405
7068
  get: GetFn;
6406
7069
  set: SetFn;
6407
7070
  delete: DeleteFn;
6408
- setup?: SetupFn<Config$1<T>, Env<T>>;
6409
- destroy?: DestroyFn<Config$1<T>, Env<T>>;
7071
+ setup?: SetupFn<Config<T>, Env<T>>;
7072
+ destroy?: DestroyFn<Config<T>, Env<T>>;
6410
7073
  }
6411
- type Init<T extends TypesGeneric = Types> = (context: Context$1<Types<Partial<Settings<T>>, Env<T>, InitSettings<T>>>) => Instance<T> | Promise<Instance<T>>;
7074
+ type Init<T extends TypesGeneric = Types> = (context: Context<Types<Partial<Settings<T>>, Env<T>, InitSettings<T>>>) => Instance<T> | Promise<Instance<T>>;
6412
7075
  type InitStore<T extends TypesGeneric = Types> = {
6413
7076
  code: Init<T>;
6414
- config?: Partial<Config$1<T>>;
7077
+ config?: Partial<Config<T>>;
6415
7078
  env?: Partial<Env<T>>;
6416
7079
  };
6417
7080
  interface InitStores {
@@ -6506,88 +7169,43 @@ type DeepPartial<T> = {
6506
7169
  type PromiseOrValue<T> = T | Promise<T>;
6507
7170
 
6508
7171
  /**
6509
- * Shared mapping configuration interface.
6510
- * Used by both Source.Config and Destination.Config.
7172
+ * Flow Configuration System (v4)
7173
+ *
7174
+ * Core types for walkerOS unified configuration.
7175
+ * Platform-agnostic, runtime-focused.
7176
+ *
7177
+ * The Flow system enables "one config to rule them all" - a single
7178
+ * walkeros.config.json file that manages multiple flows
7179
+ * (web_prod, web_stage, server_prod, etc.) with shared configuration
7180
+ * and reusable variables.
7181
+ *
7182
+ * Single declaration merge: `Flow` is both the interface for one flow
7183
+ * and the namespace holding all related types.
7184
+ *
7185
+ * ## Connection Rules
7186
+ *
7187
+ * Sources use `next` to connect to transformers (pre-collector chain).
7188
+ * Sources use `before` for consent-exempt pre-source preprocessing
7189
+ * (decode, validate, authenticate raw input before the source.next chain).
7190
+ *
7191
+ * Destinations use `before` to connect to transformers (post-collector chain).
7192
+ * Destinations use `next` for post-push processing.
7193
+ *
7194
+ * Transformers use `next` to chain to other transformers. The same transformer
7195
+ * pool is shared by both pre-collector and post-collector chains.
7196
+ *
7197
+ * The collector is implicit - it is never referenced directly in connections.
7198
+ * It sits between the source chain and the destination chain automatically.
7199
+ *
7200
+ * Circular `next` references are safely handled at runtime by `walkChain()`
7201
+ * in the collector module (visited-set detection).
7202
+ *
7203
+ * ```
7204
+ * Source → [before → Preprocessing] → [next → Transformer chain] → Collector → [before → Transformer chain] → Destination → [next → Post-push]
7205
+ * ```
7206
+ *
7207
+ * @packageDocumentation
6511
7208
  */
6512
- interface Config<T = unknown> {
6513
- consent?: Consent;
6514
- data?: Value | Values;
6515
- include?: string[];
6516
- mapping?: Rules<Rule<T>>;
6517
- policy?: Policy;
6518
- }
6519
- interface Policy {
6520
- [key: string]: Value;
6521
- }
6522
- interface Rules<T = Rule> {
6523
- [entity: string]: Record<string, T | Array<T>> | undefined;
6524
- }
6525
- interface Rule<Settings = unknown> {
6526
- batch?: number;
6527
- batchFn?: (destination: Instance$4, collector: Instance$5) => void;
6528
- batched?: Batch<Settings>;
6529
- condition?: Condition;
6530
- consent?: Consent;
6531
- settings?: Settings;
6532
- data?: Data;
6533
- include?: string[];
6534
- ignore?: boolean;
6535
- silent?: boolean;
6536
- name?: string;
6537
- policy?: Policy;
6538
- }
6539
- type Data = Value | Values;
6540
- type Value = ValueType | Array<ValueType>;
6541
- type Values = Array<Value>;
6542
- type ValueType = string | ValueConfig;
6543
- interface ValueConfig {
6544
- condition?: Condition;
6545
- consent?: Consent;
6546
- fn?: Fn;
6547
- key?: string;
6548
- loop?: Loop;
6549
- map?: Map;
6550
- set?: Value[];
6551
- validate?: Validate;
6552
- value?: PropertyType;
6553
- }
6554
- interface Context {
6555
- event: DeepPartialEvent;
6556
- /** The surrounding mapping config: a Value (value-level) or a Rule (rule-level). */
6557
- mapping: Value | Rule;
6558
- collector: Instance$5;
6559
- logger: Instance$3;
6560
- consent?: Consent;
6561
- }
6562
- type Fn = (value: unknown, context: Context) => PromiseOrValue<Property | unknown>;
6563
- type Condition = (value: unknown, context: Context) => PromiseOrValue<boolean>;
6564
- type Validate = (value: unknown, context: Context) => PromiseOrValue<boolean>;
6565
- type Loop = [Value, Value];
6566
- type Map = {
6567
- [key: string]: Value;
6568
- };
6569
-
6570
- interface CacheRule {
6571
- /**
6572
- * Optional match expression. Omitted means always-match.
6573
- */
6574
- match?: MatchExpression;
6575
- key: string[];
6576
- ttl: number;
6577
- update?: Record<string, Value>;
6578
- }
6579
- interface Cache {
6580
- /**
6581
- * Stop the chain on cache HIT (default: false). When true, skip remaining steps and return cached value.
6582
- */
6583
- stop?: boolean;
6584
- store?: string;
6585
- /**
6586
- * Optional key prefix written to the store. When absent, cache keys are written directly. Same store + same key + same namespace = same cache entry.
6587
- */
6588
- namespace?: string;
6589
- rules: CacheRule[];
6590
- }
6591
7209
 
6592
7210
  /**
6593
7211
  * Single flow configuration.
@@ -6843,13 +7461,27 @@ declare namespace Flow {
6843
7461
  */
6844
7462
  package?: string;
6845
7463
  /**
6846
- * Resolved import variable name (string) or inline code definition (Code).
7464
+ * Inline code definition (object form only).
6847
7465
  *
6848
- * - String: auto-resolved from packages[package].imports[0] during getFlowSettings(),
6849
- * or provided explicitly for advanced use cases.
6850
- * - Code: object with type, push, and optional init for inline code definition.
7466
+ * Object: `{push, type?, init?}` for inline code definition.
7467
+ * For named-export selection from a package, use the `import` field with `package`.
7468
+ */
7469
+ code?: Code;
7470
+ /**
7471
+ * Named export from `package` to import as this source's implementation.
7472
+ *
7473
+ * Requires `package` to be set. Mutually exclusive with `code`.
7474
+ *
7475
+ * - Top-level identifier only: `/^[A-Za-z_$][A-Za-z0-9_$]*$/`. No dotted paths.
7476
+ * - `package: "X"` alone (no `import`, no `code`) loads X's default export.
7477
+ * - `package: "X"` + `import: "fooFactory"` loads named export `fooFactory` from X.
7478
+ *
7479
+ * @example
7480
+ * ```json
7481
+ * { "package": "@walkeros/web-source-browser", "import": "sourceBrowser" }
7482
+ * ```
6851
7483
  */
6852
- code?: string | Code;
7484
+ import?: string;
6853
7485
  /**
6854
7486
  * Source-specific configuration. Structure depends on the source package.
6855
7487
  * Passed to the source's initialization function.
@@ -6877,7 +7509,7 @@ declare namespace Flow {
6877
7509
  * (decode, validate, authenticate, normalize raw input).
6878
7510
  * Raw request data is available in context.ingest.
6879
7511
  */
6880
- before?: RouteSpec;
7512
+ before?: Route;
6881
7513
  /**
6882
7514
  * First transformer in pre-collector chain.
6883
7515
  *
@@ -6886,10 +7518,10 @@ declare namespace Flow {
6886
7518
  * If omitted, events route directly to the collector.
6887
7519
  * Can be an array for explicit chain control (bypasses transformer.next resolution).
6888
7520
  */
6889
- next?: RouteSpec;
7521
+ next?: Route;
6890
7522
  /** Cache configuration for this source. */
6891
- cache?: Cache;
6892
- validate?: Validate$1;
7523
+ cache?: Cache<EventCacheRule>;
7524
+ validate?: Validate;
6893
7525
  /**
6894
7526
  * Source-level variables (highest priority in cascade).
6895
7527
  * Overrides flow and root variables.
@@ -6910,8 +7542,23 @@ declare namespace Flow {
6910
7542
  interface Destination {
6911
7543
  /** Package specifier with optional version. Optional when `code` is provided. */
6912
7544
  package?: string;
6913
- /** Resolved import variable name (string) or inline code definition (Code). */
6914
- code?: string | Code;
7545
+ /**
7546
+ * Inline code definition (object form only).
7547
+ *
7548
+ * Object: `{push, type?, init?}` for inline code definition.
7549
+ * For named-export selection from a package, use the `import` field with `package`.
7550
+ */
7551
+ code?: Code;
7552
+ /**
7553
+ * Named export from `package` to import as this destination's implementation.
7554
+ * See `Flow.Source.import` for full rules.
7555
+ *
7556
+ * @example
7557
+ * ```json
7558
+ * { "package": "@walkeros/web-destination-gtag", "import": "destinationGtag" }
7559
+ * ```
7560
+ */
7561
+ import?: string;
6915
7562
  /**
6916
7563
  * Destination-specific configuration. Typically includes:
6917
7564
  * - settings: API keys, IDs, endpoints
@@ -6929,7 +7576,7 @@ declare namespace Flow {
6929
7576
  * If omitted, events are sent directly from the collector.
6930
7577
  * Can be an array for explicit chain control.
6931
7578
  */
6932
- before?: RouteSpec;
7579
+ before?: Route;
6933
7580
  /**
6934
7581
  * First transformer in post-push chain.
6935
7582
  *
@@ -6937,10 +7584,10 @@ declare namespace Flow {
6937
7584
  * at context.ingest._response. Consent is inherited from the destination
6938
7585
  * gate - no separate consent check needed.
6939
7586
  */
6940
- next?: RouteSpec;
7587
+ next?: Route;
6941
7588
  /** Cache configuration for this destination. */
6942
- cache?: Cache;
6943
- validate?: Validate$1;
7589
+ cache?: Cache<EventCacheRule>;
7590
+ validate?: Validate;
6944
7591
  /** Destination-level variables (highest priority in cascade). */
6945
7592
  variables?: Variables;
6946
7593
  /**
@@ -6958,8 +7605,23 @@ declare namespace Flow {
6958
7605
  interface Transformer {
6959
7606
  /** Package specifier with optional version. Optional when `code` is provided. */
6960
7607
  package?: string;
6961
- /** Resolved import variable name (string) or inline code definition (Code). */
6962
- code?: string | Code;
7608
+ /**
7609
+ * Inline code definition (object form only).
7610
+ *
7611
+ * Object: `{push, type?, init?}` for inline code definition.
7612
+ * For named-export selection from a package, use the `import` field with `package`.
7613
+ */
7614
+ code?: Code;
7615
+ /**
7616
+ * Named export from `package` to import as this transformer's implementation.
7617
+ * See `Flow.Source.import` for full rules.
7618
+ *
7619
+ * @example
7620
+ * ```json
7621
+ * { "package": "@walkeros/transformer-ga4", "import": "transformerGa4" }
7622
+ * ```
7623
+ */
7624
+ import?: string;
6963
7625
  /** Transformer-specific configuration. Structure depends on the package. */
6964
7626
  config?: unknown;
6965
7627
  /** Transformer environment configuration. */
@@ -6971,7 +7633,7 @@ declare namespace Flow {
6971
7633
  * Enables pre-processing or context loading before the main transform.
6972
7634
  * Uses the same chain resolution as source.next and destination.before.
6973
7635
  */
6974
- before?: RouteSpec;
7636
+ before?: Route;
6975
7637
  /**
6976
7638
  * Next transformer in chain.
6977
7639
  *
@@ -6982,10 +7644,10 @@ declare namespace Flow {
6982
7644
  * Array values define an explicit chain (no walking). Circular references
6983
7645
  * are safely detected at runtime by `walkChain()`.
6984
7646
  */
6985
- next?: RouteSpec;
7647
+ next?: Route;
6986
7648
  /** Cache configuration for this transformer. */
6987
- cache?: Cache;
6988
- validate?: Validate$1;
7649
+ cache?: Cache<EventCacheRule>;
7650
+ validate?: Validate;
6989
7651
  /** Transformer-level variables (highest priority in cascade). */
6990
7652
  variables?: Variables;
6991
7653
  /**
@@ -7004,12 +7666,35 @@ declare namespace Flow {
7004
7666
  interface Store {
7005
7667
  /** Package specifier with optional version. Optional when `code` is provided. */
7006
7668
  package?: string;
7007
- /** Resolved import variable name (string) or inline code definition (Code). */
7008
- code?: string | Code;
7669
+ /**
7670
+ * Inline code definition (object form only).
7671
+ *
7672
+ * Object: `{push, type?, init?}` for inline code definition.
7673
+ * For named-export selection from a package, use the `import` field with `package`.
7674
+ */
7675
+ code?: Code;
7676
+ /**
7677
+ * Named export from `package` to import as this store's implementation.
7678
+ * See `Flow.Source.import` for full rules.
7679
+ *
7680
+ * @example
7681
+ * ```json
7682
+ * { "package": "@walkeros/server-store-fs", "import": "storeFs" }
7683
+ * ```
7684
+ */
7685
+ import?: string;
7009
7686
  /** Store-specific configuration. */
7010
7687
  config?: unknown;
7011
7688
  /** Store environment configuration. */
7012
7689
  env?: unknown;
7690
+ /**
7691
+ * Cache configuration for this store.
7692
+ *
7693
+ * When present, the collector wraps the bare store with a cache layer
7694
+ * (read-through, write-through, single-flight). The cache layer may
7695
+ * recursively delegate to another store via `cache.store`.
7696
+ */
7697
+ cache?: Cache<StoreCacheRule>;
7013
7698
  /** Store-level variables (highest priority in cascade). */
7014
7699
  variables?: Variables;
7015
7700
  /**