@nira-opencrvs/toolkit 1.9.11-rc.39d8d68

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (77) hide show
  1. package/README.md +70 -0
  2. package/build.sh +56 -0
  3. package/dist/api/index.d.ts +11 -0
  4. package/dist/api/index.d.ts.map +1 -0
  5. package/dist/api/index.js +52 -0
  6. package/dist/commons/api/router.d.ts +4125 -0
  7. package/dist/commons/conditionals/conditionals.d.ts +824 -0
  8. package/dist/commons/conditionals/index.d.ts +2 -0
  9. package/dist/commons/conditionals/validate.d.ts +101 -0
  10. package/dist/commons/events/ActionConfig.d.ts +1609 -0
  11. package/dist/commons/events/ActionDocument.d.ts +2180 -0
  12. package/dist/commons/events/ActionInput.d.ts +1229 -0
  13. package/dist/commons/events/ActionType.d.ts +52 -0
  14. package/dist/commons/events/AdvancedSearchConfig.d.ts +1538 -0
  15. package/dist/commons/events/CompositeFieldValue.d.ts +280 -0
  16. package/dist/commons/events/Conditional.d.ts +55 -0
  17. package/dist/commons/events/Constants.d.ts +3 -0
  18. package/dist/commons/events/CountryConfigQueryInput.d.ts +4784 -0
  19. package/dist/commons/events/CreatedAtLocation.d.ts +2 -0
  20. package/dist/commons/events/DeduplicationConfig.d.ts +233 -0
  21. package/dist/commons/events/Draft.d.ts +118 -0
  22. package/dist/commons/events/DynamicFieldValue.d.ts +139 -0
  23. package/dist/commons/events/EventConfig.d.ts +2255 -0
  24. package/dist/commons/events/EventConfigInput.d.ts +10 -0
  25. package/dist/commons/events/EventDocument.d.ts +1457 -0
  26. package/dist/commons/events/EventIndex.d.ts +1134 -0
  27. package/dist/commons/events/EventInput.d.ts +13 -0
  28. package/dist/commons/events/EventMetadata.d.ts +413 -0
  29. package/dist/commons/events/FieldConfig.d.ts +12935 -0
  30. package/dist/commons/events/FieldType.d.ts +55 -0
  31. package/dist/commons/events/FieldTypeMapping.d.ts +1289 -0
  32. package/dist/commons/events/FieldValue.d.ts +512 -0
  33. package/dist/commons/events/FileUtils.d.ts +4 -0
  34. package/dist/commons/events/FormConfig.d.ts +755 -0
  35. package/dist/commons/events/PageConfig.d.ts +342 -0
  36. package/dist/commons/events/PlainDate.d.ts +19 -0
  37. package/dist/commons/events/SummaryConfig.d.ts +170 -0
  38. package/dist/commons/events/TemplateConfig.d.ts +66 -0
  39. package/dist/commons/events/TranslationConfig.d.ts +15 -0
  40. package/dist/commons/events/WorkqueueColumnConfig.d.ts +53 -0
  41. package/dist/commons/events/WorkqueueConfig.d.ts +7957 -0
  42. package/dist/commons/events/deduplication.d.ts +69 -0
  43. package/dist/commons/events/defineConfig.d.ts +234 -0
  44. package/dist/commons/events/event.d.ts +80 -0
  45. package/dist/commons/events/field.d.ts +514 -0
  46. package/dist/commons/events/index.d.ts +45 -0
  47. package/dist/commons/events/locations.d.ts +24 -0
  48. package/dist/commons/events/scopes.d.ts +55 -0
  49. package/dist/commons/events/serializer.d.ts +2 -0
  50. package/dist/commons/events/state/availableActions.d.ts +6 -0
  51. package/dist/commons/events/state/flags.d.ts +4 -0
  52. package/dist/commons/events/state/index.d.ts +119 -0
  53. package/dist/commons/events/state/utils.d.ts +311 -0
  54. package/dist/commons/events/test.utils.d.ts +248 -0
  55. package/dist/commons/events/transactions.d.ts +2 -0
  56. package/dist/commons/events/utils.d.ts +486 -0
  57. package/dist/commons/events/workqueueDefaultColumns.d.ts +3 -0
  58. package/dist/commons/notification/UserNotifications.d.ts +762 -0
  59. package/dist/commons/notification/index.d.ts +2 -0
  60. package/dist/conditionals/index.d.ts +2 -0
  61. package/dist/conditionals/index.d.ts.map +1 -0
  62. package/dist/conditionals/index.js +689 -0
  63. package/dist/events/deduplication.d.ts +69 -0
  64. package/dist/events/deduplication.d.ts.map +1 -0
  65. package/dist/events/deduplication.js +101 -0
  66. package/dist/events/index.d.ts +2 -0
  67. package/dist/events/index.d.ts.map +1 -0
  68. package/dist/events/index.js +9327 -0
  69. package/dist/notification/index.d.ts +2 -0
  70. package/dist/notification/index.d.ts.map +1 -0
  71. package/dist/notification/index.js +6674 -0
  72. package/dist/scopes/index.d.ts +385 -0
  73. package/dist/scopes/index.d.ts.map +1 -0
  74. package/dist/scopes/index.js +349 -0
  75. package/package.json +40 -0
  76. package/tsconfig.json +27 -0
  77. package/tsconfig.tsbuildinfo +1 -0
