Skip to content

ProjectGroupMappingModel

Defined in: packages/core/src/models/project-group-mapping.ts:16

Data operations for identity-provider group mappings.

new ProjectGroupMappingModel(db, tables?): ProjectGroupMappingModel

Defined in: packages/core/src/models/project-group-mapping.ts:24

DatabaseAdapter

Database adapter.

ProjectGroupMappingTables

Table handles.

ProjectGroupMappingModel

create(projectId, groupName, role): Promise<ProjectGroupMapping>

Defined in: packages/core/src/models/project-group-mapping.ts:50

Create a group mapping for a project.

string

string

"admin" | "viewer" | "approver" | "developer"

Promise<ProjectGroupMapping>


list(projectId): Promise<ProjectGroupMapping[]>

Defined in: packages/core/src/models/project-group-mapping.ts:30

List all group mappings for a project.

string

Promise<ProjectGroupMapping[]>


remove(projectId, id): Promise<void>

Defined in: packages/core/src/models/project-group-mapping.ts:65

Remove a group mapping by id within a project.

string

string

Promise<void>


static inputError(groupName, role): string | null

Defined in: packages/core/src/models/project-group-mapping.ts:40

Validate group-mapping input; returns an error message, or null when acceptable. Names match exactly: a wildcard would silently grant org-wide access.

string | undefined

string | undefined

string | null