@opencrvs/toolkit 2.1.0-rc.28fe5a3 → 2.1.0-rc.3028b2e

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 (247) hide show
  1. package/README.md +3 -12
  2. package/build.sh +22 -4
  3. package/create-countryconfig/index.js +441 -59
  4. package/create-countryconfig/node_modules/.bin/degit +21 -0
  5. package/create-countryconfig/package.json +4 -1
  6. package/dist/application-config/index.js +364 -285
  7. package/dist/authentication/index.d.ts +66 -0
  8. package/dist/authentication/index.d.ts.map +1 -0
  9. package/dist/authentication/index.js +765 -0
  10. package/dist/cli.js +3778 -1231
  11. package/dist/commons/api/router.d.ts +980 -420
  12. package/dist/commons/application-config/index.d.ts +0 -2
  13. package/dist/commons/conditionals/conditionals.d.ts +6 -6
  14. package/dist/commons/conditionals/validate.d.ts +34 -8
  15. package/dist/commons/events/ActionConfig.d.ts +5 -14
  16. package/dist/commons/events/ActionDocument.d.ts +41 -21
  17. package/dist/commons/events/ActionInput.d.ts +4 -10
  18. package/dist/commons/events/ActionStatus.d.ts +14 -0
  19. package/dist/commons/events/AdvancedSearchConfig.d.ts +48 -12
  20. package/dist/commons/events/AuditLog.d.ts +148 -0
  21. package/dist/commons/events/Draft.d.ts +1 -21
  22. package/dist/commons/events/EventConfig.d.ts +3 -0
  23. package/dist/commons/events/EventDocument.d.ts +474 -6
  24. package/dist/commons/events/EventIndex.d.ts +3 -26
  25. package/dist/commons/events/EventMetadata.d.ts +1 -11
  26. package/dist/commons/events/EventStatus.d.ts +19 -0
  27. package/dist/commons/events/FieldConfig.d.ts +109 -63
  28. package/dist/commons/events/FieldTypeMapping.d.ts +17 -17
  29. package/dist/commons/events/FieldValue.d.ts +3 -2
  30. package/dist/commons/events/Flag.d.ts +42 -0
  31. package/dist/commons/events/FormConfig.d.ts +6 -0
  32. package/dist/commons/events/PageConfig.d.ts +4 -0
  33. package/dist/commons/events/PlainDate.d.ts +8 -0
  34. package/dist/commons/events/SummaryConfig.d.ts +249 -0
  35. package/dist/commons/events/WorkqueueConfig.d.ts +17 -14
  36. package/dist/commons/events/event.d.ts +12 -0
  37. package/dist/commons/events/index.d.ts +1 -0
  38. package/dist/commons/events/locationPayloads.d.ts +95 -0
  39. package/dist/commons/events/locations.d.ts +246 -13
  40. package/dist/commons/events/mocks.test.utils.d.ts +46 -2
  41. package/dist/commons/events/scopes.d.ts +21 -1
  42. package/dist/commons/events/test.utils.d.ts +82 -32
  43. package/dist/commons/events/utils.d.ts +41 -6
  44. package/dist/commons/notification/UserNotifications.d.ts +28 -13
  45. package/dist/commons/notification/dispatch.d.ts +10 -0
  46. package/dist/commons/notification/index.d.ts +1 -0
  47. package/dist/conditionals/index.js +349 -65
  48. package/dist/csv.d.ts +25 -0
  49. package/dist/csv.d.ts.map +1 -0
  50. package/dist/csv.js +120 -0
  51. package/dist/environment/derived-variables.d.ts +12 -0
  52. package/dist/environment/derived-variables.d.ts.map +1 -1
  53. package/dist/environment/derived-variables.js +14 -0
  54. package/dist/environment/index.d.ts +1 -0
  55. package/dist/environment/index.d.ts.map +1 -1
  56. package/dist/environment/index.js +12 -1
  57. package/dist/environment/logger.d.ts +15 -3
  58. package/dist/environment/logger.d.ts.map +1 -1
  59. package/dist/environment/manage-users.js +1 -1
  60. package/dist/environment/paths.d.ts +7 -0
  61. package/dist/environment/paths.d.ts.map +1 -0
  62. package/dist/environment/paths.js +72 -0
  63. package/dist/environment/questions.d.ts.map +1 -1
  64. package/dist/environment/questions.js +20 -14
  65. package/dist/environment/setup-environment.d.ts +1 -1
  66. package/dist/environment/setup-environment.d.ts.map +1 -1
  67. package/dist/environment/setup-environment.js +603 -562
  68. package/dist/environment/swarm-to-k8s.js +3 -4
  69. package/dist/environment/templates.d.ts +0 -1
  70. package/dist/environment/templates.d.ts.map +1 -1
  71. package/dist/environment/templates.js +5 -9
  72. package/dist/environment/update-workflows.d.ts.map +1 -1
  73. package/dist/environment/update-workflows.js +21 -5
  74. package/dist/environment/upgrade.d.ts +2 -0
  75. package/dist/environment/upgrade.d.ts.map +1 -0
  76. package/dist/environment/upgrade.js +82 -0
  77. package/dist/environment/users.js +11 -13
  78. package/dist/environment/utils.d.ts +0 -12
  79. package/dist/environment/utils.d.ts.map +1 -1
  80. package/dist/environment/utils.js +1 -28
  81. package/dist/events/index.js +7842 -7212
  82. package/dist/migrations/v2.1/add-recovery-link-notifications.d.ts +3 -0
  83. package/dist/migrations/v2.1/add-recovery-link-notifications.d.ts.map +1 -0
  84. package/dist/migrations/v2.1/add-recovery-link-notifications.js +511 -0
  85. package/dist/migrations/v2.1/add-translations.d.ts +9 -0
  86. package/dist/migrations/v2.1/add-translations.d.ts.map +1 -0
  87. package/dist/migrations/v2.1/add-translations.js +149 -0
  88. package/dist/migrations/{v2.0/rename-api-paths.d.ts → v2.1/enable-telemetry.d.ts} +1 -1
  89. package/dist/migrations/v2.1/enable-telemetry.d.ts.map +1 -0
  90. package/dist/migrations/v2.1/enable-telemetry.js +455 -0
  91. package/dist/migrations/v2.1/index.d.ts.map +1 -1
  92. package/dist/migrations/v2.1/index.js +1952 -0
  93. package/dist/migrations/v2.1/migrate-infrastructure-to-assets.d.ts +14 -0
  94. package/dist/migrations/v2.1/migrate-infrastructure-to-assets.d.ts.map +1 -0
  95. package/dist/migrations/v2.1/migrate-infrastructure-to-assets.js +348 -0
  96. package/dist/migrations/v2.1/remove-metabase-package-installs.d.ts +2 -0
  97. package/dist/migrations/v2.1/remove-metabase-package-installs.d.ts.map +1 -0
  98. package/dist/migrations/v2.1/remove-metabase-package-installs.js +161 -0
  99. package/dist/migrations/{v2.0/migrate-scopes.d.ts → v2.1/remove-sentry.d.ts} +1 -1
  100. package/dist/migrations/v2.1/remove-sentry.d.ts.map +1 -0
  101. package/dist/migrations/v2.1/remove-sentry.js +354 -0
  102. package/dist/migrations/{v2.0/create-events-index.d.ts → v2.1/rename-trigger-paths.d.ts} +1 -1
  103. package/dist/migrations/v2.1/rename-trigger-paths.d.ts.map +1 -0
  104. package/dist/migrations/{v2.0/rename-api-paths.js → v2.1/rename-trigger-paths.js} +69 -40
  105. package/dist/migrations/v2.1/template-files.d.ts +8 -0
  106. package/dist/migrations/v2.1/template-files.d.ts.map +1 -0
  107. package/dist/migrations/v2.1/template-files.js +49 -0
  108. package/dist/migrations/v2.1/upgrade-tilt.d.ts +8 -0
  109. package/dist/migrations/v2.1/upgrade-tilt.d.ts.map +1 -0
  110. package/dist/migrations/v2.1/upgrade-tilt.js +139 -0
  111. package/dist/notification/index.js +1925 -1485
  112. package/dist/scopes/index.d.ts +614 -36
  113. package/dist/scopes/index.js +351 -65
  114. package/dist/telemetry/index.d.ts +45 -0
  115. package/dist/telemetry/index.d.ts.map +1 -0
  116. package/dist/telemetry/index.js +43 -0
  117. package/dist/templates/charts-values/dependencies/values.yaml +8 -0
  118. package/dist/templates/charts-values/opencrvs-services/values.yaml +10 -3
  119. package/dist/templates/charts-values/opentelemetry/values.yaml +102 -0
  120. package/dist/templates/charts-values/traefik/values.yaml +23 -9
  121. package/dist/templates/countryconfig-template/.tiltignore +1 -0
  122. package/dist/templates/countryconfig-template/Dockerfile.assets +7 -0
  123. package/dist/templates/countryconfig-template/Tiltfile +112 -0
  124. package/dist/templates/countryconfig-template/assets/README.md +1 -0
  125. package/dist/templates/countryconfig-template/assets/clear-all-data-dev.sh +61 -0
  126. package/dist/templates/countryconfig-template/assets/deployment/deploy.sh +455 -0
  127. package/dist/templates/countryconfig-template/assets/deployment/reindex.sh +168 -0
  128. package/dist/templates/countryconfig-template/assets/deployment/validate-required-variables-in-compose-files.ts +67 -0
  129. package/dist/templates/countryconfig-template/assets/elasticsearch/reindex.sh +168 -0
  130. package/dist/templates/countryconfig-template/assets/metabase/README.md +34 -0
  131. package/dist/templates/countryconfig-template/assets/metabase/environment-configuration.sql +36 -0
  132. package/dist/templates/countryconfig-template/assets/metabase/initialize-database.sh +46 -0
  133. package/dist/templates/countryconfig-template/assets/metabase/metabase.init.db.sql +27737 -0
  134. package/dist/templates/countryconfig-template/assets/metabase/open-shell.sh +21 -0
  135. package/dist/templates/countryconfig-template/assets/metabase/package.json +13 -0
  136. package/dist/templates/countryconfig-template/assets/metabase/run-dev.sh +108 -0
  137. package/dist/templates/countryconfig-template/assets/metabase/run.sh +120 -0
  138. package/dist/templates/countryconfig-template/assets/metabase/update-database.sh +40 -0
  139. package/dist/templates/countryconfig-template/assets/postgres/setup-analytics.sh +135 -0
  140. package/dist/templates/countryconfig-template/assets/postgres/setup-reference-data.sh +108 -0
  141. package/dist/templates/countryconfig-template/tilt/clear-all-data.ps1 +50 -0
  142. package/dist/templates/countryconfig-template/tilt/clear-all-data.sh +35 -0
  143. package/dist/templates/countryconfig-template/tilt/common.tilt +145 -0
  144. package/dist/templates/countryconfig-template/tilt/examples/dependencies/values.yaml +15 -0
  145. package/dist/templates/countryconfig-template/tilt/examples/opencrvs-services/values.yaml +56 -0
  146. package/dist/templates/countryconfig-template/tilt/examples/traefik/values-minikube.yaml +21 -0
  147. package/dist/templates/countryconfig-template/tilt/examples/traefik/values.yaml +38 -0
  148. package/dist/templates/countryconfig-template/tilt/helm/dependencies/values.yaml +17 -0
  149. package/dist/templates/countryconfig-template/tilt/helm/opencrvs-services/values.yaml +16 -0
  150. package/dist/templates/countryconfig-template/tilt/lib.tilt +95 -0
  151. package/dist/templates/countryconfig-template/tilt/opencrvs.tilt +136 -0
  152. package/dist/templates/inventory/inventory.template.yml +1 -3
  153. package/dist/translations/template.d.ts +11 -0
  154. package/dist/translations/template.d.ts.map +1 -0
  155. package/dist/translations/template.js +100 -0
  156. package/dist/verify/endpoints.d.ts +2 -0
  157. package/dist/verify/endpoints.d.ts.map +1 -0
  158. package/dist/verify/endpoints.js +510 -0
  159. package/opencrvs-toolkit-2.1.0-rc.3028b2e.tgz +0 -0
  160. package/package.json +14 -7
  161. package/tsconfig.build.json +11 -0
  162. package/tsconfig.build.tsbuildinfo +1 -0
  163. package/tsconfig.json +3 -0
  164. package/dist/migrations/v2.0/add-birth-certificate-issuance-flag.d.ts +0 -3
  165. package/dist/migrations/v2.0/add-birth-certificate-issuance-flag.d.ts.map +0 -1
  166. package/dist/migrations/v2.0/add-birth-certificate-issuance-flag.js +0 -429
  167. package/dist/migrations/v2.0/add-resend-invite-notification.d.ts +0 -3
  168. package/dist/migrations/v2.0/add-resend-invite-notification.d.ts.map +0 -1
  169. package/dist/migrations/v2.0/add-resend-invite-notification.js +0 -373
  170. package/dist/migrations/v2.0/checkout-upstream-files.d.ts +0 -22
  171. package/dist/migrations/v2.0/checkout-upstream-files.d.ts.map +0 -1
  172. package/dist/migrations/v2.0/checkout-upstream-files.js +0 -146
  173. package/dist/migrations/v2.0/convert-config-files-to-ts.d.ts +0 -2
  174. package/dist/migrations/v2.0/convert-config-files-to-ts.d.ts.map +0 -1
  175. package/dist/migrations/v2.0/convert-config-files-to-ts.js +0 -838
  176. package/dist/migrations/v2.0/convert-paragraph-to-heading.d.ts +0 -3
  177. package/dist/migrations/v2.0/convert-paragraph-to-heading.d.ts.map +0 -1
  178. package/dist/migrations/v2.0/convert-paragraph-to-heading.js +0 -158
  179. package/dist/migrations/v2.0/create-events-index.d.ts.map +0 -1
  180. package/dist/migrations/v2.0/create-events-index.js +0 -325
  181. package/dist/migrations/v2.0/delete-infrastructure-directory.d.ts +0 -11
  182. package/dist/migrations/v2.0/delete-infrastructure-directory.d.ts.map +0 -1
  183. package/dist/migrations/v2.0/delete-infrastructure-directory.js +0 -123
  184. package/dist/migrations/v2.0/fix-accept-requested-registration-function-type.d.ts +0 -3
  185. package/dist/migrations/v2.0/fix-accept-requested-registration-function-type.d.ts.map +0 -1
  186. package/dist/migrations/v2.0/fix-accept-requested-registration-function-type.js +0 -110
  187. package/dist/migrations/v2.0/index.d.ts +0 -13
  188. package/dist/migrations/v2.0/index.d.ts.map +0 -1
  189. package/dist/migrations/v2.0/index.js +0 -103
  190. package/dist/migrations/v2.0/make-built-in-validate-actions-custom.d.ts +0 -3
  191. package/dist/migrations/v2.0/make-built-in-validate-actions-custom.d.ts.map +0 -1
  192. package/dist/migrations/v2.0/make-built-in-validate-actions-custom.js +0 -432
  193. package/dist/migrations/v2.0/merge-infrastructure-directory.d.ts +0 -13
  194. package/dist/migrations/v2.0/merge-infrastructure-directory.d.ts.map +0 -1
  195. package/dist/migrations/v2.0/merge-infrastructure-directory.js +0 -222
  196. package/dist/migrations/v2.0/migrate-application-config-url.d.ts +0 -3
  197. package/dist/migrations/v2.0/migrate-application-config-url.d.ts.map +0 -1
  198. package/dist/migrations/v2.0/migrate-application-config-url.js +0 -343
  199. package/dist/migrations/v2.0/migrate-scopes.d.ts.map +0 -1
  200. package/dist/migrations/v2.0/migrate-scopes.js +0 -305
  201. package/dist/migrations/v2.0/migrate-validated-workqueue-status-to-flag.d.ts +0 -3
  202. package/dist/migrations/v2.0/migrate-validated-workqueue-status-to-flag.d.ts.map +0 -1
  203. package/dist/migrations/v2.0/migrate-validated-workqueue-status-to-flag.js +0 -267
  204. package/dist/migrations/v2.0/migrate-workqueue-configs.d.ts +0 -3
  205. package/dist/migrations/v2.0/migrate-workqueue-configs.d.ts.map +0 -1
  206. package/dist/migrations/v2.0/migrate-workqueue-configs.js +0 -317
  207. package/dist/migrations/v2.0/remove-delete-actions.d.ts +0 -3
  208. package/dist/migrations/v2.0/remove-delete-actions.d.ts.map +0 -1
  209. package/dist/migrations/v2.0/remove-delete-actions.js +0 -156
  210. package/dist/migrations/v2.0/remove-demo-scope.d.ts +0 -3
  211. package/dist/migrations/v2.0/remove-demo-scope.d.ts.map +0 -1
  212. package/dist/migrations/v2.0/remove-demo-scope.js +0 -74
  213. package/dist/migrations/v2.0/remove-deprecated-imports.d.ts +0 -3
  214. package/dist/migrations/v2.0/remove-deprecated-imports.d.ts.map +0 -1
  215. package/dist/migrations/v2.0/remove-deprecated-imports.js +0 -96
  216. package/dist/migrations/v2.0/remove-fhir-url-helpers.d.ts +0 -3
  217. package/dist/migrations/v2.0/remove-fhir-url-helpers.d.ts.map +0 -1
  218. package/dist/migrations/v2.0/remove-fhir-url-helpers.js +0 -163
  219. package/dist/migrations/v2.0/remove-hearth-migrations.d.ts +0 -3
  220. package/dist/migrations/v2.0/remove-hearth-migrations.d.ts.map +0 -1
  221. package/dist/migrations/v2.0/remove-hearth-migrations.js +0 -87
  222. package/dist/migrations/v2.0/remove-old-statistics-service.d.ts +0 -3
  223. package/dist/migrations/v2.0/remove-old-statistics-service.d.ts.map +0 -1
  224. package/dist/migrations/v2.0/remove-old-statistics-service.js +0 -356
  225. package/dist/migrations/v2.0/remove-pending-certification-flag.d.ts +0 -3
  226. package/dist/migrations/v2.0/remove-pending-certification-flag.d.ts.map +0 -1
  227. package/dist/migrations/v2.0/remove-pending-certification-flag.js +0 -109
  228. package/dist/migrations/v2.0/remove-review-from-register-action.d.ts +0 -3
  229. package/dist/migrations/v2.0/remove-review-from-register-action.d.ts.map +0 -1
  230. package/dist/migrations/v2.0/remove-review-from-register-action.js +0 -163
  231. package/dist/migrations/v2.0/remove-unused-environment-variables.d.ts +0 -3
  232. package/dist/migrations/v2.0/remove-unused-environment-variables.d.ts.map +0 -1
  233. package/dist/migrations/v2.0/remove-unused-environment-variables.js +0 -186
  234. package/dist/migrations/v2.0/rename-api-paths.d.ts.map +0 -1
  235. package/dist/migrations/v2.0/rename-location-parent-id.d.ts +0 -3
  236. package/dist/migrations/v2.0/rename-location-parent-id.d.ts.map +0 -1
  237. package/dist/migrations/v2.0/rename-location-parent-id.js +0 -180
  238. package/dist/migrations/v2.0/simplify-analytics-precalculations.d.ts +0 -3
  239. package/dist/migrations/v2.0/simplify-analytics-precalculations.d.ts.map +0 -1
  240. package/dist/migrations/v2.0/simplify-analytics-precalculations.js +0 -195
  241. package/dist/migrations/v2.0/update-package-json.d.ts +0 -3
  242. package/dist/migrations/v2.0/update-package-json.d.ts.map +0 -1
  243. package/dist/migrations/v2.0/update-package-json.js +0 -105
  244. package/dist/templates/inventory/production.example.yml +0 -77
  245. package/dist/templates/inventory/qa.example.yml +0 -48
  246. package/opencrvs-toolkit-2.1.0-rc.28fe5a3.tgz +0 -0
  247. package/tsconfig.tsbuildinfo +0 -1