@@ -0,0 +1,4125 @@
1
+ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2
+ ctx: {
3
+ user: {
4
+ type: "user";
5
+ id: string;
6
+ role: string;
7
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
8
+ signature?: string | undefined;
9
+ } | {
10
+ type: "system";
11
+ id: string;
12
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
13
+ primaryOfficeId?: undefined;
14
+ signature?: undefined;
15
+ };
16
+ token: `Bearer ${string}`;
17
+ };
18
+ meta: import("trpc-to-openapi").OpenApiMeta;
19
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
20
+ transformer: true;
21
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
22
+ event: import("@trpc/server").TRPCBuiltRouter<{
23
+ ctx: {
24
+ user: {
25
+ type: "user";
26
+ id: string;
27
+ role: string;
28
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
29
+ signature?: string | undefined;
30
+ } | {
31
+ type: "system";
32
+ id: string;
33
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
34
+ primaryOfficeId?: undefined;
35
+ signature?: undefined;
36
+ };
37
+ token: `Bearer ${string}`;
38
+ };
39
+ meta: import("trpc-to-openapi").OpenApiMeta;
40
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
41
+ transformer: true;
42
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
43
+ config: import("@trpc/server").TRPCBuiltRouter<{
44
+ ctx: {
45
+ user: {
46
+ type: "user";
47
+ id: string;
48
+ role: string;
49
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
50
+ signature?: string | undefined;
51
+ } | {
52
+ type: "system";
53
+ id: string;
54
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
55
+ primaryOfficeId?: undefined;
56
+ signature?: undefined;
57
+ };
58
+ token: `Bearer ${string}`;
59
+ };
60
+ meta: import("trpc-to-openapi").OpenApiMeta;
61
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
62
+ transformer: true;
63
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
64
+ get: import("@trpc/server").TRPCQueryProcedure<{
65
+ input: void;
66
+ output: {
67
+ id: string;
68
+ title: import("../commons").TranslationConfig;
69
+ declaration: {
70
+ label: import("../commons").TranslationConfig;
71
+ pages: {
72
+ type: "FORM";
73
+ id: string;
74
+ title: import("../commons").TranslationConfig;
75
+ fields: import("../commons").FieldConfig[];
76
+ requireCompletionToContinue: boolean;
77
+ conditional?: import("../commons").JSONSchema | undefined;
78
+ }[];
79
+ };
80
+ actions: ({
81
+ type: "READ";
82
+ label: import("../commons").TranslationConfig;
83
+ review: {
84
+ title: import("../commons").TranslationConfig;
85
+ fields: import("../commons").FieldConfig[];
86
+ };
87
+ } | {
88
+ type: "DECLARE";
89
+ label: import("../commons").TranslationConfig;
90
+ review: {
91
+ title: import("../commons").TranslationConfig;
92
+ fields: import("../commons").FieldConfig[];
93
+ };
94
+ deduplication?: {
95
+ id: string;
96
+ query: import("../commons").ClauseOutput;
97
+ label: import("../commons").TranslationConfig;
98
+ } | undefined;
99
+ } | {
100
+ type: "VALIDATE";
101
+ label: import("../commons").TranslationConfig;
102
+ review: {
103
+ title: import("../commons").TranslationConfig;
104
+ fields: import("../commons").FieldConfig[];
105
+ };
106
+ deduplication?: {
107
+ id: string;
108
+ query: import("../commons").ClauseOutput;
109
+ label: import("../commons").TranslationConfig;
110
+ } | undefined;
111
+ } | {
112
+ type: "REJECT";
113
+ label: import("../commons").TranslationConfig;
114
+ } | {
115
+ type: "ARCHIVE";
116
+ label: import("../commons").TranslationConfig;
117
+ } | {
118
+ type: "REGISTER";
119
+ label: import("../commons").TranslationConfig;
120
+ review: {
121
+ title: import("../commons").TranslationConfig;
122
+ fields: import("../commons").FieldConfig[];
123
+ };
124
+ deduplication?: {
125
+ id: string;
126
+ query: import("../commons").ClauseOutput;
127
+ label: import("../commons").TranslationConfig;
128
+ } | undefined;
129
+ } | {
130
+ type: "DELETE";
131
+ label: import("../commons").TranslationConfig;
132
+ } | {
133
+ type: "PRINT_CERTIFICATE";
134
+ label: import("../commons").TranslationConfig;
135
+ printForm: {
136
+ label: import("../commons").TranslationConfig;
137
+ pages: ({
138
+ type: "FORM";
139
+ id: string;
140
+ title: import("../commons").TranslationConfig;
141
+ fields: import("../commons").FieldConfig[];
142
+ requireCompletionToContinue: boolean;
143
+ conditional?: import("../commons").JSONSchema | undefined;
144
+ } | {
145
+ type: "VERIFICATION";
146
+ id: string;
147
+ title: import("../commons").TranslationConfig;
148
+ actions: {
149
+ cancel: {
150
+ label: import("../commons").TranslationConfig;
151
+ confirmation: {
152
+ title: import("../commons").TranslationConfig;
153
+ body: import("../commons").TranslationConfig;
154
+ };
155
+ };
156
+ verify: {
157
+ label: import("../commons").TranslationConfig;
158
+ };
159
+ };
160
+ fields: import("../commons").FieldConfig[];
161
+ requireCompletionToContinue: boolean;
162
+ conditional?: import("../commons").JSONSchema | undefined;
163
+ })[];
164
+ };
165
+ } | {
166
+ type: "REQUEST_CORRECTION";
167
+ label: import("../commons").TranslationConfig;
168
+ correctionForm: {
169
+ label: import("../commons").TranslationConfig;
170
+ pages: ({
171
+ type: "FORM";
172
+ id: string;
173
+ title: import("../commons").TranslationConfig;
174
+ fields: import("../commons").FieldConfig[];
175
+ requireCompletionToContinue: boolean;
176
+ conditional?: import("../commons").JSONSchema | undefined;
177
+ } | {
178
+ type: "VERIFICATION";
179
+ id: string;
180
+ title: import("../commons").TranslationConfig;
181
+ actions: {
182
+ cancel: {
183
+ label: import("../commons").TranslationConfig;
184
+ confirmation: {
185
+ title: import("../commons").TranslationConfig;
186
+ body: import("../commons").TranslationConfig;
187
+ };
188
+ };
189
+ verify: {
190
+ label: import("../commons").TranslationConfig;
191
+ };
192
+ };
193
+ fields: import("../commons").FieldConfig[];
194
+ requireCompletionToContinue: boolean;
195
+ conditional?: import("../commons").JSONSchema | undefined;
196
+ })[];
197
+ };
198
+ } | {
199
+ type: "REJECT_CORRECTION";
200
+ label: import("../commons").TranslationConfig;
201
+ } | {
202
+ type: "APPROVE_CORRECTION";
203
+ label: import("../commons").TranslationConfig;
204
+ })[];
205
+ label: import("../commons").TranslationConfig;
206
+ summary: {
207
+ fields: ({
208
+ fieldId: string;
209
+ label?: import("../commons").TranslationConfig | undefined;
210
+ conditionals?: {
211
+ type: "SHOW";
212
+ conditional: import("../commons").JSONSchema;
213
+ }[] | undefined;
214
+ emptyValueMessage?: import("../commons").TranslationConfig | undefined;
215
+ } | {
216
+ id: string;
217
+ value: import("../commons").TranslationConfig;
218
+ label: import("../commons").TranslationConfig;
219
+ conditionals?: {
220
+ type: "SHOW";
221
+ conditional: import("../commons").JSONSchema;
222
+ }[] | undefined;
223
+ emptyValueMessage?: import("../commons").TranslationConfig | undefined;
224
+ })[];
225
+ };
226
+ advancedSearch: {
227
+ title: import("../commons").TranslationConfig;
228
+ fields: ({
229
+ config: {
230
+ type: "exact" | "fuzzy" | "range" | "within";
231
+ searchFields?: string[] | undefined;
232
+ };
233
+ fieldId: string;
234
+ fieldType: "field";
235
+ type?: "NAME" | "PHONE" | "ID" | "ADDRESS" | "TEXT" | "NUMBER" | "NUMBER_WITH_UNIT" | "TEXTAREA" | "EMAIL" | "DATE" | "AGE" | "DATE_RANGE" | "SELECT_DATE_RANGE" | "TIME" | "PARAGRAPH" | "PAGE_HEADER" | "RADIO_GROUP" | "FILE" | "FILE_WITH_OPTIONS" | "BULLET_LIST" | "CHECKBOX" | "SELECT" | "COUNTRY" | "LOCATION" | "DIVIDER" | "ADMINISTRATIVE_AREA" | "FACILITY" | "OFFICE" | "SIGNATURE" | "DATA" | "BUTTON" | "SEARCH" | "ALPHA_PRINT_BUTTON" | "HTTP" | "LINK_BUTTON" | "VERIFICATION_STATUS" | "QUERY_PARAM_READER" | "QR_READER" | "ID_READER" | "LOADER" | undefined;
236
+ options?: {
237
+ value: string;
238
+ label: string | import("../commons").TranslationConfig;
239
+ }[] | undefined;
240
+ label?: import("../commons").TranslationConfig | undefined;
241
+ conditionals?: ({
242
+ type: "SHOW";
243
+ conditional: import("../commons").JSONSchema;
244
+ } | {
245
+ type: "ENABLE";
246
+ conditional: import("../commons").JSONSchema;
247
+ } | {
248
+ type: "DISPLAY_ON_REVIEW";
249
+ conditional: import("../commons").JSONSchema;
250
+ })[] | undefined;
251
+ searchCriteriaLabelPrefix?: import("../commons").TranslationConfig | undefined;
252
+ validations?: {
253
+ message: import("../commons").TranslationConfig;
254
+ validator: import("../commons").JSONSchema;
255
+ }[] | undefined;
256
+ } | {
257
+ config: {
258
+ type: "exact" | "fuzzy" | "range" | "within";
259
+ searchFields?: string[] | undefined;
260
+ };
261
+ fieldId: "event.status" | "event.trackingId" | "event.updatedAt" | "event.legalStatuses.REGISTERED.acceptedAt" | "event.legalStatuses.REGISTERED.createdAtLocation" | "event.legalStatuses.REGISTERED.registrationNumber";
262
+ fieldType: "event";
263
+ type?: "NAME" | "PHONE" | "ID" | "ADDRESS" | "TEXT" | "NUMBER" | "NUMBER_WITH_UNIT" | "TEXTAREA" | "EMAIL" | "DATE" | "AGE" | "DATE_RANGE" | "SELECT_DATE_RANGE" | "TIME" | "PARAGRAPH" | "PAGE_HEADER" | "RADIO_GROUP" | "FILE" | "FILE_WITH_OPTIONS" | "BULLET_LIST" | "CHECKBOX" | "SELECT" | "COUNTRY" | "LOCATION" | "DIVIDER" | "ADMINISTRATIVE_AREA" | "FACILITY" | "OFFICE" | "SIGNATURE" | "DATA" | "BUTTON" | "SEARCH" | "ALPHA_PRINT_BUTTON" | "HTTP" | "LINK_BUTTON" | "VERIFICATION_STATUS" | "QUERY_PARAM_READER" | "QR_READER" | "ID_READER" | "LOADER" | undefined;
264
+ options?: {
265
+ value: string;
266
+ label: string | import("../commons").TranslationConfig;
267
+ }[] | undefined;
268
+ label?: import("../commons").TranslationConfig | undefined;
269
+ conditionals?: ({
270
+ type: "SHOW";
271
+ conditional: import("../commons").JSONSchema;
272
+ } | {
273
+ type: "ENABLE";
274
+ conditional: import("../commons").JSONSchema;
275
+ } | {
276
+ type: "DISPLAY_ON_REVIEW";
277
+ conditional: import("../commons").JSONSchema;
278
+ })[] | undefined;
279
+ searchCriteriaLabelPrefix?: import("../commons").TranslationConfig | undefined;
280
+ validations?: {
281
+ message: import("../commons").TranslationConfig;
282
+ validator: import("../commons").JSONSchema;
283
+ }[] | undefined;
284
+ })[];
285
+ }[];
286
+ dateOfEvent?: {
287
+ $$field: string;
288
+ $$subfield: string[];
289
+ } | {
290
+ $$event: "createdAt" | "updatedAt" | "legalStatuses.DECLARED.createdAt" | "legalStatuses.DECLARED.acceptedAt" | "legalStatuses.REGISTERED.createdAt" | "legalStatuses.REGISTERED.acceptedAt";
291
+ } | undefined;
292
+ fallbackTitle?: import("../commons").TranslationConfig | undefined;
293
+ }[];
294
+ meta: import("trpc-to-openapi").OpenApiMeta;
295
+ }>;
296
+ }>>;
297
+ create: import("@trpc/server").TRPCMutationProcedure<{
298
+ input: {
299
+ type: string;
300
+ transactionId: string;
301
+ };
302
+ output: {
303
+ type: string;
304
+ id: string & import("zod").BRAND<"UUID">;
305
+ createdAt: string;
306
+ trackingId: string;
307
+ updatedAt: string;
308
+ actions: ({
309
+ type: "ASSIGN";
310
+ id: string & import("zod").BRAND<"UUID">;
311
+ status: "Rejected" | "Requested" | "Accepted";
312
+ transactionId: string;
313
+ createdByUserType: "system" | "user";
314
+ createdAt: string;
315
+ createdBy: string;
316
+ createdByRole: string;
317
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
318
+ assignedTo: string;
319
+ createdBySignature?: string | null | undefined;
320
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
321
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
322
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
323
+ } | {
324
+ type: "UNASSIGN";
325
+ id: string & import("zod").BRAND<"UUID">;
326
+ status: "Rejected" | "Requested" | "Accepted";
327
+ transactionId: string;
328
+ createdByUserType: "system" | "user";
329
+ createdAt: string;
330
+ createdBy: string;
331
+ createdByRole: string;
332
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
333
+ createdBySignature?: string | null | undefined;
334
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
335
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
336
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
337
+ } | {
338
+ type: "REGISTER";
339
+ id: string & import("zod").BRAND<"UUID">;
340
+ status: "Rejected" | "Requested" | "Accepted";
341
+ transactionId: string;
342
+ createdByUserType: "system" | "user";
343
+ createdAt: string;
344
+ createdBy: string;
345
+ createdByRole: string;
346
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
347
+ createdBySignature?: string | null | undefined;
348
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
349
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
350
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
351
+ registrationNumber?: string | undefined;
352
+ } | {
353
+ type: "DECLARE";
354
+ id: string & import("zod").BRAND<"UUID">;
355
+ status: "Rejected" | "Requested" | "Accepted";
356
+ transactionId: string;
357
+ createdByUserType: "system" | "user";
358
+ createdAt: string;
359
+ createdBy: string;
360
+ createdByRole: string;
361
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
362
+ createdBySignature?: string | null | undefined;
363
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
364
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
365
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
366
+ } | {
367
+ type: "VALIDATE";
368
+ id: string & import("zod").BRAND<"UUID">;
369
+ status: "Rejected" | "Requested" | "Accepted";
370
+ transactionId: string;
371
+ createdByUserType: "system" | "user";
372
+ createdAt: string;
373
+ createdBy: string;
374
+ createdByRole: string;
375
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
376
+ createdBySignature?: string | null | undefined;
377
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
378
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
379
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
380
+ } | {
381
+ type: "REJECT";
382
+ id: string & import("zod").BRAND<"UUID">;
383
+ status: "Rejected" | "Requested" | "Accepted";
384
+ content: {
385
+ reason: string;
386
+ };
387
+ transactionId: string;
388
+ createdByUserType: "system" | "user";
389
+ createdAt: string;
390
+ createdBy: string;
391
+ createdByRole: string;
392
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
393
+ createdBySignature?: string | null | undefined;
394
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
395
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
396
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
397
+ } | {
398
+ type: "DUPLICATE_DETECTED";
399
+ id: string & import("zod").BRAND<"UUID">;
400
+ status: "Rejected" | "Requested" | "Accepted";
401
+ content: {
402
+ duplicates: {
403
+ id: string & import("zod").BRAND<"UUID">;
404
+ trackingId: string;
405
+ }[];
406
+ };
407
+ transactionId: string;
408
+ createdByUserType: "system" | "user";
409
+ createdAt: string;
410
+ createdBy: string;
411
+ createdByRole: string;
412
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
413
+ createdBySignature?: string | null | undefined;
414
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
415
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
416
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
417
+ } | {
418
+ type: "MARK_AS_NOT_DUPLICATE";
419
+ id: string & import("zod").BRAND<"UUID">;
420
+ status: "Rejected" | "Requested" | "Accepted";
421
+ transactionId: string;
422
+ createdByUserType: "system" | "user";
423
+ createdAt: string;
424
+ createdBy: string;
425
+ createdByRole: string;
426
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
427
+ createdBySignature?: string | null | undefined;
428
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
429
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
430
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
431
+ } | {
432
+ type: "MARK_AS_DUPLICATE";
433
+ id: string & import("zod").BRAND<"UUID">;
434
+ status: "Rejected" | "Requested" | "Accepted";
435
+ transactionId: string;
436
+ createdByUserType: "system" | "user";
437
+ createdAt: string;
438
+ createdBy: string;
439
+ createdByRole: string;
440
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
441
+ content?: {
442
+ duplicateOf: string & import("zod").BRAND<"UUID">;
443
+ } | undefined;
444
+ createdBySignature?: string | null | undefined;
445
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
446
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
447
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
448
+ } | {
449
+ type: "ARCHIVE";
450
+ id: string & import("zod").BRAND<"UUID">;
451
+ status: "Rejected" | "Requested" | "Accepted";
452
+ content: {
453
+ reason: string;
454
+ };
455
+ transactionId: string;
456
+ createdByUserType: "system" | "user";
457
+ createdAt: string;
458
+ createdBy: string;
459
+ createdByRole: string;
460
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
461
+ createdBySignature?: string | null | undefined;
462
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
463
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
464
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
465
+ } | {
466
+ type: "CREATE";
467
+ id: string & import("zod").BRAND<"UUID">;
468
+ status: "Rejected" | "Requested" | "Accepted";
469
+ transactionId: string;
470
+ createdByUserType: "system" | "user";
471
+ createdAt: string;
472
+ createdBy: string;
473
+ createdByRole: string;
474
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
475
+ createdBySignature?: string | null | undefined;
476
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
477
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
478
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
479
+ } | {
480
+ type: "NOTIFY";
481
+ id: string & import("zod").BRAND<"UUID">;
482
+ status: "Rejected" | "Requested" | "Accepted";
483
+ transactionId: string;
484
+ createdByUserType: "system" | "user";
485
+ createdAt: string;
486
+ createdBy: string;
487
+ createdByRole: string;
488
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
489
+ createdBySignature?: string | null | undefined;
490
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
491
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
492
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
493
+ } | {
494
+ type: "PRINT_CERTIFICATE";
495
+ id: string & import("zod").BRAND<"UUID">;
496
+ status: "Rejected" | "Requested" | "Accepted";
497
+ transactionId: string;
498
+ createdByUserType: "system" | "user";
499
+ createdAt: string;
500
+ createdBy: string;
501
+ createdByRole: string;
502
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
503
+ content?: {
504
+ templateId?: string | undefined;
505
+ } | null | undefined;
506
+ createdBySignature?: string | null | undefined;
507
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
508
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
509
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
510
+ } | {
511
+ type: "REQUEST_CORRECTION";
512
+ id: string & import("zod").BRAND<"UUID">;
513
+ status: "Rejected" | "Requested" | "Accepted";
514
+ transactionId: string;
515
+ createdByUserType: "system" | "user";
516
+ createdAt: string;
517
+ createdBy: string;
518
+ createdByRole: string;
519
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
520
+ createdBySignature?: string | null | undefined;
521
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
522
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
523
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
524
+ } | {
525
+ type: "APPROVE_CORRECTION";
526
+ id: string & import("zod").BRAND<"UUID">;
527
+ status: "Rejected" | "Requested" | "Accepted";
528
+ transactionId: string;
529
+ createdByUserType: "system" | "user";
530
+ createdAt: string;
531
+ createdBy: string;
532
+ createdByRole: string;
533
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
534
+ requestId: string;
535
+ createdBySignature?: string | null | undefined;
536
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
537
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
538
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
539
+ } | {
540
+ type: "REJECT_CORRECTION";
541
+ id: string & import("zod").BRAND<"UUID">;
542
+ status: "Rejected" | "Requested" | "Accepted";
543
+ content: {
544
+ reason: string;
545
+ };
546
+ transactionId: string;
547
+ createdByUserType: "system" | "user";
548
+ createdAt: string;
549
+ createdBy: string;
550
+ createdByRole: string;
551
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
552
+ requestId: string;
553
+ createdBySignature?: string | null | undefined;
554
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
555
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
556
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
557
+ } | {
558
+ type: "READ";
559
+ id: string & import("zod").BRAND<"UUID">;
560
+ status: "Rejected" | "Requested" | "Accepted";
561
+ transactionId: string;
562
+ createdByUserType: "system" | "user";
563
+ createdAt: string;
564
+ createdBy: string;
565
+ createdByRole: string;
566
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
567
+ createdBySignature?: string | null | undefined;
568
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
569
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
570
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
571
+ } | {
572
+ type: "NOTIFY" | "DECLARE" | "VALIDATE" | "REGISTER" | "REJECT" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "REJECT_CORRECTION" | "APPROVE_CORRECTION";
573
+ id: string & import("zod").BRAND<"UUID">;
574
+ status: "Rejected";
575
+ transactionId: string;
576
+ createdByUserType: "system" | "user";
577
+ createdAt: string;
578
+ createdBy: string;
579
+ createdByRole: string;
580
+ createdBySignature?: string | null | undefined;
581
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
582
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
583
+ })[];
584
+ };
585
+ meta: import("trpc-to-openapi").OpenApiMeta;
586
+ }>;
587
+ get: import("@trpc/server").TRPCQueryProcedure<{
588
+ input: string;
589
+ output: {
590
+ type: string;
591
+ id: string & import("zod").BRAND<"UUID">;
592
+ createdAt: string;
593
+ trackingId: string;
594
+ updatedAt: string;
595
+ actions: ({
596
+ type: "ASSIGN";
597
+ id: string & import("zod").BRAND<"UUID">;
598
+ status: "Rejected" | "Requested" | "Accepted";
599
+ transactionId: string;
600
+ createdByUserType: "system" | "user";
601
+ createdAt: string;
602
+ createdBy: string;
603
+ createdByRole: string;
604
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
605
+ assignedTo: string;
606
+ createdBySignature?: string | null | undefined;
607
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
608
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
609
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
610
+ } | {
611
+ type: "UNASSIGN";
612
+ id: string & import("zod").BRAND<"UUID">;
613
+ status: "Rejected" | "Requested" | "Accepted";
614
+ transactionId: string;
615
+ createdByUserType: "system" | "user";
616
+ createdAt: string;
617
+ createdBy: string;
618
+ createdByRole: string;
619
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
620
+ createdBySignature?: string | null | undefined;
621
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
622
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
623
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
624
+ } | {
625
+ type: "REGISTER";
626
+ id: string & import("zod").BRAND<"UUID">;
627
+ status: "Rejected" | "Requested" | "Accepted";
628
+ transactionId: string;
629
+ createdByUserType: "system" | "user";
630
+ createdAt: string;
631
+ createdBy: string;
632
+ createdByRole: string;
633
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
634
+ createdBySignature?: string | null | undefined;
635
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
636
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
637
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
638
+ registrationNumber?: string | undefined;
639
+ } | {
640
+ type: "DECLARE";
641
+ id: string & import("zod").BRAND<"UUID">;
642
+ status: "Rejected" | "Requested" | "Accepted";
643
+ transactionId: string;
644
+ createdByUserType: "system" | "user";
645
+ createdAt: string;
646
+ createdBy: string;
647
+ createdByRole: string;
648
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
649
+ createdBySignature?: string | null | undefined;
650
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
651
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
652
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
653
+ } | {
654
+ type: "VALIDATE";
655
+ id: string & import("zod").BRAND<"UUID">;
656
+ status: "Rejected" | "Requested" | "Accepted";
657
+ transactionId: string;
658
+ createdByUserType: "system" | "user";
659
+ createdAt: string;
660
+ createdBy: string;
661
+ createdByRole: string;
662
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
663
+ createdBySignature?: string | null | undefined;
664
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
665
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
666
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
667
+ } | {
668
+ type: "REJECT";
669
+ id: string & import("zod").BRAND<"UUID">;
670
+ status: "Rejected" | "Requested" | "Accepted";
671
+ content: {
672
+ reason: string;
673
+ };
674
+ transactionId: string;
675
+ createdByUserType: "system" | "user";
676
+ createdAt: string;
677
+ createdBy: string;
678
+ createdByRole: string;
679
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
680
+ createdBySignature?: string | null | undefined;
681
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
682
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
683
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
684
+ } | {
685
+ type: "DUPLICATE_DETECTED";
686
+ id: string & import("zod").BRAND<"UUID">;
687
+ status: "Rejected" | "Requested" | "Accepted";
688
+ content: {
689
+ duplicates: {
690
+ id: string & import("zod").BRAND<"UUID">;
691
+ trackingId: string;
692
+ }[];
693
+ };
694
+ transactionId: string;
695
+ createdByUserType: "system" | "user";
696
+ createdAt: string;
697
+ createdBy: string;
698
+ createdByRole: string;
699
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
700
+ createdBySignature?: string | null | undefined;
701
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
702
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
703
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
704
+ } | {
705
+ type: "MARK_AS_NOT_DUPLICATE";
706
+ id: string & import("zod").BRAND<"UUID">;
707
+ status: "Rejected" | "Requested" | "Accepted";
708
+ transactionId: string;
709
+ createdByUserType: "system" | "user";
710
+ createdAt: string;
711
+ createdBy: string;
712
+ createdByRole: string;
713
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
714
+ createdBySignature?: string | null | undefined;
715
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
716
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
717
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
718
+ } | {
719
+ type: "MARK_AS_DUPLICATE";
720
+ id: string & import("zod").BRAND<"UUID">;
721
+ status: "Rejected" | "Requested" | "Accepted";
722
+ transactionId: string;
723
+ createdByUserType: "system" | "user";
724
+ createdAt: string;
725
+ createdBy: string;
726
+ createdByRole: string;
727
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
728
+ content?: {
729
+ duplicateOf: string & import("zod").BRAND<"UUID">;
730
+ } | undefined;
731
+ createdBySignature?: string | null | undefined;
732
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
733
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
734
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
735
+ } | {
736
+ type: "ARCHIVE";
737
+ id: string & import("zod").BRAND<"UUID">;
738
+ status: "Rejected" | "Requested" | "Accepted";
739
+ content: {
740
+ reason: string;
741
+ };
742
+ transactionId: string;
743
+ createdByUserType: "system" | "user";
744
+ createdAt: string;
745
+ createdBy: string;
746
+ createdByRole: string;
747
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
748
+ createdBySignature?: string | null | undefined;
749
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
750
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
751
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
752
+ } | {
753
+ type: "CREATE";
754
+ id: string & import("zod").BRAND<"UUID">;
755
+ status: "Rejected" | "Requested" | "Accepted";
756
+ transactionId: string;
757
+ createdByUserType: "system" | "user";
758
+ createdAt: string;
759
+ createdBy: string;
760
+ createdByRole: string;
761
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
762
+ createdBySignature?: string | null | undefined;
763
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
764
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
765
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
766
+ } | {
767
+ type: "NOTIFY";
768
+ id: string & import("zod").BRAND<"UUID">;
769
+ status: "Rejected" | "Requested" | "Accepted";
770
+ transactionId: string;
771
+ createdByUserType: "system" | "user";
772
+ createdAt: string;
773
+ createdBy: string;
774
+ createdByRole: string;
775
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
776
+ createdBySignature?: string | null | undefined;
777
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
778
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
779
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
780
+ } | {
781
+ type: "PRINT_CERTIFICATE";
782
+ id: string & import("zod").BRAND<"UUID">;
783
+ status: "Rejected" | "Requested" | "Accepted";
784
+ transactionId: string;
785
+ createdByUserType: "system" | "user";
786
+ createdAt: string;
787
+ createdBy: string;
788
+ createdByRole: string;
789
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
790
+ content?: {
791
+ templateId?: string | undefined;
792
+ } | null | undefined;
793
+ createdBySignature?: string | null | undefined;
794
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
795
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
796
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
797
+ } | {
798
+ type: "REQUEST_CORRECTION";
799
+ id: string & import("zod").BRAND<"UUID">;
800
+ status: "Rejected" | "Requested" | "Accepted";
801
+ transactionId: string;
802
+ createdByUserType: "system" | "user";
803
+ createdAt: string;
804
+ createdBy: string;
805
+ createdByRole: string;
806
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
807
+ createdBySignature?: string | null | undefined;
808
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
809
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
810
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
811
+ } | {
812
+ type: "APPROVE_CORRECTION";
813
+ id: string & import("zod").BRAND<"UUID">;
814
+ status: "Rejected" | "Requested" | "Accepted";
815
+ transactionId: string;
816
+ createdByUserType: "system" | "user";
817
+ createdAt: string;
818
+ createdBy: string;
819
+ createdByRole: string;
820
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
821
+ requestId: string;
822
+ createdBySignature?: string | null | undefined;
823
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
824
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
825
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
826
+ } | {
827
+ type: "REJECT_CORRECTION";
828
+ id: string & import("zod").BRAND<"UUID">;
829
+ status: "Rejected" | "Requested" | "Accepted";
830
+ content: {
831
+ reason: string;
832
+ };
833
+ transactionId: string;
834
+ createdByUserType: "system" | "user";
835
+ createdAt: string;
836
+ createdBy: string;
837
+ createdByRole: string;
838
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
839
+ requestId: string;
840
+ createdBySignature?: string | null | undefined;
841
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
842
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
843
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
844
+ } | {
845
+ type: "READ";
846
+ id: string & import("zod").BRAND<"UUID">;
847
+ status: "Rejected" | "Requested" | "Accepted";
848
+ transactionId: string;
849
+ createdByUserType: "system" | "user";
850
+ createdAt: string;
851
+ createdBy: string;
852
+ createdByRole: string;
853
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
854
+ createdBySignature?: string | null | undefined;
855
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
856
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
857
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
858
+ } | {
859
+ type: "NOTIFY" | "DECLARE" | "VALIDATE" | "REGISTER" | "REJECT" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "REJECT_CORRECTION" | "APPROVE_CORRECTION";
860
+ id: string & import("zod").BRAND<"UUID">;
861
+ status: "Rejected";
862
+ transactionId: string;
863
+ createdByUserType: "system" | "user";
864
+ createdAt: string;
865
+ createdBy: string;
866
+ createdByRole: string;
867
+ createdBySignature?: string | null | undefined;
868
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
869
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
870
+ })[];
871
+ };
872
+ meta: import("trpc-to-openapi").OpenApiMeta;
873
+ }>;
874
+ getDuplicates: import("@trpc/server").TRPCQueryProcedure<{
875
+ input: {
876
+ eventId: string;
877
+ };
878
+ output: {
879
+ type: string;
880
+ id: string & import("zod").BRAND<"UUID">;
881
+ createdAt: string;
882
+ trackingId: string;
883
+ updatedAt: string;
884
+ actions: ({
885
+ type: "ASSIGN";
886
+ id: string & import("zod").BRAND<"UUID">;
887
+ status: "Rejected" | "Requested" | "Accepted";
888
+ transactionId: string;
889
+ createdByUserType: "system" | "user";
890
+ createdAt: string;
891
+ createdBy: string;
892
+ createdByRole: string;
893
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
894
+ assignedTo: string;
895
+ createdBySignature?: string | null | undefined;
896
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
897
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
898
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
899
+ } | {
900
+ type: "UNASSIGN";
901
+ id: string & import("zod").BRAND<"UUID">;
902
+ status: "Rejected" | "Requested" | "Accepted";
903
+ transactionId: string;
904
+ createdByUserType: "system" | "user";
905
+ createdAt: string;
906
+ createdBy: string;
907
+ createdByRole: string;
908
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
909
+ createdBySignature?: string | null | undefined;
910
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
911
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
912
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
913
+ } | {
914
+ type: "REGISTER";
915
+ id: string & import("zod").BRAND<"UUID">;
916
+ status: "Rejected" | "Requested" | "Accepted";
917
+ transactionId: string;
918
+ createdByUserType: "system" | "user";
919
+ createdAt: string;
920
+ createdBy: string;
921
+ createdByRole: string;
922
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
923
+ createdBySignature?: string | null | undefined;
924
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
925
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
926
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
927
+ registrationNumber?: string | undefined;
928
+ } | {
929
+ type: "DECLARE";
930
+ id: string & import("zod").BRAND<"UUID">;
931
+ status: "Rejected" | "Requested" | "Accepted";
932
+ transactionId: string;
933
+ createdByUserType: "system" | "user";
934
+ createdAt: string;
935
+ createdBy: string;
936
+ createdByRole: string;
937
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
938
+ createdBySignature?: string | null | undefined;
939
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
940
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
941
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
942
+ } | {
943
+ type: "VALIDATE";
944
+ id: string & import("zod").BRAND<"UUID">;
945
+ status: "Rejected" | "Requested" | "Accepted";
946
+ transactionId: string;
947
+ createdByUserType: "system" | "user";
948
+ createdAt: string;
949
+ createdBy: string;
950
+ createdByRole: string;
951
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
952
+ createdBySignature?: string | null | undefined;
953
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
954
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
955
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
956
+ } | {
957
+ type: "REJECT";
958
+ id: string & import("zod").BRAND<"UUID">;
959
+ status: "Rejected" | "Requested" | "Accepted";
960
+ content: {
961
+ reason: string;
962
+ };
963
+ transactionId: string;
964
+ createdByUserType: "system" | "user";
965
+ createdAt: string;
966
+ createdBy: string;
967
+ createdByRole: string;
968
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
969
+ createdBySignature?: string | null | undefined;
970
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
971
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
972
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
973
+ } | {
974
+ type: "DUPLICATE_DETECTED";
975
+ id: string & import("zod").BRAND<"UUID">;
976
+ status: "Rejected" | "Requested" | "Accepted";
977
+ content: {
978
+ duplicates: {
979
+ id: string & import("zod").BRAND<"UUID">;
980
+ trackingId: string;
981
+ }[];
982
+ };
983
+ transactionId: string;
984
+ createdByUserType: "system" | "user";
985
+ createdAt: string;
986
+ createdBy: string;
987
+ createdByRole: string;
988
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
989
+ createdBySignature?: string | null | undefined;
990
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
991
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
992
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
993
+ } | {
994
+ type: "MARK_AS_NOT_DUPLICATE";
995
+ id: string & import("zod").BRAND<"UUID">;
996
+ status: "Rejected" | "Requested" | "Accepted";
997
+ transactionId: string;
998
+ createdByUserType: "system" | "user";
999
+ createdAt: string;
1000
+ createdBy: string;
1001
+ createdByRole: string;
1002
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1003
+ createdBySignature?: string | null | undefined;
1004
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1005
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1006
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1007
+ } | {
1008
+ type: "MARK_AS_DUPLICATE";
1009
+ id: string & import("zod").BRAND<"UUID">;
1010
+ status: "Rejected" | "Requested" | "Accepted";
1011
+ transactionId: string;
1012
+ createdByUserType: "system" | "user";
1013
+ createdAt: string;
1014
+ createdBy: string;
1015
+ createdByRole: string;
1016
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1017
+ content?: {
1018
+ duplicateOf: string & import("zod").BRAND<"UUID">;
1019
+ } | undefined;
1020
+ createdBySignature?: string | null | undefined;
1021
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1022
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1023
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1024
+ } | {
1025
+ type: "ARCHIVE";
1026
+ id: string & import("zod").BRAND<"UUID">;
1027
+ status: "Rejected" | "Requested" | "Accepted";
1028
+ content: {
1029
+ reason: string;
1030
+ };
1031
+ transactionId: string;
1032
+ createdByUserType: "system" | "user";
1033
+ createdAt: string;
1034
+ createdBy: string;
1035
+ createdByRole: string;
1036
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1037
+ createdBySignature?: string | null | undefined;
1038
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1039
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1040
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1041
+ } | {
1042
+ type: "CREATE";
1043
+ id: string & import("zod").BRAND<"UUID">;
1044
+ status: "Rejected" | "Requested" | "Accepted";
1045
+ transactionId: string;
1046
+ createdByUserType: "system" | "user";
1047
+ createdAt: string;
1048
+ createdBy: string;
1049
+ createdByRole: string;
1050
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1051
+ createdBySignature?: string | null | undefined;
1052
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1053
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1054
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1055
+ } | {
1056
+ type: "NOTIFY";
1057
+ id: string & import("zod").BRAND<"UUID">;
1058
+ status: "Rejected" | "Requested" | "Accepted";
1059
+ transactionId: string;
1060
+ createdByUserType: "system" | "user";
1061
+ createdAt: string;
1062
+ createdBy: string;
1063
+ createdByRole: string;
1064
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1065
+ createdBySignature?: string | null | undefined;
1066
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1067
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1068
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1069
+ } | {
1070
+ type: "PRINT_CERTIFICATE";
1071
+ id: string & import("zod").BRAND<"UUID">;
1072
+ status: "Rejected" | "Requested" | "Accepted";
1073
+ transactionId: string;
1074
+ createdByUserType: "system" | "user";
1075
+ createdAt: string;
1076
+ createdBy: string;
1077
+ createdByRole: string;
1078
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1079
+ content?: {
1080
+ templateId?: string | undefined;
1081
+ } | null | undefined;
1082
+ createdBySignature?: string | null | undefined;
1083
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1084
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1085
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1086
+ } | {
1087
+ type: "REQUEST_CORRECTION";
1088
+ id: string & import("zod").BRAND<"UUID">;
1089
+ status: "Rejected" | "Requested" | "Accepted";
1090
+ transactionId: string;
1091
+ createdByUserType: "system" | "user";
1092
+ createdAt: string;
1093
+ createdBy: string;
1094
+ createdByRole: string;
1095
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1096
+ createdBySignature?: string | null | undefined;
1097
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1098
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1099
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1100
+ } | {
1101
+ type: "APPROVE_CORRECTION";
1102
+ id: string & import("zod").BRAND<"UUID">;
1103
+ status: "Rejected" | "Requested" | "Accepted";
1104
+ transactionId: string;
1105
+ createdByUserType: "system" | "user";
1106
+ createdAt: string;
1107
+ createdBy: string;
1108
+ createdByRole: string;
1109
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1110
+ requestId: string;
1111
+ createdBySignature?: string | null | undefined;
1112
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1113
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1114
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1115
+ } | {
1116
+ type: "REJECT_CORRECTION";
1117
+ id: string & import("zod").BRAND<"UUID">;
1118
+ status: "Rejected" | "Requested" | "Accepted";
1119
+ content: {
1120
+ reason: string;
1121
+ };
1122
+ transactionId: string;
1123
+ createdByUserType: "system" | "user";
1124
+ createdAt: string;
1125
+ createdBy: string;
1126
+ createdByRole: string;
1127
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1128
+ requestId: string;
1129
+ createdBySignature?: string | null | undefined;
1130
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1131
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1132
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1133
+ } | {
1134
+ type: "READ";
1135
+ id: string & import("zod").BRAND<"UUID">;
1136
+ status: "Rejected" | "Requested" | "Accepted";
1137
+ transactionId: string;
1138
+ createdByUserType: "system" | "user";
1139
+ createdAt: string;
1140
+ createdBy: string;
1141
+ createdByRole: string;
1142
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1143
+ createdBySignature?: string | null | undefined;
1144
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1145
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1146
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1147
+ } | {
1148
+ type: "NOTIFY" | "DECLARE" | "VALIDATE" | "REGISTER" | "REJECT" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "REJECT_CORRECTION" | "APPROVE_CORRECTION";
1149
+ id: string & import("zod").BRAND<"UUID">;
1150
+ status: "Rejected";
1151
+ transactionId: string;
1152
+ createdByUserType: "system" | "user";
1153
+ createdAt: string;
1154
+ createdBy: string;
1155
+ createdByRole: string;
1156
+ createdBySignature?: string | null | undefined;
1157
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1158
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1159
+ })[];
1160
+ }[];
1161
+ meta: import("trpc-to-openapi").OpenApiMeta;
1162
+ }>;
1163
+ delete: import("@trpc/server").TRPCMutationProcedure<{
1164
+ input: {
1165
+ eventId: string;
1166
+ };
1167
+ output: {
1168
+ id: string & import("zod").BRAND<"UUID">;
1169
+ };
1170
+ meta: import("trpc-to-openapi").OpenApiMeta;
1171
+ }>;
1172
+ draft: import("@trpc/server").TRPCBuiltRouter<{
1173
+ ctx: {
1174
+ user: {
1175
+ type: "user";
1176
+ id: string;
1177
+ role: string;
1178
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
1179
+ signature?: string | undefined;
1180
+ } | {
1181
+ type: "system";
1182
+ id: string;
1183
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
1184
+ primaryOfficeId?: undefined;
1185
+ signature?: undefined;
1186
+ };
1187
+ token: `Bearer ${string}`;
1188
+ };
1189
+ meta: import("trpc-to-openapi").OpenApiMeta;
1190
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
1191
+ transformer: true;
1192
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
1193
+ list: import("@trpc/server").TRPCQueryProcedure<{
1194
+ input: void;
1195
+ output: {
1196
+ id: string & import("zod").BRAND<"UUID">;
1197
+ transactionId: string;
1198
+ createdAt: string;
1199
+ eventId: string & import("zod").BRAND<"UUID">;
1200
+ action: {
1201
+ type: "CREATE" | "NOTIFY" | "DECLARE" | "VALIDATE" | "REGISTER" | "DUPLICATE_DETECTED" | "REJECT" | "MARK_AS_DUPLICATE" | "MARK_AS_NOT_DUPLICATE" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "REJECT_CORRECTION" | "APPROVE_CORRECTION" | "READ" | "ASSIGN" | "UNASSIGN";
1202
+ status: "Rejected" | "Requested" | "Accepted";
1203
+ transactionId: string;
1204
+ createdByUserType: "system" | "user";
1205
+ createdAt: string;
1206
+ createdBy: string;
1207
+ createdByRole: string;
1208
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1209
+ createdBySignature?: string | null | undefined;
1210
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1211
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1212
+ };
1213
+ }[];
1214
+ meta: import("trpc-to-openapi").OpenApiMeta;
1215
+ }>;
1216
+ create: import("@trpc/server").TRPCMutationProcedure<{
1217
+ input: {
1218
+ type: "CREATE" | "NOTIFY" | "DECLARE" | "VALIDATE" | "REGISTER" | "DUPLICATE_DETECTED" | "REJECT" | "MARK_AS_DUPLICATE" | "MARK_AS_NOT_DUPLICATE" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "REJECT_CORRECTION" | "APPROVE_CORRECTION" | "READ" | "ASSIGN" | "UNASSIGN";
1219
+ status: "Rejected" | "Requested" | "Accepted";
1220
+ transactionId: string;
1221
+ eventId: string;
1222
+ createdAtLocation?: string | null | undefined;
1223
+ declaration?: Record<string, import("../commons").FieldUpdateValue> | undefined;
1224
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | undefined;
1225
+ originalActionId?: string | undefined;
1226
+ keepAssignment?: boolean | undefined;
1227
+ };
1228
+ output: {
1229
+ id: string & import("zod").BRAND<"UUID">;
1230
+ transactionId: string;
1231
+ createdAt: string;
1232
+ eventId: string & import("zod").BRAND<"UUID">;
1233
+ action: {
1234
+ type: "CREATE" | "NOTIFY" | "DECLARE" | "VALIDATE" | "REGISTER" | "DUPLICATE_DETECTED" | "REJECT" | "MARK_AS_DUPLICATE" | "MARK_AS_NOT_DUPLICATE" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "REJECT_CORRECTION" | "APPROVE_CORRECTION" | "READ" | "ASSIGN" | "UNASSIGN";
1235
+ status: "Rejected" | "Requested" | "Accepted";
1236
+ transactionId: string;
1237
+ createdByUserType: "system" | "user";
1238
+ createdAt: string;
1239
+ createdBy: string;
1240
+ createdByRole: string;
1241
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1242
+ createdBySignature?: string | null | undefined;
1243
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1244
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1245
+ };
1246
+ };
1247
+ meta: import("trpc-to-openapi").OpenApiMeta;
1248
+ }>;
1249
+ }>>;
1250
+ actions: import("@trpc/server").TRPCBuiltRouter<{
1251
+ ctx: {
1252
+ user: {
1253
+ type: "user";
1254
+ id: string;
1255
+ role: string;
1256
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
1257
+ signature?: string | undefined;
1258
+ } | {
1259
+ type: "system";
1260
+ id: string;
1261
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
1262
+ primaryOfficeId?: undefined;
1263
+ signature?: undefined;
1264
+ };
1265
+ token: `Bearer ${string}`;
1266
+ };
1267
+ meta: import("trpc-to-openapi").OpenApiMeta;
1268
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
1269
+ transformer: true;
1270
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
1271
+ notify: import("@trpc/server").TRPCBuiltRouter<{
1272
+ ctx: {
1273
+ user: {
1274
+ type: "user";
1275
+ id: string;
1276
+ role: string;
1277
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
1278
+ signature?: string | undefined;
1279
+ } | {
1280
+ type: "system";
1281
+ id: string;
1282
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
1283
+ primaryOfficeId?: undefined;
1284
+ signature?: undefined;
1285
+ };
1286
+ token: `Bearer ${string}`;
1287
+ };
1288
+ meta: import("trpc-to-openapi").OpenApiMeta;
1289
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
1290
+ transformer: true;
1291
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
1292
+ request: import("@trpc/server").TRPCMutationProcedure<{
1293
+ input: import("../commons").ActionInput;
1294
+ output: import("../commons").EventDocument;
1295
+ meta: import("trpc-to-openapi").OpenApiMeta;
1296
+ }>;
1297
+ accept: import("@trpc/server").TRPCMutationProcedure<{
1298
+ input: import("../commons").ActionInput & {
1299
+ actionId: string;
1300
+ };
1301
+ output: import("../commons").EventDocument;
1302
+ meta: import("trpc-to-openapi").OpenApiMeta;
1303
+ }>;
1304
+ reject: import("@trpc/server").TRPCMutationProcedure<{
1305
+ input: {
1306
+ eventId: string;
1307
+ actionId: string;
1308
+ transactionId: string;
1309
+ };
1310
+ output: import("../commons").EventDocument;
1311
+ meta: import("trpc-to-openapi").OpenApiMeta;
1312
+ }>;
1313
+ }>>;
1314
+ declare: import("@trpc/server").TRPCBuiltRouter<{
1315
+ ctx: {
1316
+ user: {
1317
+ type: "user";
1318
+ id: string;
1319
+ role: string;
1320
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
1321
+ signature?: string | undefined;
1322
+ } | {
1323
+ type: "system";
1324
+ id: string;
1325
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
1326
+ primaryOfficeId?: undefined;
1327
+ signature?: undefined;
1328
+ };
1329
+ token: `Bearer ${string}`;
1330
+ };
1331
+ meta: import("trpc-to-openapi").OpenApiMeta;
1332
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
1333
+ transformer: true;
1334
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
1335
+ request: import("@trpc/server").TRPCMutationProcedure<{
1336
+ input: {
1337
+ transactionId: string;
1338
+ eventId: string;
1339
+ type?: "DECLARE" | undefined;
1340
+ createdAtLocation?: string | null | undefined;
1341
+ declaration?: Record<string, import("../commons").FieldUpdateValue> | undefined;
1342
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | undefined;
1343
+ originalActionId?: string | undefined;
1344
+ keepAssignment?: boolean | undefined;
1345
+ };
1346
+ output: {
1347
+ type: string;
1348
+ id: string & import("zod").BRAND<"UUID">;
1349
+ createdAt: string;
1350
+ trackingId: string;
1351
+ updatedAt: string;
1352
+ actions: ({
1353
+ type: "ASSIGN";
1354
+ id: string & import("zod").BRAND<"UUID">;
1355
+ status: "Rejected" | "Requested" | "Accepted";
1356
+ transactionId: string;
1357
+ createdByUserType: "system" | "user";
1358
+ createdAt: string;
1359
+ createdBy: string;
1360
+ createdByRole: string;
1361
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1362
+ assignedTo: string;
1363
+ createdBySignature?: string | null | undefined;
1364
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1365
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1366
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1367
+ } | {
1368
+ type: "UNASSIGN";
1369
+ id: string & import("zod").BRAND<"UUID">;
1370
+ status: "Rejected" | "Requested" | "Accepted";
1371
+ transactionId: string;
1372
+ createdByUserType: "system" | "user";
1373
+ createdAt: string;
1374
+ createdBy: string;
1375
+ createdByRole: string;
1376
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1377
+ createdBySignature?: string | null | undefined;
1378
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1379
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1380
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1381
+ } | {
1382
+ type: "REGISTER";
1383
+ id: string & import("zod").BRAND<"UUID">;
1384
+ status: "Rejected" | "Requested" | "Accepted";
1385
+ transactionId: string;
1386
+ createdByUserType: "system" | "user";
1387
+ createdAt: string;
1388
+ createdBy: string;
1389
+ createdByRole: string;
1390
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1391
+ createdBySignature?: string | null | undefined;
1392
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1393
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1394
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1395
+ registrationNumber?: string | undefined;
1396
+ } | {
1397
+ type: "DECLARE";
1398
+ id: string & import("zod").BRAND<"UUID">;
1399
+ status: "Rejected" | "Requested" | "Accepted";
1400
+ transactionId: string;
1401
+ createdByUserType: "system" | "user";
1402
+ createdAt: string;
1403
+ createdBy: string;
1404
+ createdByRole: string;
1405
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1406
+ createdBySignature?: string | null | undefined;
1407
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1408
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1409
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1410
+ } | {
1411
+ type: "VALIDATE";
1412
+ id: string & import("zod").BRAND<"UUID">;
1413
+ status: "Rejected" | "Requested" | "Accepted";
1414
+ transactionId: string;
1415
+ createdByUserType: "system" | "user";
1416
+ createdAt: string;
1417
+ createdBy: string;
1418
+ createdByRole: string;
1419
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1420
+ createdBySignature?: string | null | undefined;
1421
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1422
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1423
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1424
+ } | {
1425
+ type: "REJECT";
1426
+ id: string & import("zod").BRAND<"UUID">;
1427
+ status: "Rejected" | "Requested" | "Accepted";
1428
+ content: {
1429
+ reason: string;
1430
+ };
1431
+ transactionId: string;
1432
+ createdByUserType: "system" | "user";
1433
+ createdAt: string;
1434
+ createdBy: string;
1435
+ createdByRole: string;
1436
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1437
+ createdBySignature?: string | null | undefined;
1438
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1439
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1440
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1441
+ } | {
1442
+ type: "DUPLICATE_DETECTED";
1443
+ id: string & import("zod").BRAND<"UUID">;
1444
+ status: "Rejected" | "Requested" | "Accepted";
1445
+ content: {
1446
+ duplicates: {
1447
+ id: string & import("zod").BRAND<"UUID">;
1448
+ trackingId: string;
1449
+ }[];
1450
+ };
1451
+ transactionId: string;
1452
+ createdByUserType: "system" | "user";
1453
+ createdAt: string;
1454
+ createdBy: string;
1455
+ createdByRole: string;
1456
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1457
+ createdBySignature?: string | null | undefined;
1458
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1459
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1460
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1461
+ } | {
1462
+ type: "MARK_AS_NOT_DUPLICATE";
1463
+ id: string & import("zod").BRAND<"UUID">;
1464
+ status: "Rejected" | "Requested" | "Accepted";
1465
+ transactionId: string;
1466
+ createdByUserType: "system" | "user";
1467
+ createdAt: string;
1468
+ createdBy: string;
1469
+ createdByRole: string;
1470
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1471
+ createdBySignature?: string | null | undefined;
1472
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1473
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1474
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1475
+ } | {
1476
+ type: "MARK_AS_DUPLICATE";
1477
+ id: string & import("zod").BRAND<"UUID">;
1478
+ status: "Rejected" | "Requested" | "Accepted";
1479
+ transactionId: string;
1480
+ createdByUserType: "system" | "user";
1481
+ createdAt: string;
1482
+ createdBy: string;
1483
+ createdByRole: string;
1484
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1485
+ content?: {
1486
+ duplicateOf: string & import("zod").BRAND<"UUID">;
1487
+ } | undefined;
1488
+ createdBySignature?: string | null | undefined;
1489
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1490
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1491
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1492
+ } | {
1493
+ type: "ARCHIVE";
1494
+ id: string & import("zod").BRAND<"UUID">;
1495
+ status: "Rejected" | "Requested" | "Accepted";
1496
+ content: {
1497
+ reason: string;
1498
+ };
1499
+ transactionId: string;
1500
+ createdByUserType: "system" | "user";
1501
+ createdAt: string;
1502
+ createdBy: string;
1503
+ createdByRole: string;
1504
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1505
+ createdBySignature?: string | null | undefined;
1506
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1507
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1508
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1509
+ } | {
1510
+ type: "CREATE";
1511
+ id: string & import("zod").BRAND<"UUID">;
1512
+ status: "Rejected" | "Requested" | "Accepted";
1513
+ transactionId: string;
1514
+ createdByUserType: "system" | "user";
1515
+ createdAt: string;
1516
+ createdBy: string;
1517
+ createdByRole: string;
1518
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1519
+ createdBySignature?: string | null | undefined;
1520
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1521
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1522
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1523
+ } | {
1524
+ type: "NOTIFY";
1525
+ id: string & import("zod").BRAND<"UUID">;
1526
+ status: "Rejected" | "Requested" | "Accepted";
1527
+ transactionId: string;
1528
+ createdByUserType: "system" | "user";
1529
+ createdAt: string;
1530
+ createdBy: string;
1531
+ createdByRole: string;
1532
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1533
+ createdBySignature?: string | null | undefined;
1534
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1535
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1536
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1537
+ } | {
1538
+ type: "PRINT_CERTIFICATE";
1539
+ id: string & import("zod").BRAND<"UUID">;
1540
+ status: "Rejected" | "Requested" | "Accepted";
1541
+ transactionId: string;
1542
+ createdByUserType: "system" | "user";
1543
+ createdAt: string;
1544
+ createdBy: string;
1545
+ createdByRole: string;
1546
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1547
+ content?: {
1548
+ templateId?: string | undefined;
1549
+ } | null | undefined;
1550
+ createdBySignature?: string | null | undefined;
1551
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1552
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1553
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1554
+ } | {
1555
+ type: "REQUEST_CORRECTION";
1556
+ id: string & import("zod").BRAND<"UUID">;
1557
+ status: "Rejected" | "Requested" | "Accepted";
1558
+ transactionId: string;
1559
+ createdByUserType: "system" | "user";
1560
+ createdAt: string;
1561
+ createdBy: string;
1562
+ createdByRole: string;
1563
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1564
+ createdBySignature?: string | null | undefined;
1565
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1566
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1567
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1568
+ } | {
1569
+ type: "APPROVE_CORRECTION";
1570
+ id: string & import("zod").BRAND<"UUID">;
1571
+ status: "Rejected" | "Requested" | "Accepted";
1572
+ transactionId: string;
1573
+ createdByUserType: "system" | "user";
1574
+ createdAt: string;
1575
+ createdBy: string;
1576
+ createdByRole: string;
1577
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1578
+ requestId: string;
1579
+ createdBySignature?: string | null | undefined;
1580
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1581
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1582
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1583
+ } | {
1584
+ type: "REJECT_CORRECTION";
1585
+ id: string & import("zod").BRAND<"UUID">;
1586
+ status: "Rejected" | "Requested" | "Accepted";
1587
+ content: {
1588
+ reason: string;
1589
+ };
1590
+ transactionId: string;
1591
+ createdByUserType: "system" | "user";
1592
+ createdAt: string;
1593
+ createdBy: string;
1594
+ createdByRole: string;
1595
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1596
+ requestId: string;
1597
+ createdBySignature?: string | null | undefined;
1598
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1599
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1600
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1601
+ } | {
1602
+ type: "READ";
1603
+ id: string & import("zod").BRAND<"UUID">;
1604
+ status: "Rejected" | "Requested" | "Accepted";
1605
+ transactionId: string;
1606
+ createdByUserType: "system" | "user";
1607
+ createdAt: string;
1608
+ createdBy: string;
1609
+ createdByRole: string;
1610
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1611
+ createdBySignature?: string | null | undefined;
1612
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1613
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1614
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1615
+ } | {
1616
+ type: "NOTIFY" | "DECLARE" | "VALIDATE" | "REGISTER" | "REJECT" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "REJECT_CORRECTION" | "APPROVE_CORRECTION";
1617
+ id: string & import("zod").BRAND<"UUID">;
1618
+ status: "Rejected";
1619
+ transactionId: string;
1620
+ createdByUserType: "system" | "user";
1621
+ createdAt: string;
1622
+ createdBy: string;
1623
+ createdByRole: string;
1624
+ createdBySignature?: string | null | undefined;
1625
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1626
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1627
+ })[];
1628
+ };
1629
+ meta: import("trpc-to-openapi").OpenApiMeta;
1630
+ }>;
1631
+ accept: import("@trpc/server").TRPCMutationProcedure<{
1632
+ input: import("../commons").ActionInput & {
1633
+ actionId: string;
1634
+ };
1635
+ output: import("../commons").EventDocument;
1636
+ meta: import("trpc-to-openapi").OpenApiMeta;
1637
+ }>;
1638
+ reject: import("@trpc/server").TRPCMutationProcedure<{
1639
+ input: {
1640
+ eventId: string;
1641
+ actionId: string;
1642
+ transactionId: string;
1643
+ };
1644
+ output: import("../commons").EventDocument;
1645
+ meta: import("trpc-to-openapi").OpenApiMeta;
1646
+ }>;
1647
+ }>>;
1648
+ validate: import("@trpc/server").TRPCBuiltRouter<{
1649
+ ctx: {
1650
+ user: {
1651
+ type: "user";
1652
+ id: string;
1653
+ role: string;
1654
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
1655
+ signature?: string | undefined;
1656
+ } | {
1657
+ type: "system";
1658
+ id: string;
1659
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
1660
+ primaryOfficeId?: undefined;
1661
+ signature?: undefined;
1662
+ };
1663
+ token: `Bearer ${string}`;
1664
+ };
1665
+ meta: import("trpc-to-openapi").OpenApiMeta;
1666
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
1667
+ transformer: true;
1668
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
1669
+ request: import("@trpc/server").TRPCMutationProcedure<{
1670
+ input: import("../commons").ActionInput;
1671
+ output: import("../commons").EventDocument;
1672
+ meta: import("trpc-to-openapi").OpenApiMeta;
1673
+ }>;
1674
+ accept: import("@trpc/server").TRPCMutationProcedure<{
1675
+ input: import("../commons").ActionInput & {
1676
+ actionId: string;
1677
+ };
1678
+ output: import("../commons").EventDocument;
1679
+ meta: import("trpc-to-openapi").OpenApiMeta;
1680
+ }>;
1681
+ reject: import("@trpc/server").TRPCMutationProcedure<{
1682
+ input: {
1683
+ eventId: string;
1684
+ actionId: string;
1685
+ transactionId: string;
1686
+ };
1687
+ output: import("../commons").EventDocument;
1688
+ meta: import("trpc-to-openapi").OpenApiMeta;
1689
+ }>;
1690
+ }>>;
1691
+ reject: import("@trpc/server").TRPCBuiltRouter<{
1692
+ ctx: {
1693
+ user: {
1694
+ type: "user";
1695
+ id: string;
1696
+ role: string;
1697
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
1698
+ signature?: string | undefined;
1699
+ } | {
1700
+ type: "system";
1701
+ id: string;
1702
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
1703
+ primaryOfficeId?: undefined;
1704
+ signature?: undefined;
1705
+ };
1706
+ token: `Bearer ${string}`;
1707
+ };
1708
+ meta: import("trpc-to-openapi").OpenApiMeta;
1709
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
1710
+ transformer: true;
1711
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
1712
+ request: import("@trpc/server").TRPCMutationProcedure<{
1713
+ input: import("../commons").ActionInput;
1714
+ output: import("../commons").EventDocument;
1715
+ meta: import("trpc-to-openapi").OpenApiMeta;
1716
+ }>;
1717
+ accept: import("@trpc/server").TRPCMutationProcedure<{
1718
+ input: import("../commons").ActionInput & {
1719
+ actionId: string;
1720
+ };
1721
+ output: import("../commons").EventDocument;
1722
+ meta: import("trpc-to-openapi").OpenApiMeta;
1723
+ }>;
1724
+ reject: import("@trpc/server").TRPCMutationProcedure<{
1725
+ input: {
1726
+ eventId: string;
1727
+ actionId: string;
1728
+ transactionId: string;
1729
+ };
1730
+ output: import("../commons").EventDocument;
1731
+ meta: import("trpc-to-openapi").OpenApiMeta;
1732
+ }>;
1733
+ }>>;
1734
+ archive: import("@trpc/server").TRPCBuiltRouter<{
1735
+ ctx: {
1736
+ user: {
1737
+ type: "user";
1738
+ id: string;
1739
+ role: string;
1740
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
1741
+ signature?: string | undefined;
1742
+ } | {
1743
+ type: "system";
1744
+ id: string;
1745
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
1746
+ primaryOfficeId?: undefined;
1747
+ signature?: undefined;
1748
+ };
1749
+ token: `Bearer ${string}`;
1750
+ };
1751
+ meta: import("trpc-to-openapi").OpenApiMeta;
1752
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
1753
+ transformer: true;
1754
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
1755
+ request: import("@trpc/server").TRPCMutationProcedure<{
1756
+ input: import("../commons").ActionInput;
1757
+ output: import("../commons").EventDocument;
1758
+ meta: import("trpc-to-openapi").OpenApiMeta;
1759
+ }>;
1760
+ accept: import("@trpc/server").TRPCMutationProcedure<{
1761
+ input: import("../commons").ActionInput & {
1762
+ actionId: string;
1763
+ };
1764
+ output: import("../commons").EventDocument;
1765
+ meta: import("trpc-to-openapi").OpenApiMeta;
1766
+ }>;
1767
+ reject: import("@trpc/server").TRPCMutationProcedure<{
1768
+ input: {
1769
+ eventId: string;
1770
+ actionId: string;
1771
+ transactionId: string;
1772
+ };
1773
+ output: import("../commons").EventDocument;
1774
+ meta: import("trpc-to-openapi").OpenApiMeta;
1775
+ }>;
1776
+ }>>;
1777
+ register: import("@trpc/server").TRPCBuiltRouter<{
1778
+ ctx: {
1779
+ user: {
1780
+ type: "user";
1781
+ id: string;
1782
+ role: string;
1783
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
1784
+ signature?: string | undefined;
1785
+ } | {
1786
+ type: "system";
1787
+ id: string;
1788
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
1789
+ primaryOfficeId?: undefined;
1790
+ signature?: undefined;
1791
+ };
1792
+ token: `Bearer ${string}`;
1793
+ };
1794
+ meta: import("trpc-to-openapi").OpenApiMeta;
1795
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
1796
+ transformer: true;
1797
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
1798
+ request: import("@trpc/server").TRPCMutationProcedure<{
1799
+ input: import("../commons").ActionInput;
1800
+ output: import("../commons").EventDocument;
1801
+ meta: import("trpc-to-openapi").OpenApiMeta;
1802
+ }>;
1803
+ accept: import("@trpc/server").TRPCMutationProcedure<{
1804
+ input: import("../commons").ActionInput & {
1805
+ actionId: string;
1806
+ };
1807
+ output: import("../commons").EventDocument;
1808
+ meta: import("trpc-to-openapi").OpenApiMeta;
1809
+ }>;
1810
+ reject: import("@trpc/server").TRPCMutationProcedure<{
1811
+ input: {
1812
+ eventId: string;
1813
+ actionId: string;
1814
+ transactionId: string;
1815
+ };
1816
+ output: import("../commons").EventDocument;
1817
+ meta: import("trpc-to-openapi").OpenApiMeta;
1818
+ }>;
1819
+ }>>;
1820
+ printCertificate: import("@trpc/server").TRPCBuiltRouter<{
1821
+ ctx: {
1822
+ user: {
1823
+ type: "user";
1824
+ id: string;
1825
+ role: string;
1826
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
1827
+ signature?: string | undefined;
1828
+ } | {
1829
+ type: "system";
1830
+ id: string;
1831
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
1832
+ primaryOfficeId?: undefined;
1833
+ signature?: undefined;
1834
+ };
1835
+ token: `Bearer ${string}`;
1836
+ };
1837
+ meta: import("trpc-to-openapi").OpenApiMeta;
1838
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
1839
+ transformer: true;
1840
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
1841
+ request: import("@trpc/server").TRPCMutationProcedure<{
1842
+ input: import("../commons").ActionInput;
1843
+ output: import("../commons").EventDocument;
1844
+ meta: import("trpc-to-openapi").OpenApiMeta;
1845
+ }>;
1846
+ accept: import("@trpc/server").TRPCMutationProcedure<{
1847
+ input: import("../commons").ActionInput & {
1848
+ actionId: string;
1849
+ };
1850
+ output: import("../commons").EventDocument;
1851
+ meta: import("trpc-to-openapi").OpenApiMeta;
1852
+ }>;
1853
+ reject: import("@trpc/server").TRPCMutationProcedure<{
1854
+ input: {
1855
+ eventId: string;
1856
+ actionId: string;
1857
+ transactionId: string;
1858
+ };
1859
+ output: import("../commons").EventDocument;
1860
+ meta: import("trpc-to-openapi").OpenApiMeta;
1861
+ }>;
1862
+ }>>;
1863
+ assignment: import("@trpc/server").TRPCBuiltRouter<{
1864
+ ctx: {
1865
+ user: {
1866
+ type: "user";
1867
+ id: string;
1868
+ role: string;
1869
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
1870
+ signature?: string | undefined;
1871
+ } | {
1872
+ type: "system";
1873
+ id: string;
1874
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
1875
+ primaryOfficeId?: undefined;
1876
+ signature?: undefined;
1877
+ };
1878
+ token: `Bearer ${string}`;
1879
+ };
1880
+ meta: import("trpc-to-openapi").OpenApiMeta;
1881
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
1882
+ transformer: true;
1883
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
1884
+ assign: import("@trpc/server").TRPCMutationProcedure<{
1885
+ input: {
1886
+ type: "ASSIGN";
1887
+ transactionId: string;
1888
+ assignedTo: string;
1889
+ eventId: string;
1890
+ createdAtLocation?: string | null | undefined;
1891
+ declaration?: Record<string, import("../commons").FieldUpdateValue> | undefined;
1892
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | undefined;
1893
+ originalActionId?: string | undefined;
1894
+ keepAssignment?: boolean | undefined;
1895
+ };
1896
+ output: {
1897
+ type: string;
1898
+ id: string & import("zod").BRAND<"UUID">;
1899
+ createdAt: string;
1900
+ trackingId: string;
1901
+ updatedAt: string;
1902
+ actions: ({
1903
+ type: "ASSIGN";
1904
+ id: string & import("zod").BRAND<"UUID">;
1905
+ status: "Rejected" | "Requested" | "Accepted";
1906
+ transactionId: string;
1907
+ createdByUserType: "system" | "user";
1908
+ createdAt: string;
1909
+ createdBy: string;
1910
+ createdByRole: string;
1911
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1912
+ assignedTo: string;
1913
+ createdBySignature?: string | null | undefined;
1914
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1915
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1916
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1917
+ } | {
1918
+ type: "UNASSIGN";
1919
+ id: string & import("zod").BRAND<"UUID">;
1920
+ status: "Rejected" | "Requested" | "Accepted";
1921
+ transactionId: string;
1922
+ createdByUserType: "system" | "user";
1923
+ createdAt: string;
1924
+ createdBy: string;
1925
+ createdByRole: string;
1926
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1927
+ createdBySignature?: string | null | undefined;
1928
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1929
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1930
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1931
+ } | {
1932
+ type: "REGISTER";
1933
+ id: string & import("zod").BRAND<"UUID">;
1934
+ status: "Rejected" | "Requested" | "Accepted";
1935
+ transactionId: string;
1936
+ createdByUserType: "system" | "user";
1937
+ createdAt: string;
1938
+ createdBy: string;
1939
+ createdByRole: string;
1940
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1941
+ createdBySignature?: string | null | undefined;
1942
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1943
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1944
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1945
+ registrationNumber?: string | undefined;
1946
+ } | {
1947
+ type: "DECLARE";
1948
+ id: string & import("zod").BRAND<"UUID">;
1949
+ status: "Rejected" | "Requested" | "Accepted";
1950
+ transactionId: string;
1951
+ createdByUserType: "system" | "user";
1952
+ createdAt: string;
1953
+ createdBy: string;
1954
+ createdByRole: string;
1955
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1956
+ createdBySignature?: string | null | undefined;
1957
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1958
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1959
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1960
+ } | {
1961
+ type: "VALIDATE";
1962
+ id: string & import("zod").BRAND<"UUID">;
1963
+ status: "Rejected" | "Requested" | "Accepted";
1964
+ transactionId: string;
1965
+ createdByUserType: "system" | "user";
1966
+ createdAt: string;
1967
+ createdBy: string;
1968
+ createdByRole: string;
1969
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1970
+ createdBySignature?: string | null | undefined;
1971
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1972
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1973
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1974
+ } | {
1975
+ type: "REJECT";
1976
+ id: string & import("zod").BRAND<"UUID">;
1977
+ status: "Rejected" | "Requested" | "Accepted";
1978
+ content: {
1979
+ reason: string;
1980
+ };
1981
+ transactionId: string;
1982
+ createdByUserType: "system" | "user";
1983
+ createdAt: string;
1984
+ createdBy: string;
1985
+ createdByRole: string;
1986
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
1987
+ createdBySignature?: string | null | undefined;
1988
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1989
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
1990
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
1991
+ } | {
1992
+ type: "DUPLICATE_DETECTED";
1993
+ id: string & import("zod").BRAND<"UUID">;
1994
+ status: "Rejected" | "Requested" | "Accepted";
1995
+ content: {
1996
+ duplicates: {
1997
+ id: string & import("zod").BRAND<"UUID">;
1998
+ trackingId: string;
1999
+ }[];
2000
+ };
2001
+ transactionId: string;
2002
+ createdByUserType: "system" | "user";
2003
+ createdAt: string;
2004
+ createdBy: string;
2005
+ createdByRole: string;
2006
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2007
+ createdBySignature?: string | null | undefined;
2008
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2009
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2010
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2011
+ } | {
2012
+ type: "MARK_AS_NOT_DUPLICATE";
2013
+ id: string & import("zod").BRAND<"UUID">;
2014
+ status: "Rejected" | "Requested" | "Accepted";
2015
+ transactionId: string;
2016
+ createdByUserType: "system" | "user";
2017
+ createdAt: string;
2018
+ createdBy: string;
2019
+ createdByRole: string;
2020
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2021
+ createdBySignature?: string | null | undefined;
2022
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2023
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2024
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2025
+ } | {
2026
+ type: "MARK_AS_DUPLICATE";
2027
+ id: string & import("zod").BRAND<"UUID">;
2028
+ status: "Rejected" | "Requested" | "Accepted";
2029
+ transactionId: string;
2030
+ createdByUserType: "system" | "user";
2031
+ createdAt: string;
2032
+ createdBy: string;
2033
+ createdByRole: string;
2034
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2035
+ content?: {
2036
+ duplicateOf: string & import("zod").BRAND<"UUID">;
2037
+ } | undefined;
2038
+ createdBySignature?: string | null | undefined;
2039
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2040
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2041
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2042
+ } | {
2043
+ type: "ARCHIVE";
2044
+ id: string & import("zod").BRAND<"UUID">;
2045
+ status: "Rejected" | "Requested" | "Accepted";
2046
+ content: {
2047
+ reason: string;
2048
+ };
2049
+ transactionId: string;
2050
+ createdByUserType: "system" | "user";
2051
+ createdAt: string;
2052
+ createdBy: string;
2053
+ createdByRole: string;
2054
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2055
+ createdBySignature?: string | null | undefined;
2056
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2057
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2058
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2059
+ } | {
2060
+ type: "CREATE";
2061
+ id: string & import("zod").BRAND<"UUID">;
2062
+ status: "Rejected" | "Requested" | "Accepted";
2063
+ transactionId: string;
2064
+ createdByUserType: "system" | "user";
2065
+ createdAt: string;
2066
+ createdBy: string;
2067
+ createdByRole: string;
2068
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2069
+ createdBySignature?: string | null | undefined;
2070
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2071
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2072
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2073
+ } | {
2074
+ type: "NOTIFY";
2075
+ id: string & import("zod").BRAND<"UUID">;
2076
+ status: "Rejected" | "Requested" | "Accepted";
2077
+ transactionId: string;
2078
+ createdByUserType: "system" | "user";
2079
+ createdAt: string;
2080
+ createdBy: string;
2081
+ createdByRole: string;
2082
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2083
+ createdBySignature?: string | null | undefined;
2084
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2085
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2086
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2087
+ } | {
2088
+ type: "PRINT_CERTIFICATE";
2089
+ id: string & import("zod").BRAND<"UUID">;
2090
+ status: "Rejected" | "Requested" | "Accepted";
2091
+ transactionId: string;
2092
+ createdByUserType: "system" | "user";
2093
+ createdAt: string;
2094
+ createdBy: string;
2095
+ createdByRole: string;
2096
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2097
+ content?: {
2098
+ templateId?: string | undefined;
2099
+ } | null | undefined;
2100
+ createdBySignature?: string | null | undefined;
2101
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2102
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2103
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2104
+ } | {
2105
+ type: "REQUEST_CORRECTION";
2106
+ id: string & import("zod").BRAND<"UUID">;
2107
+ status: "Rejected" | "Requested" | "Accepted";
2108
+ transactionId: string;
2109
+ createdByUserType: "system" | "user";
2110
+ createdAt: string;
2111
+ createdBy: string;
2112
+ createdByRole: string;
2113
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2114
+ createdBySignature?: string | null | undefined;
2115
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2116
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2117
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2118
+ } | {
2119
+ type: "APPROVE_CORRECTION";
2120
+ id: string & import("zod").BRAND<"UUID">;
2121
+ status: "Rejected" | "Requested" | "Accepted";
2122
+ transactionId: string;
2123
+ createdByUserType: "system" | "user";
2124
+ createdAt: string;
2125
+ createdBy: string;
2126
+ createdByRole: string;
2127
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2128
+ requestId: string;
2129
+ createdBySignature?: string | null | undefined;
2130
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2131
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2132
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2133
+ } | {
2134
+ type: "REJECT_CORRECTION";
2135
+ id: string & import("zod").BRAND<"UUID">;
2136
+ status: "Rejected" | "Requested" | "Accepted";
2137
+ content: {
2138
+ reason: string;
2139
+ };
2140
+ transactionId: string;
2141
+ createdByUserType: "system" | "user";
2142
+ createdAt: string;
2143
+ createdBy: string;
2144
+ createdByRole: string;
2145
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2146
+ requestId: string;
2147
+ createdBySignature?: string | null | undefined;
2148
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2149
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2150
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2151
+ } | {
2152
+ type: "READ";
2153
+ id: string & import("zod").BRAND<"UUID">;
2154
+ status: "Rejected" | "Requested" | "Accepted";
2155
+ transactionId: string;
2156
+ createdByUserType: "system" | "user";
2157
+ createdAt: string;
2158
+ createdBy: string;
2159
+ createdByRole: string;
2160
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2161
+ createdBySignature?: string | null | undefined;
2162
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2163
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2164
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2165
+ } | {
2166
+ type: "NOTIFY" | "DECLARE" | "VALIDATE" | "REGISTER" | "REJECT" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "REJECT_CORRECTION" | "APPROVE_CORRECTION";
2167
+ id: string & import("zod").BRAND<"UUID">;
2168
+ status: "Rejected";
2169
+ transactionId: string;
2170
+ createdByUserType: "system" | "user";
2171
+ createdAt: string;
2172
+ createdBy: string;
2173
+ createdByRole: string;
2174
+ createdBySignature?: string | null | undefined;
2175
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2176
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2177
+ })[];
2178
+ };
2179
+ meta: import("trpc-to-openapi").OpenApiMeta;
2180
+ }>;
2181
+ unassign: import("@trpc/server").TRPCMutationProcedure<{
2182
+ input: {
2183
+ transactionId: string;
2184
+ eventId: string;
2185
+ type?: "UNASSIGN" | undefined;
2186
+ createdAtLocation?: string | null | undefined;
2187
+ declaration?: Record<string, import("../commons").FieldUpdateValue> | undefined;
2188
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | undefined;
2189
+ originalActionId?: string | undefined;
2190
+ assignedTo?: null | undefined;
2191
+ keepAssignment?: boolean | undefined;
2192
+ };
2193
+ output: {
2194
+ type: string;
2195
+ id: string & import("zod").BRAND<"UUID">;
2196
+ createdAt: string;
2197
+ trackingId: string;
2198
+ updatedAt: string;
2199
+ actions: ({
2200
+ type: "ASSIGN";
2201
+ id: string & import("zod").BRAND<"UUID">;
2202
+ status: "Rejected" | "Requested" | "Accepted";
2203
+ transactionId: string;
2204
+ createdByUserType: "system" | "user";
2205
+ createdAt: string;
2206
+ createdBy: string;
2207
+ createdByRole: string;
2208
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2209
+ assignedTo: string;
2210
+ createdBySignature?: string | null | undefined;
2211
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2212
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2213
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2214
+ } | {
2215
+ type: "UNASSIGN";
2216
+ id: string & import("zod").BRAND<"UUID">;
2217
+ status: "Rejected" | "Requested" | "Accepted";
2218
+ transactionId: string;
2219
+ createdByUserType: "system" | "user";
2220
+ createdAt: string;
2221
+ createdBy: string;
2222
+ createdByRole: string;
2223
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2224
+ createdBySignature?: string | null | undefined;
2225
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2226
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2227
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2228
+ } | {
2229
+ type: "REGISTER";
2230
+ id: string & import("zod").BRAND<"UUID">;
2231
+ status: "Rejected" | "Requested" | "Accepted";
2232
+ transactionId: string;
2233
+ createdByUserType: "system" | "user";
2234
+ createdAt: string;
2235
+ createdBy: string;
2236
+ createdByRole: string;
2237
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2238
+ createdBySignature?: string | null | undefined;
2239
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2240
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2241
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2242
+ registrationNumber?: string | undefined;
2243
+ } | {
2244
+ type: "DECLARE";
2245
+ id: string & import("zod").BRAND<"UUID">;
2246
+ status: "Rejected" | "Requested" | "Accepted";
2247
+ transactionId: string;
2248
+ createdByUserType: "system" | "user";
2249
+ createdAt: string;
2250
+ createdBy: string;
2251
+ createdByRole: string;
2252
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2253
+ createdBySignature?: string | null | undefined;
2254
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2255
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2256
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2257
+ } | {
2258
+ type: "VALIDATE";
2259
+ id: string & import("zod").BRAND<"UUID">;
2260
+ status: "Rejected" | "Requested" | "Accepted";
2261
+ transactionId: string;
2262
+ createdByUserType: "system" | "user";
2263
+ createdAt: string;
2264
+ createdBy: string;
2265
+ createdByRole: string;
2266
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2267
+ createdBySignature?: string | null | undefined;
2268
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2269
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2270
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2271
+ } | {
2272
+ type: "REJECT";
2273
+ id: string & import("zod").BRAND<"UUID">;
2274
+ status: "Rejected" | "Requested" | "Accepted";
2275
+ content: {
2276
+ reason: string;
2277
+ };
2278
+ transactionId: string;
2279
+ createdByUserType: "system" | "user";
2280
+ createdAt: string;
2281
+ createdBy: string;
2282
+ createdByRole: string;
2283
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2284
+ createdBySignature?: string | null | undefined;
2285
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2286
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2287
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2288
+ } | {
2289
+ type: "DUPLICATE_DETECTED";
2290
+ id: string & import("zod").BRAND<"UUID">;
2291
+ status: "Rejected" | "Requested" | "Accepted";
2292
+ content: {
2293
+ duplicates: {
2294
+ id: string & import("zod").BRAND<"UUID">;
2295
+ trackingId: string;
2296
+ }[];
2297
+ };
2298
+ transactionId: string;
2299
+ createdByUserType: "system" | "user";
2300
+ createdAt: string;
2301
+ createdBy: string;
2302
+ createdByRole: string;
2303
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2304
+ createdBySignature?: string | null | undefined;
2305
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2306
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2307
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2308
+ } | {
2309
+ type: "MARK_AS_NOT_DUPLICATE";
2310
+ id: string & import("zod").BRAND<"UUID">;
2311
+ status: "Rejected" | "Requested" | "Accepted";
2312
+ transactionId: string;
2313
+ createdByUserType: "system" | "user";
2314
+ createdAt: string;
2315
+ createdBy: string;
2316
+ createdByRole: string;
2317
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2318
+ createdBySignature?: string | null | undefined;
2319
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2320
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2321
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2322
+ } | {
2323
+ type: "MARK_AS_DUPLICATE";
2324
+ id: string & import("zod").BRAND<"UUID">;
2325
+ status: "Rejected" | "Requested" | "Accepted";
2326
+ transactionId: string;
2327
+ createdByUserType: "system" | "user";
2328
+ createdAt: string;
2329
+ createdBy: string;
2330
+ createdByRole: string;
2331
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2332
+ content?: {
2333
+ duplicateOf: string & import("zod").BRAND<"UUID">;
2334
+ } | undefined;
2335
+ createdBySignature?: string | null | undefined;
2336
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2337
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2338
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2339
+ } | {
2340
+ type: "ARCHIVE";
2341
+ id: string & import("zod").BRAND<"UUID">;
2342
+ status: "Rejected" | "Requested" | "Accepted";
2343
+ content: {
2344
+ reason: string;
2345
+ };
2346
+ transactionId: string;
2347
+ createdByUserType: "system" | "user";
2348
+ createdAt: string;
2349
+ createdBy: string;
2350
+ createdByRole: string;
2351
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2352
+ createdBySignature?: string | null | undefined;
2353
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2354
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2355
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2356
+ } | {
2357
+ type: "CREATE";
2358
+ id: string & import("zod").BRAND<"UUID">;
2359
+ status: "Rejected" | "Requested" | "Accepted";
2360
+ transactionId: string;
2361
+ createdByUserType: "system" | "user";
2362
+ createdAt: string;
2363
+ createdBy: string;
2364
+ createdByRole: string;
2365
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2366
+ createdBySignature?: string | null | undefined;
2367
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2368
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2369
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2370
+ } | {
2371
+ type: "NOTIFY";
2372
+ id: string & import("zod").BRAND<"UUID">;
2373
+ status: "Rejected" | "Requested" | "Accepted";
2374
+ transactionId: string;
2375
+ createdByUserType: "system" | "user";
2376
+ createdAt: string;
2377
+ createdBy: string;
2378
+ createdByRole: string;
2379
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2380
+ createdBySignature?: string | null | undefined;
2381
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2382
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2383
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2384
+ } | {
2385
+ type: "PRINT_CERTIFICATE";
2386
+ id: string & import("zod").BRAND<"UUID">;
2387
+ status: "Rejected" | "Requested" | "Accepted";
2388
+ transactionId: string;
2389
+ createdByUserType: "system" | "user";
2390
+ createdAt: string;
2391
+ createdBy: string;
2392
+ createdByRole: string;
2393
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2394
+ content?: {
2395
+ templateId?: string | undefined;
2396
+ } | null | undefined;
2397
+ createdBySignature?: string | null | undefined;
2398
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2399
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2400
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2401
+ } | {
2402
+ type: "REQUEST_CORRECTION";
2403
+ id: string & import("zod").BRAND<"UUID">;
2404
+ status: "Rejected" | "Requested" | "Accepted";
2405
+ transactionId: string;
2406
+ createdByUserType: "system" | "user";
2407
+ createdAt: string;
2408
+ createdBy: string;
2409
+ createdByRole: string;
2410
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2411
+ createdBySignature?: string | null | undefined;
2412
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2413
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2414
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2415
+ } | {
2416
+ type: "APPROVE_CORRECTION";
2417
+ id: string & import("zod").BRAND<"UUID">;
2418
+ status: "Rejected" | "Requested" | "Accepted";
2419
+ transactionId: string;
2420
+ createdByUserType: "system" | "user";
2421
+ createdAt: string;
2422
+ createdBy: string;
2423
+ createdByRole: string;
2424
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2425
+ requestId: string;
2426
+ createdBySignature?: string | null | undefined;
2427
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2428
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2429
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2430
+ } | {
2431
+ type: "REJECT_CORRECTION";
2432
+ id: string & import("zod").BRAND<"UUID">;
2433
+ status: "Rejected" | "Requested" | "Accepted";
2434
+ content: {
2435
+ reason: string;
2436
+ };
2437
+ transactionId: string;
2438
+ createdByUserType: "system" | "user";
2439
+ createdAt: string;
2440
+ createdBy: string;
2441
+ createdByRole: string;
2442
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2443
+ requestId: string;
2444
+ createdBySignature?: string | null | undefined;
2445
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2446
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2447
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2448
+ } | {
2449
+ type: "READ";
2450
+ id: string & import("zod").BRAND<"UUID">;
2451
+ status: "Rejected" | "Requested" | "Accepted";
2452
+ transactionId: string;
2453
+ createdByUserType: "system" | "user";
2454
+ createdAt: string;
2455
+ createdBy: string;
2456
+ createdByRole: string;
2457
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2458
+ createdBySignature?: string | null | undefined;
2459
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2460
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2461
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2462
+ } | {
2463
+ type: "NOTIFY" | "DECLARE" | "VALIDATE" | "REGISTER" | "REJECT" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "REJECT_CORRECTION" | "APPROVE_CORRECTION";
2464
+ id: string & import("zod").BRAND<"UUID">;
2465
+ status: "Rejected";
2466
+ transactionId: string;
2467
+ createdByUserType: "system" | "user";
2468
+ createdAt: string;
2469
+ createdBy: string;
2470
+ createdByRole: string;
2471
+ createdBySignature?: string | null | undefined;
2472
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2473
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2474
+ })[];
2475
+ };
2476
+ meta: import("trpc-to-openapi").OpenApiMeta;
2477
+ }>;
2478
+ }>>;
2479
+ correction: import("@trpc/server").TRPCBuiltRouter<{
2480
+ ctx: {
2481
+ user: {
2482
+ type: "user";
2483
+ id: string;
2484
+ role: string;
2485
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
2486
+ signature?: string | undefined;
2487
+ } | {
2488
+ type: "system";
2489
+ id: string;
2490
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
2491
+ primaryOfficeId?: undefined;
2492
+ signature?: undefined;
2493
+ };
2494
+ token: `Bearer ${string}`;
2495
+ };
2496
+ meta: import("trpc-to-openapi").OpenApiMeta;
2497
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
2498
+ transformer: true;
2499
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
2500
+ request: import("@trpc/server").TRPCBuiltRouter<{
2501
+ ctx: {
2502
+ user: {
2503
+ type: "user";
2504
+ id: string;
2505
+ role: string;
2506
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
2507
+ signature?: string | undefined;
2508
+ } | {
2509
+ type: "system";
2510
+ id: string;
2511
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
2512
+ primaryOfficeId?: undefined;
2513
+ signature?: undefined;
2514
+ };
2515
+ token: `Bearer ${string}`;
2516
+ };
2517
+ meta: import("trpc-to-openapi").OpenApiMeta;
2518
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
2519
+ transformer: true;
2520
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
2521
+ request: import("@trpc/server").TRPCMutationProcedure<{
2522
+ input: import("../commons").ActionInput;
2523
+ output: import("../commons").EventDocument;
2524
+ meta: import("trpc-to-openapi").OpenApiMeta;
2525
+ }>;
2526
+ accept: import("@trpc/server").TRPCMutationProcedure<{
2527
+ input: import("../commons").ActionInput & {
2528
+ actionId: string;
2529
+ };
2530
+ output: import("../commons").EventDocument;
2531
+ meta: import("trpc-to-openapi").OpenApiMeta;
2532
+ }>;
2533
+ reject: import("@trpc/server").TRPCMutationProcedure<{
2534
+ input: {
2535
+ eventId: string;
2536
+ actionId: string;
2537
+ transactionId: string;
2538
+ };
2539
+ output: import("../commons").EventDocument;
2540
+ meta: import("trpc-to-openapi").OpenApiMeta;
2541
+ }>;
2542
+ }>>;
2543
+ approve: import("@trpc/server").TRPCBuiltRouter<{
2544
+ ctx: {
2545
+ user: {
2546
+ type: "user";
2547
+ id: string;
2548
+ role: string;
2549
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
2550
+ signature?: string | undefined;
2551
+ } | {
2552
+ type: "system";
2553
+ id: string;
2554
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
2555
+ primaryOfficeId?: undefined;
2556
+ signature?: undefined;
2557
+ };
2558
+ token: `Bearer ${string}`;
2559
+ };
2560
+ meta: import("trpc-to-openapi").OpenApiMeta;
2561
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
2562
+ transformer: true;
2563
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
2564
+ request: import("@trpc/server").TRPCMutationProcedure<{
2565
+ input: import("../commons").ActionInput;
2566
+ output: import("../commons").EventDocument;
2567
+ meta: import("trpc-to-openapi").OpenApiMeta;
2568
+ }>;
2569
+ accept: import("@trpc/server").TRPCMutationProcedure<{
2570
+ input: import("../commons").ActionInput & {
2571
+ actionId: string;
2572
+ };
2573
+ output: import("../commons").EventDocument;
2574
+ meta: import("trpc-to-openapi").OpenApiMeta;
2575
+ }>;
2576
+ reject: import("@trpc/server").TRPCMutationProcedure<{
2577
+ input: {
2578
+ eventId: string;
2579
+ actionId: string;
2580
+ transactionId: string;
2581
+ };
2582
+ output: import("../commons").EventDocument;
2583
+ meta: import("trpc-to-openapi").OpenApiMeta;
2584
+ }>;
2585
+ }>>;
2586
+ reject: import("@trpc/server").TRPCBuiltRouter<{
2587
+ ctx: {
2588
+ user: {
2589
+ type: "user";
2590
+ id: string;
2591
+ role: string;
2592
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
2593
+ signature?: string | undefined;
2594
+ } | {
2595
+ type: "system";
2596
+ id: string;
2597
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
2598
+ primaryOfficeId?: undefined;
2599
+ signature?: undefined;
2600
+ };
2601
+ token: `Bearer ${string}`;
2602
+ };
2603
+ meta: import("trpc-to-openapi").OpenApiMeta;
2604
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
2605
+ transformer: true;
2606
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
2607
+ request: import("@trpc/server").TRPCMutationProcedure<{
2608
+ input: import("../commons").ActionInput;
2609
+ output: import("../commons").EventDocument;
2610
+ meta: import("trpc-to-openapi").OpenApiMeta;
2611
+ }>;
2612
+ accept: import("@trpc/server").TRPCMutationProcedure<{
2613
+ input: import("../commons").ActionInput & {
2614
+ actionId: string;
2615
+ };
2616
+ output: import("../commons").EventDocument;
2617
+ meta: import("trpc-to-openapi").OpenApiMeta;
2618
+ }>;
2619
+ reject: import("@trpc/server").TRPCMutationProcedure<{
2620
+ input: {
2621
+ eventId: string;
2622
+ actionId: string;
2623
+ transactionId: string;
2624
+ };
2625
+ output: import("../commons").EventDocument;
2626
+ meta: import("trpc-to-openapi").OpenApiMeta;
2627
+ }>;
2628
+ }>>;
2629
+ }>>;
2630
+ duplicate: import("@trpc/server").TRPCBuiltRouter<{
2631
+ ctx: {
2632
+ user: {
2633
+ type: "user";
2634
+ id: string;
2635
+ role: string;
2636
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
2637
+ signature?: string | undefined;
2638
+ } | {
2639
+ type: "system";
2640
+ id: string;
2641
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
2642
+ primaryOfficeId?: undefined;
2643
+ signature?: undefined;
2644
+ };
2645
+ token: `Bearer ${string}`;
2646
+ };
2647
+ meta: import("trpc-to-openapi").OpenApiMeta;
2648
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
2649
+ transformer: true;
2650
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
2651
+ markAsDuplicate: import("@trpc/server").TRPCMutationProcedure<{
2652
+ input: {
2653
+ transactionId: string;
2654
+ eventId: string;
2655
+ type?: "MARK_AS_DUPLICATE" | undefined;
2656
+ content?: {
2657
+ duplicateOf: string;
2658
+ } | undefined;
2659
+ createdAtLocation?: string | null | undefined;
2660
+ declaration?: Record<string, import("../commons").FieldUpdateValue> | undefined;
2661
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | undefined;
2662
+ originalActionId?: string | undefined;
2663
+ keepAssignment?: boolean | undefined;
2664
+ };
2665
+ output: {
2666
+ type: string;
2667
+ id: string & import("zod").BRAND<"UUID">;
2668
+ createdAt: string;
2669
+ trackingId: string;
2670
+ updatedAt: string;
2671
+ actions: ({
2672
+ type: "ASSIGN";
2673
+ id: string & import("zod").BRAND<"UUID">;
2674
+ status: "Rejected" | "Requested" | "Accepted";
2675
+ transactionId: string;
2676
+ createdByUserType: "system" | "user";
2677
+ createdAt: string;
2678
+ createdBy: string;
2679
+ createdByRole: string;
2680
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2681
+ assignedTo: string;
2682
+ createdBySignature?: string | null | undefined;
2683
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2684
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2685
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2686
+ } | {
2687
+ type: "UNASSIGN";
2688
+ id: string & import("zod").BRAND<"UUID">;
2689
+ status: "Rejected" | "Requested" | "Accepted";
2690
+ transactionId: string;
2691
+ createdByUserType: "system" | "user";
2692
+ createdAt: string;
2693
+ createdBy: string;
2694
+ createdByRole: string;
2695
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2696
+ createdBySignature?: string | null | undefined;
2697
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2698
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2699
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2700
+ } | {
2701
+ type: "REGISTER";
2702
+ id: string & import("zod").BRAND<"UUID">;
2703
+ status: "Rejected" | "Requested" | "Accepted";
2704
+ transactionId: string;
2705
+ createdByUserType: "system" | "user";
2706
+ createdAt: string;
2707
+ createdBy: string;
2708
+ createdByRole: string;
2709
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2710
+ createdBySignature?: string | null | undefined;
2711
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2712
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2713
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2714
+ registrationNumber?: string | undefined;
2715
+ } | {
2716
+ type: "DECLARE";
2717
+ id: string & import("zod").BRAND<"UUID">;
2718
+ status: "Rejected" | "Requested" | "Accepted";
2719
+ transactionId: string;
2720
+ createdByUserType: "system" | "user";
2721
+ createdAt: string;
2722
+ createdBy: string;
2723
+ createdByRole: string;
2724
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2725
+ createdBySignature?: string | null | undefined;
2726
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2727
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2728
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2729
+ } | {
2730
+ type: "VALIDATE";
2731
+ id: string & import("zod").BRAND<"UUID">;
2732
+ status: "Rejected" | "Requested" | "Accepted";
2733
+ transactionId: string;
2734
+ createdByUserType: "system" | "user";
2735
+ createdAt: string;
2736
+ createdBy: string;
2737
+ createdByRole: string;
2738
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2739
+ createdBySignature?: string | null | undefined;
2740
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2741
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2742
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2743
+ } | {
2744
+ type: "REJECT";
2745
+ id: string & import("zod").BRAND<"UUID">;
2746
+ status: "Rejected" | "Requested" | "Accepted";
2747
+ content: {
2748
+ reason: string;
2749
+ };
2750
+ transactionId: string;
2751
+ createdByUserType: "system" | "user";
2752
+ createdAt: string;
2753
+ createdBy: string;
2754
+ createdByRole: string;
2755
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2756
+ createdBySignature?: string | null | undefined;
2757
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2758
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2759
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2760
+ } | {
2761
+ type: "DUPLICATE_DETECTED";
2762
+ id: string & import("zod").BRAND<"UUID">;
2763
+ status: "Rejected" | "Requested" | "Accepted";
2764
+ content: {
2765
+ duplicates: {
2766
+ id: string & import("zod").BRAND<"UUID">;
2767
+ trackingId: string;
2768
+ }[];
2769
+ };
2770
+ transactionId: string;
2771
+ createdByUserType: "system" | "user";
2772
+ createdAt: string;
2773
+ createdBy: string;
2774
+ createdByRole: string;
2775
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2776
+ createdBySignature?: string | null | undefined;
2777
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2778
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2779
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2780
+ } | {
2781
+ type: "MARK_AS_NOT_DUPLICATE";
2782
+ id: string & import("zod").BRAND<"UUID">;
2783
+ status: "Rejected" | "Requested" | "Accepted";
2784
+ transactionId: string;
2785
+ createdByUserType: "system" | "user";
2786
+ createdAt: string;
2787
+ createdBy: string;
2788
+ createdByRole: string;
2789
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2790
+ createdBySignature?: string | null | undefined;
2791
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2792
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2793
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2794
+ } | {
2795
+ type: "MARK_AS_DUPLICATE";
2796
+ id: string & import("zod").BRAND<"UUID">;
2797
+ status: "Rejected" | "Requested" | "Accepted";
2798
+ transactionId: string;
2799
+ createdByUserType: "system" | "user";
2800
+ createdAt: string;
2801
+ createdBy: string;
2802
+ createdByRole: string;
2803
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2804
+ content?: {
2805
+ duplicateOf: string & import("zod").BRAND<"UUID">;
2806
+ } | undefined;
2807
+ createdBySignature?: string | null | undefined;
2808
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2809
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2810
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2811
+ } | {
2812
+ type: "ARCHIVE";
2813
+ id: string & import("zod").BRAND<"UUID">;
2814
+ status: "Rejected" | "Requested" | "Accepted";
2815
+ content: {
2816
+ reason: string;
2817
+ };
2818
+ transactionId: string;
2819
+ createdByUserType: "system" | "user";
2820
+ createdAt: string;
2821
+ createdBy: string;
2822
+ createdByRole: string;
2823
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2824
+ createdBySignature?: string | null | undefined;
2825
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2826
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2827
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2828
+ } | {
2829
+ type: "CREATE";
2830
+ id: string & import("zod").BRAND<"UUID">;
2831
+ status: "Rejected" | "Requested" | "Accepted";
2832
+ transactionId: string;
2833
+ createdByUserType: "system" | "user";
2834
+ createdAt: string;
2835
+ createdBy: string;
2836
+ createdByRole: string;
2837
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2838
+ createdBySignature?: string | null | undefined;
2839
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2840
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2841
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2842
+ } | {
2843
+ type: "NOTIFY";
2844
+ id: string & import("zod").BRAND<"UUID">;
2845
+ status: "Rejected" | "Requested" | "Accepted";
2846
+ transactionId: string;
2847
+ createdByUserType: "system" | "user";
2848
+ createdAt: string;
2849
+ createdBy: string;
2850
+ createdByRole: string;
2851
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2852
+ createdBySignature?: string | null | undefined;
2853
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2854
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2855
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2856
+ } | {
2857
+ type: "PRINT_CERTIFICATE";
2858
+ id: string & import("zod").BRAND<"UUID">;
2859
+ status: "Rejected" | "Requested" | "Accepted";
2860
+ transactionId: string;
2861
+ createdByUserType: "system" | "user";
2862
+ createdAt: string;
2863
+ createdBy: string;
2864
+ createdByRole: string;
2865
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2866
+ content?: {
2867
+ templateId?: string | undefined;
2868
+ } | null | undefined;
2869
+ createdBySignature?: string | null | undefined;
2870
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2871
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2872
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2873
+ } | {
2874
+ type: "REQUEST_CORRECTION";
2875
+ id: string & import("zod").BRAND<"UUID">;
2876
+ status: "Rejected" | "Requested" | "Accepted";
2877
+ transactionId: string;
2878
+ createdByUserType: "system" | "user";
2879
+ createdAt: string;
2880
+ createdBy: string;
2881
+ createdByRole: string;
2882
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2883
+ createdBySignature?: string | null | undefined;
2884
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2885
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2886
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2887
+ } | {
2888
+ type: "APPROVE_CORRECTION";
2889
+ id: string & import("zod").BRAND<"UUID">;
2890
+ status: "Rejected" | "Requested" | "Accepted";
2891
+ transactionId: string;
2892
+ createdByUserType: "system" | "user";
2893
+ createdAt: string;
2894
+ createdBy: string;
2895
+ createdByRole: string;
2896
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2897
+ requestId: string;
2898
+ createdBySignature?: string | null | undefined;
2899
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2900
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2901
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2902
+ } | {
2903
+ type: "REJECT_CORRECTION";
2904
+ id: string & import("zod").BRAND<"UUID">;
2905
+ status: "Rejected" | "Requested" | "Accepted";
2906
+ content: {
2907
+ reason: string;
2908
+ };
2909
+ transactionId: string;
2910
+ createdByUserType: "system" | "user";
2911
+ createdAt: string;
2912
+ createdBy: string;
2913
+ createdByRole: string;
2914
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2915
+ requestId: string;
2916
+ createdBySignature?: string | null | undefined;
2917
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2918
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2919
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2920
+ } | {
2921
+ type: "READ";
2922
+ id: string & import("zod").BRAND<"UUID">;
2923
+ status: "Rejected" | "Requested" | "Accepted";
2924
+ transactionId: string;
2925
+ createdByUserType: "system" | "user";
2926
+ createdAt: string;
2927
+ createdBy: string;
2928
+ createdByRole: string;
2929
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2930
+ createdBySignature?: string | null | undefined;
2931
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2932
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2933
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2934
+ } | {
2935
+ type: "NOTIFY" | "DECLARE" | "VALIDATE" | "REGISTER" | "REJECT" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "REJECT_CORRECTION" | "APPROVE_CORRECTION";
2936
+ id: string & import("zod").BRAND<"UUID">;
2937
+ status: "Rejected";
2938
+ transactionId: string;
2939
+ createdByUserType: "system" | "user";
2940
+ createdAt: string;
2941
+ createdBy: string;
2942
+ createdByRole: string;
2943
+ createdBySignature?: string | null | undefined;
2944
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2945
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2946
+ })[];
2947
+ };
2948
+ meta: import("trpc-to-openapi").OpenApiMeta;
2949
+ }>;
2950
+ markNotDuplicate: import("@trpc/server").TRPCMutationProcedure<{
2951
+ input: {
2952
+ transactionId: string;
2953
+ eventId: string;
2954
+ type?: "MARK_AS_NOT_DUPLICATE" | undefined;
2955
+ createdAtLocation?: string | null | undefined;
2956
+ declaration?: Record<string, import("../commons").FieldUpdateValue> | undefined;
2957
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | undefined;
2958
+ originalActionId?: string | undefined;
2959
+ keepAssignment?: boolean | undefined;
2960
+ };
2961
+ output: {
2962
+ type: string;
2963
+ id: string & import("zod").BRAND<"UUID">;
2964
+ createdAt: string;
2965
+ trackingId: string;
2966
+ updatedAt: string;
2967
+ actions: ({
2968
+ type: "ASSIGN";
2969
+ id: string & import("zod").BRAND<"UUID">;
2970
+ status: "Rejected" | "Requested" | "Accepted";
2971
+ transactionId: string;
2972
+ createdByUserType: "system" | "user";
2973
+ createdAt: string;
2974
+ createdBy: string;
2975
+ createdByRole: string;
2976
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2977
+ assignedTo: string;
2978
+ createdBySignature?: string | null | undefined;
2979
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2980
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2981
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2982
+ } | {
2983
+ type: "UNASSIGN";
2984
+ id: string & import("zod").BRAND<"UUID">;
2985
+ status: "Rejected" | "Requested" | "Accepted";
2986
+ transactionId: string;
2987
+ createdByUserType: "system" | "user";
2988
+ createdAt: string;
2989
+ createdBy: string;
2990
+ createdByRole: string;
2991
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
2992
+ createdBySignature?: string | null | undefined;
2993
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2994
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
2995
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
2996
+ } | {
2997
+ type: "REGISTER";
2998
+ id: string & import("zod").BRAND<"UUID">;
2999
+ status: "Rejected" | "Requested" | "Accepted";
3000
+ transactionId: string;
3001
+ createdByUserType: "system" | "user";
3002
+ createdAt: string;
3003
+ createdBy: string;
3004
+ createdByRole: string;
3005
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3006
+ createdBySignature?: string | null | undefined;
3007
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3008
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3009
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3010
+ registrationNumber?: string | undefined;
3011
+ } | {
3012
+ type: "DECLARE";
3013
+ id: string & import("zod").BRAND<"UUID">;
3014
+ status: "Rejected" | "Requested" | "Accepted";
3015
+ transactionId: string;
3016
+ createdByUserType: "system" | "user";
3017
+ createdAt: string;
3018
+ createdBy: string;
3019
+ createdByRole: string;
3020
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3021
+ createdBySignature?: string | null | undefined;
3022
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3023
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3024
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3025
+ } | {
3026
+ type: "VALIDATE";
3027
+ id: string & import("zod").BRAND<"UUID">;
3028
+ status: "Rejected" | "Requested" | "Accepted";
3029
+ transactionId: string;
3030
+ createdByUserType: "system" | "user";
3031
+ createdAt: string;
3032
+ createdBy: string;
3033
+ createdByRole: string;
3034
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3035
+ createdBySignature?: string | null | undefined;
3036
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3037
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3038
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3039
+ } | {
3040
+ type: "REJECT";
3041
+ id: string & import("zod").BRAND<"UUID">;
3042
+ status: "Rejected" | "Requested" | "Accepted";
3043
+ content: {
3044
+ reason: string;
3045
+ };
3046
+ transactionId: string;
3047
+ createdByUserType: "system" | "user";
3048
+ createdAt: string;
3049
+ createdBy: string;
3050
+ createdByRole: string;
3051
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3052
+ createdBySignature?: string | null | undefined;
3053
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3054
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3055
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3056
+ } | {
3057
+ type: "DUPLICATE_DETECTED";
3058
+ id: string & import("zod").BRAND<"UUID">;
3059
+ status: "Rejected" | "Requested" | "Accepted";
3060
+ content: {
3061
+ duplicates: {
3062
+ id: string & import("zod").BRAND<"UUID">;
3063
+ trackingId: string;
3064
+ }[];
3065
+ };
3066
+ transactionId: string;
3067
+ createdByUserType: "system" | "user";
3068
+ createdAt: string;
3069
+ createdBy: string;
3070
+ createdByRole: string;
3071
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3072
+ createdBySignature?: string | null | undefined;
3073
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3074
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3075
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3076
+ } | {
3077
+ type: "MARK_AS_NOT_DUPLICATE";
3078
+ id: string & import("zod").BRAND<"UUID">;
3079
+ status: "Rejected" | "Requested" | "Accepted";
3080
+ transactionId: string;
3081
+ createdByUserType: "system" | "user";
3082
+ createdAt: string;
3083
+ createdBy: string;
3084
+ createdByRole: string;
3085
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3086
+ createdBySignature?: string | null | undefined;
3087
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3088
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3089
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3090
+ } | {
3091
+ type: "MARK_AS_DUPLICATE";
3092
+ id: string & import("zod").BRAND<"UUID">;
3093
+ status: "Rejected" | "Requested" | "Accepted";
3094
+ transactionId: string;
3095
+ createdByUserType: "system" | "user";
3096
+ createdAt: string;
3097
+ createdBy: string;
3098
+ createdByRole: string;
3099
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3100
+ content?: {
3101
+ duplicateOf: string & import("zod").BRAND<"UUID">;
3102
+ } | undefined;
3103
+ createdBySignature?: string | null | undefined;
3104
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3105
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3106
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3107
+ } | {
3108
+ type: "ARCHIVE";
3109
+ id: string & import("zod").BRAND<"UUID">;
3110
+ status: "Rejected" | "Requested" | "Accepted";
3111
+ content: {
3112
+ reason: string;
3113
+ };
3114
+ transactionId: string;
3115
+ createdByUserType: "system" | "user";
3116
+ createdAt: string;
3117
+ createdBy: string;
3118
+ createdByRole: string;
3119
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3120
+ createdBySignature?: string | null | undefined;
3121
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3122
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3123
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3124
+ } | {
3125
+ type: "CREATE";
3126
+ id: string & import("zod").BRAND<"UUID">;
3127
+ status: "Rejected" | "Requested" | "Accepted";
3128
+ transactionId: string;
3129
+ createdByUserType: "system" | "user";
3130
+ createdAt: string;
3131
+ createdBy: string;
3132
+ createdByRole: string;
3133
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3134
+ createdBySignature?: string | null | undefined;
3135
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3136
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3137
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3138
+ } | {
3139
+ type: "NOTIFY";
3140
+ id: string & import("zod").BRAND<"UUID">;
3141
+ status: "Rejected" | "Requested" | "Accepted";
3142
+ transactionId: string;
3143
+ createdByUserType: "system" | "user";
3144
+ createdAt: string;
3145
+ createdBy: string;
3146
+ createdByRole: string;
3147
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3148
+ createdBySignature?: string | null | undefined;
3149
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3150
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3151
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3152
+ } | {
3153
+ type: "PRINT_CERTIFICATE";
3154
+ id: string & import("zod").BRAND<"UUID">;
3155
+ status: "Rejected" | "Requested" | "Accepted";
3156
+ transactionId: string;
3157
+ createdByUserType: "system" | "user";
3158
+ createdAt: string;
3159
+ createdBy: string;
3160
+ createdByRole: string;
3161
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3162
+ content?: {
3163
+ templateId?: string | undefined;
3164
+ } | null | undefined;
3165
+ createdBySignature?: string | null | undefined;
3166
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3167
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3168
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3169
+ } | {
3170
+ type: "REQUEST_CORRECTION";
3171
+ id: string & import("zod").BRAND<"UUID">;
3172
+ status: "Rejected" | "Requested" | "Accepted";
3173
+ transactionId: string;
3174
+ createdByUserType: "system" | "user";
3175
+ createdAt: string;
3176
+ createdBy: string;
3177
+ createdByRole: string;
3178
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3179
+ createdBySignature?: string | null | undefined;
3180
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3181
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3182
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3183
+ } | {
3184
+ type: "APPROVE_CORRECTION";
3185
+ id: string & import("zod").BRAND<"UUID">;
3186
+ status: "Rejected" | "Requested" | "Accepted";
3187
+ transactionId: string;
3188
+ createdByUserType: "system" | "user";
3189
+ createdAt: string;
3190
+ createdBy: string;
3191
+ createdByRole: string;
3192
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3193
+ requestId: string;
3194
+ createdBySignature?: string | null | undefined;
3195
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3196
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3197
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3198
+ } | {
3199
+ type: "REJECT_CORRECTION";
3200
+ id: string & import("zod").BRAND<"UUID">;
3201
+ status: "Rejected" | "Requested" | "Accepted";
3202
+ content: {
3203
+ reason: string;
3204
+ };
3205
+ transactionId: string;
3206
+ createdByUserType: "system" | "user";
3207
+ createdAt: string;
3208
+ createdBy: string;
3209
+ createdByRole: string;
3210
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3211
+ requestId: string;
3212
+ createdBySignature?: string | null | undefined;
3213
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3214
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3215
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3216
+ } | {
3217
+ type: "READ";
3218
+ id: string & import("zod").BRAND<"UUID">;
3219
+ status: "Rejected" | "Requested" | "Accepted";
3220
+ transactionId: string;
3221
+ createdByUserType: "system" | "user";
3222
+ createdAt: string;
3223
+ createdBy: string;
3224
+ createdByRole: string;
3225
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3226
+ createdBySignature?: string | null | undefined;
3227
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3228
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3229
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3230
+ } | {
3231
+ type: "NOTIFY" | "DECLARE" | "VALIDATE" | "REGISTER" | "REJECT" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "REJECT_CORRECTION" | "APPROVE_CORRECTION";
3232
+ id: string & import("zod").BRAND<"UUID">;
3233
+ status: "Rejected";
3234
+ transactionId: string;
3235
+ createdByUserType: "system" | "user";
3236
+ createdAt: string;
3237
+ createdBy: string;
3238
+ createdByRole: string;
3239
+ createdBySignature?: string | null | undefined;
3240
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3241
+ originalActionId?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3242
+ })[];
3243
+ };
3244
+ meta: import("trpc-to-openapi").OpenApiMeta;
3245
+ }>;
3246
+ }>>;
3247
+ }>>;
3248
+ search: import("@trpc/server").TRPCQueryProcedure<{
3249
+ input: {
3250
+ sort?: unknown;
3251
+ query?: unknown;
3252
+ limit?: number | undefined;
3253
+ offset?: number | undefined;
3254
+ };
3255
+ output: {
3256
+ total: number;
3257
+ results: {
3258
+ type: string;
3259
+ id: string & import("zod").BRAND<"UUID">;
3260
+ status: "ARCHIVED" | "DECLARED" | "REGISTERED" | "VALIDATED" | "CREATED" | "NOTIFIED";
3261
+ createdAt: string;
3262
+ createdBy: string;
3263
+ declaration: Record<string, import("../commons").FieldValue>;
3264
+ trackingId: string;
3265
+ updatedAt: string;
3266
+ legalStatuses: {
3267
+ DECLARED?: {
3268
+ createdAt: string;
3269
+ createdBy: string;
3270
+ createdByRole: string;
3271
+ acceptedAt: string;
3272
+ createdByUserType?: "system" | "user" | null | undefined;
3273
+ createdBySignature?: string | null | undefined;
3274
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3275
+ } | null | undefined;
3276
+ REGISTERED?: {
3277
+ createdAt: string;
3278
+ createdBy: string;
3279
+ createdByRole: string;
3280
+ registrationNumber: string;
3281
+ acceptedAt: string;
3282
+ createdByUserType?: "system" | "user" | null | undefined;
3283
+ createdBySignature?: string | null | undefined;
3284
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3285
+ } | null | undefined;
3286
+ };
3287
+ updatedByUserRole: string;
3288
+ potentialDuplicates: {
3289
+ id: string & import("zod").BRAND<"UUID">;
3290
+ trackingId: string;
3291
+ }[];
3292
+ flags: string[];
3293
+ createdByUserType?: "system" | "user" | null | undefined;
3294
+ createdBySignature?: string | null | undefined;
3295
+ createdAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3296
+ assignedTo?: string | null | undefined;
3297
+ dateOfEvent?: string | null | undefined;
3298
+ updatedAtLocation?: (string & import("zod").BRAND<"UUID">) | null | undefined;
3299
+ updatedBy?: string | null | undefined;
3300
+ }[];
3301
+ };
3302
+ meta: import("trpc-to-openapi").OpenApiMeta;
3303
+ }>;
3304
+ bulkImport: import("@trpc/server").TRPCMutationProcedure<{
3305
+ input: {
3306
+ type: string;
3307
+ id: string;
3308
+ createdAt: string;
3309
+ trackingId: string;
3310
+ updatedAt: string;
3311
+ actions: ({
3312
+ type: "ASSIGN";
3313
+ id: string;
3314
+ status: "Rejected" | "Requested" | "Accepted";
3315
+ transactionId: string;
3316
+ createdByUserType: "system" | "user";
3317
+ createdAt: string;
3318
+ createdBy: string;
3319
+ createdByRole: string;
3320
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3321
+ assignedTo: string;
3322
+ createdBySignature?: string | null | undefined;
3323
+ createdAtLocation?: string | null | undefined;
3324
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3325
+ originalActionId?: string | null | undefined;
3326
+ } | {
3327
+ type: "UNASSIGN";
3328
+ id: string;
3329
+ status: "Rejected" | "Requested" | "Accepted";
3330
+ transactionId: string;
3331
+ createdByUserType: "system" | "user";
3332
+ createdAt: string;
3333
+ createdBy: string;
3334
+ createdByRole: string;
3335
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3336
+ createdBySignature?: string | null | undefined;
3337
+ createdAtLocation?: string | null | undefined;
3338
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3339
+ originalActionId?: string | null | undefined;
3340
+ } | {
3341
+ type: "REGISTER";
3342
+ id: string;
3343
+ status: "Rejected" | "Requested" | "Accepted";
3344
+ transactionId: string;
3345
+ createdByUserType: "system" | "user";
3346
+ createdAt: string;
3347
+ createdBy: string;
3348
+ createdByRole: string;
3349
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3350
+ createdBySignature?: string | null | undefined;
3351
+ createdAtLocation?: string | null | undefined;
3352
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3353
+ originalActionId?: string | null | undefined;
3354
+ registrationNumber?: string | undefined;
3355
+ } | {
3356
+ type: "DECLARE";
3357
+ id: string;
3358
+ status: "Rejected" | "Requested" | "Accepted";
3359
+ transactionId: string;
3360
+ createdByUserType: "system" | "user";
3361
+ createdAt: string;
3362
+ createdBy: string;
3363
+ createdByRole: string;
3364
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3365
+ createdBySignature?: string | null | undefined;
3366
+ createdAtLocation?: string | null | undefined;
3367
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3368
+ originalActionId?: string | null | undefined;
3369
+ } | {
3370
+ type: "VALIDATE";
3371
+ id: string;
3372
+ status: "Rejected" | "Requested" | "Accepted";
3373
+ transactionId: string;
3374
+ createdByUserType: "system" | "user";
3375
+ createdAt: string;
3376
+ createdBy: string;
3377
+ createdByRole: string;
3378
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3379
+ createdBySignature?: string | null | undefined;
3380
+ createdAtLocation?: string | null | undefined;
3381
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3382
+ originalActionId?: string | null | undefined;
3383
+ } | {
3384
+ type: "REJECT";
3385
+ id: string;
3386
+ status: "Rejected" | "Requested" | "Accepted";
3387
+ content: {
3388
+ reason: string;
3389
+ };
3390
+ transactionId: string;
3391
+ createdByUserType: "system" | "user";
3392
+ createdAt: string;
3393
+ createdBy: string;
3394
+ createdByRole: string;
3395
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3396
+ createdBySignature?: string | null | undefined;
3397
+ createdAtLocation?: string | null | undefined;
3398
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3399
+ originalActionId?: string | null | undefined;
3400
+ } | {
3401
+ type: "DUPLICATE_DETECTED";
3402
+ id: string;
3403
+ status: "Rejected" | "Requested" | "Accepted";
3404
+ content: {
3405
+ duplicates: {
3406
+ id: string;
3407
+ trackingId: string;
3408
+ }[];
3409
+ };
3410
+ transactionId: string;
3411
+ createdByUserType: "system" | "user";
3412
+ createdAt: string;
3413
+ createdBy: string;
3414
+ createdByRole: string;
3415
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3416
+ createdBySignature?: string | null | undefined;
3417
+ createdAtLocation?: string | null | undefined;
3418
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3419
+ originalActionId?: string | null | undefined;
3420
+ } | {
3421
+ type: "MARK_AS_NOT_DUPLICATE";
3422
+ id: string;
3423
+ status: "Rejected" | "Requested" | "Accepted";
3424
+ transactionId: string;
3425
+ createdByUserType: "system" | "user";
3426
+ createdAt: string;
3427
+ createdBy: string;
3428
+ createdByRole: string;
3429
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3430
+ createdBySignature?: string | null | undefined;
3431
+ createdAtLocation?: string | null | undefined;
3432
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3433
+ originalActionId?: string | null | undefined;
3434
+ } | {
3435
+ type: "MARK_AS_DUPLICATE";
3436
+ id: string;
3437
+ status: "Rejected" | "Requested" | "Accepted";
3438
+ transactionId: string;
3439
+ createdByUserType: "system" | "user";
3440
+ createdAt: string;
3441
+ createdBy: string;
3442
+ createdByRole: string;
3443
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3444
+ content?: {
3445
+ duplicateOf: string;
3446
+ } | undefined;
3447
+ createdBySignature?: string | null | undefined;
3448
+ createdAtLocation?: string | null | undefined;
3449
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3450
+ originalActionId?: string | null | undefined;
3451
+ } | {
3452
+ type: "ARCHIVE";
3453
+ id: string;
3454
+ status: "Rejected" | "Requested" | "Accepted";
3455
+ content: {
3456
+ reason: string;
3457
+ };
3458
+ transactionId: string;
3459
+ createdByUserType: "system" | "user";
3460
+ createdAt: string;
3461
+ createdBy: string;
3462
+ createdByRole: string;
3463
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3464
+ createdBySignature?: string | null | undefined;
3465
+ createdAtLocation?: string | null | undefined;
3466
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3467
+ originalActionId?: string | null | undefined;
3468
+ } | {
3469
+ type: "CREATE";
3470
+ id: string;
3471
+ status: "Rejected" | "Requested" | "Accepted";
3472
+ transactionId: string;
3473
+ createdByUserType: "system" | "user";
3474
+ createdAt: string;
3475
+ createdBy: string;
3476
+ createdByRole: string;
3477
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3478
+ createdBySignature?: string | null | undefined;
3479
+ createdAtLocation?: string | null | undefined;
3480
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3481
+ originalActionId?: string | null | undefined;
3482
+ } | {
3483
+ type: "NOTIFY";
3484
+ id: string;
3485
+ status: "Rejected" | "Requested" | "Accepted";
3486
+ transactionId: string;
3487
+ createdByUserType: "system" | "user";
3488
+ createdAt: string;
3489
+ createdBy: string;
3490
+ createdByRole: string;
3491
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3492
+ createdBySignature?: string | null | undefined;
3493
+ createdAtLocation?: string | null | undefined;
3494
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3495
+ originalActionId?: string | null | undefined;
3496
+ } | {
3497
+ type: "PRINT_CERTIFICATE";
3498
+ id: string;
3499
+ status: "Rejected" | "Requested" | "Accepted";
3500
+ transactionId: string;
3501
+ createdByUserType: "system" | "user";
3502
+ createdAt: string;
3503
+ createdBy: string;
3504
+ createdByRole: string;
3505
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3506
+ content?: {
3507
+ templateId?: string | undefined;
3508
+ } | null | undefined;
3509
+ createdBySignature?: string | null | undefined;
3510
+ createdAtLocation?: string | null | undefined;
3511
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3512
+ originalActionId?: string | null | undefined;
3513
+ } | {
3514
+ type: "REQUEST_CORRECTION";
3515
+ id: string;
3516
+ status: "Rejected" | "Requested" | "Accepted";
3517
+ transactionId: string;
3518
+ createdByUserType: "system" | "user";
3519
+ createdAt: string;
3520
+ createdBy: string;
3521
+ createdByRole: string;
3522
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3523
+ createdBySignature?: string | null | undefined;
3524
+ createdAtLocation?: string | null | undefined;
3525
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3526
+ originalActionId?: string | null | undefined;
3527
+ } | {
3528
+ type: "APPROVE_CORRECTION";
3529
+ id: string;
3530
+ status: "Rejected" | "Requested" | "Accepted";
3531
+ transactionId: string;
3532
+ createdByUserType: "system" | "user";
3533
+ createdAt: string;
3534
+ createdBy: string;
3535
+ createdByRole: string;
3536
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3537
+ requestId: string;
3538
+ createdBySignature?: string | null | undefined;
3539
+ createdAtLocation?: string | null | undefined;
3540
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3541
+ originalActionId?: string | null | undefined;
3542
+ } | {
3543
+ type: "REJECT_CORRECTION";
3544
+ id: string;
3545
+ status: "Rejected" | "Requested" | "Accepted";
3546
+ content: {
3547
+ reason: string;
3548
+ };
3549
+ transactionId: string;
3550
+ createdByUserType: "system" | "user";
3551
+ createdAt: string;
3552
+ createdBy: string;
3553
+ createdByRole: string;
3554
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3555
+ requestId: string;
3556
+ createdBySignature?: string | null | undefined;
3557
+ createdAtLocation?: string | null | undefined;
3558
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3559
+ originalActionId?: string | null | undefined;
3560
+ } | {
3561
+ type: "READ";
3562
+ id: string;
3563
+ status: "Rejected" | "Requested" | "Accepted";
3564
+ transactionId: string;
3565
+ createdByUserType: "system" | "user";
3566
+ createdAt: string;
3567
+ createdBy: string;
3568
+ createdByRole: string;
3569
+ declaration: Record<string, import("../commons").FieldUpdateValue>;
3570
+ createdBySignature?: string | null | undefined;
3571
+ createdAtLocation?: string | null | undefined;
3572
+ annotation?: Record<string, import("../commons").FieldUpdateValue> | null | undefined;
3573
+ originalActionId?: string | null | undefined;
3574
+ } | {
3575
+ type: "NOTIFY" | "DECLARE" | "VALIDATE" | "REGISTER" | "REJECT" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "REJECT_CORRECTION" | "APPROVE_CORRECTION";
3576
+ id: string;
3577
+ status: "Rejected";
3578
+ transactionId: string;
3579
+ createdByUserType: "system" | "user";
3580
+ createdAt: string;
3581
+ createdBy: string;
3582
+ createdByRole: string;
3583
+ createdBySignature?: string | null | undefined;
3584
+ createdAtLocation?: string | null | undefined;
3585
+ originalActionId?: string | null | undefined;
3586
+ })[];
3587
+ }[];
3588
+ output: any;
3589
+ meta: import("trpc-to-openapi").OpenApiMeta;
3590
+ }>;
3591
+ reindex: import("@trpc/server").TRPCBuiltRouter<{
3592
+ ctx: {
3593
+ user: {
3594
+ type: "user";
3595
+ id: string;
3596
+ role: string;
3597
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
3598
+ signature?: string | undefined;
3599
+ } | {
3600
+ type: "system";
3601
+ id: string;
3602
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
3603
+ primaryOfficeId?: undefined;
3604
+ signature?: undefined;
3605
+ };
3606
+ token: `Bearer ${string}`;
3607
+ };
3608
+ meta: import("trpc-to-openapi").OpenApiMeta;
3609
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
3610
+ transformer: true;
3611
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
3612
+ trigger: import("@trpc/server").TRPCMutationProcedure<{
3613
+ input: void;
3614
+ output: void;
3615
+ meta: import("trpc-to-openapi").OpenApiMeta;
3616
+ }>;
3617
+ status: import("@trpc/server").TRPCQueryProcedure<{
3618
+ input: {
3619
+ limit?: number | undefined;
3620
+ } | undefined;
3621
+ output: {
3622
+ id: string;
3623
+ status: "failed" | "running" | "completed";
3624
+ timestamp: string;
3625
+ progress: {
3626
+ processed: number;
3627
+ };
3628
+ error_message: string | null;
3629
+ completed_at: string | null;
3630
+ }[];
3631
+ meta: import("trpc-to-openapi").OpenApiMeta;
3632
+ }>;
3633
+ }>>;
3634
+ }>>;
3635
+ user: import("@trpc/server").TRPCBuiltRouter<{
3636
+ ctx: {
3637
+ user: {
3638
+ type: "user";
3639
+ id: string;
3640
+ role: string;
3641
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
3642
+ signature?: string | undefined;
3643
+ } | {
3644
+ type: "system";
3645
+ id: string;
3646
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
3647
+ primaryOfficeId?: undefined;
3648
+ signature?: undefined;
3649
+ };
3650
+ token: `Bearer ${string}`;
3651
+ };
3652
+ meta: import("trpc-to-openapi").OpenApiMeta;
3653
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
3654
+ transformer: true;
3655
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
3656
+ get: import("@trpc/server").TRPCQueryProcedure<{
3657
+ input: string;
3658
+ output: {
3659
+ type: "user";
3660
+ id: string;
3661
+ name: {
3662
+ use: string;
3663
+ family: string;
3664
+ given: string[];
3665
+ }[];
3666
+ role: string;
3667
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
3668
+ signature?: string | undefined;
3669
+ device?: string | undefined;
3670
+ fullHonorificName?: string | undefined;
3671
+ avatar?: string | undefined;
3672
+ } | {
3673
+ type: "system";
3674
+ id: string;
3675
+ name: string;
3676
+ role: "NATIONAL_ID" | "HEALTH" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
3677
+ signature?: undefined;
3678
+ fullHonorificName?: string | undefined;
3679
+ primaryOfficeId?: undefined;
3680
+ avatar?: undefined;
3681
+ };
3682
+ meta: import("trpc-to-openapi").OpenApiMeta;
3683
+ }>;
3684
+ list: import("@trpc/server").TRPCQueryProcedure<{
3685
+ input: string[];
3686
+ output: ({
3687
+ type: "user";
3688
+ id: string;
3689
+ name: {
3690
+ use: string;
3691
+ family: string;
3692
+ given: string[];
3693
+ }[];
3694
+ role: string;
3695
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
3696
+ signature?: string | undefined;
3697
+ device?: string | undefined;
3698
+ fullHonorificName?: string | undefined;
3699
+ avatar?: string | undefined;
3700
+ } | {
3701
+ type: "system";
3702
+ id: string;
3703
+ name: string;
3704
+ role: "NATIONAL_ID" | "HEALTH" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
3705
+ signature?: undefined;
3706
+ fullHonorificName?: string | undefined;
3707
+ primaryOfficeId?: undefined;
3708
+ avatar?: undefined;
3709
+ })[];
3710
+ meta: import("trpc-to-openapi").OpenApiMeta;
3711
+ }>;
3712
+ actions: import("@trpc/server").TRPCQueryProcedure<{
3713
+ input: {
3714
+ userId: string;
3715
+ skip?: number | undefined;
3716
+ count?: number | undefined;
3717
+ timeStart?: string | undefined;
3718
+ timeEnd?: string | undefined;
3719
+ actionTypes?: ("READ" | "DECLARE" | "VALIDATE" | "REJECT" | "ARCHIVE" | "REGISTER" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "REJECT_CORRECTION" | "APPROVE_CORRECTION" | "CREATE" | "NOTIFY" | "DUPLICATE_DETECTED" | "MARK_AS_DUPLICATE" | "ASSIGN" | "UNASSIGN" | "MARK_AS_NOT_DUPLICATE")[] | undefined;
3720
+ };
3721
+ output: {
3722
+ results: {
3723
+ id: (string & import("zod").BRAND<"UUID">) | null;
3724
+ status: import("../storage/postgres/events/schema/app/ActionStatus").default;
3725
+ eventType: string | null;
3726
+ createdAt: string | null;
3727
+ updatedAt: string | null;
3728
+ transactionId: string | null;
3729
+ eventId: string & import("zod").BRAND<"UUID">;
3730
+ actionType: import("../storage/postgres/events/schema/app/ActionType").default;
3731
+ declaration: Record<string, any>;
3732
+ annotation: Record<string, any> | null;
3733
+ createdBy: string;
3734
+ createdByRole: string;
3735
+ createdByUserType: import("../storage/postgres/events/schema/app/UserType").default;
3736
+ createdBySignature: string | null;
3737
+ createdAtLocation: (string & import("zod").BRAND<"UUID">) | null;
3738
+ assignedTo: string | null;
3739
+ originalActionId: (string & import("zod").BRAND<"UUID">) | null;
3740
+ registrationNumber: string | null;
3741
+ requestId: string | null;
3742
+ content: Record<string, any> | null;
3743
+ trackingId: string | null;
3744
+ }[];
3745
+ total: number;
3746
+ };
3747
+ meta: import("trpc-to-openapi").OpenApiMeta;
3748
+ }>;
3749
+ }>>;
3750
+ locations: import("@trpc/server").TRPCBuiltRouter<{
3751
+ ctx: {
3752
+ user: {
3753
+ type: "user";
3754
+ id: string;
3755
+ role: string;
3756
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
3757
+ signature?: string | undefined;
3758
+ } | {
3759
+ type: "system";
3760
+ id: string;
3761
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
3762
+ primaryOfficeId?: undefined;
3763
+ signature?: undefined;
3764
+ };
3765
+ token: `Bearer ${string}`;
3766
+ };
3767
+ meta: import("trpc-to-openapi").OpenApiMeta;
3768
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
3769
+ transformer: true;
3770
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
3771
+ sync: import("@trpc/server").TRPCMutationProcedure<{
3772
+ input: void;
3773
+ output: void;
3774
+ meta: import("trpc-to-openapi").OpenApiMeta;
3775
+ }>;
3776
+ list: import("@trpc/server").TRPCQueryProcedure<{
3777
+ input: {
3778
+ locationType?: "ADMIN_STRUCTURE" | "CRVS_OFFICE" | "HEALTH_FACILITY" | undefined;
3779
+ locationIds?: string[] | undefined;
3780
+ isActive?: boolean | undefined;
3781
+ } | undefined;
3782
+ output: {
3783
+ id: string & import("zod").BRAND<"UUID">;
3784
+ name: string;
3785
+ parentId: (string & import("zod").BRAND<"UUID">) | null;
3786
+ validUntil: string | null;
3787
+ locationType: "ADMIN_STRUCTURE" | "HEALTH_FACILITY" | "CRVS_OFFICE" | null;
3788
+ }[];
3789
+ meta: import("trpc-to-openapi").OpenApiMeta;
3790
+ }>;
3791
+ set: import("@trpc/server").TRPCMutationProcedure<{
3792
+ input: {
3793
+ id: string;
3794
+ name: string;
3795
+ parentId: string | null;
3796
+ validUntil: string | null;
3797
+ locationType: "ADMIN_STRUCTURE" | "HEALTH_FACILITY" | "CRVS_OFFICE" | null;
3798
+ }[];
3799
+ output: void;
3800
+ meta: import("trpc-to-openapi").OpenApiMeta;
3801
+ }>;
3802
+ }>>;
3803
+ workqueue: import("@trpc/server").TRPCBuiltRouter<{
3804
+ ctx: {
3805
+ user: {
3806
+ type: "user";
3807
+ id: string;
3808
+ role: string;
3809
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
3810
+ signature?: string | undefined;
3811
+ } | {
3812
+ type: "system";
3813
+ id: string;
3814
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
3815
+ primaryOfficeId?: undefined;
3816
+ signature?: undefined;
3817
+ };
3818
+ token: `Bearer ${string}`;
3819
+ };
3820
+ meta: import("trpc-to-openapi").OpenApiMeta;
3821
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
3822
+ transformer: true;
3823
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
3824
+ config: import("@trpc/server").TRPCBuiltRouter<{
3825
+ ctx: {
3826
+ user: {
3827
+ type: "user";
3828
+ id: string;
3829
+ role: string;
3830
+ primaryOfficeId: string & import("zod").BRAND<"UUID">;
3831
+ signature?: string | undefined;
3832
+ } | {
3833
+ type: "system";
3834
+ id: string;
3835
+ role: "HEALTH" | "NATIONAL_ID" | "RECORD_SEARCH" | "REINDEX" | "WEBHOOK" | "IMPORT_EXPORT";
3836
+ primaryOfficeId?: undefined;
3837
+ signature?: undefined;
3838
+ };
3839
+ token: `Bearer ${string}`;
3840
+ };
3841
+ meta: import("trpc-to-openapi").OpenApiMeta;
3842
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
3843
+ transformer: true;
3844
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
3845
+ list: import("@trpc/server").TRPCQueryProcedure<{
3846
+ input: void;
3847
+ output: {
3848
+ name: import("../commons").TranslationConfig;
3849
+ actions: {
3850
+ type: "DELETE" | "DECLARE" | "VALIDATE" | "REGISTER" | "MARK_AS_DUPLICATE" | "ARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "READ" | "ASSIGN" | "UNASSIGN" | "DEFAULT";
3851
+ conditionals?: import("../commons").JSONSchema[] | undefined;
3852
+ }[];
3853
+ query: {
3854
+ type: "or";
3855
+ clauses: {
3856
+ status?: {
3857
+ type: "exact";
3858
+ term: "ARCHIVED" | "DECLARED" | "REGISTERED" | "VALIDATED" | "CREATED" | "NOTIFIED";
3859
+ } | {
3860
+ type: "anyOf";
3861
+ terms: ("ARCHIVED" | "DECLARED" | "REGISTERED" | "VALIDATED" | "CREATED" | "NOTIFIED")[];
3862
+ } | undefined;
3863
+ data?: any;
3864
+ createdByUserType?: {
3865
+ type: "exact";
3866
+ term: "system" | "user";
3867
+ } | undefined;
3868
+ createdAt?: {
3869
+ type: "range";
3870
+ gte: string;
3871
+ lte: string;
3872
+ } | {
3873
+ type: "exact";
3874
+ term: string;
3875
+ } | {
3876
+ type: "timePeriod";
3877
+ term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
3878
+ } | undefined;
3879
+ createdBy?: {
3880
+ type: "exact";
3881
+ term: string | {
3882
+ $userField: "id" | "name" | "device" | "district" | "firstname" | "surname" | "middlename" | "role" | "fullHonorificName" | "province" | "primaryOfficeId";
3883
+ $location?: string | undefined;
3884
+ };
3885
+ } | undefined;
3886
+ createdAtLocation?: {
3887
+ type: "exact";
3888
+ term: string | {
3889
+ $userField: "id" | "name" | "device" | "district" | "firstname" | "surname" | "middlename" | "role" | "fullHonorificName" | "province" | "primaryOfficeId";
3890
+ $location?: string | undefined;
3891
+ };
3892
+ } | {
3893
+ type: "within";
3894
+ location: string | {
3895
+ $userField: "id" | "name" | "device" | "district" | "firstname" | "surname" | "middlename" | "role" | "fullHonorificName" | "province" | "primaryOfficeId";
3896
+ $location?: string | undefined;
3897
+ };
3898
+ } | undefined;
3899
+ assignedTo?: {
3900
+ type: "exact";
3901
+ term: string | {
3902
+ $userField: "id" | "name" | "device" | "district" | "firstname" | "surname" | "middlename" | "role" | "fullHonorificName" | "province" | "primaryOfficeId";
3903
+ $location?: string | undefined;
3904
+ };
3905
+ } | undefined;
3906
+ trackingId?: {
3907
+ type: "exact";
3908
+ term: string;
3909
+ } | undefined;
3910
+ updatedAt?: {
3911
+ type: "range";
3912
+ gte: string;
3913
+ lte: string;
3914
+ } | {
3915
+ type: "exact";
3916
+ term: string;
3917
+ } | {
3918
+ type: "timePeriod";
3919
+ term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
3920
+ } | undefined;
3921
+ updatedByUserRole?: {
3922
+ type: "exact";
3923
+ term: string | {
3924
+ $userField: "id" | "name" | "device" | "district" | "firstname" | "surname" | "middlename" | "role" | "fullHonorificName" | "province" | "primaryOfficeId";
3925
+ $location?: string | undefined;
3926
+ };
3927
+ } | undefined;
3928
+ updatedAtLocation?: {
3929
+ type: "exact";
3930
+ term: string | {
3931
+ $userField: "id" | "name" | "device" | "district" | "firstname" | "surname" | "middlename" | "role" | "fullHonorificName" | "province" | "primaryOfficeId";
3932
+ $location?: string | undefined;
3933
+ };
3934
+ } | {
3935
+ type: "within";
3936
+ location: string | {
3937
+ $userField: "id" | "name" | "device" | "district" | "firstname" | "surname" | "middlename" | "role" | "fullHonorificName" | "province" | "primaryOfficeId";
3938
+ $location?: string | undefined;
3939
+ };
3940
+ } | undefined;
3941
+ updatedBy?: {
3942
+ type: "exact";
3943
+ term: string | {
3944
+ $userField: "id" | "name" | "device" | "district" | "firstname" | "surname" | "middlename" | "role" | "fullHonorificName" | "province" | "primaryOfficeId";
3945
+ $location?: string | undefined;
3946
+ };
3947
+ } | undefined;
3948
+ flags?: {
3949
+ anyOf?: string[] | undefined;
3950
+ noneOf?: string[] | undefined;
3951
+ } | undefined;
3952
+ "legalStatuses.REGISTERED.createdAt"?: {
3953
+ type: "range";
3954
+ gte: string;
3955
+ lte: string;
3956
+ } | {
3957
+ type: "exact";
3958
+ term: string;
3959
+ } | {
3960
+ type: "timePeriod";
3961
+ term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
3962
+ } | undefined;
3963
+ eventType?: string | undefined;
3964
+ "legalStatuses.REGISTERED.createdAtLocation"?: {
3965
+ type: "exact";
3966
+ term: string;
3967
+ } | {
3968
+ type: "within";
3969
+ location: string;
3970
+ } | undefined;
3971
+ "legalStatuses.REGISTERED.registrationNumber"?: {
3972
+ type: "exact";
3973
+ term: string;
3974
+ } | undefined;
3975
+ }[];
3976
+ } | {
3977
+ type: "and";
3978
+ clauses: {
3979
+ status?: {
3980
+ type: "exact";
3981
+ term: "ARCHIVED" | "DECLARED" | "REGISTERED" | "VALIDATED" | "CREATED" | "NOTIFIED";
3982
+ } | {
3983
+ type: "anyOf";
3984
+ terms: ("ARCHIVED" | "DECLARED" | "REGISTERED" | "VALIDATED" | "CREATED" | "NOTIFIED")[];
3985
+ } | undefined;
3986
+ data?: any;
3987
+ createdByUserType?: {
3988
+ type: "exact";
3989
+ term: "system" | "user";
3990
+ } | undefined;
3991
+ createdAt?: {
3992
+ type: "range";
3993
+ gte: string;
3994
+ lte: string;
3995
+ } | {
3996
+ type: "exact";
3997
+ term: string;
3998
+ } | {
3999
+ type: "timePeriod";
4000
+ term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
4001
+ } | undefined;
4002
+ createdBy?: {
4003
+ type: "exact";
4004
+ term: string | {
4005
+ $userField: "id" | "name" | "device" | "district" | "firstname" | "surname" | "middlename" | "role" | "fullHonorificName" | "province" | "primaryOfficeId";
4006
+ $location?: string | undefined;
4007
+ };
4008
+ } | undefined;
4009
+ createdAtLocation?: {
4010
+ type: "exact";
4011
+ term: string | {
4012
+ $userField: "id" | "name" | "device" | "district" | "firstname" | "surname" | "middlename" | "role" | "fullHonorificName" | "province" | "primaryOfficeId";
4013
+ $location?: string | undefined;
4014
+ };
4015
+ } | {
4016
+ type: "within";
4017
+ location: string | {
4018
+ $userField: "id" | "name" | "device" | "district" | "firstname" | "surname" | "middlename" | "role" | "fullHonorificName" | "province" | "primaryOfficeId";
4019
+ $location?: string | undefined;
4020
+ };
4021
+ } | undefined;
4022
+ assignedTo?: {
4023
+ type: "exact";
4024
+ term: string | {
4025
+ $userField: "id" | "name" | "device" | "district" | "firstname" | "surname" | "middlename" | "role" | "fullHonorificName" | "province" | "primaryOfficeId";
4026
+ $location?: string | undefined;
4027
+ };
4028
+ } | undefined;
4029
+ trackingId?: {
4030
+ type: "exact";
4031
+ term: string;
4032
+ } | undefined;
4033
+ updatedAt?: {
4034
+ type: "range";
4035
+ gte: string;
4036
+ lte: string;
4037
+ } | {
4038
+ type: "exact";
4039
+ term: string;
4040
+ } | {
4041
+ type: "timePeriod";
4042
+ term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
4043
+ } | undefined;
4044
+ updatedByUserRole?: {
4045
+ type: "exact";
4046
+ term: string | {
4047
+ $userField: "id" | "name" | "device" | "district" | "firstname" | "surname" | "middlename" | "role" | "fullHonorificName" | "province" | "primaryOfficeId";
4048
+ $location?: string | undefined;
4049
+ };
4050
+ } | undefined;
4051
+ updatedAtLocation?: {
4052
+ type: "exact";
4053
+ term: string | {
4054
+ $userField: "id" | "name" | "device" | "district" | "firstname" | "surname" | "middlename" | "role" | "fullHonorificName" | "province" | "primaryOfficeId";
4055
+ $location?: string | undefined;
4056
+ };
4057
+ } | {
4058
+ type: "within";
4059
+ location: string | {
4060
+ $userField: "id" | "name" | "device" | "district" | "firstname" | "surname" | "middlename" | "role" | "fullHonorificName" | "province" | "primaryOfficeId";
4061
+ $location?: string | undefined;
4062
+ };
4063
+ } | undefined;
4064
+ updatedBy?: {
4065
+ type: "exact";
4066
+ term: string | {
4067
+ $userField: "id" | "name" | "device" | "district" | "firstname" | "surname" | "middlename" | "role" | "fullHonorificName" | "province" | "primaryOfficeId";
4068
+ $location?: string | undefined;
4069
+ };
4070
+ } | undefined;
4071
+ flags?: {
4072
+ anyOf?: string[] | undefined;
4073
+ noneOf?: string[] | undefined;
4074
+ } | undefined;
4075
+ "legalStatuses.REGISTERED.createdAt"?: {
4076
+ type: "range";
4077
+ gte: string;
4078
+ lte: string;
4079
+ } | {
4080
+ type: "exact";
4081
+ term: string;
4082
+ } | {
4083
+ type: "timePeriod";
4084
+ term: "last7Days" | "last30Days" | "last90Days" | "last365Days";
4085
+ } | undefined;
4086
+ eventType?: string | undefined;
4087
+ "legalStatuses.REGISTERED.createdAtLocation"?: {
4088
+ type: "exact";
4089
+ term: string;
4090
+ } | {
4091
+ type: "within";
4092
+ location: string;
4093
+ } | undefined;
4094
+ "legalStatuses.REGISTERED.registrationNumber"?: {
4095
+ type: "exact";
4096
+ term: string;
4097
+ } | undefined;
4098
+ }[];
4099
+ };
4100
+ icon: "Validated" | "Registered" | "Certified" | "Archived" | "List" | "Draft" | "Archive" | "IdentificationCard" | "Check" | "Assigned" | "Close" | "Collapse" | "DuplicateYellow" | "Expand" | "ExternalValidate" | "FilledCheck" | "InReview" | "Offline" | "RequiresUpdates" | "Sent" | "WaitingApproval" | "ChartActivity" | "Activity" | "ArchiveTray" | "ArrowLeft" | "ArrowRight" | "Buildings" | "Circle" | "CaretDown" | "CaretLeft" | "CaretRight" | "ChartBar" | "ChartLine" | "ChatCircle" | "CheckSquare" | "Compass" | "Copy" | "Database" | "DotsThreeVertical" | "ArrowCounterClockwise" | "MagnifyingGlassMinus" | "MagnifyingGlassPlus" | "Export" | "Eye" | "EyeSlash" | "Envelope" | "File" | "FileSearch" | "FileMinus" | "FilePlus" | "FileText" | "FileX" | "Handshake" | "Gear" | "GitBranch" | "ListBullets" | "Lock" | "MagnifyingGlass" | "MapPin" | "Medal" | "NotePencil" | "Paperclip" | "PaperPlaneTilt" | "Pen" | "Pencil" | "PencilSimpleLine" | "Phone" | "Plus" | "Printer" | "SignOut" | "Star" | "Target" | "TextT" | "Trash" | "UploadSimple" | "User" | "UserPlus" | "Users" | "WarningCircle" | "X" | "CircleWavyCheck" | "CircleWavyQuestion" | "ArchiveBox" | "ArrowCircleDown" | "FileArrowUp" | "FileDotted" | "Files" | "PencilLine" | "PencilCircle" | "UserCircle" | "Clock" | "QrCode" | "Webcam" | "Sun" | "DeviceTabletCamera" | "Globe" | "Fingerprint" | "PushPin" | "Timer";
4101
+ slug: string;
4102
+ columns: {
4103
+ value: {
4104
+ $event: "type" | "id" | "status" | "title" | "createdByUserType" | "createdAt" | "createdBy" | "createdAtLocation" | "assignedTo" | "trackingId" | "updatedAt" | "legalStatuses" | "dateOfEvent" | "updatedByUserRole" | "updatedAtLocation" | "updatedBy" | "flags" | "outbox";
4105
+ };
4106
+ label: import("../commons").TranslationConfig;
4107
+ }[];
4108
+ emptyMessage?: import("../commons").TranslationConfig | undefined;
4109
+ }[];
4110
+ meta: import("trpc-to-openapi").OpenApiMeta;
4111
+ }>;
4112
+ }>>;
4113
+ count: import("@trpc/server").TRPCQueryProcedure<{
4114
+ input: {
4115
+ slug: string;
4116
+ query?: any;
4117
+ }[];
4118
+ output: Record<string, number>;
4119
+ meta: import("trpc-to-openapi").OpenApiMeta;
4120
+ }>;
4121
+ }>>;
4122
+ }>>;
4123
+ /** @knipignore */
4124
+ export type AppRouter = typeof appRouter;
4125
+ //# sourceMappingURL=router.d.ts.map