removeMembersFrom
GroupWrapper removeMembersFrom(id, MembersRequest)
DELETE /api/2.0/group/{id}/members
Remove group members
Removes the listed accounts from a group, leaving the rest of its members in place. The caller needs the permissions to edit groups and to add and remove users, and the ID has to belong to a group that has not been deleted, otherwise the operation answers 404. The accounts themselves are kept; only their membership in this group ends, together with the access they had through it. The call is idempotent and forgiving: an ID that is not a member, and one that matches no account at all, are both skipped without an error, and an empty list simply changes nothing. The answer is the group with the members that remain. Emptying a group cannot be done through POST api/2.0/group/{id}/members, which needs at least one valid account, so list every member here, or move them away with PUT api/2.0/group/{fromId}/members/{toId}.
Parameters
| Name | In | Type | Description | Notes |
|---|---|---|---|---|
| id | path | UUID (uuid) | The ID of the group whose members are changed, taken from the route. It has to be a group that has not been deleted, otherwise the operation answers 404. | [required] [example: 00000000-0000-0000-0000-000000000000] |
| MembersRequest | body | MembersRequest | The accounts to add, replace with, or remove. | [required] |
Responses
| Status code | Description | Type | Response headers |
|---|---|---|---|
| 200 | The group with the members that remain | GroupWrapper | X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset |
| 403 | No permissions to perform this action | - | - |
| 404 | No group has the specified ID | - | - |
| 401 | Unauthorized | ErrorApiResponse | - |
| 429 | Too Many Requests. | ErrorApiResponse | Retry-After |
| 500 | Internal Server Error. | ErrorApiResponse | - |
| 400 | Bad Request. | ErrorApiResponse | - |
| 502 | Bad Gateway. Returned by the reverse proxy, response body may be HTML and not JSON. | - | - |
| 503 | Service Unavailable. Returned by the reverse proxy, response body may be HTML and not JSON. | - | - |
Return type
Authorization
Basic, OAuth2 (scopes: read, write), ApiKeyBearer, asc_auth_key, Bearer, OpenId
HTTP request headers
- Content-Type: application/json
- Accept: application/json