@@ -2,18 +2,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2
2
  ctx: Partial<{
3
3
  token: `Bearer ${string}`;
4
4
  user: {
5
- id: string & import("zod").$brand<"UUID">;
6
- type: "system";
7
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
8
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
9
- signature?: undefined;
10
- } | {
11
5
  id: string & import("zod").$brand<"UUID">;
12
6
  role: string;
13
7
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
14
8
  primaryOfficeId: string & import("zod").$brand<"UUID">;
15
9
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
16
10
  type: "user";
11
+ } | {
12
+ id: string & import("zod").$brand<"UUID">;
13
+ type: "system";
14
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
15
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
16
+ signature?: undefined;
17
17
  };
18
18
  }>;
19
19
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -24,18 +24,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
24
24
  ctx: Partial<{
25
25
  token: `Bearer ${string}`;
26
26
  user: {
27
- id: string & import("zod").$brand<"UUID">;
28
- type: "system";
29
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
30
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
31
- signature?: undefined;
32
- } | {
33
27
  id: string & import("zod").$brand<"UUID">;
34
28
  role: string;
35
29
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
36
30
  primaryOfficeId: string & import("zod").$brand<"UUID">;
37
31
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
38
32
  type: "user";
33
+ } | {
34
+ id: string & import("zod").$brand<"UUID">;
35
+ type: "system";
36
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
37
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
38
+ signature?: undefined;
39
39
  };
40
40
  }>;
41
41
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -46,18 +46,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
46
46
  ctx: Partial<{
47
47
  token: `Bearer ${string}`;
48
48
  user: {
49
- id: string & import("zod").$brand<"UUID">;
50
- type: "system";
51
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
52
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
53
- signature?: undefined;
54
- } | {
55
49
  id: string & import("zod").$brand<"UUID">;
56
50
  role: string;
57
51
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
58
52
  primaryOfficeId: string & import("zod").$brand<"UUID">;
59
53
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
60
54
  type: "user";
55
+ } | {
56
+ id: string & import("zod").$brand<"UUID">;
57
+ type: "system";
58
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
59
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
60
+ signature?: undefined;
61
61
  };
62
62
  }>;
63
63
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -81,6 +81,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
81
81
  status: "completed" | "failed" | "running";
82
82
  progress: {
83
83
  processed: number;
84
+ skipped: number;
85
+ errors: string[];
84
86
  };
85
87
  error_message: string | null;
86
88
  completed_at: string | null;
@@ -92,18 +94,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
92
94
  ctx: Partial<{
93
95
  token: `Bearer ${string}`;
94
96
  user: {
95
- id: string & import("zod").$brand<"UUID">;
96
- type: "system";
97
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
98
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
99
- signature?: undefined;
100
- } | {
101
97
  id: string & import("zod").$brand<"UUID">;
102
98
  role: string;
103
99
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
104
100
  primaryOfficeId: string & import("zod").$brand<"UUID">;
105
101
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
106
102
  type: "user";
103
+ } | {
104
+ id: string & import("zod").$brand<"UUID">;
105
+ type: "system";
106
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
107
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
108
+ signature?: undefined;
107
109
  };
108
110
  }>;
109
111
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -223,9 +225,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
223
225
  status: "Accepted" | "Rejected" | "Requested";
224
226
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
225
227
  type: "ARCHIVE";
226
- content: {
228
+ content?: {
227
229
  reason: string;
228
- };
230
+ } | undefined;
229
231
  } | {
230
232
  id: string & import("zod").$brand<"UUID">;
231
233
  transactionId: string;
@@ -326,7 +328,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
326
328
  status: "Accepted" | "Rejected" | "Requested";
327
329
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
328
330
  type: "APPROVE_CORRECTION";
329
- requestId: string;
331
+ requestId: string & import("zod").$brand<"UUID">;
330
332
  content?: {
331
333
  immediateCorrection?: boolean | undefined;
332
334
  } | undefined;
@@ -344,7 +346,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
344
346
  status: "Accepted" | "Rejected" | "Requested";
345
347
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
346
348
  type: "REJECT_CORRECTION";
347
- requestId: string;
349
+ requestId: string & import("zod").$brand<"UUID">;
348
350
  content: {
349
351
  reason: string;
350
352
  };
@@ -407,9 +409,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
407
409
  status: "Accepted" | "Rejected" | "Requested";
408
410
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
409
411
  type: "EDIT";
410
- content: {
412
+ content?: {
411
413
  comment?: string | undefined;
412
- };
414
+ } | undefined;
413
415
  } | {
414
416
  id: string & import("zod").$brand<"UUID">;
415
417
  transactionId: string;
@@ -446,7 +448,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
446
448
  input: {
447
449
  eventId: string;
448
450
  customActionType?: string | undefined;
449
- waitFor?: boolean | undefined;
450
451
  };
451
452
  output: {
452
453
  id: string & import("zod").$brand<"UUID">;
@@ -549,9 +550,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
549
550
  status: "Accepted" | "Rejected" | "Requested";
550
551
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
551
552
  type: "ARCHIVE";
552
- content: {
553
+ content?: {
553
554
  reason: string;
554
- };
555
+ } | undefined;
555
556
  } | {
556
557
  id: string & import("zod").$brand<"UUID">;
557
558
  transactionId: string;
@@ -652,7 +653,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
652
653
  status: "Accepted" | "Rejected" | "Requested";
653
654
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
654
655
  type: "APPROVE_CORRECTION";
655
- requestId: string;
656
+ requestId: string & import("zod").$brand<"UUID">;
656
657
  content?: {
657
658
  immediateCorrection?: boolean | undefined;
658
659
  } | undefined;
@@ -670,7 +671,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
670
671
  status: "Accepted" | "Rejected" | "Requested";
671
672
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
672
673
  type: "REJECT_CORRECTION";
673
- requestId: string;
674
+ requestId: string & import("zod").$brand<"UUID">;
674
675
  content: {
675
676
  reason: string;
676
677
  };
@@ -733,9 +734,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
733
734
  status: "Accepted" | "Rejected" | "Requested";
734
735
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
735
736
  type: "EDIT";
736
- content: {
737
+ content?: {
737
738
  comment?: string | undefined;
738
- };
739
+ } | undefined;
739
740
  } | {
740
741
  id: string & import("zod").$brand<"UUID">;
741
742
  transactionId: string;
@@ -874,9 +875,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
874
875
  status: "Accepted" | "Rejected" | "Requested";
875
876
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
876
877
  type: "ARCHIVE";
877
- content: {
878
+ content?: {
878
879
  reason: string;
879
- };
880
+ } | undefined;
880
881
  } | {
881
882
  id: string & import("zod").$brand<"UUID">;
882
883
  transactionId: string;
@@ -977,7 +978,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
977
978
  status: "Accepted" | "Rejected" | "Requested";
978
979
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
979
980
  type: "APPROVE_CORRECTION";
980
- requestId: string;
981
+ requestId: string & import("zod").$brand<"UUID">;
981
982
  content?: {
982
983
  immediateCorrection?: boolean | undefined;
983
984
  } | undefined;
@@ -995,7 +996,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
995
996
  status: "Accepted" | "Rejected" | "Requested";
996
997
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
997
998
  type: "REJECT_CORRECTION";
998
- requestId: string;
999
+ requestId: string & import("zod").$brand<"UUID">;
999
1000
  content: {
1000
1001
  reason: string;
1001
1002
  };
@@ -1058,9 +1059,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1058
1059
  status: "Accepted" | "Rejected" | "Requested";
1059
1060
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
1060
1061
  type: "EDIT";
1061
- content: {
1062
+ content?: {
1062
1063
  comment?: string | undefined;
1063
- };
1064
+ } | undefined;
1064
1065
  } | {
1065
1066
  id: string & import("zod").$brand<"UUID">;
1066
1067
  transactionId: string;
@@ -1106,18 +1107,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1106
1107
  ctx: Partial<{
1107
1108
  token: `Bearer ${string}`;
1108
1109
  user: {
1109
- id: string & import("zod").$brand<"UUID">;
1110
- type: "system";
1111
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
1112
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
1113
- signature?: undefined;
1114
- } | {
1115
1110
  id: string & import("zod").$brand<"UUID">;
1116
1111
  role: string;
1117
1112
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
1118
1113
  primaryOfficeId: string & import("zod").$brand<"UUID">;
1119
1114
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
1120
1115
  type: "user";
1116
+ } | {
1117
+ id: string & import("zod").$brand<"UUID">;
1118
+ type: "system";
1119
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
1120
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
1121
+ signature?: undefined;
1121
1122
  };
1122
1123
  }>;
1123
1124
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -1158,7 +1159,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1158
1159
  keepAssignmentIfAccepted?: boolean | undefined;
1159
1160
  keepAssignmentIfRejected?: boolean | undefined;
1160
1161
  createdAtLocation?: string | null | undefined;
1161
- type: "APPROVE_CORRECTION" | "ARCHIVE" | "ASSIGN" | "CREATE" | "CUSTOM" | "DECLARE" | "DUPLICATE_DETECTED" | "EDIT" | "MARK_AS_DUPLICATE" | "MARK_AS_NOT_DUPLICATE" | "NOTIFY" | "PRINT_CERTIFICATE" | "READ" | "REGISTER" | "REJECT" | "REJECT_CORRECTION" | "REQUEST_CORRECTION" | "UNARCHIVE" | "UNASSIGN";
1162
+ type: "DECLARE";
1162
1163
  status: "Accepted" | "Rejected" | "Requested";
1163
1164
  };
1164
1165
  output: {
@@ -1183,22 +1184,54 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1183
1184
  meta: import("trpc-to-openapi").OpenApiMeta;
1184
1185
  }>;
1185
1186
  }>>;
