Rotate built-in admin accounts in a resource group
POST/api/v1/ManagedResourceGroup/:managedResourceGroupId/RotateAccounts
Schedules a password rotation for the built-in administrator accounts of managed resources and returns how many rotations were scheduled. Send all set to true to rotate every managed resource in the group (for a platform group, every managed resource on that platform), or list resource IDs in ids. Resources whose account cannot be rotated are skipped.
Permission required: Requires the Admin role, or an application account with the App role.
Caution: Rotation changes real account passwords on the selected resources, so confirm the selection before you call it.
Request
Responses
- 200
- 400
- 401
- 403
- 404
The number of rotations scheduled, as a plain integer. Resources that could not be scheduled are skipped and are not listed in this response.
No rotations were scheduled. The body is a list of messages that say why, for example a resource has no host, its platform has no built-in account, the account was not found by a host scan, or the account has dependencies. The list is empty when the request selects no managed resources.
The request is not signed in.
The signed-in user does not have the required role.
No resource group has that ID.