@opencrvs/toolkit 1.9.15-rc.5292f71 → 1.9.15-rc.a8774ba
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/events/index.js
CHANGED
|
@@ -1037,7 +1037,9 @@ var SCOPES = {
|
|
|
1037
1037
|
// config
|
|
1038
1038
|
CONFIG_UPDATE_ALL: "config.update:all",
|
|
1039
1039
|
// data seeding
|
|
1040
|
-
USER_DATA_SEEDING: "user.data-seeding"
|
|
1040
|
+
USER_DATA_SEEDING: "user.data-seeding",
|
|
1041
|
+
// bootstrap: allows countryconfig to register integrations on startup
|
|
1042
|
+
INTEGRATION_CREATE: "integration.create"
|
|
1041
1043
|
};
|
|
1042
1044
|
var LegacyScopes = import_zod11.z.union([
|
|
1043
1045
|
import_zod11.z.literal(SCOPES.BYPASSRATELIMIT),
|
|
@@ -1112,6 +1114,7 @@ var UserScopes = import_zod11.z.union([
|
|
|
1112
1114
|
]);
|
|
1113
1115
|
var ConfigScope = import_zod11.z.literal(SCOPES.CONFIG_UPDATE_ALL);
|
|
1114
1116
|
var DataSeedingScope = import_zod11.z.literal(SCOPES.USER_DATA_SEEDING);
|
|
1117
|
+
var IntegrationCreateScope = import_zod11.z.literal(SCOPES.INTEGRATION_CREATE);
|
|
1115
1118
|
var LiteralScopes = import_zod11.z.union([
|
|
1116
1119
|
LegacyScopes,
|
|
1117
1120
|
IntegrationScopes,
|
|
@@ -1129,7 +1132,8 @@ var LiteralScopes = import_zod11.z.union([
|
|
|
1129
1132
|
UserScopes,
|
|
1130
1133
|
ConfigScope,
|
|
1131
1134
|
DataSeedingScope,
|
|
1132
|
-
InternalOperationsScopes
|
|
1135
|
+
InternalOperationsScopes,
|
|
1136
|
+
IntegrationCreateScope
|
|
1133
1137
|
]);
|
|
1134
1138
|
var rawConfigurableScopeRegex = /^([a-zA-Z][a-zA-Z0-9.-]*(?:\.[a-zA-Z0-9.-]+)*)\[((?:\w+=[\w.-]+(?:\|[\w.-]+)*)(?:,[\w]+=[\w.-]+(?:\|[\w.-]+)*)*)\]$/;
|
|
1135
1139
|
var rawConfigurableScope = import_zod11.z.string().regex(rawConfigurableScopeRegex);
|
|
@@ -671,7 +671,9 @@ var SCOPES = {
|
|
|
671
671
|
// config
|
|
672
672
|
CONFIG_UPDATE_ALL: "config.update:all",
|
|
673
673
|
// data seeding
|
|
674
|
-
USER_DATA_SEEDING: "user.data-seeding"
|
|
674
|
+
USER_DATA_SEEDING: "user.data-seeding",
|
|
675
|
+
// bootstrap: allows countryconfig to register integrations on startup
|
|
676
|
+
INTEGRATION_CREATE: "integration.create"
|
|
675
677
|
};
|
|
676
678
|
var LegacyScopes = import_zod11.z.union([
|
|
677
679
|
import_zod11.z.literal(SCOPES.BYPASSRATELIMIT),
|
|
@@ -746,6 +748,7 @@ var UserScopes = import_zod11.z.union([
|
|
|
746
748
|
]);
|
|
747
749
|
var ConfigScope = import_zod11.z.literal(SCOPES.CONFIG_UPDATE_ALL);
|
|
748
750
|
var DataSeedingScope = import_zod11.z.literal(SCOPES.USER_DATA_SEEDING);
|
|
751
|
+
var IntegrationCreateScope = import_zod11.z.literal(SCOPES.INTEGRATION_CREATE);
|
|
749
752
|
var LiteralScopes = import_zod11.z.union([
|
|
750
753
|
LegacyScopes,
|
|
751
754
|
IntegrationScopes,
|
|
@@ -763,7 +766,8 @@ var LiteralScopes = import_zod11.z.union([
|
|
|
763
766
|
UserScopes,
|
|
764
767
|
ConfigScope,
|
|
765
768
|
DataSeedingScope,
|
|
766
|
-
InternalOperationsScopes
|
|
769
|
+
InternalOperationsScopes,
|
|
770
|
+
IntegrationCreateScope
|
|
767
771
|
]);
|
|
768
772
|
var rawConfigurableScopeRegex = /^([a-zA-Z][a-zA-Z0-9.-]*(?:\.[a-zA-Z0-9.-]+)*)\[((?:\w+=[\w.-]+(?:\|[\w.-]+)*)(?:,[\w]+=[\w.-]+(?:\|[\w.-]+)*)*)\]$/;
|
|
769
773
|
var rawConfigurableScope = import_zod11.z.string().regex(rawConfigurableScopeRegex);
|
package/dist/scopes/index.d.ts
CHANGED
|
@@ -61,9 +61,10 @@ export declare const SCOPES: {
|
|
|
61
61
|
readonly USER_UPDATE_MY_JURISDICTION: "user.update:my-jurisdiction";
|
|
62
62
|
readonly CONFIG_UPDATE_ALL: "config.update:all";
|
|
63
63
|
readonly USER_DATA_SEEDING: "user.data-seeding";
|
|
64
|
+
readonly INTEGRATION_CREATE: "integration.create";
|
|
64
65
|
};
|
|
65
66
|
export declare const SearchScopes: z.ZodUnion<[z.ZodLiteral<"search.birth:my-jurisdiction">, z.ZodLiteral<"search.birth">, z.ZodLiteral<"search.death:my-jurisdiction">, z.ZodLiteral<"search.death">, z.ZodLiteral<"search.marriage:my-jurisdiction">, z.ZodLiteral<"search.marriage">]>;
|
|
66
|
-
declare const LiteralScopes: z.ZodUnion<[z.ZodUnion<[z.ZodLiteral<"bypassratelimit">, z.ZodLiteral<"register">, z.ZodLiteral<"demo">, z.ZodLiteral<"config">]>, z.ZodUnion<[z.ZodLiteral<"webhook">, z.ZodLiteral<"nationalId">, z.ZodLiteral<"notification-api">, z.ZodLiteral<"recordsearch">]>, z.ZodLiteral<"record.unassign-others">, z.ZodUnion<[z.ZodLiteral<"record.declare-birth">, z.ZodLiteral<"record.declare-birth:my-jurisdiction">, z.ZodLiteral<"record.declare-death">, z.ZodLiteral<"record.declare-death:my-jurisdiction">, z.ZodLiteral<"record.declare-marriage">, z.ZodLiteral<"record.declare-marriage:my-jurisdiction">, z.ZodLiteral<"record.declaration-submit-incomplete">, z.ZodLiteral<"record.declaration-submit-for-review">]>, z.ZodUnion<[z.ZodLiteral<"record.declaration-submit-for-approval">, z.ZodLiteral<"record.declaration-submit-for-updates">, z.ZodLiteral<"record.declaration-edit">, z.ZodLiteral<"record.review-duplicates">, z.ZodLiteral<"record.declaration-archive">, z.ZodLiteral<"record.declaration-reinstate">]>, z.ZodLiteral<"record.register">, z.ZodLiteral<"record.registration-print&issue-certified-copies">, z.ZodUnion<[z.ZodLiteral<"record.registration-request-correction">, z.ZodLiteral<"record.registration-correct">, z.ZodLiteral<"record.confirm-registration">, z.ZodLiteral<"record.reject-registration">]>, z.ZodUnion<[z.ZodLiteral<"search.birth:my-jurisdiction">, z.ZodLiteral<"search.birth">, z.ZodLiteral<"search.death:my-jurisdiction">, z.ZodLiteral<"search.death">, z.ZodLiteral<"search.marriage:my-jurisdiction">, z.ZodLiteral<"search.marriage">]>, z.ZodLiteral<"record.read">, z.ZodLiteral<"profile.electronic-signature">, z.ZodUnion<[z.ZodLiteral<"performance.read">, z.ZodLiteral<"performance.read-dashboards">, z.ZodLiteral<"performance.vital-statistics-export">]>, z.ZodUnion<[z.ZodLiteral<"organisation.read-locations:all">, z.ZodLiteral<"organisation.read-locations:my-office">, z.ZodLiteral<"organisation.read-locations:my-jurisdiction">]>, z.ZodUnion<[z.ZodLiteral<"user.read:all">, z.ZodLiteral<"user.read:my-office">, z.ZodLiteral<"user.read:my-jurisdiction">, z.ZodLiteral<"user.read:only-my-audit">, z.ZodLiteral<"user.create:all">, z.ZodLiteral<"user.create:my-jurisdiction">, z.ZodLiteral<"user.update:all">, z.ZodLiteral<"user.update:my-jurisdiction">]>, z.ZodLiteral<"config.update:all">, z.ZodLiteral<"user.data-seeding">, z.ZodUnion<[z.ZodLiteral<"record.reindex">, z.ZodLiteral<"record.import">]>]>;
|
|
67
|
+
declare const LiteralScopes: z.ZodUnion<[z.ZodUnion<[z.ZodLiteral<"bypassratelimit">, z.ZodLiteral<"register">, z.ZodLiteral<"demo">, z.ZodLiteral<"config">]>, z.ZodUnion<[z.ZodLiteral<"webhook">, z.ZodLiteral<"nationalId">, z.ZodLiteral<"notification-api">, z.ZodLiteral<"recordsearch">]>, z.ZodLiteral<"record.unassign-others">, z.ZodUnion<[z.ZodLiteral<"record.declare-birth">, z.ZodLiteral<"record.declare-birth:my-jurisdiction">, z.ZodLiteral<"record.declare-death">, z.ZodLiteral<"record.declare-death:my-jurisdiction">, z.ZodLiteral<"record.declare-marriage">, z.ZodLiteral<"record.declare-marriage:my-jurisdiction">, z.ZodLiteral<"record.declaration-submit-incomplete">, z.ZodLiteral<"record.declaration-submit-for-review">]>, z.ZodUnion<[z.ZodLiteral<"record.declaration-submit-for-approval">, z.ZodLiteral<"record.declaration-submit-for-updates">, z.ZodLiteral<"record.declaration-edit">, z.ZodLiteral<"record.review-duplicates">, z.ZodLiteral<"record.declaration-archive">, z.ZodLiteral<"record.declaration-reinstate">]>, z.ZodLiteral<"record.register">, z.ZodLiteral<"record.registration-print&issue-certified-copies">, z.ZodUnion<[z.ZodLiteral<"record.registration-request-correction">, z.ZodLiteral<"record.registration-correct">, z.ZodLiteral<"record.confirm-registration">, z.ZodLiteral<"record.reject-registration">]>, z.ZodUnion<[z.ZodLiteral<"search.birth:my-jurisdiction">, z.ZodLiteral<"search.birth">, z.ZodLiteral<"search.death:my-jurisdiction">, z.ZodLiteral<"search.death">, z.ZodLiteral<"search.marriage:my-jurisdiction">, z.ZodLiteral<"search.marriage">]>, z.ZodLiteral<"record.read">, z.ZodLiteral<"profile.electronic-signature">, z.ZodUnion<[z.ZodLiteral<"performance.read">, z.ZodLiteral<"performance.read-dashboards">, z.ZodLiteral<"performance.vital-statistics-export">]>, z.ZodUnion<[z.ZodLiteral<"organisation.read-locations:all">, z.ZodLiteral<"organisation.read-locations:my-office">, z.ZodLiteral<"organisation.read-locations:my-jurisdiction">]>, z.ZodUnion<[z.ZodLiteral<"user.read:all">, z.ZodLiteral<"user.read:my-office">, z.ZodLiteral<"user.read:my-jurisdiction">, z.ZodLiteral<"user.read:only-my-audit">, z.ZodLiteral<"user.create:all">, z.ZodLiteral<"user.create:my-jurisdiction">, z.ZodLiteral<"user.update:all">, z.ZodLiteral<"user.update:my-jurisdiction">]>, z.ZodLiteral<"config.update:all">, z.ZodLiteral<"user.data-seeding">, z.ZodUnion<[z.ZodLiteral<"record.reindex">, z.ZodLiteral<"record.import">]>, z.ZodLiteral<"integration.create">]>;
|
|
67
68
|
declare const SearchScope: z.ZodObject<{
|
|
68
69
|
type: z.ZodLiteral<"search">;
|
|
69
70
|
options: z.ZodObject<{
|
|
@@ -354,7 +355,7 @@ export declare function parseConfigurableScope(scope: string): {
|
|
|
354
355
|
};
|
|
355
356
|
} | undefined;
|
|
356
357
|
export declare function parseLiteralScope(scope: string): {
|
|
357
|
-
type: "bypassratelimit" | "register" | "demo" | "config" | "webhook" | "nationalId" | "notification-api" | "recordsearch" | "record.import" | "record.reindex" | "record.declare-birth" | "record.declare-birth:my-jurisdiction" | "record.declare-death" | "record.declare-death:my-jurisdiction" | "record.declare-marriage" | "record.declare-marriage:my-jurisdiction" | "record.declaration-submit-incomplete" | "record.declaration-submit-for-review" | "record.unassign-others" | "record.declaration-submit-for-approval" | "record.declaration-submit-for-updates" | "record.declaration-edit" | "record.review-duplicates" | "record.declaration-archive" | "record.declaration-reinstate" | "record.register" | "record.registration-print&issue-certified-copies" | "record.registration-request-correction" | "record.registration-correct" | "record.confirm-registration" | "record.reject-registration" | "search.birth:my-jurisdiction" | "search.birth" | "search.death:my-jurisdiction" | "search.death" | "search.marriage:my-jurisdiction" | "search.marriage" | "record.read" | "profile.electronic-signature" | "performance.read" | "performance.read-dashboards" | "performance.vital-statistics-export" | "organisation.read-locations:all" | "organisation.read-locations:my-office" | "organisation.read-locations:my-jurisdiction" | "user.read:all" | "user.read:my-office" | "user.read:my-jurisdiction" | "user.read:only-my-audit" | "user.create:all" | "user.create:my-jurisdiction" | "user.update:all" | "user.update:my-jurisdiction" | "config.update:all" | "user.data-seeding";
|
|
358
|
+
type: "bypassratelimit" | "register" | "demo" | "config" | "webhook" | "nationalId" | "notification-api" | "recordsearch" | "record.import" | "record.reindex" | "record.declare-birth" | "record.declare-birth:my-jurisdiction" | "record.declare-death" | "record.declare-death:my-jurisdiction" | "record.declare-marriage" | "record.declare-marriage:my-jurisdiction" | "record.declaration-submit-incomplete" | "record.declaration-submit-for-review" | "record.unassign-others" | "record.declaration-submit-for-approval" | "record.declaration-submit-for-updates" | "record.declaration-edit" | "record.review-duplicates" | "record.declaration-archive" | "record.declaration-reinstate" | "record.register" | "record.registration-print&issue-certified-copies" | "record.registration-request-correction" | "record.registration-correct" | "record.confirm-registration" | "record.reject-registration" | "search.birth:my-jurisdiction" | "search.birth" | "search.death:my-jurisdiction" | "search.death" | "search.marriage:my-jurisdiction" | "search.marriage" | "record.read" | "profile.electronic-signature" | "performance.read" | "performance.read-dashboards" | "performance.vital-statistics-export" | "organisation.read-locations:all" | "organisation.read-locations:my-office" | "organisation.read-locations:my-jurisdiction" | "user.read:all" | "user.read:my-office" | "user.read:my-jurisdiction" | "user.read:only-my-audit" | "user.create:all" | "user.create:my-jurisdiction" | "user.update:all" | "user.update:my-jurisdiction" | "config.update:all" | "user.data-seeding" | "integration.create";
|
|
358
359
|
} | undefined;
|
|
359
360
|
/**
|
|
360
361
|
* Stringifies a ConfigurableScopes object into a scope string.
|
package/dist/scopes/index.js
CHANGED
|
@@ -112,7 +112,9 @@ var SCOPES = {
|
|
|
112
112
|
// config
|
|
113
113
|
CONFIG_UPDATE_ALL: "config.update:all",
|
|
114
114
|
// data seeding
|
|
115
|
-
USER_DATA_SEEDING: "user.data-seeding"
|
|
115
|
+
USER_DATA_SEEDING: "user.data-seeding",
|
|
116
|
+
// bootstrap: allows countryconfig to register integrations on startup
|
|
117
|
+
INTEGRATION_CREATE: "integration.create"
|
|
116
118
|
};
|
|
117
119
|
var LegacyScopes = import_zod.z.union([
|
|
118
120
|
import_zod.z.literal(SCOPES.BYPASSRATELIMIT),
|
|
@@ -187,6 +189,7 @@ var UserScopes = import_zod.z.union([
|
|
|
187
189
|
]);
|
|
188
190
|
var ConfigScope = import_zod.z.literal(SCOPES.CONFIG_UPDATE_ALL);
|
|
189
191
|
var DataSeedingScope = import_zod.z.literal(SCOPES.USER_DATA_SEEDING);
|
|
192
|
+
var IntegrationCreateScope = import_zod.z.literal(SCOPES.INTEGRATION_CREATE);
|
|
190
193
|
var LiteralScopes = import_zod.z.union([
|
|
191
194
|
LegacyScopes,
|
|
192
195
|
IntegrationScopes,
|
|
@@ -204,7 +207,8 @@ var LiteralScopes = import_zod.z.union([
|
|
|
204
207
|
UserScopes,
|
|
205
208
|
ConfigScope,
|
|
206
209
|
DataSeedingScope,
|
|
207
|
-
InternalOperationsScopes
|
|
210
|
+
InternalOperationsScopes,
|
|
211
|
+
IntegrationCreateScope
|
|
208
212
|
]);
|
|
209
213
|
var rawConfigurableScopeRegex = /^([a-zA-Z][a-zA-Z0-9.-]*(?:\.[a-zA-Z0-9.-]+)*)\[((?:\w+=[\w.-]+(?:\|[\w.-]+)*)(?:,[\w]+=[\w.-]+(?:\|[\w.-]+)*)*)\]$/;
|
|
210
214
|
var rawConfigurableScope = import_zod.z.string().regex(rawConfigurableScopeRegex);
|