1186
- actions: import("@trpc/server").TRPCBuiltRouter<{
1187
+ file: import("@trpc/server").TRPCBuiltRouter<{
1187
1188
  ctx: Partial<{
1188
1189
  token: `Bearer ${string}`;
1189
1190
  user: {
1191
+ id: string & import("zod").$brand<"UUID">;
1192
+ role: string;
1193
+ signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
1194
+ primaryOfficeId: string & import("zod").$brand<"UUID">;
1195
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
1196
+ type: "user";
1197
+ } | {
1190
1198
  id: string & import("zod").$brand<"UUID">;
1191
1199
  type: "system";
1192
1200
  primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
1193
1201
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
1194
1202
  signature?: undefined;
1195
- } | {
1203
+ };
1204
+ }>;
1205
+ meta: import("trpc-to-openapi").OpenApiMeta;
1206
+ errorShape: import("@trpc/server").TRPCDefaultErrorShape;
1207
+ transformer: true;
1208
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
1209
+ getPresignedUrl: import("@trpc/server").TRPCQueryProcedure<{
1210
+ input: {
1211
+ filePath: string;
1212
+ };
1213
+ output: {
1214
+ presignedURL: string;
1215
+ };
1216
+ meta: import("trpc-to-openapi").OpenApiMeta;
1217
+ }>;
1218
+ }>>;
1219
+ actions: import("@trpc/server").TRPCBuiltRouter<{
1220
+ ctx: Partial<{
1221
+ token: `Bearer ${string}`;
1222
+ user: {
1196
1223
  id: string & import("zod").$brand<"UUID">;
1197
1224
  role: string;
1198
1225
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
1199
1226
  primaryOfficeId: string & import("zod").$brand<"UUID">;
1200
1227
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
1201
1228
  type: "user";
1229
+ } | {
1230
+ id: string & import("zod").$brand<"UUID">;
1231
+ type: "system";
1232
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
1233
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
1234
+ signature?: undefined;
1202
1235
  };
1203
1236
  }>;
1204
1237
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -1209,18 +1242,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1209
1242
  ctx: Partial<{
1210
1243
  token: `Bearer ${string}`;
1211
1244
  user: {
1212
- id: string & import("zod").$brand<"UUID">;
1213
- type: "system";
1214
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
1215
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
1216
- signature?: undefined;
1217
- } | {
1218
1245
  id: string & import("zod").$brand<"UUID">;
1219
1246
  role: string;
1220
1247
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
1221
1248
  primaryOfficeId: string & import("zod").$brand<"UUID">;
1222
1249
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
1223
1250
  type: "user";
1251
+ } | {
1252
+ id: string & import("zod").$brand<"UUID">;
1253
+ type: "system";
1254
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
1255
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
1256
+ signature?: undefined;
1224
1257
  };
1225
1258
  }>;
1226
1259
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -1354,9 +1387,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1354
1387
  waitFor?: boolean | undefined;
1355
1388
  createdAtLocation?: string | null | undefined;
1356
1389
  type?: "ARCHIVE" | undefined;
1357
- content: {
1390
+ content?: {
1358
1391
  reason: string;
1359
- };
1392
+ } | undefined;
1360
1393
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected"> | Omit<{
1361
1394
  eventId: string;
1362
1395
  transactionId: string;
@@ -1491,9 +1524,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1491
1524
  waitFor?: boolean | undefined;
1492
1525
  createdAtLocation?: string | null | undefined;
1493
1526
  type?: "EDIT" | undefined;
1494
- content: {
1495
- comment?: string | undefined;
1496
- };
1497
1527
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected">) & {
1498
1528
  actionId: string;
1499
1529
  };
@@ -1516,18 +1546,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1516
1546
  ctx: Partial<{
1517
1547
  token: `Bearer ${string}`;
1518
1548
  user: {
1519
- id: string & import("zod").$brand<"UUID">;
1520
- type: "system";
1521
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
1522
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
1523
- signature?: undefined;
1524
- } | {
1525
1549
  id: string & import("zod").$brand<"UUID">;
1526
1550
  role: string;
1527
1551
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
1528
1552
  primaryOfficeId: string & import("zod").$brand<"UUID">;
1529
1553
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
1530
1554
  type: "user";
1555
+ } | {
1556
+ id: string & import("zod").$brand<"UUID">;
1557
+ type: "system";
1558
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
1559
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
1560
+ signature?: undefined;
1531
1561
  };
1532
1562
  }>;
1533
1563
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -1648,9 +1678,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1648
1678
  status: "Accepted" | "Rejected" | "Requested";
1649
1679
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
1650
1680
  type: "ARCHIVE";
1651
- content: {
1681
+ content?: {
1652
1682
  reason: string;
1653
- };
1683
+ } | undefined;
1654
1684
  } | {
1655
1685
  id: string & import("zod").$brand<"UUID">;
1656
1686
  transactionId: string;
@@ -1751,7 +1781,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1751
1781
  status: "Accepted" | "Rejected" | "Requested";
1752
1782
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
1753
1783
  type: "APPROVE_CORRECTION";
1754
- requestId: string;
1784
+ requestId: string & import("zod").$brand<"UUID">;
1755
1785
  content?: {
1756
1786
  immediateCorrection?: boolean | undefined;
1757
1787
  } | undefined;
@@ -1769,7 +1799,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1769
1799
  status: "Accepted" | "Rejected" | "Requested";
1770
1800
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
1771
1801
  type: "REJECT_CORRECTION";
1772
- requestId: string;
1802
+ requestId: string & import("zod").$brand<"UUID">;
1773
1803
  content: {
1774
1804
  reason: string;
1775
1805
  };
@@ -1832,9 +1862,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1832
1862
  status: "Accepted" | "Rejected" | "Requested";
1833
1863
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
1834
1864
  type: "EDIT";
1835
- content: {
1865
+ content?: {
1836
1866
  comment?: string | undefined;
1837
- };
1867
+ } | undefined;
1838
1868
  } | {
1839
1869
  id: string & import("zod").$brand<"UUID">;
1840
1870
  transactionId: string;
@@ -1872,18 +1902,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1872
1902
  ctx: Partial<{
1873
1903
  token: `Bearer ${string}`;
1874
1904
  user: {
1875
- id: string & import("zod").$brand<"UUID">;
1876
- type: "system";
1877
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
1878
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
1879
- signature?: undefined;
1880
- } | {
1881
1905
  id: string & import("zod").$brand<"UUID">;
1882
1906
  role: string;
1883
1907
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
1884
1908
  primaryOfficeId: string & import("zod").$brand<"UUID">;
1885
1909
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
1886
1910
  type: "user";
1911
+ } | {
1912
+ id: string & import("zod").$brand<"UUID">;
1913
+ type: "system";
1914
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
1915
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
1916
+ signature?: undefined;
1887
1917
  };
1888
1918
  }>;
1889
1919
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -2012,9 +2042,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2012
2042
  waitFor?: boolean | undefined;
2013
2043
  createdAtLocation?: string | null | undefined;
2014
2044
  type?: "ARCHIVE" | undefined;
2015
- content: {
2045
+ content?: {
2016
2046
  reason: string;
2017
- };
2047
+ } | undefined;
2018
2048
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected"> | Omit<{
2019
2049
  eventId: string;
2020
2050
  transactionId: string;
@@ -2149,9 +2179,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2149
2179
  waitFor?: boolean | undefined;
2150
2180
  createdAtLocation?: string | null | undefined;
2151
2181
  type?: "EDIT" | undefined;
2152
- content: {
2153
- comment?: string | undefined;
2154
- };
2155
2182
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected">) & {
2156
2183
  actionId: string;
2157
2184
  };
@@ -2284,9 +2311,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2284
2311
  status: "Accepted" | "Rejected" | "Requested";
2285
2312
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
2286
2313
  type: "ARCHIVE";
2287
- content: {
2314
+ content?: {
2288
2315
  reason: string;
2289
- };
2316
+ } | undefined;
2290
2317
  } | {
2291
2318
  id: string & import("zod").$brand<"UUID">;
2292
2319
  transactionId: string;
@@ -2387,7 +2414,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2387
2414
  status: "Accepted" | "Rejected" | "Requested";
2388
2415
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
2389
2416
  type: "APPROVE_CORRECTION";
2390
- requestId: string;
2417
+ requestId: string & import("zod").$brand<"UUID">;
2391
2418
  content?: {
2392
2419
  immediateCorrection?: boolean | undefined;
2393
2420
  } | undefined;
@@ -2405,7 +2432,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2405
2432
  status: "Accepted" | "Rejected" | "Requested";
2406
2433
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
2407
2434
  type: "REJECT_CORRECTION";
2408
- requestId: string;
2435
+ requestId: string & import("zod").$brand<"UUID">;
2409
2436
  content: {
2410
2437
  reason: string;
2411
2438
  };
@@ -2468,9 +2495,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2468
2495
  status: "Accepted" | "Rejected" | "Requested";
2469
2496
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
2470
2497
  type: "EDIT";
2471
- content: {
2498
+ content?: {
2472
2499
  comment?: string | undefined;
2473
- };
2500
+ } | undefined;
2474
2501
  } | {
2475
2502
  id: string & import("zod").$brand<"UUID">;
2476
2503
  transactionId: string;
@@ -2508,18 +2535,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2508
2535
  ctx: Partial<{
2509
2536
  token: `Bearer ${string}`;
2510
2537
  user: {
2511
- id: string & import("zod").$brand<"UUID">;
2512
- type: "system";
2513
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
2514
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
2515
- signature?: undefined;
2516
- } | {
2517
2538
  id: string & import("zod").$brand<"UUID">;
2518
2539
  role: string;
2519
2540
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
2520
2541
  primaryOfficeId: string & import("zod").$brand<"UUID">;
2521
2542
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
2522
2543
  type: "user";
2544
+ } | {
2545
+ id: string & import("zod").$brand<"UUID">;
2546
+ type: "system";
2547
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
2548
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
2549
+ signature?: undefined;
2523
2550
  };
2524
2551
  }>;
2525
2552
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -2653,9 +2680,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2653
2680
  waitFor?: boolean | undefined;
2654
2681
  createdAtLocation?: string | null | undefined;
2655
2682
  type?: "ARCHIVE" | undefined;
2656
- content: {
2683
+ content?: {
2657
2684
  reason: string;
2658
- };
2685
+ } | undefined;
2659
2686
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected"> | Omit<{
2660
2687
  eventId: string;
2661
2688
  transactionId: string;
@@ -2790,9 +2817,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2790
2817
  waitFor?: boolean | undefined;
2791
2818
  createdAtLocation?: string | null | undefined;
2792
2819
  type?: "EDIT" | undefined;
2793
- content: {
2794
- comment?: string | undefined;
2795
- };
2796
2820
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected">) & {
2797
2821
  actionId: string;
2798
2822
  };
@@ -2815,18 +2839,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2815
2839
  ctx: Partial<{
2816
2840
  token: `Bearer ${string}`;
2817
2841
  user: {
2818
- id: string & import("zod").$brand<"UUID">;
2819
- type: "system";
2820
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
2821
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
2822
- signature?: undefined;
2823
- } | {
2824
2842
  id: string & import("zod").$brand<"UUID">;
2825
2843
  role: string;
2826
2844
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
2827
2845
  primaryOfficeId: string & import("zod").$brand<"UUID">;
2828
2846
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
2829
2847
  type: "user";
2848
+ } | {
2849
+ id: string & import("zod").$brand<"UUID">;
2850
+ type: "system";
2851
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
2852
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
2853
+ signature?: undefined;
2830
2854
  };
2831
2855
  }>;
2832
2856
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -2960,9 +2984,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2960
2984
  waitFor?: boolean | undefined;
2961
2985
  createdAtLocation?: string | null | undefined;
2962
2986
  type?: "ARCHIVE" | undefined;
2963
- content: {
2987
+ content?: {
2964
2988
  reason: string;
2965
- };
2989
+ } | undefined;
2966
2990
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected"> | Omit<{
2967
2991
  eventId: string;
2968
2992
  transactionId: string;
@@ -3097,9 +3121,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3097
3121
  waitFor?: boolean | undefined;
3098
3122
  createdAtLocation?: string | null | undefined;
3099
3123
  type?: "EDIT" | undefined;
3100
- content: {
3101
- comment?: string | undefined;
3102
- };
3103
3124
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected">) & {
3104
3125
  actionId: string;
