-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathaccess-check.interface.ts
More file actions
45 lines (41 loc) · 1.11 KB
/
access-check.interface.ts
File metadata and controls
45 lines (41 loc) · 1.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
// Copyright The Linux Foundation and each contributor to LFX.
// SPDX-License-Identifier: MIT
/**
* Access check request for a single resource
*/
export interface AccessCheckRequest {
/** Resource type (project, meeting, committee) */
resource: AccessCheckResourceType;
/** Resource unique identifier */
id: string;
/** Access type to check (writer, viewer, etc.) */
access: AccessCheckAccessType;
}
/**
* Internal format for the microservice access check API
*/
export interface AccessCheckApiRequest {
/** Array of access check strings in format "resource:id#access" */
requests: string[];
}
/**
* Response from the access check microservice
*/
export interface AccessCheckApiResponse {
/** Array of result strings in format "resource:id#access@user:username\ttrue/false" */
results: string[];
}
/**
* Resource types
*/
export type AccessCheckResourceType =
| 'project'
| 'meeting'
| 'committee'
| 'past_meeting'
| 'v1_meeting'
| 'v1_past_meeting'
| 'groupsio_service'
| 'groupsio_mailing_list'
| 'groupsio_member';
export type AccessCheckAccessType = 'writer' | 'viewer' | 'organizer';