@opencrvs/toolkit 1.8.1-rc.1e3e9b5 → 1.8.1-rc.20fdb4a

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.
@@ -1418,6 +1418,10 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1418
1418
  type: "REJECT_CORRECTION";
1419
1419
  id: string & import("zod").BRAND<"UUID">;
1420
1420
  status: "Rejected" | "Requested" | "Accepted";
1421
+ reason: {
1422
+ message: string;
1423
+ isDuplicate?: boolean | undefined;
1424
+ };
1421
1425
  transactionId: string;
1422
1426
  createdByUserType: "system" | "user";
1423
1427
  createdAt: string;
@@ -2984,6 +2988,10 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2984
2988
  type: "REJECT_CORRECTION";
2985
2989
  id: string & import("zod").BRAND<"UUID">;
2986
2990
  status: "Rejected" | "Requested" | "Accepted";
2991
+ reason: {
2992
+ message: string;
2993
+ isDuplicate?: boolean | undefined;
2994
+ };
2987
2995
  transactionId: string;
2988
2996
  createdByUserType: "system" | "user";
2989
2997
  createdAt: string;
@@ -5342,6 +5350,10 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5342
5350
  type: "REJECT_CORRECTION";
5343
5351
  id: string & import("zod").BRAND<"UUID">;
5344
5352
  status: "Rejected" | "Requested" | "Accepted";
5353
+ reason: {
5354
+ message: string;
5355
+ isDuplicate?: boolean | undefined;
5356
+ };
5345
5357
  transactionId: string;
5346
5358
  createdByUserType: "system" | "user";
5347
5359
  createdAt: string;
@@ -7005,6 +7017,10 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
7005
7017
  type: "REJECT_CORRECTION";
7006
7018
  id: string & import("zod").BRAND<"UUID">;
7007
7019
  status: "Rejected" | "Requested" | "Accepted";
7020
+ reason: {
7021
+ message: string;
7022
+ isDuplicate?: boolean | undefined;
7023
+ };
7008
7024
  transactionId: string;
7009
7025
  createdByUserType: "system" | "user";
7010
7026
  createdAt: string;
@@ -8910,6 +8926,10 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8910
8926
  type: "REJECT_CORRECTION";
8911
8927
  id: string;
8912
8928
  status: "Rejected" | "Requested" | "Accepted";
8929
+ reason: {
8930
+ message: string;
8931
+ isDuplicate?: boolean | undefined;
8932
+ };
8913
8933
  transactionId: string;
8914
8934
  createdByUserType: "system" | "user";
8915
8935
  createdAt: string;
@@ -10472,6 +10492,10 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
10472
10492
  type: "REJECT_CORRECTION";
10473
10493
  id: string & import("zod").BRAND<"UUID">;
10474
10494
  status: "Rejected" | "Requested" | "Accepted";
10495
+ reason: {
10496
+ message: string;
10497
+ isDuplicate?: boolean | undefined;
10498
+ };
10475
10499
  transactionId: string;
10476
10500
  createdByUserType: "system" | "user";
10477
10501
  createdAt: string;