3105
3126
  };
@@ -3122,18 +3143,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3122
3143
  ctx: Partial<{
3123
3144
  token: `Bearer ${string}`;
3124
3145
  user: {
3125
- id: string & import("zod").$brand<"UUID">;
3126
- type: "system";
3127
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
3128
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
3129
- signature?: undefined;
3130
- } | {
3131
3146
  id: string & import("zod").$brand<"UUID">;
3132
3147
  role: string;
3133
3148
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
3134
3149
  primaryOfficeId: string & import("zod").$brand<"UUID">;
3135
3150
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
3136
3151
  type: "user";
3152
+ } | {
3153
+ id: string & import("zod").$brand<"UUID">;
3154
+ type: "system";
3155
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
3156
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
3157
+ signature?: undefined;
3137
3158
  };
3138
3159
  }>;
3139
3160
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -3267,9 +3288,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3267
3288
  waitFor?: boolean | undefined;
3268
3289
  createdAtLocation?: string | null | undefined;
3269
3290
  type?: "ARCHIVE" | undefined;
3270
- content: {
3291
+ content?: {
3271
3292
  reason: string;
3272
- };
3293
+ } | undefined;
3273
3294
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected"> | Omit<{
3274
3295
  eventId: string;
3275
3296
  transactionId: string;
@@ -3404,9 +3425,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3404
3425
  waitFor?: boolean | undefined;
3405
3426
  createdAtLocation?: string | null | undefined;
3406
3427
  type?: "EDIT" | undefined;
3407
- content: {
3408
- comment?: string | undefined;
3409
- };
3410
3428
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected">) & {
3411
3429
  actionId: string;
3412
3430
  };
@@ -3429,18 +3447,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3429
3447
  ctx: Partial<{
3430
3448
  token: `Bearer ${string}`;
3431
3449
  user: {
3432
- id: string & import("zod").$brand<"UUID">;
3433
- type: "system";
3434
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
3435
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
3436
- signature?: undefined;
3437
- } | {
3438
3450
  id: string & import("zod").$brand<"UUID">;
3439
3451
  role: string;
3440
3452
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
3441
3453
  primaryOfficeId: string & import("zod").$brand<"UUID">;
3442
3454
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
3443
3455
  type: "user";
3456
+ } | {
3457
+ id: string & import("zod").$brand<"UUID">;
3458
+ type: "system";
3459
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
3460
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
3461
+ signature?: undefined;
3444
3462
  };
3445
3463
  }>;
3446
3464
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -3574,9 +3592,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3574
3592
  waitFor?: boolean | undefined;
3575
3593
  createdAtLocation?: string | null | undefined;
3576
3594
  type?: "ARCHIVE" | undefined;
3577
- content: {
3595
+ content?: {
3578
3596
  reason: string;
3579
- };
3597
+ } | undefined;
3580
3598
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected"> | Omit<{
3581
3599
  eventId: string;
3582
3600
  transactionId: string;
@@ -3711,9 +3729,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3711
3729
  waitFor?: boolean | undefined;
3712
3730
  createdAtLocation?: string | null | undefined;
3713
3731
  type?: "EDIT" | undefined;
3714
- content: {
3715
- comment?: string | undefined;
3716
- };
3717
3732
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected">) & {
3718
3733
  actionId: string;
3719
3734
  };
@@ -3736,18 +3751,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3736
3751
  ctx: Partial<{
3737
3752
  token: `Bearer ${string}`;
3738
3753
  user: {
3739
- id: string & import("zod").$brand<"UUID">;
3740
- type: "system";
3741
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
3742
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
3743
- signature?: undefined;
3744
- } | {
3745
3754
  id: string & import("zod").$brand<"UUID">;
3746
3755
  role: string;
3747
3756
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
3748
3757
  primaryOfficeId: string & import("zod").$brand<"UUID">;
3749
3758
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
3750
3759
  type: "user";
3760
+ } | {
3761
+ id: string & import("zod").$brand<"UUID">;
3762
+ type: "system";
3763
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
3764
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
3765
+ signature?: undefined;
3751
3766
  };
3752
3767
  }>;
3753
3768
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -3881,9 +3896,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3881
3896
  waitFor?: boolean | undefined;
3882
3897
  createdAtLocation?: string | null | undefined;
3883
3898
  type?: "ARCHIVE" | undefined;
3884
- content: {
3899
+ content?: {
3885
3900
  reason: string;
3886
- };
3901
+ } | undefined;
3887
3902
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected"> | Omit<{
3888
3903
  eventId: string;
3889
3904
  transactionId: string;
@@ -4018,9 +4033,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4018
4033
  waitFor?: boolean | undefined;
4019
4034
  createdAtLocation?: string | null | undefined;
4020
4035
  type?: "EDIT" | undefined;
4021
- content: {
4022
- comment?: string | undefined;
4023
- };
4024
4036
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected">) & {
4025
4037
  actionId: string;
4026
4038
  };
@@ -4043,18 +4055,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4043
4055
  ctx: Partial<{
4044
4056
  token: `Bearer ${string}`;
4045
4057
  user: {
4046
- id: string & import("zod").$brand<"UUID">;
4047
- type: "system";
4048
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
4049
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
4050
- signature?: undefined;
4051
- } | {
4052
4058
  id: string & import("zod").$brand<"UUID">;
4053
4059
  role: string;
4054
4060
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
4055
4061
  primaryOfficeId: string & import("zod").$brand<"UUID">;
4056
4062
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
4057
4063
  type: "user";
4064
+ } | {
4065
+ id: string & import("zod").$brand<"UUID">;
4066
+ type: "system";
4067
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
4068
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
4069
+ signature?: undefined;
4058
4070
  };
4059
4071
  }>;
4060
4072
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -4188,9 +4200,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4188
4200
  waitFor?: boolean | undefined;
4189
4201
  createdAtLocation?: string | null | undefined;
4190
4202
  type?: "ARCHIVE" | undefined;
4191
- content: {
4203
+ content?: {
4192
4204
  reason: string;
4193
- };
4205
+ } | undefined;
4194
4206
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected"> | Omit<{
4195
4207
  eventId: string;
4196
4208
  transactionId: string;
@@ -4325,9 +4337,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4325
4337
  waitFor?: boolean | undefined;
4326
4338
  createdAtLocation?: string | null | undefined;
4327
4339
  type?: "EDIT" | undefined;
4328
- content: {
4329
- comment?: string | undefined;
4330
- };
4331
4340
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected">) & {
4332
4341
  actionId: string;
4333
4342
  };
@@ -4350,18 +4359,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4350
4359
  ctx: Partial<{
4351
4360
  token: `Bearer ${string}`;
4352
4361
  user: {
4353
- id: string & import("zod").$brand<"UUID">;
4354
- type: "system";
4355
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
4356
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
4357
- signature?: undefined;
4358
- } | {
4359
4362
  id: string & import("zod").$brand<"UUID">;
4360
4363
  role: string;
4361
4364
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
4362
4365
  primaryOfficeId: string & import("zod").$brand<"UUID">;
4363
4366
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
4364
4367
  type: "user";
4368
+ } | {
4369
+ id: string & import("zod").$brand<"UUID">;
4370
+ type: "system";
4371
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
4372
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
4373
+ signature?: undefined;
4365
4374
  };
4366
4375
  }>;
4367
4376
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -4490,9 +4499,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4490
4499
  waitFor?: boolean | undefined;
4491
4500
  createdAtLocation?: string | null | undefined;
4492
4501
  type?: "ARCHIVE" | undefined;
4493
- content: {
4502
+ content?: {
4494
4503
  reason: string;
4495
- };
4504
+ } | undefined;
4496
4505
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected"> | Omit<{
4497
4506
  eventId: string;
4498
4507
  transactionId: string;
@@ -4627,9 +4636,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4627
4636
  waitFor?: boolean | undefined;
4628
4637
  createdAtLocation?: string | null | undefined;
4629
4638
  type?: "EDIT" | undefined;
4630
- content: {
4631
- comment?: string | undefined;
4632
- };
4633
4639
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected">) & {
4634
4640
  actionId: string;
4635
4641
  };
@@ -4763,9 +4769,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4763
4769
  status: "Accepted" | "Rejected" | "Requested";
4764
4770
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
4765
4771
  type: "ARCHIVE";
4766
- content: {
4772
+ content?: {
4767
4773
  reason: string;
4768
- };
4774
+ } | undefined;
4769
4775
  } | {
4770
4776
  id: string & import("zod").$brand<"UUID">;
4771
4777
  transactionId: string;
@@ -4866,7 +4872,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4866
4872
  status: "Accepted" | "Rejected" | "Requested";
4867
4873
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
4868
4874
  type: "APPROVE_CORRECTION";
4869
- requestId: string;
4875
+ requestId: string & import("zod").$brand<"UUID">;
4870
4876
  content?: {
4871
4877
  immediateCorrection?: boolean | undefined;
4872
4878
  } | undefined;
@@ -4884,7 +4890,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4884
4890
  status: "Accepted" | "Rejected" | "Requested";
4885
4891
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
4886
4892
  type: "REJECT_CORRECTION";
4887
- requestId: string;
4893
+ requestId: string & import("zod").$brand<"UUID">;
4888
4894
  content: {
4889
4895
  reason: string;
4890
4896
  };
@@ -4947,9 +4953,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4947
4953
  status: "Accepted" | "Rejected" | "Requested";
4948
4954
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
4949
4955
  type: "EDIT";
4950
- content: {
4956
+ content?: {
4951
4957
  comment?: string | undefined;
4952
- };
4958
+ } | undefined;
4953
4959
  } | {
4954
4960
  id: string & import("zod").$brand<"UUID">;
4955
4961
  transactionId: string;
@@ -4987,18 +4993,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4987
4993
  ctx: Partial<{
4988
4994
  token: `Bearer ${string}`;
4989
4995
  user: {
4990
- id: string & import("zod").$brand<"UUID">;
4991
- type: "system";
4992
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
4993
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
4994
- signature?: undefined;
4995
- } | {
4996
4996
  id: string & import("zod").$brand<"UUID">;
4997
4997
  role: string;
4998
4998
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
4999
4999
  primaryOfficeId: string & import("zod").$brand<"UUID">;
5000
5000
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
5001
5001
  type: "user";
5002
+ } | {
5003
+ id: string & import("zod").$brand<"UUID">;
5004
+ type: "system";
5005
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
5006
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
5007
+ signature?: undefined;
5002
5008
  };
5003
5009
  }>;
5004
5010
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -5025,6 +5031,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5025
5031
  type: string;
5026
5032
  createdAt: string;
5027
5033
  updatedAt: string;
5034
+ trackingId: string;
5028
5035
  actions: ({
5029
5036
  id: string & import("zod").$brand<"UUID">;
5030
5037
  transactionId: string;
@@ -5121,9 +5128,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5121
5128
  status: "Accepted" | "Rejected" | "Requested";
5122
5129
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
5123
5130
  type: "ARCHIVE";
5124
- content: {
5131
+ content?: {
5125
5132
  reason: string;
5126
- };
5133
+ } | undefined;
5127
5134
  } | {
5128
5135
  id: string & import("zod").$brand<"UUID">;
5129
5136
  transactionId: string;
@@ -5224,7 +5231,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5224
5231
  status: "Accepted" | "Rejected" | "Requested";
5225
5232
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
5226
5233
  type: "APPROVE_CORRECTION";
5227
- requestId: string;
5234
+ requestId: string & import("zod").$brand<"UUID">;
5228
5235
  content?: {
5229
5236
  immediateCorrection?: boolean | undefined;
5230
5237
  } | undefined;
@@ -5242,7 +5249,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5242
5249
  status: "Accepted" | "Rejected" | "Requested";
5243
5250
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
5244
5251
  type: "REJECT_CORRECTION";
5245
- requestId: string;
5252
+ requestId: string & import("zod").$brand<"UUID">;
5246
5253
  content: {
5247
5254
  reason: string;
5248
5255
  };
@@ -5305,9 +5312,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5305
5312
  status: "Accepted" | "Rejected" | "Requested";
5306
5313
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
5307
5314
  type: "EDIT";
5308
- content: {
5315
+ content?: {
5309
5316
  comment?: string | undefined;
5310
- };
5317
+ } | undefined;
5311
5318
  } | {
5312
5319
  id: string & import("zod").$brand<"UUID">;
5313
5320
  transactionId: string;
@@ -5336,8 +5343,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5336
5343
  type: "APPROVE_CORRECTION" | "ARCHIVE" | "CUSTOM" | "DECLARE" | "EDIT" | "NOTIFY" | "PRINT_CERTIFICATE" | "REGISTER" | "REJECT" | "REJECT_CORRECTION" | "REQUEST_CORRECTION" | "UNARCHIVE";
5337
5344
  status: "Rejected";
5338
5345
  })[];
5339
- trackingId: string;
5340
- };
5346
+ } & import("zod").$brand<"EventDocumentOnlyLastAction">;
5341
5347
  meta: import("trpc-to-openapi").OpenApiMeta;
5342
5348
  }>;
