Attach grants to a group
POST/groups/:group_id/grants
Attaches a batch of the organization's grants, skipping those already attached. Every grant must belong to the organization (404 otherwise). A sponsored group only accepts grants whose abilities are all rooted on a cluster (409 otherwise). Changes access at once for every member of the group.
Requires grant:write and at least the org-admin role.
Request
Responses
- 200
- 400
- 401
- 404
- 409
- 422
The IDs newly attached
An ID in the path is not a valid integer
UNAUTHORIZED: the token lacks the grant:read / grant:write ability, or the caller lacks the required role in the organization
The group or a grant does not exist in the current organization
The change violates a sponsored-group rule. error.name is one of SPONSORED_GROUP_REQUIRES_ENTERPRISE (the owner is not enterprise), SPONSORED_GROUP_CLUSTER_ONLY (a grant is not rooted on a cluster), SPONSORED_GROUP_ALREADY_EXISTS (an organization already holds a sponsored group of this owner), SPONSOR_CANNOT_BE_MEMBER (the owner is attached to its own sponsored group) or GROUP_SUSPENSION_PERMANENT (sponsorship cannot be turned back on)
Validation failed