ListRoleAssignments
POST/gitpod.v1.GroupService/ListRoleAssignments
Lists role assignments for a group or resource.
Use this method to:
- View all role assignments for a group
- Audit resource access
- Check which groups have access to resources
Examples
-
List role assignments for a group:
Shows all role assignments for a specific group.
filter: groupId: "d2c94c27-3b76-4a42-b88c-95a85e392c68" pagination: pageSize: 20 -
List role assignments by resource type:
Shows all role assignments for runners.
filter: resourceTypes: - RESOURCE_TYPE_RUNNER pagination: pageSize: 20
Authorization
All organization members can view role assignments (transparency model).
ListRoleAssignments
curl https://app.gitpod.io/api/gitpod.v1.GroupService/ListRoleAssignments \
-H 'Content-Type: application/json' \
-H "Authorization: Bearer $GITPOD_API_KEY" \
-d '{}'{
"assignments": [
{
"id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"derivedFromOrgRole": "RESOURCE_ROLE_UNSPECIFIED",
"groupId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"organizationId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"resourceId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"resourceRole": "RESOURCE_ROLE_UNSPECIFIED",
"resourceType": "RESOURCE_TYPE_UNSPECIFIED"
}
],
"pagination": {
"nextToken": "nextToken"
}
}Returns Examples
{
"assignments": [
{
"id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"derivedFromOrgRole": "RESOURCE_ROLE_UNSPECIFIED",
"groupId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"organizationId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"resourceId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"resourceRole": "RESOURCE_ROLE_UNSPECIFIED",
"resourceType": "RESOURCE_TYPE_UNSPECIFIED"
}
],
"pagination": {
"nextToken": "nextToken"
}
}