5343
5349
  unassign: import("@trpc/server").TRPCMutationProcedure<{
@@ -5360,6 +5366,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5360
5366
  type: string;
5361
5367
  createdAt: string;
5362
5368
  updatedAt: string;
5369
+ trackingId: string;
5363
5370
  actions: ({
5364
5371
  id: string & import("zod").$brand<"UUID">;
5365
5372
  transactionId: string;
@@ -5456,9 +5463,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5456
5463
  status: "Accepted" | "Rejected" | "Requested";
5457
5464
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
5458
5465
  type: "ARCHIVE";
5459
- content: {
5466
+ content?: {
5460
5467
  reason: string;
5461
- };
5468
+ } | undefined;
5462
5469
  } | {
5463
5470
  id: string & import("zod").$brand<"UUID">;
5464
5471
  transactionId: string;
@@ -5559,7 +5566,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5559
5566
  status: "Accepted" | "Rejected" | "Requested";
5560
5567
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
5561
5568
  type: "APPROVE_CORRECTION";
5562
- requestId: string;
5569
+ requestId: string & import("zod").$brand<"UUID">;
5563
5570
  content?: {
5564
5571
  immediateCorrection?: boolean | undefined;
5565
5572
  } | undefined;
@@ -5577,7 +5584,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5577
5584
  status: "Accepted" | "Rejected" | "Requested";
5578
5585
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
5579
5586
  type: "REJECT_CORRECTION";
5580
- requestId: string;
5587
+ requestId: string & import("zod").$brand<"UUID">;
5581
5588
  content: {
5582
5589
  reason: string;
5583
5590
  };
@@ -5640,9 +5647,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5640
5647
  status: "Accepted" | "Rejected" | "Requested";
5641
5648
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
5642
5649
  type: "EDIT";
5643
- content: {
5650
+ content?: {
5644
5651
  comment?: string | undefined;
5645
- };
5652
+ } | undefined;
5646
5653
  } | {
5647
5654
  id: string & import("zod").$brand<"UUID">;
5648
5655
  transactionId: string;
@@ -5671,8 +5678,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5671
5678
  type: "APPROVE_CORRECTION" | "ARCHIVE" | "CUSTOM" | "DECLARE" | "EDIT" | "NOTIFY" | "PRINT_CERTIFICATE" | "REGISTER" | "REJECT" | "REJECT_CORRECTION" | "REQUEST_CORRECTION" | "UNARCHIVE";
5672
5679
  status: "Rejected";
5673
5680
  })[];
5674
- trackingId: string;
5675
- };
5681
+ } & import("zod").$brand<"EventDocumentOnlyLastAction">;
5676
5682
  meta: import("trpc-to-openapi").OpenApiMeta;
5677
5683
  }>;
5678
5684
  }>>;
@@ -5680,18 +5686,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5680
5686
  ctx: Partial<{
5681
5687
  token: `Bearer ${string}`;
5682
5688
  user: {
5683
- id: string & import("zod").$brand<"UUID">;
5684
- type: "system";
5685
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
5686
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
5687
- signature?: undefined;
5688
- } | {
5689
5689
  id: string & import("zod").$brand<"UUID">;
5690
5690
  role: string;
5691
5691
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
5692
5692
  primaryOfficeId: string & import("zod").$brand<"UUID">;
5693
5693
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
5694
5694
  type: "user";
5695
+ } | {
5696
+ id: string & import("zod").$brand<"UUID">;
5697
+ type: "system";
5698
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
5699
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
5700
+ signature?: undefined;
5695
5701
  };
5696
5702
  }>;
5697
5703
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -5702,18 +5708,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5702
5708
  ctx: Partial<{
5703
5709
  token: `Bearer ${string}`;
5704
5710
  user: {
5705
- id: string & import("zod").$brand<"UUID">;
5706
- type: "system";
5707
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
5708
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
5709
- signature?: undefined;
5710
- } | {
5711
5711
  id: string & import("zod").$brand<"UUID">;
5712
5712
  role: string;
5713
5713
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
5714
5714
  primaryOfficeId: string & import("zod").$brand<"UUID">;
5715
5715
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
5716
5716
  type: "user";
5717
+ } | {
5718
+ id: string & import("zod").$brand<"UUID">;
5719
+ type: "system";
5720
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
5721
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
5722
+ signature?: undefined;
5717
5723
  };
5718
5724
  }>;
5719
5725
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -5847,9 +5853,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5847
5853
  waitFor?: boolean | undefined;
5848
5854
  createdAtLocation?: string | null | undefined;
5849
5855
  type?: "ARCHIVE" | undefined;
5850
- content: {
5856
+ content?: {
5851
5857
  reason: string;
5852
- };
5858
+ } | undefined;
5853
5859
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected"> | Omit<{
5854
5860
  eventId: string;
5855
5861
  transactionId: string;
@@ -5984,9 +5990,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5984
5990
  waitFor?: boolean | undefined;
5985
5991
  createdAtLocation?: string | null | undefined;
5986
5992
  type?: "EDIT" | undefined;
5987
- content: {
5988
- comment?: string | undefined;
5989
- };
5990
5993
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected">) & {
5991
5994
  actionId: string;
5992
5995
  };
@@ -6009,18 +6012,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
6009
6012
  ctx: Partial<{
6010
6013
  token: `Bearer ${string}`;
6011
6014
  user: {
6012
- id: string & import("zod").$brand<"UUID">;
6013
- type: "system";
6014
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
6015
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
6016
- signature?: undefined;
6017
- } | {
6018
6015
  id: string & import("zod").$brand<"UUID">;
6019
6016
  role: string;
6020
6017
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
6021
6018
  primaryOfficeId: string & import("zod").$brand<"UUID">;
6022
6019
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
6023
6020
  type: "user";
6021
+ } | {
6022
+ id: string & import("zod").$brand<"UUID">;
6023
+ type: "system";
6024
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
6025
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
6026
+ signature?: undefined;
6024
6027
  };
6025
6028
  }>;
6026
6029
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -6154,9 +6157,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
6154
6157
  waitFor?: boolean | undefined;
6155
6158
  createdAtLocation?: string | null | undefined;
6156
6159
  type?: "ARCHIVE" | undefined;
6157
- content: {
6160
+ content?: {
6158
6161
  reason: string;
6159
- };
6162
+ } | undefined;
6160
6163
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected"> | Omit<{
6161
6164
  eventId: string;
6162
6165
  transactionId: string;
@@ -6291,9 +6294,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
6291
6294
  waitFor?: boolean | undefined;
6292
6295
  createdAtLocation?: string | null | undefined;
6293
6296
  type?: "EDIT" | undefined;
6294
- content: {
6295
- comment?: string | undefined;
6296
- };
6297
6297
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected">) & {
6298
6298
  actionId: string;
6299
6299
  };
@@ -6316,18 +6316,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
6316
6316
  ctx: Partial<{
6317
6317
  token: `Bearer ${string}`;
6318
6318
  user: {
6319
- id: string & import("zod").$brand<"UUID">;
6320
- type: "system";
6321
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
6322
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
6323
- signature?: undefined;
6324
- } | {
6325
6319
  id: string & import("zod").$brand<"UUID">;
6326
6320
  role: string;
6327
6321
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
6328
6322
  primaryOfficeId: string & import("zod").$brand<"UUID">;
6329
6323
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
6330
6324
  type: "user";
6325
+ } | {
6326
+ id: string & import("zod").$brand<"UUID">;
6327
+ type: "system";
6328
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
6329
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
6330
+ signature?: undefined;
6331
6331
  };
6332
6332
  }>;
6333
6333
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -6461,9 +6461,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
6461
6461
  waitFor?: boolean | undefined;
6462
6462
  createdAtLocation?: string | null | undefined;
6463
6463
  type?: "ARCHIVE" | undefined;
6464
- content: {
6464
+ content?: {
6465
6465
  reason: string;
6466
- };
6466
+ } | undefined;
6467
6467
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected"> | Omit<{
6468
6468
  eventId: string;
6469
6469
  transactionId: string;
@@ -6598,9 +6598,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
6598
6598
  waitFor?: boolean | undefined;
6599
6599
  createdAtLocation?: string | null | undefined;
6600
6600
  type?: "EDIT" | undefined;
6601
- content: {
6602
- comment?: string | undefined;
6603
- };
6604
6601
  }, "keepAssignmentIfAccepted" | "keepAssignmentIfRejected">) & {
6605
6602
  actionId: string;
6606
6603
  };
@@ -6624,18 +6621,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
6624
6621
  ctx: Partial<{
6625
6622
  token: `Bearer ${string}`;
6626
6623
  user: {
6627
- id: string & import("zod").$brand<"UUID">;
6628
- type: "system";
6629
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
6630
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
6631
- signature?: undefined;
6632
- } | {
6633
6624
  id: string & import("zod").$brand<"UUID">;
6634
6625
  role: string;
6635
6626
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
6636
6627
  primaryOfficeId: string & import("zod").$brand<"UUID">;
6637
6628
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
6638
6629
  type: "user";
6630
+ } | {
6631
+ id: string & import("zod").$brand<"UUID">;
6632
+ type: "system";
6633
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
6634
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
6635
+ signature?: undefined;
6639
6636
  };
6640
6637
  }>;
6641
6638
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -6760,9 +6757,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
6760
6757
  status: "Accepted" | "Rejected" | "Requested";
6761
6758
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
6762
6759
  type: "ARCHIVE";
6763
- content: {
6760
+ content?: {
6764
6761
  reason: string;
6765
- };
6762
+ } | undefined;
6766
6763
  } | {
6767
6764
  id: string & import("zod").$brand<"UUID">;
6768
6765
  transactionId: string;
@@ -6863,7 +6860,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
6863
6860
  status: "Accepted" | "Rejected" | "Requested";
6864
6861
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
6865
6862
  type: "APPROVE_CORRECTION";
6866
- requestId: string;
6863
+ requestId: string & import("zod").$brand<"UUID">;
6867
6864
  content?: {
6868
6865
  immediateCorrection?: boolean | undefined;
6869
6866
  } | undefined;
@@ -6881,7 +6878,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
6881
6878
  status: "Accepted" | "Rejected" | "Requested";
6882
6879
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
6883
6880
  type: "REJECT_CORRECTION";
6884
- requestId: string;
6881
+ requestId: string & import("zod").$brand<"UUID">;
6885
6882
  content: {
6886
6883
  reason: string;
6887
6884
  };
@@ -6944,9 +6941,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
6944
6941
  status: "Accepted" | "Rejected" | "Requested";
6945
6942
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
6946
6943
  type: "EDIT";
6947
- content: {
6944
+ content?: {
6948
6945
  comment?: string | undefined;
6949
- };
6946
+ } | undefined;
6950
6947
  } | {
6951
6948
  id: string & import("zod").$brand<"UUID">;
6952
6949
  transactionId: string;
@@ -7094,9 +7091,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
7094
7091
  status: "Accepted" | "Rejected" | "Requested";
7095
7092
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
7096
7093
  type: "ARCHIVE";
7097
- content: {
7094
+ content?: {
7098
7095
  reason: string;
7099
- };
7096
+ } | undefined;
7100
7097
  } | {
7101
7098
  id: string & import("zod").$brand<"UUID">;
7102
7099
  transactionId: string;
@@ -7197,7 +7194,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
7197
7194
  status: "Accepted" | "Rejected" | "Requested";
7198
7195
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
7199
7196
  type: "APPROVE_CORRECTION";
7200
- requestId: string;
7197
+ requestId: string & import("zod").$brand<"UUID">;
7201
7198
  content?: {
7202
7199
  immediateCorrection?: boolean | undefined;
7203
7200
  } | undefined;
@@ -7215,7 +7212,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
7215
7212
  status: "Accepted" | "Rejected" | "Requested";
7216
7213
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
7217
7214
  type: "REJECT_CORRECTION";
7218
- requestId: string;
7215
+ requestId: string & import("zod").$brand<"UUID">;
7219
7216
  content: {
7220
7217
  reason: string;
7221
7218
  };
@@ -7278,9 +7275,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
7278
7275
  status: "Accepted" | "Rejected" | "Requested";
7279
7276
  originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
7280
7277
  type: "EDIT";
7281
- content: {
7278
+ content?: {
7282
7279
  comment?: string | undefined;
7283
- };
7280
+ } | undefined;
7284
7281
  } | {
7285
7282
  id: string & import("zod").$brand<"UUID">;
7286
7283
  transactionId: string;
@@ -7479,9 +7476,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
7479
7476
  status: "Accepted" | "Rejected" | "Requested";
7480
7477
  originalActionId?: string | null | undefined;
7481
7478
  type: "ARCHIVE";
7482
- content: {
7479
+ content?: {
7483
7480
  reason: string;
7484
- };
7481
+ } | undefined;
7485
7482
  } | {
7486
7483
  id: string;
7487
7484
  transactionId: string;
@@ -7663,9 +7660,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
7663
7660
  status: "Accepted" | "Rejected" | "Requested";
7664
7661
  originalActionId?: string | null | undefined;
7665
7662
  type: "EDIT";
7666
- content: {
7663
+ content?: {
7667
7664
  comment?: string | undefined;
7668
- };
7665
+ } | undefined;
7669
7666
  } | {
7670
7667
  id: string;
7671
7668
  transactionId: string;
@@ -7704,18 +7701,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
7704
7701
  ctx: Partial<{
7705
7702
  token: `Bearer ${string}`;
7706
7703
  user: {
7707
- id: string & import("zod").$brand<"UUID">;
7708
- type: "system";
7709
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
7710
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
7711
- signature?: undefined;
7712
- } | {
7713
7704
  id: string & import("zod").$brand<"UUID">;
7714
7705
  role: string;
7715
7706
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
7716
7707
  primaryOfficeId: string & import("zod").$brand<"UUID">;
7717
7708
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
7718
7709
  type: "user";
7710
+ } | {
7711
+ id: string & import("zod").$brand<"UUID">;
7712
+ type: "system";
7713
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
7714
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
7715
+ signature?: undefined;
7719
7716
  };
7720
7717
  }>;
7721
7718
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -7870,8 +7867,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
7870
7867
  email?: string | undefined;
7871
7868
  status?: string | undefined;
7872
7869
  primaryOfficeId?: string | undefined;
7873
- count: number;
7874
- skip: number;
7870
+ count?: number | undefined;
7871
+ skip?: number | undefined;
7875
7872
  sortBy?: "createdAt" | "email" | "firstname" | "role" | "status" | "surname" | "username" | undefined;
7876
7873
  sortOrder: "asc" | "desc";
7877
7874
  };
@@ -7898,60 +7895,22 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
7898
7895
  })[];
7899
7896
  meta: object;
7900
7897
  }>;
