Groups
Operations of the Identity API (public). Paths are relative to your deployment's API host.
GET /api/identity-api/groups
List groups
List groups, optionally filtered by parentId and/or search. When an organization is in context, results are scoped to that organization's subtree.
Authentication: bearer token (Authorization: Bearer <token>)
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
parentId | query | string | no | Restrict results to direct children of the given parent group id. Omit to list realm-root groups (or, when an organization is in context, the organization itself + its direct children). |
recursive | query | boolean | no | When listing members, include members of all descendant groups too. Ignored on group-list endpoints. |
search | query | string | no | Substring search over the group name (Keycloak semantics). |
skip | query | number | no | Pagination skip (offset). |
take | query | number | no | Pagination take (limit). |
| Status | Description | Body |
|---|---|---|
| 200 | List groups | application/json object |
| 401 | Unauthorized | application/json object |
| 403 | Forbidden | application/json object |
POST /api/identity-api/groups
Create group
Authentication: bearer token (Authorization: Bearer <token>)
Request body: application/json CreateGroupDto
| Status | Description | Body |
|---|---|---|
| 201 | Group created | application/json object |
| 400 | Bad Request | application/json object |
| 401 | Unauthorized | application/json object |
| 403 | Forbidden | application/json object |
| 409 | Conflict | application/json object |
GET /api/identity-api/groups/{id}
Get group by id
Authentication: bearer token (Authorization: Bearer <token>)
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes |
| Status | Description | Body |
|---|---|---|
| 200 | Group detail | application/json object |
| 401 | Unauthorized | application/json object |
| 403 | Forbidden | application/json object |
| 404 | Not Found | application/json object |
PATCH /api/identity-api/groups/{id}
Update group
Authentication: bearer token (Authorization: Bearer <token>)
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes |
Request body: application/json UpdateGroupDto
| Status | Description | Body |
|---|---|---|
| 200 | Group updated | application/json object |
| 400 | Bad Request | application/json object |
| 401 | Unauthorized | application/json object |
| 403 | Forbidden | application/json object |
| 404 | Not Found | application/json object |
| 409 | Conflict | application/json object |
DELETE /api/identity-api/groups/{id}
Delete group
Authentication: bearer token (Authorization: Bearer <token>)
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes |
| Status | Description | Body |
|---|---|---|
| 204 | ||
| 401 | Unauthorized | application/json object |
| 403 | Forbidden | application/json object |
| 404 | Not Found | application/json object |
POST /api/identity-api/groups/{id}/members
Add member to group
Authentication: bearer token (Authorization: Bearer <token>)
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes |
Request body: application/json AddGroupMemberDto
| Status | Description | Body |
|---|---|---|
| 204 | ||
| 401 | Unauthorized | application/json object |
| 403 | Forbidden | application/json object |
| 404 | Not Found | application/json object |
DELETE /api/identity-api/groups/{id}/members/{userId}
Remove member from group
Authentication: bearer token (Authorization: Bearer <token>)
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes | |
userId | path | string | yes |
| Status | Description | Body |
|---|---|---|
| 204 | ||
| 401 | Unauthorized | application/json object |
| 403 | Forbidden | application/json object |
| 404 | Not Found | application/json object |