feat(#1): Add permission and role model

This commit is contained in:
2025-10-31 09:26:37 +01:00
parent 36364a7977
commit 1997877168
12 changed files with 218 additions and 31 deletions

View File

@@ -3,11 +3,13 @@ declare module '#auth-utils' {
keycloakId: string
name: string
organizations: Organization[]
roles: string[]
}
interface UserSession {
name: string
organizations: Organization[]
roles: string[]
loggedInAt: number
jwt: {
accessToken: string

View File

@@ -5,6 +5,11 @@ export interface KeycloakTokenPayload {
family_name?: string
email?: string
organization?: Record<string, { id?: string }>
resource_access?: {
legalconsenthub?: {
roles?: string[]
}
}
}
export interface Organization {