Skip to content

Groups API ​

10 endpoints. Request and response schemas are described on the schemas page; the other tags are listed in the API index.

Endpoints ​

GET /api/v1/groups ​

List groups

List all groups

Responses

StatusDescriptionBody
200List of groupsapplication/json: object
403Forbiddenapplication/json: Error

Fields of the 200 response (application/json):

FieldTypeRequiredDescription
dataarray of Groupno-

POST /api/v1/groups ​

Create group

Create a new group

Request body (required)

application/json: object

FieldTypeRequiredDescription
descriptionstringno-
namestringyes-

Responses

StatusDescriptionBody
201Group createdapplication/json: Group
400Invalid requestapplication/json: Error
403Forbiddenapplication/json: Error

GET /api/v1/groups/{id} ​

Get group

Get details of a specific group

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)yes-

Responses

StatusDescriptionBody
200Group detailsapplication/json: Group
400Invalid request, including a NUL byte in the URL or the bodyapplication/json: Error
403Forbiddenapplication/json: Error
404Group not found-

PATCH /api/v1/groups/{id} ​

Update group

Update a group

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)yes-

Request body (required)

application/json: object

FieldTypeRequiredDescription
descriptionstringno-
namestringno-

Responses

StatusDescriptionBody
200Group updatedapplication/json: Group
400Invalid request, including a NUL byte in the URL or the bodyapplication/json: Error
403Forbiddenapplication/json: Error
404Group not found-

DELETE /api/v1/groups/{id} ​

Delete group

Delete a group

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)yes-

Responses

StatusDescriptionBody
204Group deleted-
400Invalid request, including a NUL byte in the URL or the bodyapplication/json: Error
403Forbiddenapplication/json: Error
404Group not found-

GET /api/v1/groups/{id}/members ​

List group members

List members of a group

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)yes-

Responses

StatusDescriptionBody
200List of group membersapplication/json: object
400Invalid request, including a NUL byte in the URL or the bodyapplication/json: Error
403Forbiddenapplication/json: Error
404Group not found-

Fields of the 200 response (application/json):

FieldTypeRequiredDescription
membersarray of GroupMemberno-

PUT /api/v1/groups/{id}/members ​

Set group members

Replace all members of a group

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)yes-

Request body (required)

application/json: object

FieldTypeRequiredDescription
membersarray of string (uuid)yes-

Responses

StatusDescriptionBody
204Members updated-
400Invalid requestapplication/json: Error
403Forbiddenapplication/json: Error
404Group not found-

POST /api/v1/groups/{id}/members/{userId} ​

Add group member

Add a user to a group

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)yes-
userIdpathstring (uuid)yes-

Responses

StatusDescriptionBody
200Member added-
400Invalid request, including a NUL byte in the URL or the bodyapplication/json: Error
403Forbiddenapplication/json: Error
404Group or user not found-

DELETE /api/v1/groups/{id}/members/{userId} ​

Remove group member

Remove a user from a group

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)yes-
userIdpathstring (uuid)yes-

Responses

StatusDescriptionBody
204Member removed-
400Invalid request, including a NUL byte in the URL or the bodyapplication/json: Error
403Forbiddenapplication/json: Error
404Group or user not found-

GET /api/v1/users/{id}/groups ​

List user's groups

List groups that a user belongs to

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)yes-

Responses

StatusDescriptionBody
200List of groupsapplication/json: object
400Invalid request, including a NUL byte in the URL or the bodyapplication/json: Error
403Forbiddenapplication/json: Error
404User not found-

Fields of the 200 response (application/json):

FieldTypeRequiredDescription
dataarray of Groupno-

Free software under the AGPL-3.0-or-later.