7901
- actions: import("@trpc/server").TRPCQueryProcedure<{
7902
- input: {
7903
- userId: string;
7904
- skip?: number | undefined;
7905
- count?: number | undefined;
7906
- timeStart?: string | undefined;
7907
- timeEnd?: string | undefined;
7908
- actionTypes?: ("APPROVE_CORRECTION" | "ARCHIVE" | "ASSIGN" | "CREATE" | "CUSTOM" | "DECLARE" | "DUPLICATE_DETECTED" | "EDIT" | "MARK_AS_DUPLICATE" | "MARK_AS_NOT_DUPLICATE" | "NOTIFY" | "PRINT_CERTIFICATE" | "READ" | "REGISTER" | "REJECT" | "REJECT_CORRECTION" | "REQUEST_CORRECTION" | "UNARCHIVE" | "UNASSIGN")[] | undefined;
7909
- };
7910
- output: {
7911
- results: {
7912
- actionType: string;
7913
- annotation: Record<string, any> | null;
7914
- assignedTo: string | null;
7915
- content: Record<string, any> | null;
7916
- createdAt: string | null;
7917
- createdAtLocation: (string & import("zod").$brand<"UUID">) | null;
7918
- createdBy: string;
7919
- createdByRole: string | null;
7920
- createdBySignature: string | null;
7921
- createdByUserType: import("../storage/postgres/events/schema/app/UserType").default;
7922
- customActionType: string | null;
7923
- declaration: Record<string, any>;
7924
- eventId: string & import("zod").$brand<"UUID">;
7925
- eventType: string | null;
7926
- id: (string & import("zod").$brand<"UUID">) | null;
7927
- originalActionId: (string & import("zod").$brand<"UUID">) | null;
7928
- registrationNumber: string | null;
7929
- requestId: string | null;
7930
- status: import("../storage/postgres/events/schema/app/ActionStatus").default;
7931
- trackingId: string | null;
7932
- transactionId: string | null;
7933
- updatedAt: string | null;
7934
- }[];
7935
- total: number;
7936
- };
7937
- meta: import("trpc-to-openapi").OpenApiMeta;
7938
- }>;
7939
7898
  roles: import("@trpc/server").TRPCBuiltRouter<{
7940
7899
  ctx: Partial<{
7941
7900
  token: `Bearer ${string}`;
7942
7901
  user: {
7943
- id: string & import("zod").$brand<"UUID">;
7944
- type: "system";
7945
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
7946
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
7947
- signature?: undefined;
7948
- } | {
7949
7902
  id: string & import("zod").$brand<"UUID">;
7950
7903
  role: string;
7951
7904
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
7952
7905
  primaryOfficeId: string & import("zod").$brand<"UUID">;
7953
7906
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
7954
7907
  type: "user";
7908
+ } | {
7909
+ id: string & import("zod").$brand<"UUID">;
7910
+ type: "system";
7911
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
7912
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
7913
+ signature?: undefined;
7955
7914
  };
7956
7915
  }>;
7957
7916
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -8064,64 +8023,24 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8064
8023
  ctx: Partial<{
8065
8024
  token: `Bearer ${string}`;
8066
8025
  user: {
8067
- id: string & import("zod").$brand<"UUID">;
8068
- type: "system";
8069
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
8070
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
8071
- signature?: undefined;
8072
- } | {
8073
8026
  id: string & import("zod").$brand<"UUID">;
8074
8027
  role: string;
8075
8028
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
8076
8029
  primaryOfficeId: string & import("zod").$brand<"UUID">;
8077
8030
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
8078
8031
  type: "user";
8032
+ } | {
8033
+ id: string & import("zod").$brand<"UUID">;
8034
+ type: "system";
8035
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
8036
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
8037
+ signature?: undefined;
8079
8038
  };
8080
8039
  }>;
8081
8040
  meta: import("trpc-to-openapi").OpenApiMeta;
8082
8041
  errorShape: import("@trpc/server").TRPCDefaultErrorShape;
8083
8042
  transformer: true;
8084
8043
  }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
8085
- record: import("@trpc/server").TRPCMutationProcedure<{
8086
- input: {
8087
- operation: "user.create_user";
8088
- requestData: {
8089
- subjectId: string;
8090
- role: string;
8091
- primaryOfficeId: string;
8092
- };
8093
- } | {
8094
- operation: "user.deactivate" | "user.reactivate";
8095
- requestData: {
8096
- subjectId: string;
8097
- reason: string;
8098
- comment?: string | undefined;
8099
- };
8100
- } | {
8101
- operation: "user.edit_user" | "user.logged_in" | "user.logged_out" | "user.password_changed" | "user.password_reset" | "user.password_reset_by_admin" | "user.resend_invite" | "user.username_reminder" | "user.username_reminder_by_admin";
8102
- requestData: {
8103
- subjectId: string;
8104
- };
8105
- } | {
8106
- operation: "user.email_address_changed";
8107
- requestData: {
8108
- subjectId: string;
8109
- };
8110
- responseSummary: {
8111
- email: string;
8112
- };
8113
- } | {
8114
- operation: "user.phone_number_changed";
8115
- requestData: {
8116
- subjectId: string;
8117
- };
8118
- responseSummary: {
8119
- phoneNumber: string;
8120
- };
8121
- };
8122
- output: void;
8123
- meta: import("trpc-to-openapi").OpenApiMeta;
8124
- }>;
8125
8044
  list: import("@trpc/server").TRPCQueryProcedure<{
8126
8045
  input: {
8127
8046
  userId: string;
@@ -8278,6 +8197,135 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8278
8197
  responseSummary: {
8279
8198
  clientId: string;
8280
8199
  };
8200
+ } | {
8201
+ id: string;
8202
+ clientId: string;
8203
+ clientType: "system" | "user";
8204
+ createdAt: string;
8205
+ operation: "locations.create";
8206
+ requestData: {
8207
+ id: string;
8208
+ versionId: string;
8209
+ name: string;
8210
+ externalId?: string | null | undefined;
8211
+ effectiveFrom: string;
8212
+ status: string;
8213
+ administrativeAreaId?: string | null | undefined;
8214
+ locationType?: string | null | undefined;
8215
+ };
8216
+ } | {
8217
+ id: string;
8218
+ clientId: string;
8219
+ clientType: "system" | "user";
8220
+ createdAt: string;
8221
+ operation: "locations.update";
8222
+ requestData: {
8223
+ id: string;
8224
+ versionId: string;
8225
+ name: string;
8226
+ externalId?: string | null | undefined;
8227
+ status: string;
8228
+ effectiveFrom: string;
8229
+ lastVersionId: string;
8230
+ };
8231
+ responseSummary: {
8232
+ previousVersionId: string;
8233
+ versionId: string;
8234
+ changed: {
8235
+ name?: {
8236
+ from: string;
8237
+ to: string;
8238
+ } | undefined;
8239
+ externalId?: {
8240
+ from: string | null;
8241
+ to: string | null;
8242
+ } | undefined;
8243
+ status?: {
8244
+ from: string;
8245
+ to: string;
8246
+ } | undefined;
8247
+ };
8248
+ };
8249
+ } | {
8250
+ id: string;
8251
+ clientId: string;
8252
+ clientType: "system" | "user";
8253
+ createdAt: string;
8254
+ operation: "administrativeAreas.update";
8255
+ requestData: {
8256
+ id: string;
8257
+ versionId: string;
8258
+ name: string;
8259
+ externalId?: string | null | undefined;
8260
+ status: string;
8261
+ effectiveFrom: string;
8262
+ lastVersionId: string;
8263
+ };
8264
+ responseSummary: {
8265
+ previousVersionId: string;
8266
+ versionId: string;
8267
+ changed: {
8268
+ name?: {
8269
+ from: string;
8270
+ to: string;
8271
+ } | undefined;
8272
+ externalId?: {
8273
+ from: string | null;
8274
+ to: string | null;
8275
+ } | undefined;
8276
+ status?: {
8277
+ from: string;
8278
+ to: string;
8279
+ } | undefined;
8280
+ };
8281
+ };
8282
+ } | {
8283
+ id: string;
8284
+ clientId: string;
8285
+ clientType: "system" | "user";
8286
+ createdAt: string;
8287
+ operation: "locations.withdrawVersion";
8288
+ requestData: {
8289
+ id: string;
8290
+ versionId: string;
8291
+ };
8292
+ responseSummary: {
8293
+ effectiveFrom: string;
8294
+ name: string;
8295
+ externalId?: string | null | undefined;
8296
+ status: string;
8297
+ };
8298
+ } | {
8299
+ id: string;
8300
+ clientId: string;
8301
+ clientType: "system" | "user";
8302
+ createdAt: string;
8303
+ operation: "administrativeAreas.withdrawVersion";
8304
+ requestData: {
8305
+ id: string;
8306
+ versionId: string;
8307
+ };
8308
+ responseSummary: {
8309
+ effectiveFrom: string;
8310
+ name: string;
8311
+ externalId?: string | null | undefined;
8312
+ status: string;
8313
+ };
8314
+ } | {
8315
+ id: string;
8316
+ clientId: string;
8317
+ clientType: "system" | "user";
8318
+ createdAt: string;
8319
+ operation: "administrativeAreas.create";
8320
+ requestData: {
8321
+ id: string;
8322
+ versionId: string;
8323
+ name: string;
8324
+ externalId?: string | null | undefined;
8325
+ effectiveFrom: string;
8326
+ status: string;
8327
+ parentId?: string | null | undefined;
8328
+ };
8281
8329
  } | {
8282
8330
  id: string;
8283
8331
  clientId: string;
@@ -8286,6 +8334,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8286
8334
  operation: "attachments.upload";
8287
8335
  requestData: {
8288
8336
  transactionId: string;
8337
+ eventId?: string | undefined;
8289
8338
  path: string | null;
8290
8339
  };
8291
8340
  responseSummary: {
@@ -8357,18 +8406,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8357
8406
  ctx: Partial<{
8358
8407
  token: `Bearer ${string}`;
8359
8408
  user: {
8360
- id: string & import("zod").$brand<"UUID">;
8361
- type: "system";
8362
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
8363
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
8364
- signature?: undefined;
8365
- } | {
8366
8409
  id: string & import("zod").$brand<"UUID">;
8367
8410
  role: string;
8368
8411
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
8369
8412
  primaryOfficeId: string & import("zod").$brand<"UUID">;
8370
8413
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
8371
8414
  type: "user";
8415
+ } | {
8416
+ id: string & import("zod").$brand<"UUID">;
8417
+ type: "system";
8418
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
8419
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
8420
+ signature?: undefined;
8372
8421
  };
8373
8422
  }>;
8374
8423
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -8387,22 +8436,94 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8387
8436
  name: string;
8388
8437
  externalId?: string | null | undefined;
8389
8438
  administrativeAreaId: (string & import("zod").$brand<"UUID">) | null;
8390
- validUntil: string | null;
8391
8439
  locationType: string | null;
8440
+ status: "active" | "inactive";
8441
+ versions: {
8442
+ versionId: string & import("zod").$brand<"UUID">;
8443
+ effectiveFrom: string;
8444
+ name: string;
8445
+ externalId?: string | null | undefined;
8446
+ status: "active" | "inactive";
8447
+ }[];
8392
8448
  }[];
8393
8449
  meta: object;
8394
8450
  }>;
8395
- set: import("@trpc/server").TRPCMutationProcedure<{
8451
+ create: import("@trpc/server").TRPCMutationProcedure<{
8396
8452
  input: {
8397
- id: string;
8453
+ id?: string | undefined;
8454
+ versionId?: string | undefined;
8398
8455
  name: string;
8399
8456
  externalId?: string | null | undefined;
8400
8457
  administrativeAreaId: string | null;
8401
- validUntil: string | null;
8402
8458
  locationType: string | null;
8403
- }[];
8404
- output: void;
8405
- meta: object;
8459
+ effectiveFrom?: string | undefined;
8460
+ status?: "active" | "inactive" | undefined;
8461
+ };
8462
+ output: {
8463
+ id: string & import("zod").$brand<"UUID">;
8464
+ name: string;
8465
+ externalId?: string | null | undefined;
8466
+ administrativeAreaId: (string & import("zod").$brand<"UUID">) | null;
8467
+ locationType: string | null;
8468
+ status: "active" | "inactive";
8469
+ versions: {
8470
+ versionId: string & import("zod").$brand<"UUID">;
8471
+ effectiveFrom: string;
8472
+ name: string;
8473
+ externalId?: string | null | undefined;
8474
+ status: "active" | "inactive";
8475
+ }[];
8476
+ };
8477
+ meta: import("trpc-to-openapi").OpenApiMeta;
8478
+ }>;
8479
+ update: import("@trpc/server").TRPCMutationProcedure<{
8480
+ input: {
8481
+ id: string;
8482
+ versionId?: string | undefined;
8483
+ name: string;
8484
+ externalId?: string | null | undefined;
8485
+ status: "active" | "inactive";
8486
+ effectiveFrom?: string | undefined;
8487
+ lastVersionId: string;
8488
+ };
8489
+ output: {
8490
+ id: string & import("zod").$brand<"UUID">;
8491
+ name: string;
8492
+ externalId?: string | null | undefined;
8493
+ administrativeAreaId: (string & import("zod").$brand<"UUID">) | null;
8494
+ locationType: string | null;
8495
+ status: "active" | "inactive";
8496
+ versions: {
8497
+ versionId: string & import("zod").$brand<"UUID">;
8498
+ effectiveFrom: string;
8499
+ name: string;
8500
+ externalId?: string | null | undefined;
8501
+ status: "active" | "inactive";
8502
+ }[];
8503
+ };
8504
+ meta: import("trpc-to-openapi").OpenApiMeta;
8505
+ }>;
8506
+ withdrawVersion: import("@trpc/server").TRPCMutationProcedure<{
8507
+ input: {
8508
+ id: string;
8509
+ versionId: string;
8510
+ };
8511
+ output: {
8512
+ id: string & import("zod").$brand<"UUID">;
8513
+ name: string;
8514
+ externalId?: string | null | undefined;
8515
+ administrativeAreaId: (string & import("zod").$brand<"UUID">) | null;
8516
+ locationType: string | null;
8517
+ status: "active" | "inactive";
8518
+ versions: {
8519
+ versionId: string & import("zod").$brand<"UUID">;
8520
+ effectiveFrom: string;
8521
+ name: string;
8522
+ externalId?: string | null | undefined;
8523
+ status: "active" | "inactive";
8524
+ }[];
8525
+ };
8526
+ meta: import("trpc-to-openapi").OpenApiMeta;
8406
8527
  }>;
8407
8528
  get: import("@trpc/server").TRPCQueryProcedure<{
8408
8529
  input: {
@@ -8413,8 +8534,15 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8413
8534
  name: string;
8414
8535
  externalId?: string | null | undefined;
8415
8536
  administrativeAreaId: (string & import("zod").$brand<"UUID">) | null;
8416
- validUntil: string | null;
8417
8537
  locationType: string | null;
8538
+ status: "active" | "inactive";
8539
+ versions: {
8540
+ versionId: string & import("zod").$brand<"UUID">;
8541
+ effectiveFrom: string;
8542
+ name: string;
8543
+ externalId?: string | null | undefined;
8544
+ status: "active" | "inactive";
8545
+ }[];
8418
8546
  };
8419
8547
  meta: import("trpc-to-openapi").OpenApiMeta;
8420
8548
  }>;
@@ -8430,18 +8558,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8430
8558
  ctx: Partial<{
8431
8559
  token: `Bearer ${string}`;
8432
8560
  user: {
8433
- id: string & import("zod").$brand<"UUID">;
8434
- type: "system";
8435
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
8436
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
8437
- signature?: undefined;
8438
- } | {
8439
8561
  id: string & import("zod").$brand<"UUID">;
8440
8562
  role: string;
8441
8563
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
8442
8564
  primaryOfficeId: string & import("zod").$brand<"UUID">;
8443
8565
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
8444
8566
  type: "user";
8567
+ } | {
8568
+ id: string & import("zod").$brand<"UUID">;
8569
+ type: "system";
8570
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
8571
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
8572
+ signature?: undefined;
8445
8573
  };
8446
8574
  }>;
8447
8575
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -8452,18 +8580,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8452
8580
  ctx: Partial<{
8453
8581
  token: `Bearer ${string}`;
8454
8582
  user: {
8455
- id: string & import("zod").$brand<"UUID">;
8456
- type: "system";
8457
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
8458
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
8459
- signature?: undefined;
8460
- } | {
8461
8583
  id: string & import("zod").$brand<"UUID">;
8462
8584
  role: string;
8463
8585
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
8464
8586
  primaryOfficeId: string & import("zod").$brand<"UUID">;
8465
8587
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
8466
8588
  type: "user";
8589
+ } | {
8590
+ id: string & import("zod").$brand<"UUID">;
8591
+ type: "system";
8592
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
8593
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
8594
+ signature?: undefined;
8467
8595
  };
8468
8596
  }>;
8469
8597
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -8771,7 +8899,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8771
8899
  $event: "assignedTo" | "createdAt" | "createdAtLocation" | "createdBy" | "createdByUserType" | "dateOfEvent" | "flags" | "id" | "legalStatuses" | "outbox" | "placeOfEvent" | "status" | "title" | "trackingId" | "type" | "updatedAt" | "updatedAtLocation" | "updatedBy" | "updatedByUserRole";
8772
8900
  };
