Groups โ
User groups โ named bundles of users used for organizational structure, role assignment, and permission grouping. Group records plus membership operations are managed here.
Scopes โ
| Scope | Reach |
|---|---|
groups:read | Listing, reading groups and their members. |
groups:write | Creating, modifying, deleting groups; managing membership. |
Endpoints โ
List Groups โ
GET /api/admin/groups/
Returns a page of group records.
Required scope: groups:read ยท also accepts API key
Query parameters โ standard pagination set; see Conventions โบ Pagination. Defaults: sort_by=created, sort_order=desc, hydrate=true.
Response 200 โ GroupInDbCursorPage
Get Group Filter Metadata โ
GET /api/admin/groups/filters
Returns filter/operator/sort options for List Groups.
Required scope: groups:read
Response 200 โ open metadata object.
Get Group by ID โ
GET /api/admin/groups/{id}
Returns a single group record.
Required scope: groups:read ยท also accepts API key
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
id | string | yes | Group ID. |
Response 200 โ GroupRead
Get Group Users โ
GET /api/admin/groups/{id}/users
Returns the list of users belonging to a group.
Required scope: groups:read
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
id | string | yes | Group ID. |
Response 200 โ list of user records.
Create Group โ
POST /api/admin/groups/
Creates a new group.
Required scope: groups:write
Request body โ GroupWriteCreate
Response 201 โ GroupRead
Update Group by ID โ
PUT /api/admin/groups/{id}
Replaces the group record.
Required scope: groups:write
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
id | string | yes | Group ID. |
Request body โ GroupWriteReplace
Response 200 โ GroupRead
Patch Group โ
PATCH /api/admin/groups/{id}
Partial group update.
Required scope: groups:write
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
id | string | yes | Group ID. |
Request body โ GroupWriteUpdate
Response 200 โ GroupRead
Delete Group by ID โ
DELETE /api/admin/groups/{id}
Removes a group. Users that were members remain โ only the group record (and their membership of it) goes away.
Required scope: groups:write
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
id | string | yes | Group ID. |
Response 204 โ empty.
Add User to Group โ
POST /api/admin/groups/{id}/users/{user_id}
Adds a user to a group.
Required scope: groups:write
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
id | string | yes | Group ID. |
user_id | string | yes | User ID. |
Response 201 โ UserRead (the user record, now reflecting group membership).
Remove User from Group โ
DELETE /api/admin/groups/{id}/users/{user_id}
Removes a user from a group.
Required scope: groups:write
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
id | string | yes | Group ID. |
user_id | string | yes | User ID. |
Response 200 โ confirmation payload.
See also โ
- Users โ user records added to / removed from groups here.
- Scope Sets โ attach scope bundles to groups via a group's scope-set membership (see the group record schema).