@@ -7945,10 +7945,24 @@ export declare const ActionDocument: z.ZodDiscriminatedUnion<"type", [z.ZodObjec
7945
7945
  }, {
7946
7946
  type: z.ZodLiteral<"REJECT_CORRECTION">;
7947
7947
  requestId: z.ZodString;
7948
+ reason: z.ZodObject<{
7949
+ message: z.ZodString;
7950
+ isDuplicate: z.ZodOptional<z.ZodBoolean>;
7951
+ }, "strip", z.ZodTypeAny, {
7952
+ message: string;
7953
+ isDuplicate?: boolean | undefined;
7954
+ }, {
7955
+ message: string;
7956
+ isDuplicate?: boolean | undefined;
7957
+ }>;
7948
7958
  }>, "strip", z.ZodTypeAny, {
7949
7959
  type: "REJECT_CORRECTION";
7950
7960
  id: string & z.BRAND<"UUID">;
7951
7961
  status: "Rejected" | "Requested" | "Accepted";
7962
+ reason: {
7963
+ message: string;
7964
+ isDuplicate?: boolean | undefined;
7965
+ };
7952
7966
  transactionId: string;
7953
7967
  createdByUserType: "system" | "user";
7954
7968
  createdAt: string;
@@ -8052,6 +8066,10 @@ export declare const ActionDocument: z.ZodDiscriminatedUnion<"type", [z.ZodObjec
8052
8066
  type: "REJECT_CORRECTION";
8053
8067
  id: string;
8054
8068
  status: "Rejected" | "Requested" | "Accepted";
8069
+ reason: {
8070
+ message: string;
8071
+ isDuplicate?: boolean | undefined;
8072
+ };
8055
8073
  transactionId: string;
8056
8074
  createdByUserType: "system" | "user";
8057
8075
  createdAt: string;
@@ -15610,10 +15628,24 @@ export declare const Action: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.ZodO
15610
15628
  }, {
15611
15629
  type: z.ZodLiteral<"REJECT_CORRECTION">;
15612
15630
  requestId: z.ZodString;
15631
+ reason: z.ZodObject<{
15632
+ message: z.ZodString;
15633
+ isDuplicate: z.ZodOptional<z.ZodBoolean>;
15634
+ }, "strip", z.ZodTypeAny, {
15635
+ message: string;
15636
+ isDuplicate?: boolean | undefined;
15637
+ }, {
15638
+ message: string;
15639
+ isDuplicate?: boolean | undefined;
15640
+ }>;
15613
15641
  }>, "strip", z.ZodTypeAny, {
15614
15642
  type: "REJECT_CORRECTION";
15615
15643
  id: string & z.BRAND<"UUID">;
15616
15644
  status: "Rejected" | "Requested" | "Accepted";
15645
+ reason: {
15646
+ message: string;
15647
+ isDuplicate?: boolean | undefined;
15648
+ };
15617
15649
  transactionId: string;
15618
15650
  createdByUserType: "system" | "user";
15619
15651
  createdAt: string;
@@ -15717,6 +15749,10 @@ export declare const Action: z.ZodUnion<[z.ZodDiscriminatedUnion<"type", [z.ZodO
15717
15749
  type: "REJECT_CORRECTION";
15718
15750
  id: string;
15719
15751
  status: "Rejected" | "Requested" | "Accepted";
15752
+ reason: {
15753
+ message: string;
15754
+ isDuplicate?: boolean | undefined;
15755
+ };
15720
15756
  transactionId: string;
15721
15757
  createdByUserType: "system" | "user";
15722
15758
  createdAt: string;
@@ -5971,8 +5971,22 @@ export declare const RejectCorrectionActionInput: z.ZodObject<z.objectUtil.exten
5971
5971
  }, {
5972
5972
  requestId: z.ZodString;
5973
5973
  type: z.ZodDefault<z.ZodLiteral<"REJECT_CORRECTION">>;
5974
+ reason: z.ZodObject<{
5975
+ message: z.ZodString;
5976
+ isDuplicate: z.ZodOptional<z.ZodBoolean>;
5977
+ }, "strip", z.ZodTypeAny, {
5978
+ message: string;
5979
+ isDuplicate?: boolean | undefined;
5980
+ }, {
5981
+ message: string;
5982
+ isDuplicate?: boolean | undefined;
5983
+ }>;
5974
5984
  }>, "strip", z.ZodTypeAny, {
5975
5985
  type: "REJECT_CORRECTION";
5986
+ reason: {
5987
+ message: string;
5988
+ isDuplicate?: boolean | undefined;
5989
+ };
5976
5990
  transactionId: string;
5977
5991
  declaration: Record<string, string | number | boolean | {
5978
5992
  type: string;
@@ -6069,6 +6083,10 @@ export declare const RejectCorrectionActionInput: z.ZodObject<z.objectUtil.exten
6069
6083
  originalActionId?: (string & z.BRAND<"UUID">) | undefined;
6070
6084
  keepAssignment?: boolean | undefined;
6071
6085
  }, {
6086
+ reason: {
6087
+ message: string;
6088
+ isDuplicate?: boolean | undefined;
6089
+ };
6072
6090
  transactionId: string;
6073
6091
  requestId: string;
6074
6092
  eventId: string;
@@ -13085,8 +13103,22 @@ export declare const ActionInput: z.ZodDiscriminatedUnion<"type", [z.ZodObject<z
13085
13103
  }, {
13086
13104
  requestId: z.ZodString;
13087
13105
  type: z.ZodDefault<z.ZodLiteral<"REJECT_CORRECTION">>;
13106
+ reason: z.ZodObject<{
13107
+ message: z.ZodString;
13108
+ isDuplicate: z.ZodOptional<z.ZodBoolean>;
13109
+ }, "strip", z.ZodTypeAny, {
13110
+ message: string;
13111
+ isDuplicate?: boolean | undefined;
13112
+ }, {
13113
+ message: string;
13114
+ isDuplicate?: boolean | undefined;
13115
+ }>;
13088
13116
  }>, "strip", z.ZodTypeAny, {
13089
13117
  type: "REJECT_CORRECTION";
13118
+ reason: {
13119
+ message: string;
13120
+ isDuplicate?: boolean | undefined;
13121
+ };
13090
13122
  transactionId: string;
13091
13123
  declaration: Record<string, string | number | boolean | {
13092
13124
  type: string;
@@ -13183,6 +13215,10 @@ export declare const ActionInput: z.ZodDiscriminatedUnion<"type", [z.ZodObject<z
13183
13215
  originalActionId?: (string & z.BRAND<"UUID">) | undefined;
13184
13216
  keepAssignment?: boolean | undefined;
13185
13217
  }, {
13218
+ reason: {
13219
+ message: string;
13220
+ isDuplicate?: boolean | undefined;
13221
+ };
13186
13222
  transactionId: string;
13187
13223
  requestId: string;
13188
13224
  eventId: string;
@@ -448,11 +448,11 @@ export declare const SearchQueryParams: z.ZodObject<{
448
448
  export type SearchQueryParams = z.infer<typeof SearchQueryParams>;
449
449
  export declare const FieldConfigSchema: z.ZodObject<z.objectUtil.extendShape<{
450
450
  config: z.ZodObject<{
451
- type: z.ZodEnum<["fuzzy", "exact", "range"]>;
451
+ type: z.ZodEnum<["fuzzy", "exact", "range", "within"]>;
452
452
  }, "strip", z.ZodTypeAny, {
453
- type: "exact" | "fuzzy" | "range";
453
+ type: "exact" | "fuzzy" | "range" | "within";
454
454
  }, {
455
- type: "exact" | "fuzzy" | "range";
455
+ type: "exact" | "fuzzy" | "range" | "within";
456
456
  }>;
457
457
  options: z.ZodOptional<z.ZodArray<z.ZodObject<{
458
458
  value: z.ZodString;
@@ -503,7 +503,7 @@ export declare const FieldConfigSchema: z.ZodObject<z.objectUtil.extendShape<{
503
503
  excludeInSearchQuery: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
504
504
  }>, "strip", z.ZodTypeAny, {
505
505
  config: {
506
- type: "exact" | "fuzzy" | "range";
506
+ type: "exact" | "fuzzy" | "range" | "within";
507
507
  };
508
508
  fieldId: string;
509
509
  fieldType: "field";
@@ -530,7 +530,7 @@ export declare const FieldConfigSchema: z.ZodObject<z.objectUtil.extendShape<{
530
530
  excludeInSearchQuery?: boolean | undefined;
531
531
  }, {
532
532
  config: {
533
- type: "exact" | "fuzzy" | "range";
533
+ type: "exact" | "fuzzy" | "range" | "within";
534
534
  };
535
535
  fieldId: string;
536
536
  fieldType: "field";
@@ -572,11 +572,11 @@ export declare const EventFieldId: z.ZodEnum<["trackingId", "status", "legalStat
572
572
  export type EventFieldId = z.infer<typeof EventFieldId>;
573
573
  export declare const EventFieldConfigSchema: z.ZodObject<z.objectUtil.extendShape<{
574
574
  config: z.ZodObject<{
575
- type: z.ZodEnum<["fuzzy", "exact", "range"]>;
575
+ type: z.ZodEnum<["fuzzy", "exact", "range", "within"]>;
576
576
  }, "strip", z.ZodTypeAny, {
577
- type: "exact" | "fuzzy" | "range";
577
+ type: "exact" | "fuzzy" | "range" | "within";
578
578
  }, {
579
- type: "exact" | "fuzzy" | "range";
579
+ type: "exact" | "fuzzy" | "range" | "within";
580
580
  }>;
581
581
  options: z.ZodOptional<z.ZodArray<z.ZodObject<{
582
582
  value: z.ZodString;
@@ -625,7 +625,7 @@ export declare const EventFieldConfigSchema: z.ZodObject<z.objectUtil.extendShap
625
625
  fieldType: z.ZodLiteral<"event">;
626
626
  }>, "strip", z.ZodTypeAny, {
627
627
  config: {
628
- type: "exact" | "fuzzy" | "range";
628
+ type: "exact" | "fuzzy" | "range" | "within";
629
629
  };
630
630
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
631
631
  fieldType: "event";
@@ -650,7 +650,7 @@ export declare const EventFieldConfigSchema: z.ZodObject<z.objectUtil.extendShap
650
650
  }[] | undefined;
651
651
  }, {
652
652
  config: {
653
- type: "exact" | "fuzzy" | "range";
653
+ type: "exact" | "fuzzy" | "range" | "within";
654
654
  };
655
655
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
656
656
  fieldType: "event";
@@ -688,11 +688,11 @@ export declare const EventFieldConfigSchema: z.ZodObject<z.objectUtil.extendShap
688
688
  }>;
689
689
  export declare const SearchField: z.ZodDiscriminatedUnion<"fieldType", [z.ZodObject<z.objectUtil.extendShape<{
690
690
  config: z.ZodObject<{
691
- type: z.ZodEnum<["fuzzy", "exact", "range"]>;
691
+ type: z.ZodEnum<["fuzzy", "exact", "range", "within"]>;
692
692
  }, "strip", z.ZodTypeAny, {
693
- type: "exact" | "fuzzy" | "range";
693
+ type: "exact" | "fuzzy" | "range" | "within";
694
694
  }, {
695
- type: "exact" | "fuzzy" | "range";
695
+ type: "exact" | "fuzzy" | "range" | "within";
696
696
  }>;
697
697
  options: z.ZodOptional<z.ZodArray<z.ZodObject<{
698
698
  value: z.ZodString;
@@ -743,7 +743,7 @@ export declare const SearchField: z.ZodDiscriminatedUnion<"fieldType", [z.ZodObj
743
743
  excludeInSearchQuery: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
744
744
  }>, "strip", z.ZodTypeAny, {
745
745
  config: {
746
- type: "exact" | "fuzzy" | "range";
746
+ type: "exact" | "fuzzy" | "range" | "within";
747
747
  };
748
748
  fieldId: string;
749
749
  fieldType: "field";
@@ -770,7 +770,7 @@ export declare const SearchField: z.ZodDiscriminatedUnion<"fieldType", [z.ZodObj
770
770
  excludeInSearchQuery?: boolean | undefined;
771
771
  }, {
772
772
  config: {
773
- type: "exact" | "fuzzy" | "range";
773
+ type: "exact" | "fuzzy" | "range" | "within";
774
774
  };
775
775
  fieldId: string;
776
776
  fieldType: "field";
@@ -809,11 +809,11 @@ export declare const SearchField: z.ZodDiscriminatedUnion<"fieldType", [z.ZodObj
809
809
  excludeInSearchQuery?: boolean | undefined;
810
810
  }>, z.ZodObject<z.objectUtil.extendShape<{
811
811
  config: z.ZodObject<{
812
- type: z.ZodEnum<["fuzzy", "exact", "range"]>;
812
+ type: z.ZodEnum<["fuzzy", "exact", "range", "within"]>;
813
813
  }, "strip", z.ZodTypeAny, {
814
- type: "exact" | "fuzzy" | "range";
814
+ type: "exact" | "fuzzy" | "range" | "within";
815
815
  }, {
816
- type: "exact" | "fuzzy" | "range";
816
+ type: "exact" | "fuzzy" | "range" | "within";
817
817
  }>;
818
818
  options: z.ZodOptional<z.ZodArray<z.ZodObject<{
819
819
  value: z.ZodString;
@@ -862,7 +862,7 @@ export declare const SearchField: z.ZodDiscriminatedUnion<"fieldType", [z.ZodObj
862
862
  fieldType: z.ZodLiteral<"event">;
863
863
  }>, "strip", z.ZodTypeAny, {
864
864
  config: {
865
- type: "exact" | "fuzzy" | "range";
865
+ type: "exact" | "fuzzy" | "range" | "within";
866
866
  };
867
867
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
868
868
  fieldType: "event";
@@ -887,7 +887,7 @@ export declare const SearchField: z.ZodDiscriminatedUnion<"fieldType", [z.ZodObj
887
887
  }[] | undefined;
888
888
  }, {
889
889
  config: {
890
- type: "exact" | "fuzzy" | "range";
890
+ type: "exact" | "fuzzy" | "range" | "within";
891
891
  };
892
892
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
893
893
  fieldType: "event";
@@ -932,11 +932,11 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
932
932
  }>;
933
933
  fields: z.ZodArray<z.ZodDiscriminatedUnion<"fieldType", [z.ZodObject<z.objectUtil.extendShape<{
934
934
  config: z.ZodObject<{
935
- type: z.ZodEnum<["fuzzy", "exact", "range"]>;
935
+ type: z.ZodEnum<["fuzzy", "exact", "range", "within"]>;
936
936
  }, "strip", z.ZodTypeAny, {
937
- type: "exact" | "fuzzy" | "range";
937
+ type: "exact" | "fuzzy" | "range" | "within";
938
938
  }, {
939
- type: "exact" | "fuzzy" | "range";
939
+ type: "exact" | "fuzzy" | "range" | "within";
940
940
  }>;
941
941
  options: z.ZodOptional<z.ZodArray<z.ZodObject<{
942
942
  value: z.ZodString;
@@ -987,7 +987,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
987
987
  excludeInSearchQuery: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
988
988
  }>, "strip", z.ZodTypeAny, {
989
989
  config: {
990
- type: "exact" | "fuzzy" | "range";
990
+ type: "exact" | "fuzzy" | "range" | "within";
991
991
  };
992
992
  fieldId: string;
993
993
  fieldType: "field";
@@ -1014,7 +1014,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
1014
1014
  excludeInSearchQuery?: boolean | undefined;
1015
1015
  }, {
1016
1016
  config: {
1017
- type: "exact" | "fuzzy" | "range";
1017
+ type: "exact" | "fuzzy" | "range" | "within";
1018
1018
  };
1019
1019
  fieldId: string;
1020
1020
  fieldType: "field";
@@ -1053,11 +1053,11 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
1053
1053
  excludeInSearchQuery?: boolean | undefined;
1054
1054
  }>, z.ZodObject<z.objectUtil.extendShape<{
1055
1055
  config: z.ZodObject<{
1056
- type: z.ZodEnum<["fuzzy", "exact", "range"]>;
1056
+ type: z.ZodEnum<["fuzzy", "exact", "range", "within"]>;
1057
1057
  }, "strip", z.ZodTypeAny, {
1058
- type: "exact" | "fuzzy" | "range";
1058
+ type: "exact" | "fuzzy" | "range" | "within";
1059
1059
  }, {
1060
- type: "exact" | "fuzzy" | "range";
1060
+ type: "exact" | "fuzzy" | "range" | "within";
1061
1061
  }>;
1062
1062
  options: z.ZodOptional<z.ZodArray<z.ZodObject<{
1063
1063
  value: z.ZodString;
@@ -1106,7 +1106,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
1106
1106
  fieldType: z.ZodLiteral<"event">;
1107
1107
  }>, "strip", z.ZodTypeAny, {
1108
1108
  config: {
1109
- type: "exact" | "fuzzy" | "range";
1109
+ type: "exact" | "fuzzy" | "range" | "within";
1110
1110
  };
1111
1111
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
1112
1112
  fieldType: "event";
@@ -1131,7 +1131,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
1131
1131
  }[] | undefined;
1132
1132
  }, {
1133
1133
  config: {
1134
- type: "exact" | "fuzzy" | "range";
1134
+ type: "exact" | "fuzzy" | "range" | "within";
1135
1135
  };
1136
1136
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
1137
1137
  fieldType: "event";
@@ -1171,7 +1171,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
1171
1171
  title: TranslationConfig;
1172
1172
  fields: ({
1173
1173
  config: {
1174
- type: "exact" | "fuzzy" | "range";
1174
+ type: "exact" | "fuzzy" | "range" | "within";
1175
1175
  };
1176
1176
  fieldId: string;
1177
1177
  fieldType: "field";
@@ -1198,7 +1198,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
1198
1198
  excludeInSearchQuery?: boolean | undefined;
1199
1199
  } | {
1200
1200
  config: {
1201
- type: "exact" | "fuzzy" | "range";
1201
+ type: "exact" | "fuzzy" | "range" | "within";
1202
1202
  };
1203
1203
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
1204
1204
  fieldType: "event";
@@ -1230,7 +1230,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
1230
1230
  };
1231
1231
  fields: ({
1232
1232
  config: {
1233
- type: "exact" | "fuzzy" | "range";
1233
+ type: "exact" | "fuzzy" | "range" | "within";
1234
1234
  };
1235
1235
  fieldId: string;
1236
1236
  fieldType: "field";
@@ -1269,7 +1269,7 @@ export declare const AdvancedSearchConfig: z.ZodObject<{
1269
1269
  excludeInSearchQuery?: boolean | undefined;
1270
1270
  } | {
1271
1271
  config: {
1272
- type: "exact" | "fuzzy" | "range";
1272
+ type: "exact" | "fuzzy" | "range" | "within";
1273
1273
  };
1274
1274
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
1275
1275
  fieldType: "event";
@@ -9494,11 +9494,11 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9494
9494
  }>;
9495
9495
  fields: z.ZodArray<z.ZodDiscriminatedUnion<"fieldType", [z.ZodObject<z.objectUtil.extendShape<{
9496
9496
  config: z.ZodObject<{
9497
- type: z.ZodEnum<["fuzzy", "exact", "range"]>;
9497
+ type: z.ZodEnum<["fuzzy", "exact", "range", "within"]>;
9498
9498
  }, "strip", z.ZodTypeAny, {
9499
- type: "exact" | "fuzzy" | "range";
9499
+ type: "exact" | "fuzzy" | "range" | "within";
9500
9500
  }, {
9501
- type: "exact" | "fuzzy" | "range";
9501
+ type: "exact" | "fuzzy" | "range" | "within";
9502
9502
  }>;
9503
9503
  options: z.ZodOptional<z.ZodArray<z.ZodObject<{
9504
9504
  value: z.ZodString;
@@ -9549,7 +9549,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9549
9549
  excludeInSearchQuery: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
9550
9550
  }>, "strip", z.ZodTypeAny, {
9551
9551
  config: {
9552
- type: "exact" | "fuzzy" | "range";
9552
+ type: "exact" | "fuzzy" | "range" | "within";
9553
9553
  };
9554
9554
  fieldId: string;
9555
9555
  fieldType: "field";
@@ -9576,7 +9576,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9576
9576
  excludeInSearchQuery?: boolean | undefined;
9577
9577
  }, {
9578
9578
  config: {
9579
- type: "exact" | "fuzzy" | "range";
9579
+ type: "exact" | "fuzzy" | "range" | "within";
9580
9580
  };
9581
9581
  fieldId: string;
9582
9582
  fieldType: "field";
@@ -9615,11 +9615,11 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9615
9615
  excludeInSearchQuery?: boolean | undefined;
9616
9616
  }>, z.ZodObject<z.objectUtil.extendShape<{
9617
9617
  config: z.ZodObject<{
9618
- type: z.ZodEnum<["fuzzy", "exact", "range"]>;
9618
+ type: z.ZodEnum<["fuzzy", "exact", "range", "within"]>;
9619
9619
  }, "strip", z.ZodTypeAny, {
9620
- type: "exact" | "fuzzy" | "range";
9620
+ type: "exact" | "fuzzy" | "range" | "within";
9621
9621
  }, {
9622
- type: "exact" | "fuzzy" | "range";
9622
+ type: "exact" | "fuzzy" | "range" | "within";
9623
9623
  }>;
9624
9624
  options: z.ZodOptional<z.ZodArray<z.ZodObject<{
9625
9625
  value: z.ZodString;
@@ -9668,7 +9668,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9668
9668
  fieldType: z.ZodLiteral<"event">;
9669
9669
  }>, "strip", z.ZodTypeAny, {
9670
9670
  config: {
9671
- type: "exact" | "fuzzy" | "range";
9671
+ type: "exact" | "fuzzy" | "range" | "within";
9672
9672
  };
9673
9673
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
9674
9674
  fieldType: "event";
@@ -9693,7 +9693,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9693
9693
  }[] | undefined;
9694
9694
  }, {
9695
9695
  config: {
9696
- type: "exact" | "fuzzy" | "range";
9696
+ type: "exact" | "fuzzy" | "range" | "within";
9697
9697
  };
9698
9698
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
9699
9699
  fieldType: "event";
@@ -9733,7 +9733,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9733
9733
  title: TranslationConfig;
9734
9734
  fields: ({
9735
9735
  config: {
9736
- type: "exact" | "fuzzy" | "range";
9736
+ type: "exact" | "fuzzy" | "range" | "within";
9737
9737
  };
9738
9738
  fieldId: string;
9739
9739
  fieldType: "field";
@@ -9760,7 +9760,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9760
9760
  excludeInSearchQuery?: boolean | undefined;
9761
9761
  } | {
9762
9762
  config: {
9763
- type: "exact" | "fuzzy" | "range";
9763
+ type: "exact" | "fuzzy" | "range" | "within";
9764
9764
  };
9765
9765
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
9766
9766
  fieldType: "event";
@@ -9792,7 +9792,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9792
9792
  };
9793
9793
  fields: ({
9794
9794
  config: {
9795
- type: "exact" | "fuzzy" | "range";
9795
+ type: "exact" | "fuzzy" | "range" | "within";
9796
9796
  };
9797
9797
  fieldId: string;
9798
9798
  fieldType: "field";
@@ -9831,7 +9831,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
9831
9831
  excludeInSearchQuery?: boolean | undefined;
9832
9832
  } | {
9833
9833
  config: {
9834
- type: "exact" | "fuzzy" | "range";
9834
+ type: "exact" | "fuzzy" | "range" | "within";
9835
9835
  };
9836
9836
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
9837
9837
  fieldType: "event";
@@ -18522,7 +18522,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
18522
18522
  title: TranslationConfig;
18523
18523
  fields: ({
18524
18524
  config: {
18525
- type: "exact" | "fuzzy" | "range";
18525
+ type: "exact" | "fuzzy" | "range" | "within";
18526
18526
  };
18527
18527
  fieldId: string;
18528
18528
  fieldType: "field";
@@ -18549,7 +18549,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
18549
18549
  excludeInSearchQuery?: boolean | undefined;
18550
18550
  } | {
18551
18551
  config: {
18552
- type: "exact" | "fuzzy" | "range";
18552
+ type: "exact" | "fuzzy" | "range" | "within";
18553
18553
  };
18554
18554
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
18555
18555
  fieldType: "event";
@@ -32192,7 +32192,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
32192
32192
  };
32193
32193
  fields: ({
32194
32194
  config: {
32195
- type: "exact" | "fuzzy" | "range";
32195
+ type: "exact" | "fuzzy" | "range" | "within";
32196
32196
  };
32197
32197
  fieldId: string;
32198
32198
  fieldType: "field";
@@ -32231,7 +32231,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
32231
32231
  excludeInSearchQuery?: boolean | undefined;
32232
32232
  } | {
32233
32233
  config: {
32234
- type: "exact" | "fuzzy" | "range";
32234
+ type: "exact" | "fuzzy" | "range" | "within";
32235
32235
  };
32236
32236
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
32237
32237
  fieldType: "event";
@@ -40922,7 +40922,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
40922
40922
  title: TranslationConfig;
40923
40923
  fields: ({
40924
40924
  config: {
40925
- type: "exact" | "fuzzy" | "range";
40925
+ type: "exact" | "fuzzy" | "range" | "within";
40926
40926
  };
40927
40927
  fieldId: string;
40928
40928
  fieldType: "field";
@@ -40949,7 +40949,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
40949
40949
  excludeInSearchQuery?: boolean | undefined;
40950
40950
  } | {
40951
40951
  config: {
40952
- type: "exact" | "fuzzy" | "range";
40952
+ type: "exact" | "fuzzy" | "range" | "within";
40953
40953
  };
40954
40954
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
40955
40955
  fieldType: "event";
@@ -54592,7 +54592,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
54592
54592
  };
54593
54593
  fields: ({
54594
54594
  config: {
54595
- type: "exact" | "fuzzy" | "range";
54595
+ type: "exact" | "fuzzy" | "range" | "within";
54596
54596
  };
54597
54597
  fieldId: string;
54598
54598
  fieldType: "field";
@@ -54631,7 +54631,7 @@ export declare const EventConfig: z.ZodEffects<z.ZodObject<{
54631
54631
  excludeInSearchQuery?: boolean | undefined;
54632
54632
  } | {
54633
54633
  config: {
54634
- type: "exact" | "fuzzy" | "range";
54634
+ type: "exact" | "fuzzy" | "range" | "within";
54635
54635
  };
54636
54636
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
54637
54637
  fieldType: "event";
@@ -5690,10 +5690,24 @@ export declare const EventDocument: z.ZodObject<{
5690
5690
  }, {
5691
5691
  type: z.ZodLiteral<"REJECT_CORRECTION">;
5692
5692
  requestId: z.ZodString;
5693
+ reason: z.ZodObject<{
5694
+ message: z.ZodString;
5695
+ isDuplicate: z.ZodOptional<z.ZodBoolean>;
5696
+ }, "strip", z.ZodTypeAny, {
5697
+ message: string;
5698
+ isDuplicate?: boolean | undefined;
5699
+ }, {
5700
+ message: string;
5701
+ isDuplicate?: boolean | undefined;
5702
+ }>;
5693
5703
  }>, "strip", z.ZodTypeAny, {
5694
5704
  type: "REJECT_CORRECTION";
5695
5705
  id: string & z.BRAND<"UUID">;
5696
5706
  status: "Rejected" | "Requested" | "Accepted";
5707
+ reason: {
5708
+ message: string;
5709
+ isDuplicate?: boolean | undefined;
5710
+ };
5697
5711
  transactionId: string;
5698
5712
  createdByUserType: "system" | "user";
5699
5713
  createdAt: string;
@@ -5797,6 +5811,10 @@ export declare const EventDocument: z.ZodObject<{
5797
5811
  type: "REJECT_CORRECTION";
5798
5812
  id: string;
5799
5813
  status: "Rejected" | "Requested" | "Accepted";
5814
+ reason: {
5815
+ message: string;
5816
+ isDuplicate?: boolean | undefined;
5817
+ };
5800
5818
  transactionId: string;
5801
5819
  createdByUserType: "system" | "user";
5802
5820
  createdAt: string;
@@ -9013,6 +9031,10 @@ export declare const EventDocument: z.ZodObject<{
9013
9031
  type: "REJECT_CORRECTION";
9014
9032
  id: string & z.BRAND<"UUID">;
9015
9033
  status: "Rejected" | "Requested" | "Accepted";
9034
+ reason: {
9035
+ message: string;
9036
+ isDuplicate?: boolean | undefined;
9037
+ };
9016
9038
  transactionId: string;
9017
9039
  createdByUserType: "system" | "user";
9018
9040
  createdAt: string;
@@ -10574,6 +10596,10 @@ export declare const EventDocument: z.ZodObject<{
10574
10596
  type: "REJECT_CORRECTION";
10575
10597
  id: string;
10576
10598
  status: "Rejected" | "Requested" | "Accepted";
10599
+ reason: {
10600
+ message: string;
10601
+ isDuplicate?: boolean | undefined;
10602
+ };
10577
10603
  transactionId: string;
10578
10604
  createdByUserType: "system" | "user";
10579
10605
  createdAt: string;
@@ -725,6 +725,25 @@ export declare const QueryExpression: z.ZodEffects<z.ZodObject<{
725
725
  type: "timePeriod";
726
726
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
727
727
  }>]>>>;
728
+ 'legalStatuses.DECLARED.createdAtLocation': z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodObject<{
729
+ type: z.ZodLiteral<"within">;
730
+ location: z.ZodString;
731
+ }, "strip", z.ZodTypeAny, {
732
+ type: "within";
733
+ location: string;
734
+ }, {
735
+ type: "within";
736
+ location: string;
737
+ }>, z.ZodObject<{
738
+ type: z.ZodLiteral<"exact">;
739
+ term: z.ZodString;
740
+ }, "strip", z.ZodTypeAny, {
741
+ type: "exact";
742
+ term: string;
743
+ }, {
744
+ type: "exact";
745
+ term: string;
746
+ }>]>>>;
728
747
  'legalStatuses.REGISTERED.createdAtLocation': z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodObject<{
729
748
  type: z.ZodLiteral<"within">;
730
749
  location: z.ZodString;
@@ -945,6 +964,13 @@ export declare const QueryExpression: z.ZodEffects<z.ZodObject<{
945
964
  type: "timePeriod";
946
965
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
947
966
  } | undefined;
967
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
968
+ type: "exact";
969
+ term: string;
970
+ } | {
971
+ type: "within";
972
+ location: string;
973
+ } | undefined;
948
974
  'legalStatuses.REGISTERED.createdAtLocation'?: {
949
975
  type: "exact";
950
976
  term: string;
@@ -1038,6 +1064,13 @@ export declare const QueryExpression: z.ZodEffects<z.ZodObject<{
1038
1064
  type: "timePeriod";
1039
1065
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
1040
1066
  } | undefined;
1067
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
1068
+ type: "exact";
1069
+ term: string;
1070
+ } | {
1071
+ type: "within";
1072
+ location: string;
1073
+ } | undefined;
1041
1074
  'legalStatuses.REGISTERED.createdAtLocation'?: {
1042
1075
  type: "exact";
1043
1076
  term: string;
@@ -1131,6 +1164,13 @@ export declare const QueryExpression: z.ZodEffects<z.ZodObject<{
1131
1164
  type: "timePeriod";
1132
1165
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
1133
1166
  } | undefined;
1167
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
1168
+ type: "exact";
1169
+ term: string;
1170
+ } | {
1171
+ type: "within";
1172
+ location: string;
1173
+ } | undefined;
1134
1174
  'legalStatuses.REGISTERED.createdAtLocation'?: {
1135
1175
  type: "exact";
1136
1176
  term: string;
@@ -1224,6 +1264,13 @@ export declare const QueryExpression: z.ZodEffects<z.ZodObject<{
1224
1264
  type: "timePeriod";
1225
1265
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
1226
1266
  } | undefined;
1267
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
1268
+ type: "exact";
1269
+ term: string;
1270
+ } | {
1271
+ type: "within";
1272
+ location: string;
1273
+ } | undefined;
1227
1274
  'legalStatuses.REGISTERED.createdAtLocation'?: {
1228
1275
  type: "exact";
1229
1276
  term: string;
@@ -1359,6 +1406,25 @@ export declare const QueryType: z.ZodObject<{
1359
1406
  type: "timePeriod";
1360
1407
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
1361
1408
  }>]>>>;
1409
+ 'legalStatuses.DECLARED.createdAtLocation': z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodObject<{
1410
+ type: z.ZodLiteral<"within">;
1411
+ location: z.ZodString;
1412
+ }, "strip", z.ZodTypeAny, {
1413
+ type: "within";
1414
+ location: string;
1415
+ }, {
1416
+ type: "within";
1417
+ location: string;
1418
+ }>, z.ZodObject<{
1419
+ type: z.ZodLiteral<"exact">;
1420
+ term: z.ZodString;
1421
+ }, "strip", z.ZodTypeAny, {
1422
+ type: "exact";
1423
+ term: string;
1424
+ }, {
1425
+ type: "exact";
1426
+ term: string;
1427
+ }>]>>>;
1362
1428
  'legalStatuses.REGISTERED.createdAtLocation': z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodObject<{
1363
1429
  type: z.ZodLiteral<"within">;
1364
1430
  location: z.ZodString;
@@ -1579,6 +1645,13 @@ export declare const QueryType: z.ZodObject<{
1579
1645
  type: "timePeriod";
1580
1646
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
1581
1647
  } | undefined;
1648
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
1649
+ type: "exact";
1650
+ term: string;
1651
+ } | {
1652
+ type: "within";
1653
+ location: string;
1654
+ } | undefined;
1582
1655
  'legalStatuses.REGISTERED.createdAtLocation'?: {
1583
1656
  type: "exact";
1584
1657
  term: string;
@@ -1672,6 +1745,13 @@ export declare const QueryType: z.ZodObject<{
1672
1745
  type: "timePeriod";
1673
1746
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
1674
1747
  } | undefined;
1748
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
1749
+ type: "exact";
1750
+ term: string;
1751
+ } | {
1752
+ type: "within";
1753
+ location: string;
1754
+ } | undefined;
1675
1755
  'legalStatuses.REGISTERED.createdAtLocation'?: {
1676
1756
  type: "exact";
1677
1757
  term: string;
@@ -1765,6 +1845,13 @@ export declare const QueryType: z.ZodObject<{
1765
1845
  type: "timePeriod";
1766
1846
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
1767
1847
  } | undefined;
1848
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
1849
+ type: "exact";
1850
+ term: string;
1851
+ } | {
1852
+ type: "within";
1853
+ location: string;
1854
+ } | undefined;
1768
1855
  'legalStatuses.REGISTERED.createdAtLocation'?: {
1769
1856
  type: "exact";
1770
1857
  term: string;
@@ -1858,6 +1945,13 @@ export declare const QueryType: z.ZodObject<{
1858
1945
  type: "timePeriod";
1859
1946
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
1860
1947
  } | undefined;
1948
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
1949
+ type: "exact";
1950
+ term: string;
1951
+ } | {
1952
+ type: "within";
1953
+ location: string;
1954
+ } | undefined;
1861
1955
  'legalStatuses.REGISTERED.createdAtLocation'?: {
1862
1956
  type: "exact";
1863
1957
  term: string;
@@ -1951,6 +2045,13 @@ export declare const QueryType: z.ZodObject<{
1951
2045
  type: "timePeriod";
1952
2046
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
1953
2047
  } | undefined;
2048
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
2049
+ type: "exact";
2050
+ term: string;
2051
+ } | {
2052
+ type: "within";
2053
+ location: string;
2054
+ } | undefined;
1954
2055
  'legalStatuses.REGISTERED.createdAtLocation'?: {
1955
2056
  type: "exact";
1956
2057
  term: string;
@@ -2044,6 +2145,13 @@ export declare const QueryType: z.ZodObject<{
2044
2145
  type: "timePeriod";
2045
2146
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
2046
2147
  } | undefined;
2148
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
2149
+ type: "exact";
2150
+ term: string;
2151
+ } | {
2152
+ type: "within";
2153
+ location: string;
2154
+ } | undefined;
2047
2155
  'legalStatuses.REGISTERED.createdAtLocation'?: {
2048
2156
  type: "exact";
2049
2157
  term: string;
@@ -2140,6 +2248,13 @@ export declare const QueryType: z.ZodObject<{
2140
2248
  type: "timePeriod";
2141
2249
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
2142
2250
  } | undefined;
2251
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
2252
+ type: "exact";
2253
+ term: string;
2254
+ } | {
2255
+ type: "within";
2256
+ location: string;
2257
+ } | undefined;
2143
2258
  'legalStatuses.REGISTERED.createdAtLocation'?: {
2144
2259
  type: "exact";
2145
2260
  term: string;
@@ -2233,6 +2348,13 @@ export declare const QueryType: z.ZodObject<{
2233
2348
  type: "timePeriod";
2234
2349
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
2235
2350
  } | undefined;
2351
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
2352
+ type: "exact";
2353
+ term: string;
2354
+ } | {
2355
+ type: "within";
2356
+ location: string;
2357
+ } | undefined;
2236
2358
  'legalStatuses.REGISTERED.createdAtLocation'?: {
2237
2359
  type: "exact";
2238
2360
  term: string;
@@ -7037,6 +7037,25 @@ export declare const WorkqueueCountInput: z.ZodArray<z.ZodObject<{
7037
7037
  type: "timePeriod";
7038
7038
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
7039
7039
  }>]>>>;
7040
+ 'legalStatuses.DECLARED.createdAtLocation': z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodObject<{
7041
+ type: z.ZodLiteral<"within">;
7042
+ location: z.ZodString;
7043
+ }, "strip", z.ZodTypeAny, {
7044
+ type: "within";
7045
+ location: string;
7046
+ }, {
7047
+ type: "within";
7048
+ location: string;
7049
+ }>, z.ZodObject<{
7050
+ type: z.ZodLiteral<"exact">;
7051
+ term: z.ZodString;
7052
+ }, "strip", z.ZodTypeAny, {
7053
+ type: "exact";
7054
+ term: string;
7055
+ }, {
7056
+ type: "exact";
7057
+ term: string;
7058
+ }>]>>>;
7040
7059
  'legalStatuses.REGISTERED.createdAtLocation': z.ZodOptional<z.ZodOptional<z.ZodUnion<[z.ZodObject<{
7041
7060
  type: z.ZodLiteral<"within">;
7042
7061
  location: z.ZodString;
@@ -7257,6 +7276,13 @@ export declare const WorkqueueCountInput: z.ZodArray<z.ZodObject<{
7257
7276
  type: "timePeriod";
7258
7277
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
7259
7278
  } | undefined;
7279
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
7280
+ type: "exact";
7281
+ term: string;
7282
+ } | {
7283
+ type: "within";
7284
+ location: string;
7285
+ } | undefined;
7260
7286
  'legalStatuses.REGISTERED.createdAtLocation'?: {
7261
7287
  type: "exact";
7262
7288
  term: string;
@@ -7350,6 +7376,13 @@ export declare const WorkqueueCountInput: z.ZodArray<z.ZodObject<{
7350
7376
  type: "timePeriod";
7351
7377
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
7352
7378
  } | undefined;
7379
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
7380
+ type: "exact";
7381
+ term: string;
7382
+ } | {
7383
+ type: "within";
7384
+ location: string;
7385
+ } | undefined;
7353
7386
  'legalStatuses.REGISTERED.createdAtLocation'?: {
7354
7387
  type: "exact";
7355
7388
  term: string;
@@ -7443,6 +7476,13 @@ export declare const WorkqueueCountInput: z.ZodArray<z.ZodObject<{
7443
7476
  type: "timePeriod";
7444
7477
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
7445
7478
  } | undefined;
7479
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
7480
+ type: "exact";
7481
+ term: string;
7482
+ } | {
7483
+ type: "within";
7484
+ location: string;
7485
+ } | undefined;
7446
7486
  'legalStatuses.REGISTERED.createdAtLocation'?: {
7447
7487
  type: "exact";
7448
7488
  term: string;
@@ -7536,6 +7576,13 @@ export declare const WorkqueueCountInput: z.ZodArray<z.ZodObject<{
7536
7576
  type: "timePeriod";
7537
7577
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
7538
7578
  } | undefined;
7579
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
7580
+ type: "exact";
7581
+ term: string;
7582
+ } | {
7583
+ type: "within";
7584
+ location: string;
7585
+ } | undefined;
7539
7586
  'legalStatuses.REGISTERED.createdAtLocation'?: {
7540
7587
  type: "exact";
7541
7588
  term: string;
@@ -7629,6 +7676,13 @@ export declare const WorkqueueCountInput: z.ZodArray<z.ZodObject<{
7629
7676
  type: "timePeriod";
7630
7677
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
7631
7678
  } | undefined;
7679
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
7680
+ type: "exact";
7681
+ term: string;
7682
+ } | {
7683
+ type: "within";
7684
+ location: string;
7685
+ } | undefined;
7632
7686
  'legalStatuses.REGISTERED.createdAtLocation'?: {
7633
7687
  type: "exact";
7634
7688
  term: string;
@@ -7722,6 +7776,13 @@ export declare const WorkqueueCountInput: z.ZodArray<z.ZodObject<{
7722
7776
  type: "timePeriod";
7723
7777
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
7724
7778
  } | undefined;
7779
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
7780
+ type: "exact";
7781
+ term: string;
7782
+ } | {
7783
+ type: "within";
7784
+ location: string;
7785
+ } | undefined;
7725
7786
  'legalStatuses.REGISTERED.createdAtLocation'?: {
7726
7787
  type: "exact";
7727
7788
  term: string;
@@ -7818,6 +7879,13 @@ export declare const WorkqueueCountInput: z.ZodArray<z.ZodObject<{
7818
7879
  type: "timePeriod";
7819
7880
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
7820
7881
  } | undefined;
7882
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
7883
+ type: "exact";
7884
+ term: string;
7885
+ } | {
7886
+ type: "within";
7887
+ location: string;
7888
+ } | undefined;
7821
7889
  'legalStatuses.REGISTERED.createdAtLocation'?: {
7822
7890
  type: "exact";
7823
7891
  term: string;
@@ -7911,6 +7979,13 @@ export declare const WorkqueueCountInput: z.ZodArray<z.ZodObject<{
7911
7979
  type: "timePeriod";
7912
7980
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
7913
7981
  } | undefined;
7982
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
7983
+ type: "exact";
7984
+ term: string;
7985
+ } | {
7986
+ type: "within";
7987
+ location: string;
7988
+ } | undefined;
7914
7989
  'legalStatuses.REGISTERED.createdAtLocation'?: {
7915
7990
  type: "exact";
7916
7991
  term: string;
@@ -8012,6 +8087,13 @@ export declare const WorkqueueCountInput: z.ZodArray<z.ZodObject<{
8012
8087
  type: "timePeriod";
8013
8088
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
8014
8089
  } | undefined;
8090
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
8091
+ type: "exact";
8092
+ term: string;
8093
+ } | {
8094
+ type: "within";
8095
+ location: string;
8096
+ } | undefined;
8015
8097
  'legalStatuses.REGISTERED.createdAtLocation'?: {
8016
8098
  type: "exact";
8017
8099
  term: string;
@@ -8105,6 +8187,13 @@ export declare const WorkqueueCountInput: z.ZodArray<z.ZodObject<{
8105
8187
  type: "timePeriod";
8106
8188
  term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
8107
8189
  } | undefined;
8190
+ 'legalStatuses.DECLARED.createdAtLocation'?: {
8191
+ type: "exact";
8192
+ term: string;
8193
+ } | {
8194
+ type: "within";
8195
+ location: string;
8196
+ } | undefined;
8108
8197
  'legalStatuses.REGISTERED.createdAtLocation'?: {
8109
8198
  type: "exact";
8110
8199
  term: string;
@@ -8657,7 +8657,7 @@ export declare const defineConfig: (config: EventConfigInput) => {
8657
8657
  title: import("./TranslationConfig").TranslationConfig;
8658
8658
  fields: ({
8659
8659
  config: {
8660
- type: "exact" | "fuzzy" | "range";
8660
+ type: "exact" | "fuzzy" | "range" | "within";
8661
8661
  };
8662
8662
  fieldId: string;
8663
8663
  fieldType: "field";
@@ -8684,7 +8684,7 @@ export declare const defineConfig: (config: EventConfigInput) => {
8684
8684
  excludeInSearchQuery?: boolean | undefined;
8685
8685
  } | {
8686
8686
  config: {
8687
- type: "exact" | "fuzzy" | "range";
8687
+ type: "exact" | "fuzzy" | "range" | "within";
8688
8688
  };
8689
8689
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
8690
8690
  fieldType: "event";
@@ -33,6 +33,14 @@ declare function eventFn(fieldId: EventFieldId): {
33
33
  type: "fuzzy";
34
34
  };
35
35
  };
36
+ within: () => {
37
+ fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
38
+ fieldType: "event";
39
+ } & {
40
+ config: {
41
+ type: "within";
42
+ };
43
+ };
36
44
  };
37
45
  declare const event: typeof eventFn & {
38
46
  /**
@@ -56,6 +56,20 @@ export declare function field(fieldId: string, options?: {
56
56
  type: "fuzzy";
57
57
  };
58
58
  };
59
+ within: () => {
60
+ options?: SelectOption[];
61
+ excludeInSearchQuery?: boolean;
62
+ alternateFieldIds?: string[];
63
+ conditionals?: FieldConditional[];
64
+ validations?: ValidationConfig[];
65
+ searchCriteriaLabelPrefix?: TranslationConfig;
66
+ fieldId: string;
67
+ fieldType: "field";
68
+ } & {
69
+ config: {
70
+ type: "within";
71
+ };
72
+ };
59
73
  $$field: string;
60
74
  isAfter: () => {
61
75
  days: (days: number) => {
@@ -414,7 +414,7 @@ export declare function eventPayloadGenerator(rng: () => number): {
414
414
  requestId: string;
415
415
  keepAssignment: boolean | undefined;
416
416
  };
417
- reject: (eventId: string, requestId: string, input?: Partial<Pick<RejectCorrectionActionInput, "transactionId" | "annotation" | "keepAssignment">>) => {
417
+ reject: (eventId: string, requestId: string, input: Partial<Pick<RejectCorrectionActionInput, "transactionId" | "annotation" | "keepAssignment" | "reason">>) => {
418
418
  type: "REJECT_CORRECTION";
419
419
  transactionId: string;
420
420
  declaration: {};
@@ -422,6 +422,10 @@ export declare function eventPayloadGenerator(rng: () => number): {
422
422
  eventId: string;
423
423
  requestId: string;
424
424
  keepAssignment: boolean | undefined;
425
+ reason: {
426
+ message: string;
427
+ isDuplicate?: boolean | undefined;
428
+ };
425
429
  };
426
430
  };
427
431
  };
@@ -15520,7 +15520,7 @@ export declare function getEventConfigById(eventConfigs: EventConfig[], id: stri
15520
15520
  title: import("./TranslationConfig").TranslationConfig;
15521
15521
  fields: ({
15522
15522
  config: {
15523
- type: "exact" | "fuzzy" | "range";
15523
+ type: "exact" | "fuzzy" | "range" | "within";
15524
15524
  };
15525
15525
  fieldId: string;
15526
15526
  fieldType: "field";
@@ -15547,7 +15547,7 @@ export declare function getEventConfigById(eventConfigs: EventConfig[], id: stri
15547
15547
  excludeInSearchQuery?: boolean | undefined;
15548
15548
  } | {
15549
15549
  config: {
15550
- type: "exact" | "fuzzy" | "range";
15550
+ type: "exact" | "fuzzy" | "range" | "within";
15551
15551
  };
15552
15552
  fieldId: "status" | "updatedAt" | "trackingId" | "legalStatuses.REGISTERED.acceptedAt" | "legalStatuses.REGISTERED.createdAtLocation";
15553
15553
  fieldType: "event";
@@ -606,8 +606,8 @@ var UrbanAddressUpdateValue = AdminStructure.extend({
606
606
  zipCode: import_zod5.z.string().nullish()
607
607
  });
608
608
  var NameFieldValue = import_zod5.z.object({
609
- firstname: import_zod5.z.string(),
610
- surname: import_zod5.z.string(),
609
+ firstname: import_zod5.z.string().min(1),
610
+ surname: import_zod5.z.string().min(1),
611
611
  middlename: import_zod5.z.string().optional()
612
612
  });
613
613
  var NameFieldUpdateValue = import_zod5.z.object({
@@ -1340,7 +1340,7 @@ var SummaryConfig = import_zod14.z.object({
1340
1340
 
1341
1341
  // ../commons/src/events/AdvancedSearchConfig.ts
1342
1342
  var import_zod15 = require("zod");
1343
- var MatchType = import_zod15.z.enum(["fuzzy", "exact", "range"]);
1343
+ var MatchType = import_zod15.z.enum(["fuzzy", "exact", "range", "within"]);
1344
1344
  var BaseField3 = import_zod15.z.object({
1345
1345
  config: import_zod15.z.object({
1346
1346
  type: MatchType.describe("Determines the type of field")
@@ -1980,7 +1980,8 @@ var ApprovedCorrectionAction = ActionBase.merge(
1980
1980
  var RejectedCorrectionAction = ActionBase.merge(
1981
1981
  import_zod19.z.object({
1982
1982
  type: import_zod19.z.literal(ActionType.REJECT_CORRECTION),
1983
- requestId: import_zod19.z.string()
1983
+ requestId: import_zod19.z.string(),
1984
+ reason: RejectionReason
1984
1985
  })
1985
1986
  );
1986
1987
  var ReadAction = ActionBase.merge(
@@ -3174,6 +3175,19 @@ function createSearchConfig(baseField) {
3174
3175
  fuzzy: () => ({
3175
3176
  ...baseField,
3176
3177
  config: { type: "fuzzy" }
3178
+ }),
3179
+ /**
3180
+ * Creates a configuration for matching locations and the child locations
3181
+ * @returns An object containing the field ID and a configuration object with a type of 'within'.
3182
+ * @example field('createdAtLocation').within()
3183
+ * // {
3184
+ * // ...
3185
+ * // config: { type: 'within' }
3186
+ * // }
3187
+ */
3188
+ within: () => ({
3189
+ ...baseField,
3190
+ config: { type: "within" }
3177
3191
  })
3178
3192
  };
3179
3193
  }
@@ -3523,6 +3537,9 @@ var QueryExpression = import_zod25.z.object({
3523
3537
  createdAt: import_zod25.z.optional(DateCondition),
3524
3538
  updatedAt: import_zod25.z.optional(DateCondition),
3525
3539
  "legalStatuses.REGISTERED.acceptedAt": import_zod25.z.optional(DateCondition),
3540
+ "legalStatuses.DECLARED.createdAtLocation": import_zod25.z.optional(
3541
+ import_zod25.z.union([Within, Exact])
3542
+ ),
3526
3543
  "legalStatuses.REGISTERED.createdAtLocation": import_zod25.z.optional(
3527
3544
  import_zod25.z.union([Within, Exact])
3528
3545
  ),
@@ -3916,7 +3933,8 @@ var RequestCorrectionActionInput = BaseActionInput.merge(
3916
3933
  var RejectCorrectionActionInput = BaseActionInput.merge(
3917
3934
  import_zod29.z.object({
3918
3935
  requestId: import_zod29.z.string(),
3919
- type: import_zod29.z.literal(ActionType.REJECT_CORRECTION).default(ActionType.REJECT_CORRECTION)
3936
+ type: import_zod29.z.literal(ActionType.REJECT_CORRECTION).default(ActionType.REJECT_CORRECTION),
3937
+ reason: RejectionReason
3920
3938
  })
3921
3939
  );
3922
3940
  var ApproveCorrectionActionInput = BaseActionInput.merge(
@@ -6755,7 +6773,7 @@ function eventPayloadGenerator(rng) {
6755
6773
  requestId,
6756
6774
  keepAssignment: input.keepAssignment
6757
6775
  }),
6758
- reject: (eventId, requestId, input = {}) => ({
6776
+ reject: (eventId, requestId, input) => ({
6759
6777
  type: ActionType.REJECT_CORRECTION,
6760
6778
  transactionId: input.transactionId ?? getUUID(),
6761
6779
  declaration: {},
@@ -6766,7 +6784,8 @@ function eventPayloadGenerator(rng) {
6766
6784
  ),
6767
6785
  eventId,
6768
6786
  requestId,
6769
- keepAssignment: input.keepAssignment
6787
+ keepAssignment: input.keepAssignment,
6788
+ reason: input.reason ?? { message: "" }
6770
6789
  })
6771
6790
  }
6772
6791
  }
@@ -6825,7 +6844,8 @@ function generateActionDocument({
6825
6844
  return {
6826
6845
  ...actionBase,
6827
6846
  requestId: getUUID(),
6828
- type: action
6847
+ type: action,
6848
+ reason: { message: "Correction rejection" }
6829
6849
  };
6830
6850
  case ActionType.REGISTER:
6831
6851
  return {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opencrvs/toolkit",
3
- "version": "1.8.1-rc.1e3e9b5",
3
+ "version": "1.8.1-rc.20fdb4a",
4
4
  "description": "OpenCRVS toolkit for building country configurations",
5
5
  "license": "MPL-2.0",
6
6
  "exports": {