8773
8901
  }[];
8774
- icon: "Activity" | "Archive" | "ArchiveBox" | "ArchiveTray" | "Archived" | "ArrowCircleDown" | "ArrowCounterClockwise" | "ArrowLeft" | "ArrowRight" | "Assigned" | "Briefcase" | "Buildings" | "CaretDown" | "CaretLeft" | "CaretRight" | "Certified" | "ChartActivity" | "ChartBar" | "ChartLine" | "ChatCircle" | "ChatText" | "Check" | "CheckSquare" | "Circle" | "CircleWavyCheck" | "CircleWavyQuestion" | "Clock" | "Close" | "Collapse" | "Compass" | "Copy" | "Database" | "DeviceTabletCamera" | "DotsThreeVertical" | "Draft" | "DuplicateYellow" | "Envelope" | "Expand" | "Export" | "ExternalValidate" | "Eye" | "EyeSlash" | "File" | "FileArrowUp" | "FileDotted" | "FileMinus" | "FilePlus" | "FileSearch" | "FileText" | "FileX" | "Files" | "FilledCheck" | "Fingerprint" | "Gear" | "GitBranch" | "Globe" | "Handshake" | "IdentificationCard" | "InReview" | "List" | "ListBullets" | "Lock" | "MagnifyingGlass" | "MagnifyingGlassMinus" | "MagnifyingGlassPlus" | "MapPin" | "Medal" | "NotePencil" | "Offline" | "PaperPlaneTilt" | "Paperclip" | "Pen" | "PenNib" | "Pencil" | "PencilCircle" | "PencilLine" | "PencilSimpleLine" | "Phone" | "Plus" | "Printer" | "PushPin" | "QrCode" | "Registered" | "RequiresUpdates" | "Sent" | "SignOut" | "Stamp" | "Star" | "Sun" | "Target" | "TextT" | "Timer" | "Trash" | "UploadSimple" | "User" | "UserCircle" | "UserPlus" | "Users" | "Validated" | "WaitingApproval" | "WarningCircle" | "Webcam" | "X";
8902
+ icon: "Activity" | "Archive" | "ArchiveBox" | "ArchiveTray" | "Archived" | "ArrowCircleDown" | "ArrowCounterClockwise" | "ArrowLeft" | "ArrowRight" | "Assigned" | "Briefcase" | "Buildings" | "CaretDown" | "CaretLeft" | "CaretRight" | "Certified" | "ChartActivity" | "ChartBar" | "ChartLine" | "ChatCircle" | "ChatText" | "Check" | "CheckSquare" | "Circle" | "CircleWavyCheck" | "CircleWavyQuestion" | "Clock" | "Close" | "Collapse" | "Compass" | "Copy" | "Database" | "DeviceTabletCamera" | "DotsThreeVertical" | "Draft" | "DuplicateYellow" | "Envelope" | "Expand" | "Export" | "ExternalValidate" | "Eye" | "EyeSlash" | "File" | "FileArrowUp" | "FileDotted" | "FileLock" | "FileMinus" | "FilePlus" | "FileSearch" | "FileText" | "FileX" | "Files" | "FilledCheck" | "Fingerprint" | "Gear" | "GitBranch" | "Globe" | "Handshake" | "IdentificationCard" | "InReview" | "List" | "ListBullets" | "Lock" | "MagnifyingGlass" | "MagnifyingGlassMinus" | "MagnifyingGlassPlus" | "MapPin" | "Medal" | "NotePencil" | "Offline" | "PaperPlaneTilt" | "Paperclip" | "Pen" | "PenNib" | "Pencil" | "PencilCircle" | "PencilLine" | "PencilSimpleLine" | "Phone" | "Plus" | "Printer" | "PushPin" | "QrCode" | "Registered" | "RequiresUpdates" | "Sent" | "SignOut" | "Stamp" | "Star" | "Sun" | "Target" | "TextT" | "Timer" | "Trash" | "UploadSimple" | "User" | "UserCircle" | "UserPlus" | "Users" | "Validated" | "WaitingApproval" | "WarningCircle" | "Webcam" | "X";
8775
8903
  emptyMessage?: {
8776
8904
  id: string;
8777
8905
  defaultMessage: string;
@@ -8794,18 +8922,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8794
8922
  ctx: Partial<{
8795
8923
  token: `Bearer ${string}`;
8796
8924
  user: {
8797
- id: string & import("zod").$brand<"UUID">;
8798
- type: "system";
8799
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
8800
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
8801
- signature?: undefined;
8802
- } | {
8803
8925
  id: string & import("zod").$brand<"UUID">;
8804
8926
  role: string;
8805
8927
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
8806
8928
  primaryOfficeId: string & import("zod").$brand<"UUID">;
8807
8929
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
8808
8930
  type: "user";
8931
+ } | {
8932
+ id: string & import("zod").$brand<"UUID">;
8933
+ type: "system";
8934
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
8935
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
8936
+ signature?: undefined;
8809
8937
  };
8810
8938
  }>;
8811
8939
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -8822,38 +8950,107 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8822
8950
  name: string;
8823
8951
  externalId?: string | null | undefined;
8824
8952
  parentId: (string & import("zod").$brand<"UUID">) | null;
8825
- validUntil: string | null;
8953
+ status: "active" | "inactive";
8954
+ versions: {
8955
+ versionId: string & import("zod").$brand<"UUID">;
8956
+ effectiveFrom: string;
8957
+ name: string;
8958
+ externalId?: string | null | undefined;
8959
+ status: "active" | "inactive";
8960
+ }[];
8826
8961
  }[];
8827
8962
  meta: import("trpc-to-openapi").OpenApiMeta;
8828
8963
  }>;
8829
- set: import("@trpc/server").TRPCMutationProcedure<{
8964
+ create: import("@trpc/server").TRPCMutationProcedure<{
8830
8965
  input: {
8831
- id: string;
8966
+ id?: string | undefined;
8967
+ versionId?: string | undefined;
8832
8968
  name: string;
8833
8969
  externalId?: string | null | undefined;
8834
8970
  parentId: string | null;
8835
- validUntil: string | null;
8836
- }[];
8837
- output: void;
8838
- meta: object;
8971
+ effectiveFrom?: string | undefined;
8972
+ status?: "active" | "inactive" | undefined;
8973
+ };
8974
+ output: {
8975
+ id: string & import("zod").$brand<"UUID">;
8976
+ name: string;
8977
+ externalId?: string | null | undefined;
8978
+ parentId: (string & import("zod").$brand<"UUID">) | null;
8979
+ status: "active" | "inactive";
8980
+ versions: {
8981
+ versionId: string & import("zod").$brand<"UUID">;
8982
+ effectiveFrom: string;
8983
+ name: string;
8984
+ externalId?: string | null | undefined;
8985
+ status: "active" | "inactive";
8986
+ }[];
8987
+ };
8988
+ meta: import("trpc-to-openapi").OpenApiMeta;
8839
8989
  }>;
8840
- }>>;
8841
- integrations: import("@trpc/server").TRPCBuiltRouter<{
8842
- ctx: Partial<{
8843
- token: `Bearer ${string}`;
8844
- user: {
8990
+ update: import("@trpc/server").TRPCMutationProcedure<{
8991
+ input: {
8992
+ id: string;
8993
+ versionId?: string | undefined;
8994
+ name: string;
8995
+ externalId?: string | null | undefined;
8996
+ status: "active" | "inactive";
8997
+ effectiveFrom?: string | undefined;
8998
+ lastVersionId: string;
8999
+ };
9000
+ output: {
8845
9001
  id: string & import("zod").$brand<"UUID">;
8846
- type: "system";
8847
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
8848
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
8849
- signature?: undefined;
8850
- } | {
9002
+ name: string;
9003
+ externalId?: string | null | undefined;
9004
+ parentId: (string & import("zod").$brand<"UUID">) | null;
9005
+ status: "active" | "inactive";
9006
+ versions: {
9007
+ versionId: string & import("zod").$brand<"UUID">;
9008
+ effectiveFrom: string;
9009
+ name: string;
9010
+ externalId?: string | null | undefined;
9011
+ status: "active" | "inactive";
9012
+ }[];
9013
+ };
9014
+ meta: import("trpc-to-openapi").OpenApiMeta;
9015
+ }>;
9016
+ withdrawVersion: import("@trpc/server").TRPCMutationProcedure<{
9017
+ input: {
9018
+ id: string;
9019
+ versionId: string;
9020
+ };
9021
+ output: {
9022
+ id: string & import("zod").$brand<"UUID">;
9023
+ name: string;
9024
+ externalId?: string | null | undefined;
9025
+ parentId: (string & import("zod").$brand<"UUID">) | null;
9026
+ status: "active" | "inactive";
9027
+ versions: {
9028
+ versionId: string & import("zod").$brand<"UUID">;
9029
+ effectiveFrom: string;
9030
+ name: string;
9031
+ externalId?: string | null | undefined;
9032
+ status: "active" | "inactive";
9033
+ }[];
9034
+ };
9035
+ meta: import("trpc-to-openapi").OpenApiMeta;
9036
+ }>;
9037
+ }>>;
9038
+ integrations: import("@trpc/server").TRPCBuiltRouter<{
9039
+ ctx: Partial<{
9040
+ token: `Bearer ${string}`;
9041
+ user: {
8851
9042
  id: string & import("zod").$brand<"UUID">;
8852
9043
  role: string;
8853
9044
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
8854
9045
  primaryOfficeId: string & import("zod").$brand<"UUID">;
8855
9046
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
8856
9047
  type: "user";
9048
+ } | {
9049
+ id: string & import("zod").$brand<"UUID">;
9050
+ type: "system";
9051
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
9052
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
9053
+ signature?: undefined;
8857
9054
  };
8858
9055
  }>;
8859
9056
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -8864,6 +9061,10 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8864
9061
  input: {
8865
9062
  name: string;
8866
9063
  scopes: string[];
9064
+ credentials?: {
9065
+ clientId: string;
9066
+ clientSecret: string;
9067
+ } | undefined;
8867
9068
  };
8868
9069
  output: {
8869
9070
  clientId: string;
@@ -8894,7 +9095,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8894
9095
  scopes: string[];
8895
9096
  status: string;
8896
9097
  createdAt: string;
8897
- createdBy: string & import("zod").$brand<"UUID">;
9098
+ createdBy: (string & import("zod").$brand<"UUID">) | null;
8898
9099
  }[];
8899
9100
  meta: import("trpc-to-openapi").OpenApiMeta;
8900
9101
  }>;
@@ -8909,7 +9110,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8909
9110
  status: string;
8910
9111
  shaSecret: string | null;
8911
9112
  createdAt: string;
8912
- createdBy: string & import("zod").$brand<"UUID">;
9113
+ createdBy: (string & import("zod").$brand<"UUID">) | null;
8913
9114
  };
8914
9115
  meta: import("trpc-to-openapi").OpenApiMeta;
8915
9116
  }>;
