1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-01-01 00:08:27 +01:00
unleash.unleash/frontend/src/interfaces/user.ts
Nuno Góis 279d3431eb
chore: UI SCIM guard for users (#6859)
https://linear.app/unleash/issue/2-2092/ui-should-not-allow-manual-management-of-scim-managed-users-in-unleash

Adds a UI SCIM guard when trying to manage users.

The condition for the guard is:
 - Enterprise
 - SCIM flag enabled
 - SCIM setting enabled
 - SCIM user


![image](https://github.com/Unleash/unleash/assets/14320932/8a5451f1-0d6e-48ba-b090-bb5832c0e9ec)
2024-04-15 14:04:41 +01:00

28 lines
619 B
TypeScript

export const AccountTypes = ['User', 'Service Account'] as const;
type AccountType = (typeof AccountTypes)[number];
export interface IUser {
id: number;
email: string;
name: string;
createdAt: string;
imageUrl: string;
loginAttempts: number;
permissions: string[] | null;
inviteLink: string;
rootRole: number;
seenAt: string | null;
username?: string;
isAPI: boolean;
paid?: boolean;
addedAt?: string;
accountType?: AccountType;
scimId?: string;
}
export interface IPermission {
permission: string;
project?: string;
environment?: string;
}