opal-security 3.1.1-beta.9cc3edb → 3.1.1-beta.b652df3

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.
@@ -1,24 +1,30 @@
1
1
  import type { NormalizedCacheObject } from "@apollo/client/core";
2
2
  import type { ApolloClient } from "@apollo/client/core/ApolloClient";
3
3
  import type { Command } from "@oclif/core/lib/command";
4
- interface AppNode {
4
+ import { type AppType, type ConnectionType, EntityType } from "../graphql/graphql";
5
+ type AppNode = {
6
+ appId: string;
5
7
  appName: string;
8
+ appType?: AppType | ConnectionType;
6
9
  assets: Record<string, AssetNode>;
7
- }
8
- interface AssetNode {
10
+ };
11
+ type AssetNode = {
12
+ assetId: string;
9
13
  assetName: string;
10
- type: string;
14
+ type: EntityType;
11
15
  roles?: Record<string, RoleNode>;
12
- }
13
- interface RoleNode {
16
+ };
17
+ type RoleNode = {
18
+ roleId: string;
14
19
  roleName: string;
15
- }
20
+ };
16
21
  export type RequestMap = Record<string, AppNode>;
17
- interface DurationOption {
22
+ export declare const DISPLAY_LABELS: Partial<Record<EntityType, string>>;
23
+ type DurationOption = {
18
24
  durationInMinutes: number;
19
25
  label: string;
20
- }
21
- interface RequestDefaults {
26
+ };
27
+ type RequestDefaults = {
22
28
  durationOptions?: DurationOption[];
23
29
  recommendedDurationInMinutes?: number | null;
24
30
  defaultDurationInMinutes?: number;
@@ -26,21 +32,22 @@ interface RequestDefaults {
26
32
  requireSupportTicket?: boolean;
27
33
  reasonOptional?: boolean;
28
34
  requesterIsAdmin?: boolean;
29
- }
30
- export interface RequestMetadata {
35
+ };
36
+ export type RequestMetadata = {
31
37
  requestMap: RequestMap;
32
38
  requestDefaults: RequestDefaults;
33
39
  durationLabel: string;
34
40
  durationInMinutes?: number;
35
41
  reason: string;
36
- }
42
+ };
37
43
  export declare function initEmptyRequestMetadata(): RequestMetadata;
38
44
  export declare function selectRequestableItems(cmd: Command, client: ApolloClient<NormalizedCacheObject>, requestMap: RequestMap): Promise<void>;
39
- export declare function chooseAssets(cmd: Command, client: ApolloClient<NormalizedCacheObject>, appId: string, requestMap: RequestMap): Promise<void>;
40
- export declare function chooseRoles(cmd: Command, client: ApolloClient<NormalizedCacheObject>, appId: string, assetId: string, requestMap: RequestMap): Promise<void>;
41
45
  export declare function doneSelectingAssets(): Promise<boolean>;
42
46
  export declare function setRequestDefaults(cmd: Command, client: ApolloClient<NormalizedCacheObject>, metadata: RequestMetadata): Promise<void>;
43
47
  export declare function promptForReason(metadata: RequestMetadata): Promise<void>;
44
48
  export declare function promptForExpiration(metadata: RequestMetadata): Promise<void>;
49
+ export declare function promptRequestSubmission(cmd: Command, metadata: RequestMetadata): Promise<boolean>;
45
50
  export declare function submitFinalRequest(cmd: Command, client: ApolloClient<NormalizedCacheObject>, metadata: RequestMetadata): Promise<void>;
51
+ export declare function bypassRequestSelection(cmd: Command, client: ApolloClient<NormalizedCacheObject>, flagValue: string[], metadata: RequestMetadata): Promise<void>;
52
+ export declare function bypassDuration(cmd: Command, duration: number, metadata: RequestMetadata): void;
46
53
  export {};