@opencrvs/toolkit 2.1.0-rc.30bcbde → 2.1.0-rc.312fbd1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -12
- package/build.sh +12 -4
- package/create-countryconfig/index.js +441 -59
- package/create-countryconfig/node_modules/.bin/degit +21 -0
- package/create-countryconfig/package.json +4 -1
- package/dist/application-config/index.js +362 -284
- package/dist/authentication/index.d.ts +66 -0
- package/dist/authentication/index.d.ts.map +1 -0
- package/dist/authentication/index.js +765 -0
- package/dist/cli.js +3347 -1229
- package/dist/commons/api/router.d.ts +3942 -3310
- package/dist/commons/application-config/index.d.ts +6 -8
- package/dist/commons/conditionals/conditionals.d.ts +259 -2102
- package/dist/commons/conditionals/validate.d.ts +34 -8
- package/dist/commons/events/ActionConfig.d.ts +105 -114
- package/dist/commons/events/ActionDocument.d.ts +145 -125
- package/dist/commons/events/ActionInput.d.ts +4 -4
- package/dist/commons/events/ActionStatus.d.ts +14 -0
- package/dist/commons/events/ActionType.d.ts +62 -62
- package/dist/commons/events/AdvancedSearchConfig.d.ts +549 -513
- package/dist/commons/events/AuditLog.d.ts +190 -42
- package/dist/commons/events/CompositeFieldValue.d.ts +4 -4
- package/dist/commons/events/Conditional.d.ts +3 -3
- package/dist/commons/events/CountryConfigQueryInput.d.ts +590 -590
- package/dist/commons/events/Draft.d.ts +27 -47
- package/dist/commons/events/DynamicFieldValue.d.ts +9 -9
- package/dist/commons/events/EventConfig.d.ts +8 -5
- package/dist/commons/events/EventDocument.d.ts +518 -50
- package/dist/commons/events/EventIndex.d.ts +49 -72
- package/dist/commons/events/EventMetadata.d.ts +39 -49
- package/dist/commons/events/EventStatus.d.ts +19 -0
- package/dist/commons/events/FieldConfig.d.ts +440 -394
- package/dist/commons/events/FieldType.d.ts +51 -51
- package/dist/commons/events/FieldTypeMapping.d.ts +89 -89
- package/dist/commons/events/FieldValue.d.ts +15 -14
- package/dist/commons/events/Flag.d.ts +57 -15
- package/dist/commons/events/FormConfig.d.ts +6 -0
- package/dist/commons/events/PageConfig.d.ts +4 -0
- package/dist/commons/events/PlainDate.d.ts +8 -0
- package/dist/commons/events/SummaryConfig.d.ts +249 -0
- package/dist/commons/events/TemplateConfig.d.ts +1 -1
- package/dist/commons/events/WorkqueueColumnConfig.d.ts +40 -40
- package/dist/commons/events/WorkqueueConfig.d.ts +817 -814
- package/dist/commons/events/deduplication.d.ts +1 -1
- package/dist/commons/events/event.d.ts +14 -2
- package/dist/commons/events/field.d.ts +78 -895
- package/dist/commons/events/index.d.ts +1 -0
- package/dist/commons/events/locationPayloads.d.ts +95 -0
- package/dist/commons/events/locations.d.ts +247 -14
- package/dist/commons/events/mocks.test.utils.d.ts +48 -4
- package/dist/commons/events/scopes.d.ts +25 -5
- package/dist/commons/events/state/index.d.ts +17 -17
- package/dist/commons/events/state/utils.d.ts +7 -7
- package/dist/commons/events/test.utils.d.ts +104 -46
- package/dist/commons/events/utils.d.ts +149 -114
- package/dist/commons/notification/UserNotifications.d.ts +38 -23
- package/dist/commons/notification/dispatch.d.ts +10 -0
- package/dist/commons/notification/index.d.ts +1 -0
- package/dist/conditionals/index.js +349 -65
- package/dist/csv.d.ts +25 -0
- package/dist/csv.d.ts.map +1 -0
- package/dist/csv.js +120 -0
- package/dist/environment/derived-variables.d.ts +119 -119
- package/dist/environment/derived-variables.d.ts.map +1 -1
- package/dist/environment/index.d.ts +1 -0
- package/dist/environment/index.d.ts.map +1 -1
- package/dist/environment/index.js +12 -1
- package/dist/environment/logger.d.ts +15 -3
- package/dist/environment/logger.d.ts.map +1 -1
- package/dist/environment/manage-users.js +1 -1
- package/dist/environment/paths.d.ts +7 -0
- package/dist/environment/paths.d.ts.map +1 -0
- package/dist/environment/paths.js +72 -0
- package/dist/environment/questions.d.ts +75 -74
- package/dist/environment/questions.d.ts.map +1 -1
- package/dist/environment/questions.js +20 -14
- package/dist/environment/setup-environment.d.ts +1 -1
- package/dist/environment/setup-environment.d.ts.map +1 -1
- package/dist/environment/setup-environment.js +589 -570
- package/dist/environment/templates.d.ts +0 -1
- package/dist/environment/templates.d.ts.map +1 -1
- package/dist/environment/templates.js +5 -9
- package/dist/environment/update-workflows.d.ts.map +1 -1
- package/dist/environment/update-workflows.js +21 -5
- package/dist/environment/upgrade.d.ts +2 -0
- package/dist/environment/upgrade.d.ts.map +1 -0
- package/dist/environment/upgrade.js +82 -0
- package/dist/environment/users.js +11 -13
- package/dist/environment/utils.d.ts +1 -13
- package/dist/environment/utils.d.ts.map +1 -1
- package/dist/environment/utils.js +1 -28
- package/dist/events/deduplication.d.ts +1 -1
- package/dist/events/index.js +5910 -5301
- package/dist/migrations/v2.0/checkout-upstream-files.d.ts +2 -2
- package/dist/migrations/v2.0/checkout-upstream-files.d.ts.map +1 -1
- package/dist/migrations/v2.0/checkout-upstream-files.js +2 -2
- package/dist/migrations/v2.0/convert-config-files-to-ts.d.ts.map +1 -1
- package/dist/migrations/v2.0/convert-config-files-to-ts.js +3 -10
- package/dist/migrations/v2.0/merge-infrastructure-directory.js +3 -3
- package/dist/migrations/v2.0/migrate-application-config-url.js +4 -3
- package/dist/migrations/v2.1/add-recovery-link-notifications.d.ts +3 -0
- package/dist/migrations/v2.1/add-recovery-link-notifications.d.ts.map +1 -0
- package/dist/migrations/v2.1/add-recovery-link-notifications.js +511 -0
- package/dist/migrations/v2.1/add-translations.d.ts +9 -0
- package/dist/migrations/v2.1/add-translations.d.ts.map +1 -0
- package/dist/migrations/v2.1/add-translations.js +149 -0
- package/dist/migrations/v2.1/enable-telemetry.d.ts +3 -0
- package/dist/migrations/v2.1/enable-telemetry.d.ts.map +1 -0
- package/dist/migrations/v2.1/enable-telemetry.js +455 -0
- package/dist/migrations/v2.1/index.d.ts.map +1 -1
- package/dist/migrations/v2.1/index.js +1556 -0
- package/dist/migrations/v2.1/remove-metabase-package-installs.d.ts +2 -0
- package/dist/migrations/v2.1/remove-metabase-package-installs.d.ts.map +1 -0
- package/dist/migrations/v2.1/remove-metabase-package-installs.js +161 -0
- package/dist/migrations/v2.1/remove-sentry.d.ts +3 -0
- package/dist/migrations/v2.1/remove-sentry.d.ts.map +1 -0
- package/dist/migrations/v2.1/remove-sentry.js +354 -0
- package/dist/migrations/v2.1/rename-trigger-paths.d.ts +3 -0
- package/dist/migrations/v2.1/rename-trigger-paths.d.ts.map +1 -0
- package/dist/migrations/v2.1/rename-trigger-paths.js +216 -0
- package/dist/notification/index.js +1904 -1492
- package/dist/scopes/index.d.ts +736 -158
- package/dist/scopes/index.js +351 -65
- package/dist/telemetry/index.d.ts +45 -0
- package/dist/telemetry/index.d.ts.map +1 -0
- package/dist/telemetry/index.js +43 -0
- package/dist/templates/charts-values/dependencies/values.yaml +8 -0
- package/dist/templates/charts-values/opencrvs-services/values.yaml +10 -3
- package/dist/templates/charts-values/opentelemetry/values.yaml +102 -0
- package/dist/templates/charts-values/traefik/values.yaml +23 -9
- package/dist/templates/inventory/inventory.template.yml +1 -3
- package/dist/translations/template.d.ts +11 -0
- package/dist/translations/template.d.ts.map +1 -0
- package/dist/translations/template.js +100 -0
- package/dist/verify/endpoints.d.ts +2 -0
- package/dist/verify/endpoints.d.ts.map +1 -0
- package/dist/verify/endpoints.js +510 -0
- package/opencrvs-toolkit-2.1.0-rc.312fbd1.tgz +0 -0
- package/package.json +13 -7
- package/tsconfig.build.json +11 -0
- package/tsconfig.build.tsbuildinfo +1 -0
- package/tsconfig.json +3 -0
- package/dist/templates/inventory/production.example.yml +0 -77
- package/dist/templates/inventory/qa.example.yml +0 -48
- package/opencrvs-toolkit-2.1.0-rc.30bcbde.tgz +0 -0
- package/tsconfig.tsbuildinfo +0 -1
|
@@ -10,6 +10,7 @@ import { UUID } from '../uuid';
|
|
|
10
10
|
import { ActionConfig, ActionConfigTypes } from './ActionConfig';
|
|
11
11
|
import { FormConfig } from './FormConfig';
|
|
12
12
|
import { PlainDate, SelectDateRangeValue } from './FieldValue';
|
|
13
|
+
import { EventIndex } from './EventIndex';
|
|
13
14
|
export declare function ageToDate(age: number, asOfDate: PlainDate): string & import("zod").$brand<"PlainDate">;
|
|
14
15
|
export declare function getDeclarationFields(configuration: EventConfig): FieldConfig[];
|
|
15
16
|
export declare function getDeclarationPages(configuration: EventConfig): {
|
|
@@ -20,9 +21,10 @@ export declare function getDeclarationPages(configuration: EventConfig): {
|
|
|
20
21
|
description: string;
|
|
21
22
|
};
|
|
22
23
|
requireCompletionToContinue: boolean;
|
|
24
|
+
showClearButton?: boolean | undefined;
|
|
23
25
|
fields: FieldConfig[];
|
|
24
|
-
type: "FORM";
|
|
25
26
|
conditional?: any;
|
|
27
|
+
type: "FORM";
|
|
26
28
|
}[];
|
|
27
29
|
export declare function getDeclaration(configuration: EventConfig): {
|
|
28
30
|
label: {
|
|
@@ -38,9 +40,10 @@ export declare function getDeclaration(configuration: EventConfig): {
|
|
|
38
40
|
description: string;
|
|
39
41
|
};
|
|
40
42
|
requireCompletionToContinue: boolean;
|
|
43
|
+
showClearButton?: boolean | undefined;
|
|
41
44
|
fields: FieldConfig[];
|
|
42
|
-
type: "FORM";
|
|
43
45
|
conditional?: any;
|
|
46
|
+
type: "FORM";
|
|
44
47
|
}[];
|
|
45
48
|
};
|
|
46
49
|
export declare function isActionConfigType(type: ActionType): type is ActionConfigTypes;
|
|
@@ -66,9 +69,10 @@ export declare function getPrintCertificatePages(configuration: EventConfig): ({
|
|
|
66
69
|
description: string;
|
|
67
70
|
};
|
|
68
71
|
requireCompletionToContinue: boolean;
|
|
72
|
+
showClearButton?: boolean | undefined;
|
|
69
73
|
fields: FieldConfig[];
|
|
70
|
-
type: "FORM";
|
|
71
74
|
conditional?: any;
|
|
75
|
+
type: "FORM";
|
|
72
76
|
} | {
|
|
73
77
|
id: string;
|
|
74
78
|
title: {
|
|
@@ -77,7 +81,9 @@ export declare function getPrintCertificatePages(configuration: EventConfig): ({
|
|
|
77
81
|
description: string;
|
|
78
82
|
};
|
|
79
83
|
requireCompletionToContinue: boolean;
|
|
84
|
+
showClearButton?: boolean | undefined;
|
|
80
85
|
fields: FieldConfig[];
|
|
86
|
+
conditional?: any;
|
|
81
87
|
type: "VERIFICATION";
|
|
82
88
|
actions: {
|
|
83
89
|
verify: {
|
|
@@ -107,7 +113,6 @@ export declare function getPrintCertificatePages(configuration: EventConfig): ({
|
|
|
107
113
|
};
|
|
108
114
|
};
|
|
109
115
|
};
|
|
110
|
-
conditional?: any;
|
|
111
116
|
})[];
|
|
112
117
|
export declare const getActionAnnotationFields: (actionConfig: ActionConfig) => FieldConfig[];
|
|
113
118
|
export declare function getAllUniqueFields(eventConfig: EventConfig): FieldConfig[];
|
|
@@ -162,313 +167,313 @@ export declare function deepMerge<T extends Record<string, unknown>, K extends R
|
|
|
162
167
|
export declare function findLastAssignmentAction(actions: Action[]): {
|
|
163
168
|
id: string & import("zod").$brand<"UUID">;
|
|
164
169
|
transactionId: string;
|
|
165
|
-
createdByUserType: "
|
|
170
|
+
createdByUserType: "system" | "user";
|
|
166
171
|
createdAt: string;
|
|
167
172
|
createdBy: string;
|
|
168
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
169
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
170
|
-
type: "REGISTER";
|
|
171
173
|
createdByRole?: string | undefined;
|
|
172
174
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
173
175
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
176
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
174
177
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
178
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
175
179
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
176
|
-
|
|
180
|
+
type: "CREATE";
|
|
177
181
|
} | {
|
|
178
182
|
id: string & import("zod").$brand<"UUID">;
|
|
179
183
|
transactionId: string;
|
|
180
|
-
createdByUserType: "
|
|
184
|
+
createdByUserType: "system" | "user";
|
|
181
185
|
createdAt: string;
|
|
182
186
|
createdBy: string;
|
|
183
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
184
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
185
|
-
type: "DUPLICATE_DETECTED";
|
|
186
|
-
content: {
|
|
187
|
-
duplicates: {
|
|
188
|
-
id: string & import("zod").$brand<"UUID">;
|
|
189
|
-
trackingId: string;
|
|
190
|
-
}[];
|
|
191
|
-
};
|
|
192
187
|
createdByRole?: string | undefined;
|
|
193
188
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
194
189
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
190
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
195
191
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
192
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
196
193
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
194
|
+
type: "REJECT";
|
|
195
|
+
content: {
|
|
196
|
+
reason: string;
|
|
197
|
+
};
|
|
197
198
|
} | {
|
|
198
199
|
id: string & import("zod").$brand<"UUID">;
|
|
199
200
|
transactionId: string;
|
|
200
|
-
createdByUserType: "
|
|
201
|
+
createdByUserType: "system" | "user";
|
|
201
202
|
createdAt: string;
|
|
202
203
|
createdBy: string;
|
|
203
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
204
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
205
|
-
type: "EDIT";
|
|
206
204
|
createdByRole?: string | undefined;
|
|
207
205
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
208
206
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
207
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
209
208
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
209
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
210
210
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
211
|
+
type: "DUPLICATE_DETECTED";
|
|
212
|
+
content: {
|
|
213
|
+
duplicates: {
|
|
214
|
+
id: string & import("zod").$brand<"UUID">;
|
|
215
|
+
trackingId: string;
|
|
216
|
+
}[];
|
|
217
|
+
};
|
|
214
218
|
} | {
|
|
215
219
|
id: string & import("zod").$brand<"UUID">;
|
|
216
220
|
transactionId: string;
|
|
217
|
-
createdByUserType: "
|
|
221
|
+
createdByUserType: "system" | "user";
|
|
218
222
|
createdAt: string;
|
|
219
223
|
createdBy: string;
|
|
220
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
221
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
222
|
-
type: "PRINT_CERTIFICATE";
|
|
223
224
|
createdByRole?: string | undefined;
|
|
224
225
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
225
226
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
227
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
226
228
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
229
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
227
230
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
228
|
-
|
|
229
|
-
templateId?: string | undefined;
|
|
230
|
-
} | null | undefined;
|
|
231
|
+
type: "MARK_AS_NOT_DUPLICATE";
|
|
231
232
|
} | {
|
|
232
233
|
id: string & import("zod").$brand<"UUID">;
|
|
233
234
|
transactionId: string;
|
|
234
|
-
createdByUserType: "
|
|
235
|
+
createdByUserType: "system" | "user";
|
|
235
236
|
createdAt: string;
|
|
236
237
|
createdBy: string;
|
|
237
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
238
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
239
|
-
type: "REQUEST_CORRECTION";
|
|
240
238
|
createdByRole?: string | undefined;
|
|
241
239
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
242
240
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
241
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
243
242
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
243
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
244
244
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
245
|
+
type: "MARK_AS_DUPLICATE";
|
|
246
|
+
content?: {
|
|
247
|
+
duplicateOf: string & import("zod").$brand<"UUID">;
|
|
248
|
+
} | undefined;
|
|
245
249
|
} | {
|
|
246
250
|
id: string & import("zod").$brand<"UUID">;
|
|
247
251
|
transactionId: string;
|
|
248
|
-
createdByUserType: "
|
|
252
|
+
createdByUserType: "system" | "user";
|
|
249
253
|
createdAt: string;
|
|
250
254
|
createdBy: string;
|
|
251
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
252
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
253
|
-
type: "CUSTOM";
|
|
254
|
-
customActionType: string;
|
|
255
255
|
createdByRole?: string | undefined;
|
|
256
256
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
257
257
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
258
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
258
259
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
260
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
259
261
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
262
|
+
type: "ARCHIVE";
|
|
263
|
+
content?: {
|
|
264
|
+
reason: string;
|
|
265
|
+
} | undefined;
|
|
260
266
|
} | {
|
|
261
267
|
id: string & import("zod").$brand<"UUID">;
|
|
262
268
|
transactionId: string;
|
|
263
|
-
createdByUserType: "
|
|
269
|
+
createdByUserType: "system" | "user";
|
|
264
270
|
createdAt: string;
|
|
265
271
|
createdBy: string;
|
|
266
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
267
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
268
|
-
type: "CREATE";
|
|
269
272
|
createdByRole?: string | undefined;
|
|
270
273
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
271
274
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
275
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
272
276
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
277
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
273
278
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
279
|
+
type: "UNARCHIVE";
|
|
274
280
|
} | {
|
|
275
281
|
id: string & import("zod").$brand<"UUID">;
|
|
276
282
|
transactionId: string;
|
|
277
|
-
createdByUserType: "
|
|
283
|
+
createdByUserType: "system" | "user";
|
|
278
284
|
createdAt: string;
|
|
279
285
|
createdBy: string;
|
|
280
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
281
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
282
|
-
type: "REJECT";
|
|
283
|
-
content: {
|
|
284
|
-
reason: string;
|
|
285
|
-
};
|
|
286
286
|
createdByRole?: string | undefined;
|
|
287
287
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
288
288
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
289
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
289
290
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
291
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
290
292
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
293
|
+
type: "NOTIFY";
|
|
291
294
|
} | {
|
|
292
295
|
id: string & import("zod").$brand<"UUID">;
|
|
293
296
|
transactionId: string;
|
|
294
|
-
createdByUserType: "
|
|
297
|
+
createdByUserType: "system" | "user";
|
|
295
298
|
createdAt: string;
|
|
296
299
|
createdBy: string;
|
|
297
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
298
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
299
|
-
type: "MARK_AS_NOT_DUPLICATE";
|
|
300
300
|
createdByRole?: string | undefined;
|
|
301
301
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
302
302
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
303
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
303
304
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
305
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
304
306
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
307
|
+
type: "REGISTER";
|
|
308
|
+
registrationNumber?: string | undefined;
|
|
305
309
|
} | {
|
|
306
310
|
id: string & import("zod").$brand<"UUID">;
|
|
307
311
|
transactionId: string;
|
|
308
|
-
createdByUserType: "
|
|
312
|
+
createdByUserType: "system" | "user";
|
|
309
313
|
createdAt: string;
|
|
310
314
|
createdBy: string;
|
|
311
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
312
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
313
|
-
type: "MARK_AS_DUPLICATE";
|
|
314
315
|
createdByRole?: string | undefined;
|
|
315
316
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
316
317
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
318
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
317
319
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
320
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
318
321
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
319
|
-
|
|
320
|
-
duplicateOf: string & import("zod").$brand<"UUID">;
|
|
321
|
-
} | undefined;
|
|
322
|
+
type: "DECLARE";
|
|
322
323
|
} | {
|
|
323
324
|
id: string & import("zod").$brand<"UUID">;
|
|
324
325
|
transactionId: string;
|
|
325
|
-
createdByUserType: "
|
|
326
|
+
createdByUserType: "system" | "user";
|
|
326
327
|
createdAt: string;
|
|
327
328
|
createdBy: string;
|
|
328
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
329
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
330
|
-
type: "ARCHIVE";
|
|
331
|
-
content: {
|
|
332
|
-
reason: string;
|
|
333
|
-
};
|
|
334
329
|
createdByRole?: string | undefined;
|
|
335
330
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
336
331
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
332
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
337
333
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
334
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
338
335
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
336
|
+
type: "ASSIGN";
|
|
337
|
+
assignedTo: string;
|
|
339
338
|
} | {
|
|
340
339
|
id: string & import("zod").$brand<"UUID">;
|
|
341
340
|
transactionId: string;
|
|
342
|
-
createdByUserType: "
|
|
341
|
+
createdByUserType: "system" | "user";
|
|
343
342
|
createdAt: string;
|
|
344
343
|
createdBy: string;
|
|
345
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
346
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
347
|
-
type: "UNARCHIVE";
|
|
348
344
|
createdByRole?: string | undefined;
|
|
349
345
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
350
346
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
347
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
351
348
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
349
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
352
350
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
351
|
+
type: "REQUEST_CORRECTION";
|
|
353
352
|
} | {
|
|
354
353
|
id: string & import("zod").$brand<"UUID">;
|
|
355
354
|
transactionId: string;
|
|
356
|
-
createdByUserType: "
|
|
355
|
+
createdByUserType: "system" | "user";
|
|
357
356
|
createdAt: string;
|
|
358
357
|
createdBy: string;
|
|
359
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
360
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
361
|
-
type: "NOTIFY";
|
|
362
358
|
createdByRole?: string | undefined;
|
|
363
359
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
364
360
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
361
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
365
362
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
363
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
366
364
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
365
|
+
type: "APPROVE_CORRECTION";
|
|
366
|
+
requestId: string & import("zod").$brand<"UUID">;
|
|
367
|
+
content?: {
|
|
368
|
+
immediateCorrection?: boolean | undefined;
|
|
369
|
+
} | undefined;
|
|
367
370
|
} | {
|
|
368
371
|
id: string & import("zod").$brand<"UUID">;
|
|
369
372
|
transactionId: string;
|
|
370
|
-
createdByUserType: "
|
|
373
|
+
createdByUserType: "system" | "user";
|
|
371
374
|
createdAt: string;
|
|
372
375
|
createdBy: string;
|
|
373
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
374
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
375
|
-
type: "DECLARE";
|
|
376
376
|
createdByRole?: string | undefined;
|
|
377
377
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
378
378
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
379
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
379
380
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
381
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
380
382
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
383
|
+
type: "REJECT_CORRECTION";
|
|
384
|
+
requestId: string & import("zod").$brand<"UUID">;
|
|
385
|
+
content: {
|
|
386
|
+
reason: string;
|
|
387
|
+
};
|
|
381
388
|
} | {
|
|
382
389
|
id: string & import("zod").$brand<"UUID">;
|
|
383
390
|
transactionId: string;
|
|
384
|
-
createdByUserType: "
|
|
391
|
+
createdByUserType: "system" | "user";
|
|
385
392
|
createdAt: string;
|
|
386
393
|
createdBy: string;
|
|
387
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
388
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
389
|
-
type: "ASSIGN";
|
|
390
|
-
assignedTo: string;
|
|
391
394
|
createdByRole?: string | undefined;
|
|
392
395
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
393
396
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
397
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
394
398
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
399
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
395
400
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
401
|
+
type: "UNASSIGN";
|
|
396
402
|
} | {
|
|
397
403
|
id: string & import("zod").$brand<"UUID">;
|
|
398
404
|
transactionId: string;
|
|
399
|
-
createdByUserType: "
|
|
405
|
+
createdByUserType: "system" | "user";
|
|
400
406
|
createdAt: string;
|
|
401
407
|
createdBy: string;
|
|
402
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
403
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
404
|
-
type: "APPROVE_CORRECTION";
|
|
405
|
-
requestId: string;
|
|
406
408
|
createdByRole?: string | undefined;
|
|
407
409
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
408
410
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
411
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
409
412
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
413
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
410
414
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
415
|
+
type: "PRINT_CERTIFICATE";
|
|
411
416
|
content?: {
|
|
412
|
-
|
|
413
|
-
} | undefined;
|
|
417
|
+
templateId?: string | undefined;
|
|
418
|
+
} | null | undefined;
|
|
414
419
|
} | {
|
|
415
420
|
id: string & import("zod").$brand<"UUID">;
|
|
416
421
|
transactionId: string;
|
|
417
|
-
createdByUserType: "
|
|
422
|
+
createdByUserType: "system" | "user";
|
|
418
423
|
createdAt: string;
|
|
419
424
|
createdBy: string;
|
|
420
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
421
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
422
|
-
type: "REJECT_CORRECTION";
|
|
423
|
-
requestId: string;
|
|
424
|
-
content: {
|
|
425
|
-
reason: string;
|
|
426
|
-
};
|
|
427
425
|
createdByRole?: string | undefined;
|
|
428
426
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
429
427
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
428
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
430
429
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
430
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
431
431
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
432
|
+
type: "READ";
|
|
432
433
|
} | {
|
|
433
434
|
id: string & import("zod").$brand<"UUID">;
|
|
434
435
|
transactionId: string;
|
|
435
|
-
createdByUserType: "
|
|
436
|
+
createdByUserType: "system" | "user";
|
|
436
437
|
createdAt: string;
|
|
437
438
|
createdBy: string;
|
|
438
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
439
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
440
|
-
type: "UNASSIGN";
|
|
441
439
|
createdByRole?: string | undefined;
|
|
442
440
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
443
441
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
442
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
444
443
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
444
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
445
445
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
446
|
+
type: "EDIT";
|
|
447
|
+
content?: {
|
|
448
|
+
comment?: string | undefined;
|
|
449
|
+
} | undefined;
|
|
446
450
|
} | {
|
|
447
451
|
id: string & import("zod").$brand<"UUID">;
|
|
448
452
|
transactionId: string;
|
|
449
|
-
createdByUserType: "
|
|
453
|
+
createdByUserType: "system" | "user";
|
|
450
454
|
createdAt: string;
|
|
451
455
|
createdBy: string;
|
|
452
|
-
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
453
|
-
status: "Requested" | "Accepted" | "Rejected";
|
|
454
|
-
type: "READ";
|
|
455
456
|
createdByRole?: string | undefined;
|
|
456
457
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
457
458
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
459
|
+
declaration: Record<string, import("./FieldValue").FieldUpdateValue>;
|
|
458
460
|
annotation?: Record<string, import("./FieldValue").FieldUpdateValue> | null | undefined;
|
|
461
|
+
status: "Accepted" | "Rejected" | "Requested";
|
|
459
462
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
463
|
+
type: "CUSTOM";
|
|
464
|
+
customActionType: string;
|
|
460
465
|
} | {
|
|
461
466
|
id: string & import("zod").$brand<"UUID">;
|
|
462
467
|
transactionId: string;
|
|
463
|
-
createdByUserType: "
|
|
468
|
+
createdByUserType: "system" | "user";
|
|
464
469
|
createdAt: string;
|
|
465
470
|
createdBy: string;
|
|
466
|
-
type: "CUSTOM" | "NOTIFY" | "DECLARE" | "REGISTER" | "EDIT" | "REJECT" | "ARCHIVE" | "UNARCHIVE" | "PRINT_CERTIFICATE" | "REQUEST_CORRECTION" | "REJECT_CORRECTION" | "APPROVE_CORRECTION";
|
|
467
|
-
status: "Rejected";
|
|
468
471
|
createdByRole?: string | undefined;
|
|
469
472
|
createdBySignature?: (string & import("zod").$brand<"DocumentPath">) | null | undefined;
|
|
470
473
|
createdAtLocation?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
471
474
|
originalActionId?: (string & import("zod").$brand<"UUID">) | null | undefined;
|
|
475
|
+
type: "APPROVE_CORRECTION" | "ARCHIVE" | "CUSTOM" | "DECLARE" | "EDIT" | "NOTIFY" | "PRINT_CERTIFICATE" | "REGISTER" | "REJECT" | "REJECT_CORRECTION" | "REQUEST_CORRECTION" | "UNARCHIVE";
|
|
476
|
+
status: "Rejected";
|
|
472
477
|
} | undefined;
|
|
473
478
|
/**
|
|
474
479
|
* Tell compiler that accessing record with arbitrary key might result to undefined
|
|
@@ -596,5 +601,35 @@ export declare function getCompleteActionContent(event: EventDocument, action: A
|
|
|
596
601
|
export declare function getCompleteActionDeclaration<T extends EventState | ActionUpdate>(declaration: T, event: EventDocument, action: ActionDocument): T;
|
|
597
602
|
export declare function getAcceptedActions(event: EventDocument): ActionDocument[];
|
|
598
603
|
export declare function aggregateActionDeclarations(event: EventDocument): EventState;
|
|
604
|
+
/**
|
|
605
|
+
* Returns the declaration after each of `event.actions`, which must be in chronological order.
|
|
606
|
+
* Index `i` equals `aggregateActionDeclarations` of the first `i + 1` actions, in linear time.
|
|
607
|
+
*/
|
|
608
|
+
export declare function getDeclarationAfterEachAction(event: EventDocument): EventState[];
|
|
609
|
+
/**
|
|
610
|
+
* Returns the event's declaration state as it will be once the single pending
|
|
611
|
+
* action is accepted — i.e. the aggregate of all accepted declarations with the
|
|
612
|
+
* pending action's changes applied on top.
|
|
613
|
+
*
|
|
614
|
+
* Country configuration confirmation handlers (and notifications) need the
|
|
615
|
+
* up-to-date declaration at confirmation time, before core has accepted the
|
|
616
|
+
* action. Reaching for `aggregateActionDeclarations` alone is not enough for
|
|
617
|
+
* corrections: when confirming an APPROVE_CORRECTION the changed fields live on
|
|
618
|
+
* the linked REQUEST_CORRECTION, not on the pending action's own (empty)
|
|
619
|
+
* declaration. This helper applies the same correction-aware merge that
|
|
620
|
+
* `aggregateActionDeclarations` uses for already-accepted approvals, so callers
|
|
621
|
+
* do not have to reimplement the `requestId`/`originalActionId` resolution.
|
|
622
|
+
*/
|
|
623
|
+
export declare function getDeclarationWithPendingAction(event: EventDocument): EventState;
|
|
599
624
|
export declare function aggregateActionAnnotations(event: EventDocument): EventState;
|
|
625
|
+
/**
|
|
626
|
+
* 2.1. onwards secured fields have accepted conditionals.
|
|
627
|
+
* Secured fields are not present in EventIndex payload.
|
|
628
|
+
* When we derive @see EventIndex from @see EventDocument, we will have all the fields present.
|
|
629
|
+
*
|
|
630
|
+
* To keep the views consistent, and not to change if event.get gets triggered, we need to clean out the secured fields.
|
|
631
|
+
*
|
|
632
|
+
* @returns EventIndex without values that evaluate to secured: true.
|
|
633
|
+
*/
|
|
634
|
+
export declare function dropSecuredDeclarationFields(eventConfig: EventConfig, eventIndex: EventIndex, validatorContext: ValidatorContext): EventIndex;
|
|
600
635
|
//# sourceMappingURL=utils.d.ts.map
|
|
@@ -1,15 +1,17 @@
|
|
|
1
1
|
import * as z from 'zod/v4';
|
|
2
2
|
export declare const TriggerEvent: {
|
|
3
|
-
readonly USER_CREATED:
|
|
4
|
-
readonly USER_UPDATED:
|
|
5
|
-
readonly USERNAME_REMINDER:
|
|
6
|
-
readonly RESET_PASSWORD:
|
|
7
|
-
readonly RESET_PASSWORD_BY_ADMIN:
|
|
8
|
-
readonly
|
|
9
|
-
readonly
|
|
10
|
-
readonly
|
|
11
|
-
readonly
|
|
12
|
-
readonly
|
|
3
|
+
readonly USER_CREATED: 'user-created';
|
|
4
|
+
readonly USER_UPDATED: 'user-updated';
|
|
5
|
+
readonly USERNAME_REMINDER: 'username-reminder';
|
|
6
|
+
readonly RESET_PASSWORD: 'reset-password';
|
|
7
|
+
readonly RESET_PASSWORD_BY_ADMIN: 'reset-password-by-admin';
|
|
8
|
+
readonly PASSWORD_RESET_LINK: 'password-reset-link';
|
|
9
|
+
readonly USERNAME_REMINDER_LINK: 'username-reminder-link';
|
|
10
|
+
readonly RESEND_INVITE: 'resend-invite';
|
|
11
|
+
readonly TWO_FA: '2fa';
|
|
12
|
+
readonly ALL_USER_NOTIFICATION: 'all-user-notification';
|
|
13
|
+
readonly CHANGE_PHONE_NUMBER: 'change-phone-number';
|
|
14
|
+
readonly CHANGE_EMAIL_ADDRESS: 'change-email-address';
|
|
13
15
|
};
|
|
14
16
|
export type TriggerEvent = (typeof TriggerEvent)[keyof typeof TriggerEvent];
|
|
15
17
|
export declare const Recipient: z.ZodObject<{
|
|
@@ -113,6 +115,32 @@ export declare const TriggerPayload: {
|
|
|
113
115
|
role: z.ZodString;
|
|
114
116
|
}, z.core.$strip>;
|
|
115
117
|
}, z.core.$strip>;
|
|
118
|
+
readonly "password-reset-link": z.ZodObject<{
|
|
119
|
+
recipient: z.ZodObject<{
|
|
120
|
+
name: z.ZodOptional<z.ZodObject<{
|
|
121
|
+
firstname: z.ZodString;
|
|
122
|
+
surname: z.ZodString;
|
|
123
|
+
middlename: z.ZodOptional<z.ZodString>;
|
|
124
|
+
}, z.core.$strip>>;
|
|
125
|
+
mobile: z.ZodOptional<z.ZodString>;
|
|
126
|
+
email: z.ZodOptional<z.ZodString>;
|
|
127
|
+
bcc: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
128
|
+
}, z.core.$strip>;
|
|
129
|
+
token: z.ZodString;
|
|
130
|
+
}, z.core.$strip>;
|
|
131
|
+
readonly "username-reminder-link": z.ZodObject<{
|
|
132
|
+
recipient: z.ZodObject<{
|
|
133
|
+
name: z.ZodOptional<z.ZodObject<{
|
|
134
|
+
firstname: z.ZodString;
|
|
135
|
+
surname: z.ZodString;
|
|
136
|
+
middlename: z.ZodOptional<z.ZodString>;
|
|
137
|
+
}, z.core.$strip>>;
|
|
138
|
+
mobile: z.ZodOptional<z.ZodString>;
|
|
139
|
+
email: z.ZodOptional<z.ZodString>;
|
|
140
|
+
bcc: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
141
|
+
}, z.core.$strip>;
|
|
142
|
+
token: z.ZodString;
|
|
143
|
+
}, z.core.$strip>;
|
|
116
144
|
readonly "resend-invite": z.ZodObject<{
|
|
117
145
|
recipient: z.ZodObject<{
|
|
118
146
|
name: z.ZodOptional<z.ZodObject<{
|
|
@@ -184,18 +212,5 @@ export declare const TriggerPayload: {
|
|
|
184
212
|
export type TriggerPayload = {
|
|
185
213
|
[K in TriggerEvent]: z.infer<(typeof TriggerPayload)[K]>;
|
|
186
214
|
};
|
|
187
|
-
export declare function triggerUserEventNotification(args: {
|
|
188
|
-
event: typeof TriggerEvent.ALL_USER_NOTIFICATION;
|
|
189
|
-
payload: TriggerPayload[typeof TriggerEvent.ALL_USER_NOTIFICATION];
|
|
190
|
-
countryConfigUrl: string;
|
|
191
|
-
}): Promise<Response>;
|
|
192
|
-
export declare function triggerUserEventNotification<T extends Exclude<TriggerEvent, typeof TriggerEvent.ALL_USER_NOTIFICATION>>(args: {
|
|
193
|
-
event: T;
|
|
194
|
-
payload: TriggerPayload[T];
|
|
195
|
-
countryConfigUrl: string;
|
|
196
|
-
authHeader: {
|
|
197
|
-
Authorization: string;
|
|
198
|
-
};
|
|
199
|
-
}): Promise<Response>;
|
|
200
215
|
export declare function parseUserEventTrigger<T extends TriggerEvent>(event: T, body: unknown): TriggerPayload[T];
|
|
201
216
|
//# sourceMappingURL=UserNotifications.d.ts.map
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { TriggerEvent, TriggerPayload } from './UserNotifications';
|
|
2
|
+
export declare function triggerUserEventNotification<T extends TriggerEvent>({ event, payload, countryConfigUrl, authHeader }: {
|
|
3
|
+
event: T;
|
|
4
|
+
payload: TriggerPayload[T];
|
|
5
|
+
countryConfigUrl: string;
|
|
6
|
+
authHeader: {
|
|
7
|
+
Authorization: string;
|
|
8
|
+
};
|
|
9
|
+
}): Promise<Response>;
|
|
10
|
+
//# sourceMappingURL=dispatch.d.ts.map
|