Add resources or resource groups to an access policy
PUT/api/v1/AccessControlPolicy/:policyId/ManagedResource
Adds resources or resource groups to a Resource based access policy and returns how many items passed and how many failed. Items already in the policy count as passed. Items whose id is not found are counted as failed.
Permission required: Administrator, or a custom role with the [AP] Modify Resources permission on this policy.
Values for entityType: 0 = Resource, 1 = ResourceGroup, 2 = SecretVault.
Caution: Adding resources to a policy immediately lets the policy users act on those resources.
Request
Responses
- 200
- 400
- 401
- 403
- 404
The result: passed (number of items changed), failed (number of items not changed) and report (a list of messages, which this route leaves empty).
The list was empty, a listed item does not fit the policy type (the policy is not Resource based), or the change failed. Items processed before the failure stay added.
Returned to a custom-role user who is not allowed to work with this policy.
The caller is not allowed to change this policy.
The access policy was not found.