@@ -8955,23 +9156,381 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8955
9156
  };
8956
9157
  meta: import("trpc-to-openapi").OpenApiMeta;
8957
9158
  }>;
9159
+ audit: import("@trpc/server").TRPCQueryProcedure<{
9160
+ input: {
9161
+ id: string;
9162
+ skip?: number | undefined;
9163
+ count?: number | undefined;
9164
+ timeStart?: string | undefined;
9165
+ timeEnd?: string | undefined;
9166
+ };
9167
+ output: {
9168
+ results: ({
9169
+ id: string;
9170
+ clientId: string;
9171
+ clientType: "system" | "user";
9172
+ createdAt: string;
9173
+ operation: "event.create";
9174
+ requestData: {
9175
+ transactionId: string;
9176
+ type: string;
9177
+ createdAtLocation: string | null;
9178
+ };
9179
+ responseSummary: {
9180
+ eventId: string;
9181
+ trackingId: string;
9182
+ };
9183
+ } | {
9184
+ id: string;
9185
+ clientId: string;
9186
+ clientType: "system" | "user";
9187
+ createdAt: string;
9188
+ operation: "event.get";
9189
+ requestData: {
9190
+ eventId: string;
9191
+ };
9192
+ responseSummary: {
9193
+ eventType: string;
9194
+ trackingId: string;
9195
+ };
9196
+ } | {
9197
+ id: string;
9198
+ clientId: string;
9199
+ createdAt: string;
9200
+ operation: "event.search";
9201
+ clientType: "system";
9202
+ requestData: {
9203
+ query: Record<string, unknown> | null;
9204
+ limit: number | null;
9205
+ offset: number | null;
9206
+ };
9207
+ responseSummary: {
9208
+ total: number;
9209
+ eventIds: string[];
9210
+ };
9211
+ } | {
9212
+ id: string;
9213
+ clientId: string;
9214
+ clientType: "system" | "user";
9215
+ createdAt: string;
9216
+ operation: "event.actions.archive.request" | "event.actions.assign.request" | "event.actions.correction.approve.request" | "event.actions.correction.reject.request" | "event.actions.correction.request.request" | "event.actions.declare.request" | "event.actions.edit.request" | "event.actions.mark_as_duplicate.request" | "event.actions.mark_as_not_duplicate.request" | "event.actions.notify.request" | "event.actions.print_certificate.request" | "event.actions.read.request" | "event.actions.register.request" | "event.actions.reinstate.request" | "event.actions.reject.request" | "event.actions.unarchive.request" | "event.actions.unassign.request" | "event.actions.validate.request";
9217
+ requestData: {
9218
+ eventId: string;
9219
+ actionType: string;
9220
+ eventType: string;
9221
+ trackingId: string;
9222
+ transactionId: string;
9223
+ };
9224
+ } | {
9225
+ id: string;
9226
+ clientId: string;
9227
+ clientType: "system" | "user";
9228
+ createdAt: string;
9229
+ operation: "event.actions.custom.request";
9230
+ requestData: {
9231
+ eventId: string;
9232
+ actionType: "CUSTOM";
9233
+ customAction: string;
9234
+ eventType: string;
9235
+ trackingId: string;
9236
+ transactionId: string;
9237
+ };
9238
+ } | {
9239
+ id: string;
9240
+ clientId: string;
9241
+ clientType: "system" | "user";
9242
+ createdAt: string;
9243
+ operation: "integrations.create";
9244
+ requestData: {
9245
+ name: string;
9246
+ scopes: string[];
9247
+ };
9248
+ responseSummary: {
9249
+ clientId: string;
9250
+ };
9251
+ } | {
9252
+ id: string;
9253
+ clientId: string;
9254
+ clientType: "system" | "user";
9255
+ createdAt: string;
9256
+ operation: "integrations.refreshToken";
9257
+ requestData: {
9258
+ clientId: string;
9259
+ };
9260
+ responseSummary: {
9261
+ clientId: string;
9262
+ };
9263
+ } | {
9264
+ id: string;
9265
+ clientId: string;
9266
+ clientType: "system" | "user";
9267
+ createdAt: string;
9268
+ operation: "integrations.deactivate";
9269
+ requestData: {
9270
+ id: string;
9271
+ };
9272
+ responseSummary: {
9273
+ id: string;
9274
+ status: string;
9275
+ };
9276
+ } | {
9277
+ id: string;
9278
+ clientId: string;
9279
+ clientType: "system" | "user";
9280
+ createdAt: string;
9281
+ operation: "integrations.activate";
9282
+ requestData: {
9283
+ id: string;
9284
+ };
9285
+ responseSummary: {
9286
+ id: string;
9287
+ status: string;
9288
+ };
9289
+ } | {
9290
+ id: string;
9291
+ clientId: string;
9292
+ clientType: "system" | "user";
9293
+ createdAt: string;
9294
+ operation: "integrations.delete";
9295
+ requestData: {
9296
+ id: string;
9297
+ };
9298
+ responseSummary: {
9299
+ id: string;
9300
+ name: string;
9301
+ };
9302
+ } | {
9303
+ id: string;
9304
+ clientId: string;
9305
+ clientType: "system" | "user";
9306
+ createdAt: string;
9307
+ operation: "integrations.refreshSecret";
9308
+ requestData: {
9309
+ id: string;
9310
+ };
9311
+ responseSummary: {
9312
+ clientId: string;
9313
+ };
9314
+ } | {
9315
+ id: string;
9316
+ clientId: string;
9317
+ clientType: "system" | "user";
9318
+ createdAt: string;
9319
+ operation: "locations.create";
9320
+ requestData: {
9321
+ id: string;
9322
+ versionId: string;
9323
+ name: string;
9324
+ externalId?: string | null | undefined;
9325
+ effectiveFrom: string;
9326
+ status: string;
9327
+ administrativeAreaId?: string | null | undefined;
9328
+ locationType?: string | null | undefined;
9329
+ };
9330
+ } | {
9331
+ id: string;
9332
+ clientId: string;
9333
+ clientType: "system" | "user";
9334
+ createdAt: string;
9335
+ operation: "locations.update";
9336
+ requestData: {
9337
+ id: string;
9338
+ versionId: string;
9339
+ name: string;
9340
+ externalId?: string | null | undefined;
9341
+ status: string;
9342
+ effectiveFrom: string;
9343
+ lastVersionId: string;
9344
+ };
9345
+ responseSummary: {
9346
+ previousVersionId: string;
9347
+ versionId: string;
9348
+ changed: {
9349
+ name?: {
9350
+ from: string;
9351
+ to: string;
9352
+ } | undefined;
9353
+ externalId?: {
9354
+ from: string | null;
9355
+ to: string | null;
9356
+ } | undefined;
9357
+ status?: {
9358
+ from: string;
9359
+ to: string;
9360
+ } | undefined;
9361
+ };
9362
+ };
9363
+ } | {
9364
+ id: string;
9365
+ clientId: string;
9366
+ clientType: "system" | "user";
9367
+ createdAt: string;
9368
+ operation: "administrativeAreas.update";
9369
+ requestData: {
9370
+ id: string;
9371
+ versionId: string;
9372
+ name: string;
9373
+ externalId?: string | null | undefined;
9374
+ status: string;
9375
+ effectiveFrom: string;
9376
+ lastVersionId: string;
9377
+ };
9378
+ responseSummary: {
9379
+ previousVersionId: string;
9380
+ versionId: string;
9381
+ changed: {
9382
+ name?: {
9383
+ from: string;
9384
+ to: string;
9385
+ } | undefined;
9386
+ externalId?: {
9387
+ from: string | null;
9388
+ to: string | null;
9389
+ } | undefined;
9390
+ status?: {
9391
+ from: string;
9392
+ to: string;
9393
+ } | undefined;
9394
+ };
9395
+ };
9396
+ } | {
9397
+ id: string;
9398
+ clientId: string;
9399
+ clientType: "system" | "user";
9400
+ createdAt: string;
9401
+ operation: "locations.withdrawVersion";
9402
+ requestData: {
9403
+ id: string;
9404
+ versionId: string;
9405
+ };
9406
+ responseSummary: {
9407
+ effectiveFrom: string;
9408
+ name: string;
9409
+ externalId?: string | null | undefined;
9410
+ status: string;
9411
+ };
9412
+ } | {
9413
+ id: string;
9414
+ clientId: string;
9415
+ clientType: "system" | "user";
9416
+ createdAt: string;
9417
+ operation: "administrativeAreas.withdrawVersion";
9418
+ requestData: {
9419
+ id: string;
9420
+ versionId: string;
9421
+ };
9422
+ responseSummary: {
9423
+ effectiveFrom: string;
9424
+ name: string;
9425
+ externalId?: string | null | undefined;
9426
+ status: string;
9427
+ };
9428
+ } | {
9429
+ id: string;
9430
+ clientId: string;
9431
+ clientType: "system" | "user";
9432
+ createdAt: string;
9433
+ operation: "administrativeAreas.create";
9434
+ requestData: {
9435
+ id: string;
9436
+ versionId: string;
9437
+ name: string;
9438
+ externalId?: string | null | undefined;
9439
+ effectiveFrom: string;
9440
+ status: string;
9441
+ parentId?: string | null | undefined;
9442
+ };
9443
+ } | {
9444
+ id: string;
9445
+ clientId: string;
9446
+ clientType: "system" | "user";
9447
+ createdAt: string;
9448
+ operation: "attachments.upload";
9449
+ requestData: {
9450
+ transactionId: string;
9451
+ eventId?: string | undefined;
9452
+ path: string | null;
9453
+ };
9454
+ responseSummary: {
9455
+ fileUrl: string;
9456
+ };
9457
+ } | {
9458
+ id: string;
9459
+ clientId: string;
9460
+ clientType: "system" | "user";
9461
+ createdAt: string;
9462
+ operation: "user.create_user";
9463
+ requestData: {
9464
+ subjectId: string;
9465
+ role: string;
9466
+ primaryOfficeId: string;
9467
+ };
9468
+ } | {
9469
+ id: string;
9470
+ clientId: string;
9471
+ clientType: "system" | "user";
9472
+ createdAt: string;
9473
+ operation: "user.deactivate" | "user.reactivate";
9474
+ requestData: {
9475
+ subjectId: string;
9476
+ reason: string;
9477
+ comment?: string | undefined;
9478
+ };
9479
+ } | {
9480
+ id: string;
9481
+ clientId: string;
9482
+ clientType: "system" | "user";
9483
+ createdAt: string;
9484
+ operation: "user.edit_user" | "user.logged_in" | "user.logged_out" | "user.password_changed" | "user.password_reset" | "user.password_reset_by_admin" | "user.resend_invite" | "user.username_reminder" | "user.username_reminder_by_admin";
9485
+ requestData: {
9486
+ subjectId: string;
9487
+ };
9488
+ } | {
9489
+ id: string;
9490
+ clientId: string;
9491
+ clientType: "system" | "user";
9492
+ createdAt: string;
9493
+ operation: "user.email_address_changed";
9494
+ requestData: {
9495
+ subjectId: string;
9496
+ };
9497
+ responseSummary: {
9498
+ email: string;
9499
+ };
9500
+ } | {
9501
+ id: string;
9502
+ clientId: string;
9503
+ clientType: "system" | "user";
9504
+ createdAt: string;
9505
+ operation: "user.phone_number_changed";
9506
+ requestData: {
9507
+ subjectId: string;
9508
+ };
9509
+ responseSummary: {
9510
+ phoneNumber: string;
9511
+ };
9512
+ })[];
9513
+ total: number;
9514
+ };
9515
+ meta: import("trpc-to-openapi").OpenApiMeta;
9516
+ }>;
8958
9517
  }>>;
8959
9518
  attachments: import("@trpc/server").TRPCBuiltRouter<{
8960
9519
  ctx: Partial<{
8961
9520
  token: `Bearer ${string}`;
8962
9521
  user: {
8963
- id: string & import("zod").$brand<"UUID">;
8964
- type: "system";
8965
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
8966
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
8967
- signature?: undefined;
8968
- } | {
8969
9522
  id: string & import("zod").$brand<"UUID">;
8970
9523
  role: string;
8971
9524
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
8972
9525
  primaryOfficeId: string & import("zod").$brand<"UUID">;
8973
9526
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
8974
9527
  type: "user";
9528
+ } | {
9529
+ id: string & import("zod").$brand<"UUID">;
9530
+ type: "system";
9531
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
9532
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
9533
+ signature?: undefined;
8975
9534
  };
8976
9535
  }>;
8977
9536
  meta: import("trpc-to-openapi").OpenApiMeta;
@@ -8985,6 +9544,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8985
9544
  } | {
8986
9545
  file: unknown;
8987
9546
  transactionId: unknown;
9547
+ eventId: unknown;
8988
9548
  path: unknown;
8989
9549
  };
8990
9550
  output: string;
@@ -8995,18 +9555,18 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
8995
9555
  ctx: Partial<{
8996
9556
  token: `Bearer ${string}`;
8997
9557
  user: {
8998
- id: string & import("zod").$brand<"UUID">;
8999
- type: "system";
9000
- primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
9001
- administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
9002
- signature?: undefined;
9003
- } | {
9004
9558
  id: string & import("zod").$brand<"UUID">;
9005
9559
  role: string;
9006
9560
  signature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
9007
9561
  primaryOfficeId: string & import("zod").$brand<"UUID">;
9008
9562
  administrativeAreaId?: (string & import("zod").$brand<"UUID">) | null | undefined;
9009
9563
  type: "user";
9564
+ } | {
9565
+ id: string & import("zod").$brand<"UUID">;
9566
+ type: "system";
9567
+ primaryOfficeId?: (string & import("zod").$brand<"UUID">) | undefined;
9568
+ administrativeAreaId?: (string & import("zod").$brand<"UUID">) | undefined;
9569
+ signature?: undefined;
9010
9570
  };
9011
9571
  }>;
9012
9572
  meta: import("trpc-to-openapi").OpenApiMeta;