grm-shared-library 1.1.216 → 1.1.218
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/cjs/modules/alert-intake/dtos/alert-intake.dto.js +39 -1
- package/dist/cjs/modules/alert-intake/dtos/alert-intake.dto.js.map +1 -1
- package/dist/cjs/modules/alert-intake/index.js +1 -0
- package/dist/cjs/modules/alert-intake/index.js.map +1 -1
- package/dist/cjs/modules/alert-intake/interfaces/alert-intake-analytics.js +3 -0
- package/dist/cjs/modules/alert-intake/interfaces/alert-intake-analytics.js.map +1 -0
- package/dist/cjs/modules/permission/data/permissions.data.js +26 -4
- package/dist/cjs/modules/permission/data/permissions.data.js.map +1 -1
- package/dist/cjs/modules/permission/enums/permission-actions.enum.js +91 -6
- package/dist/cjs/modules/permission/enums/permission-actions.enum.js.map +1 -1
- package/dist/cjs/modules/role/constants/roles-by-scope.js +2 -1
- package/dist/cjs/modules/role/constants/roles-by-scope.js.map +1 -1
- package/dist/cjs/modules/role/data/roles.data.js +125 -16
- package/dist/cjs/modules/role/data/roles.data.js.map +1 -1
- package/dist/cjs/modules/role/enums/role.enum.js +8 -0
- package/dist/cjs/modules/role/enums/role.enum.js.map +1 -1
- package/dist/esm/modules/alert-intake/dtos/alert-intake.dto.js +37 -1
- package/dist/esm/modules/alert-intake/dtos/alert-intake.dto.js.map +1 -1
- package/dist/esm/modules/alert-intake/index.js +1 -0
- package/dist/esm/modules/alert-intake/index.js.map +1 -1
- package/dist/esm/modules/alert-intake/interfaces/alert-intake-analytics.js +2 -0
- package/dist/esm/modules/alert-intake/interfaces/alert-intake-analytics.js.map +1 -0
- package/dist/esm/modules/permission/data/permissions.data.js +26 -4
- package/dist/esm/modules/permission/data/permissions.data.js.map +1 -1
- package/dist/esm/modules/permission/enums/permission-actions.enum.js +90 -5
- package/dist/esm/modules/permission/enums/permission-actions.enum.js.map +1 -1
- package/dist/esm/modules/role/constants/roles-by-scope.js +2 -1
- package/dist/esm/modules/role/constants/roles-by-scope.js.map +1 -1
- package/dist/esm/modules/role/data/roles.data.js +125 -16
- package/dist/esm/modules/role/data/roles.data.js.map +1 -1
- package/dist/esm/modules/role/enums/role.enum.js +8 -0
- package/dist/esm/modules/role/enums/role.enum.js.map +1 -1
- package/dist/types/modules/alert-intake/dtos/alert-intake.dto.d.ts +14 -0
- package/dist/types/modules/alert-intake/index.d.ts +1 -0
- package/dist/types/modules/alert-intake/interfaces/alert-intake-analytics.d.ts +241 -0
- package/dist/types/modules/permission/enums/permission-actions.enum.d.ts +47 -3
- package/dist/types/modules/role/enums/role.enum.d.ts +8 -0
- package/package.json +1 -1
|
@@ -18,6 +18,14 @@ export var Roles;
|
|
|
18
18
|
* concerns, so this role is scoped there rather than to a control centre.
|
|
19
19
|
*/
|
|
20
20
|
Roles["ORGANIZATION_SUPPORT_ADMIN"] = "Organization:Support-Admin";
|
|
21
|
+
/**
|
|
22
|
+
* Sets up and runs the organization's alert channels - the SMS short codes,
|
|
23
|
+
* WhatsApp numbers and mailboxes the public reaches it on without the app
|
|
24
|
+
* (clarion-alerts) - and works what arrives on them: the messages, the review
|
|
25
|
+
* queue of what screening held back, and the channels' analytics. Configuring
|
|
26
|
+
* a channel is an organization-level decision, so the role is scoped there.
|
|
27
|
+
*/
|
|
28
|
+
Roles["ORGANIZATION_ALERT_CHANNELS_ADMIN"] = "Organization:Alert-Channels-Admin";
|
|
21
29
|
Roles["CONTROL_CENTRE_ADMIN"] = "Control-Centre:Admin";
|
|
22
30
|
Roles["CONTROL_CENTRE_USER"] = "Control-Centre:User";
|
|
23
31
|
/** The same job, confined to one control centre. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"role.enum.js","sourceRoot":"","sources":["../../../../../src/modules/role/enums/role.enum.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,
|
|
1
|
+
{"version":3,"file":"role.enum.js","sourceRoot":"","sources":["../../../../../src/modules/role/enums/role.enum.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,KAiCX;AAjCD,WAAY,KAAK;IACb,oCAA2B,CAAA;IAC3B,kDAAyC,CAAA;IACzC,kDAAyC,CAAA;IACzC,gDAAuC,CAAA;IACvC,kEAAyD,CAAA;IACzD,oEAA2D,CAAA;IAC3D,4EAAmE,CAAA;IACnE;;;OAGG;IACH,gFAAuE,CAAA;IACvE;;;;OAIG;IACH,kEAAyD,CAAA;IACzD;;;;;;OAMG;IACH,gFAAuE,CAAA;IACvE,sDAA6C,CAAA;IAC7C,oDAA2C,CAAA;IAC3C,oDAAoD;IACpD,oFAA2E,CAAA;IAC3E,gCAAuB,CAAA;IACvB,oCAA2B,CAAA;AAC/B,CAAC,EAjCW,KAAK,KAAL,KAAK,QAiChB;AAED;;;;;;;;;;;GAWG"}
|
|
@@ -63,6 +63,20 @@ export declare class ListAlertIntakeScreenedMessagesQueryDto {
|
|
|
63
63
|
page?: number;
|
|
64
64
|
limit?: number;
|
|
65
65
|
}
|
|
66
|
+
/**
|
|
67
|
+
* The period an analytics read covers. Both ends optional: no `from` is "forever" (from
|
|
68
|
+
* the first message), no `to` is now. The service chooses how finely to cut the period for
|
|
69
|
+
* the charts, and counts arrivals by weekday and hour in `timeZone` (default Africa/Nairobi).
|
|
70
|
+
*/
|
|
71
|
+
export declare class AlertIntakeAnalyticsQueryDto {
|
|
72
|
+
from?: string;
|
|
73
|
+
to?: string;
|
|
74
|
+
timeZone?: string;
|
|
75
|
+
}
|
|
76
|
+
/** Platform operators: every organization's analytics, or one organization's. */
|
|
77
|
+
export declare class PlatformAlertIntakeAnalyticsQueryDto extends AlertIntakeAnalyticsQueryDto {
|
|
78
|
+
organizationId?: number;
|
|
79
|
+
}
|
|
66
80
|
/**
|
|
67
81
|
* A reviewer's decision on one or more screened messages. ELEVATE raises each as an
|
|
68
82
|
* incident (a grievance, for a grievance desk) without screening it again; DISMISS
|
|
@@ -0,0 +1,241 @@
|
|
|
1
|
+
import { AlertIntakeChannel, AlertIntakeMessageState, AlertIntakeScreeningReason, AlertIntakeScreeningSource, AlertIntakeScreeningStatus } from '../enums/alert-intake.enum';
|
|
2
|
+
/**
|
|
3
|
+
* Alert intake analytics: what arrived on an organization's channels over a period, what
|
|
4
|
+
* became of it, what the AI made of it and what that cost. One read, computed by
|
|
5
|
+
* clarion-alerts from one consistent snapshot, so every number on a dashboard agrees with
|
|
6
|
+
* every other.
|
|
7
|
+
*
|
|
8
|
+
* Counts only: no message text, sender or credential is ever part of it.
|
|
9
|
+
*/
|
|
10
|
+
/** How the period is cut into points for the charts. Chosen by the service from the length of the period. */
|
|
11
|
+
export type AlertIntakeAnalyticsBucket = 'hour' | 'day' | 'week' | 'month';
|
|
12
|
+
/** The AI tasks whose calls are metered. */
|
|
13
|
+
export type AlertIntakeAiTask = 'triage' | 'analysis' | 'transcription';
|
|
14
|
+
export interface AlertIntakeAnalyticsRange {
|
|
15
|
+
/** Inclusive, ISO 8601. The first message received when the period asked for was "forever". */
|
|
16
|
+
from: string;
|
|
17
|
+
/** Exclusive, ISO 8601. */
|
|
18
|
+
to: string;
|
|
19
|
+
bucket: AlertIntakeAnalyticsBucket;
|
|
20
|
+
/** IANA time zone the buckets and the hour-of-week grid are cut in. */
|
|
21
|
+
timeZone: string;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* The headline counts. Messages are counted by when they arrived.
|
|
25
|
+
*
|
|
26
|
+
* received = raised + screenedOut + duplicates + retrying + parked + queued: every message
|
|
27
|
+
* is in exactly one of those, as it stands now.
|
|
28
|
+
*/
|
|
29
|
+
export interface AlertIntakeAnalyticsTotals {
|
|
30
|
+
received: number;
|
|
31
|
+
/** Became incidents (grievances, for a grievance desk) - including screened messages a reviewer raised. */
|
|
32
|
+
raised: number;
|
|
33
|
+
/** Screened out as not a report and not raised since (waiting for review, or dismissed). */
|
|
34
|
+
screenedOut: number;
|
|
35
|
+
duplicates: number;
|
|
36
|
+
retrying: number;
|
|
37
|
+
parked: number;
|
|
38
|
+
/** Waiting for, or being worked on by, the pipeline. */
|
|
39
|
+
queued: number;
|
|
40
|
+
/** Distinct phone numbers, WhatsApp numbers and email addresses. Never the values themselves. */
|
|
41
|
+
uniqueSenders: number;
|
|
42
|
+
withAttachments: number;
|
|
43
|
+
sharedLocations: number;
|
|
44
|
+
/** Written in a language other than English, and translated. */
|
|
45
|
+
translated: number;
|
|
46
|
+
voiceNotes: number;
|
|
47
|
+
emergencies: number;
|
|
48
|
+
sensitive: number;
|
|
49
|
+
anonymous: number;
|
|
50
|
+
acknowledged: number;
|
|
51
|
+
acknowledgementFailed: number;
|
|
52
|
+
/** Median seconds from arrival to the incident being raised; null when nothing was raised. */
|
|
53
|
+
medianSecondsToIncident: number | null;
|
|
54
|
+
p90SecondsToIncident: number | null;
|
|
55
|
+
/** AI spend in the period, US dollars. */
|
|
56
|
+
aiCostUsd: number;
|
|
57
|
+
}
|
|
58
|
+
/** The previous period of the same length, for the change shown on each headline figure. Null for "forever". */
|
|
59
|
+
export interface AlertIntakeAnalyticsComparison {
|
|
60
|
+
from: string;
|
|
61
|
+
to: string;
|
|
62
|
+
received: number;
|
|
63
|
+
raised: number;
|
|
64
|
+
screenedOut: number;
|
|
65
|
+
uniqueSenders: number;
|
|
66
|
+
medianSecondsToIncident: number | null;
|
|
67
|
+
aiCostUsd: number;
|
|
68
|
+
}
|
|
69
|
+
/** One point on the message timeline. `bucket` is the start of the point, local to `timeZone`, ISO 8601 without an offset. */
|
|
70
|
+
export interface AlertIntakeAnalyticsTimelinePoint {
|
|
71
|
+
bucket: string;
|
|
72
|
+
received: number;
|
|
73
|
+
raised: number;
|
|
74
|
+
screenedOut: number;
|
|
75
|
+
duplicates: number;
|
|
76
|
+
failed: number;
|
|
77
|
+
}
|
|
78
|
+
/** Where messages stand now; the parts add up to `received`. `failed` is retrying and parked together. */
|
|
79
|
+
export interface AlertIntakeAnalyticsOutcomes {
|
|
80
|
+
received: number;
|
|
81
|
+
raised: number;
|
|
82
|
+
screenedOut: number;
|
|
83
|
+
duplicates: number;
|
|
84
|
+
failed: number;
|
|
85
|
+
queued: number;
|
|
86
|
+
}
|
|
87
|
+
export interface AlertIntakeAnalyticsChannelRow extends AlertIntakeAnalyticsOutcomes {
|
|
88
|
+
channel: AlertIntakeChannel;
|
|
89
|
+
medianSecondsToIncident: number | null;
|
|
90
|
+
}
|
|
91
|
+
export interface AlertIntakeAnalyticsConnectionRow extends AlertIntakeAnalyticsOutcomes {
|
|
92
|
+
/** Null for messages received before connections existed. */
|
|
93
|
+
connectionId: string | null;
|
|
94
|
+
name: string;
|
|
95
|
+
channel: AlertIntakeChannel | null;
|
|
96
|
+
provider: string | null;
|
|
97
|
+
enabled: boolean | null;
|
|
98
|
+
lastReceivedAt: string | null;
|
|
99
|
+
/** The connection's current error, if it is failing. */
|
|
100
|
+
lastError: string | null;
|
|
101
|
+
}
|
|
102
|
+
export interface AlertIntakeAnalyticsCount<K extends string | number | null = string> {
|
|
103
|
+
key: K;
|
|
104
|
+
count: number;
|
|
105
|
+
}
|
|
106
|
+
/** Every screening decision on messages received in the period - including those a reviewer later raised. */
|
|
107
|
+
export interface AlertIntakeAnalyticsScreening {
|
|
108
|
+
byReason: AlertIntakeAnalyticsCount<AlertIntakeScreeningReason>[];
|
|
109
|
+
byDecider: AlertIntakeAnalyticsCount<AlertIntakeScreeningSource>[];
|
|
110
|
+
byStatus: AlertIntakeAnalyticsCount<AlertIntakeScreeningStatus>[];
|
|
111
|
+
/** Mean confidence of the model's screening decisions (0-1); null without any. */
|
|
112
|
+
averageAiConfidence: number | null;
|
|
113
|
+
/** Median hours from being screened out to a person's decision; null without reviews. */
|
|
114
|
+
medianHoursToReview: number | null;
|
|
115
|
+
/** Screened messages still waiting for a person - now, whatever the period. */
|
|
116
|
+
awaitingReview: number;
|
|
117
|
+
}
|
|
118
|
+
export interface AlertIntakeAnalyticsLanguageRow {
|
|
119
|
+
/** ISO 639-1, or `und` when it could not be told. */
|
|
120
|
+
language: string;
|
|
121
|
+
count: number;
|
|
122
|
+
translated: number;
|
|
123
|
+
}
|
|
124
|
+
export interface AlertIntakeAnalyticsCategoryRow {
|
|
125
|
+
categoryId: number | null;
|
|
126
|
+
/** The organization's category name; "Uncategorised" for reports filed without one. */
|
|
127
|
+
name: string;
|
|
128
|
+
count: number;
|
|
129
|
+
}
|
|
130
|
+
export interface AlertIntakeAnalyticsLocations {
|
|
131
|
+
/** Reports placed on the map, by how: the sender's shared pin, or a place named in the message. */
|
|
132
|
+
shared: number;
|
|
133
|
+
geocoded: number;
|
|
134
|
+
unresolved: number;
|
|
135
|
+
byCountry: AlertIntakeAnalyticsCount[];
|
|
136
|
+
}
|
|
137
|
+
export interface AlertIntakeAnalyticsAttachments {
|
|
138
|
+
files: number;
|
|
139
|
+
attached: number;
|
|
140
|
+
failed: number;
|
|
141
|
+
/** `image`, `audio`, `video`, `document`. */
|
|
142
|
+
byKind: Array<{
|
|
143
|
+
kind: string;
|
|
144
|
+
files: number;
|
|
145
|
+
attached: number;
|
|
146
|
+
failed: number;
|
|
147
|
+
}>;
|
|
148
|
+
}
|
|
149
|
+
/** Arrivals by weekday (1 = Monday ... 7 = Sunday) and hour (0-23), in `timeZone`. All 168 cells, zeros included. */
|
|
150
|
+
export interface AlertIntakeAnalyticsHeatCell {
|
|
151
|
+
weekday: number;
|
|
152
|
+
hour: number;
|
|
153
|
+
count: number;
|
|
154
|
+
}
|
|
155
|
+
export interface AlertIntakeAiTaskRow {
|
|
156
|
+
task: AlertIntakeAiTask;
|
|
157
|
+
calls: number;
|
|
158
|
+
failed: number;
|
|
159
|
+
cached: number;
|
|
160
|
+
inputTokens: number;
|
|
161
|
+
cachedInputTokens: number;
|
|
162
|
+
outputTokens: number;
|
|
163
|
+
reasoningTokens: number;
|
|
164
|
+
audioSeconds: number;
|
|
165
|
+
costUsd: number;
|
|
166
|
+
averageLatencyMs: number | null;
|
|
167
|
+
p90LatencyMs: number | null;
|
|
168
|
+
}
|
|
169
|
+
export interface AlertIntakeAiModelRow {
|
|
170
|
+
model: string;
|
|
171
|
+
task: AlertIntakeAiTask;
|
|
172
|
+
calls: number;
|
|
173
|
+
inputTokens: number;
|
|
174
|
+
outputTokens: number;
|
|
175
|
+
costUsd: number;
|
|
176
|
+
/** Calls whose model had no price in the service's price table: their cost is not in `costUsd`. */
|
|
177
|
+
unpricedCalls: number;
|
|
178
|
+
}
|
|
179
|
+
export interface AlertIntakeAiTimelinePoint {
|
|
180
|
+
bucket: string;
|
|
181
|
+
calls: number;
|
|
182
|
+
inputTokens: number;
|
|
183
|
+
outputTokens: number;
|
|
184
|
+
costUsd: number;
|
|
185
|
+
}
|
|
186
|
+
export interface AlertIntakeAnalyticsAi {
|
|
187
|
+
calls: number;
|
|
188
|
+
failed: number;
|
|
189
|
+
cached: number;
|
|
190
|
+
inputTokens: number;
|
|
191
|
+
cachedInputTokens: number;
|
|
192
|
+
outputTokens: number;
|
|
193
|
+
reasoningTokens: number;
|
|
194
|
+
audioSeconds: number;
|
|
195
|
+
costUsd: number;
|
|
196
|
+
/** AI spend divided by messages received / incidents raised in the period; null when there were none. */
|
|
197
|
+
costPerMessageUsd: number | null;
|
|
198
|
+
costPerIncidentUsd: number | null;
|
|
199
|
+
byTask: AlertIntakeAiTaskRow[];
|
|
200
|
+
byModel: AlertIntakeAiModelRow[];
|
|
201
|
+
timeline: AlertIntakeAiTimelinePoint[];
|
|
202
|
+
/** When the prices used were last reviewed (the service's price table), ISO date. */
|
|
203
|
+
pricesAsOf: string;
|
|
204
|
+
}
|
|
205
|
+
/** Platform view only: one row per organization. */
|
|
206
|
+
export interface AlertIntakeAnalyticsOrganizationRow {
|
|
207
|
+
organizationId: number | null;
|
|
208
|
+
name: string;
|
|
209
|
+
received: number;
|
|
210
|
+
raised: number;
|
|
211
|
+
screenedOut: number;
|
|
212
|
+
aiCostUsd: number;
|
|
213
|
+
}
|
|
214
|
+
export interface AlertIntakeAnalytics {
|
|
215
|
+
/** Null for the platform view across every organization. */
|
|
216
|
+
organizationId: number | null;
|
|
217
|
+
range: AlertIntakeAnalyticsRange;
|
|
218
|
+
generatedAt: string;
|
|
219
|
+
totals: AlertIntakeAnalyticsTotals;
|
|
220
|
+
previous: AlertIntakeAnalyticsComparison | null;
|
|
221
|
+
timeline: AlertIntakeAnalyticsTimelinePoint[];
|
|
222
|
+
byState: AlertIntakeAnalyticsCount<AlertIntakeMessageState>[];
|
|
223
|
+
/** Every channel, zeros included. */
|
|
224
|
+
byChannel: AlertIntakeAnalyticsChannelRow[];
|
|
225
|
+
/**
|
|
226
|
+
* The organization's own connections - including those that received nothing - and any
|
|
227
|
+
* platform connection that carried its messages (without that connection's status).
|
|
228
|
+
*/
|
|
229
|
+
byConnection: AlertIntakeAnalyticsConnectionRow[];
|
|
230
|
+
screening: AlertIntakeAnalyticsScreening;
|
|
231
|
+
languages: AlertIntakeAnalyticsLanguageRow[];
|
|
232
|
+
categories: AlertIntakeAnalyticsCategoryRow[];
|
|
233
|
+
/** Low, Medium, High, Critical. */
|
|
234
|
+
priorities: AlertIntakeAnalyticsCount[];
|
|
235
|
+
locations: AlertIntakeAnalyticsLocations;
|
|
236
|
+
attachments: AlertIntakeAnalyticsAttachments;
|
|
237
|
+
heatmap: AlertIntakeAnalyticsHeatCell[];
|
|
238
|
+
ai: AlertIntakeAnalyticsAi;
|
|
239
|
+
/** Platform view only. */
|
|
240
|
+
byOrganization?: AlertIntakeAnalyticsOrganizationRow[];
|
|
241
|
+
}
|
|
@@ -147,10 +147,54 @@ export declare enum PermissionActions {
|
|
|
147
147
|
PUBLISH_NEWSFEED_POST = "publish:newsfeed-post",
|
|
148
148
|
ARCHIVE_NEWSFEED_POST = "archive:newsfeed-post",
|
|
149
149
|
DELETE_NEWSFEED_POST = "delete:newsfeed-post",
|
|
150
|
+
READ_NOTIFICATION_BRANDING = "read:notification-branding",
|
|
151
|
+
UPDATE_NOTIFICATION_BRANDING = "update:notification-branding",
|
|
152
|
+
CREATE_NOTIFICATION_EMAIL_SENDER = "create:notification-email-sender",
|
|
153
|
+
READ_NOTIFICATION_EMAIL_SENDER = "read:notification-email-sender",
|
|
154
|
+
UPDATE_NOTIFICATION_EMAIL_SENDER = "update:notification-email-sender",
|
|
155
|
+
DELETE_NOTIFICATION_EMAIL_SENDER = "delete:notification-email-sender",
|
|
156
|
+
CREATE_NOTIFICATION_SMS_SENDER = "create:notification-sms-sender",
|
|
157
|
+
READ_NOTIFICATION_SMS_SENDER = "read:notification-sms-sender",
|
|
158
|
+
UPDATE_NOTIFICATION_SMS_SENDER = "update:notification-sms-sender",
|
|
159
|
+
DELETE_NOTIFICATION_SMS_SENDER = "delete:notification-sms-sender",
|
|
160
|
+
APPROVE_NOTIFICATION_SENDER = "approve:notification-sender",
|
|
161
|
+
/**
|
|
162
|
+
* @deprecated Split into the branding / email sender / SMS sender actions
|
|
163
|
+
* above, which the gateway now requires instead. Still granted to
|
|
164
|
+
* Organization:Owner and Organization:Admin for ONE release, so a gateway that
|
|
165
|
+
* has not yet been redeployed keeps working while clarion-authentication
|
|
166
|
+
* reseeds roles; remove it (and its grants) once every gateway requires the new
|
|
167
|
+
* actions. Grant it to nothing new.
|
|
168
|
+
*/
|
|
150
169
|
READ_NOTIFICATION_SETTINGS = "read:notification-settings",
|
|
170
|
+
/** @deprecated See READ_NOTIFICATION_SETTINGS. */
|
|
151
171
|
MANAGE_NOTIFICATION_SETTINGS = "manage:notification-settings",
|
|
152
|
-
|
|
172
|
+
CREATE_ALERT_INTAKE_CONNECTION = "create:alert-intake-connection",
|
|
173
|
+
READ_ALERT_INTAKE_CONNECTION = "read:alert-intake-connection",
|
|
174
|
+
UPDATE_ALERT_INTAKE_CONNECTION = "update:alert-intake-connection",
|
|
175
|
+
DELETE_ALERT_INTAKE_CONNECTION = "delete:alert-intake-connection",
|
|
176
|
+
TEST_ALERT_INTAKE_CONNECTION = "test:alert-intake-connection",
|
|
177
|
+
READ_ALERT_INTAKE_MESSAGE = "read:alert-intake-message",
|
|
178
|
+
RETRY_ALERT_INTAKE_MESSAGE = "retry:alert-intake-message",
|
|
179
|
+
READ_ALERT_INTAKE_SCREENED_MESSAGE = "read:alert-intake-screened-message",
|
|
180
|
+
REVIEW_ALERT_INTAKE_SCREENED_MESSAGE = "review:alert-intake-screened-message",
|
|
181
|
+
READ_ALERT_INTAKE_ANALYTICS = "read:alert-intake-analytics",
|
|
182
|
+
MANAGE_ALERT_INTAKE_PLATFORM = "manage:alert-intake-platform",
|
|
183
|
+
/**
|
|
184
|
+
* @deprecated Split into the connection / message / screened-message /
|
|
185
|
+
* analytics actions above, which the gateway now requires instead. Still
|
|
186
|
+
* granted to Organization:Owner and Organization:Admin for ONE release, so a
|
|
187
|
+
* gateway that has not yet been redeployed keeps working while
|
|
188
|
+
* clarion-authentication reseeds roles; remove it (and its grants) once every
|
|
189
|
+
* gateway requires the new actions. Grant it to nothing new.
|
|
190
|
+
*/
|
|
153
191
|
READ_ALERT_INTAKE = "read:alert-intake",
|
|
154
|
-
|
|
155
|
-
|
|
192
|
+
/** @deprecated See READ_ALERT_INTAKE. */
|
|
193
|
+
MANAGE_ALERT_INTAKE = "manage:alert-intake"
|
|
156
194
|
}
|
|
195
|
+
/**
|
|
196
|
+
* Actions kept only so a gateway that has not been redeployed keeps working through
|
|
197
|
+
* a release that replaced them. Nothing new may require or be granted them; the
|
|
198
|
+
* next release removes them from the enum, the catalogue and every role.
|
|
199
|
+
*/
|
|
200
|
+
export declare const RETIRING_PERMISSION_ACTIONS: readonly string[];
|
|
@@ -17,6 +17,14 @@ export declare enum Roles {
|
|
|
17
17
|
* concerns, so this role is scoped there rather than to a control centre.
|
|
18
18
|
*/
|
|
19
19
|
ORGANIZATION_SUPPORT_ADMIN = "Organization:Support-Admin",
|
|
20
|
+
/**
|
|
21
|
+
* Sets up and runs the organization's alert channels - the SMS short codes,
|
|
22
|
+
* WhatsApp numbers and mailboxes the public reaches it on without the app
|
|
23
|
+
* (clarion-alerts) - and works what arrives on them: the messages, the review
|
|
24
|
+
* queue of what screening held back, and the channels' analytics. Configuring
|
|
25
|
+
* a channel is an organization-level decision, so the role is scoped there.
|
|
26
|
+
*/
|
|
27
|
+
ORGANIZATION_ALERT_CHANNELS_ADMIN = "Organization:Alert-Channels-Admin",
|
|
20
28
|
CONTROL_CENTRE_ADMIN = "Control-Centre:Admin",
|
|
21
29
|
CONTROL_CENTRE_USER = "Control-Centre:User",
|
|
22
30
|
/** The same job, confined to one control centre. */
|