Attach a grant to groups
POST/grants/:id/groups
Attaches the grant to a batch of the organization's groups, skipping those already attached. A sponsored group only accepts cluster-data grants (409).
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 grant or a group 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