Create a grant
POST/grants
Creates a grant from a list of abilities, optionally attaching it to one existing group in the same transaction (groupId). Each ability path must follow the resource hierarchy (400 INVALID_GRANT_PATH otherwise) and may only name clusters and workflows the organization owns, other than reading another organization's public cluster. The name is unique within the organization (409 GRANT_NAME_ALREADY_EXISTS).
Requires grant:write and at least the org-admin role.
Request
Responses
- 200
- 400
- 401
- 404
- 409
- 422
The created grant
INVALID_GRANT_PATH: an ability path does not follow the resource hierarchy, or names a cluster or workflow the organization does not own
UNAUTHORIZED: the token lacks the grant:read / grant:write ability, or the caller lacks the required role in the organization
groupId does not name a group of this organization
GRANT_NAME_ALREADY_EXISTS: a grant with this name already exists in the organization. SPONSORED_GROUP_CLUSTER_ONLY: groupId is a sponsored group and an ability is not rooted on a cluster
Validation failed