Removes a cloud account. After you remove a cloud account, it is no longer managed by the enterprise management account of the resource directory to which it belonged.
Note Resource accounts cannot be removed because these accounts depend on the resource
directory to which they belong. If you still want to remove them, upgrade them to
cloud accounts first. For more information, see PromoteResourceAccount.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | RemoveCloudAccount |
The operation that you want to perform. Set the value to RemoveCloudAccount. |
AccountId | String | Yes | 12323344**** |
The ID of the cloud account that you want to remove. |
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
RequestId | String | 9B34724D-54B0-4A51-B34D-4512372FE1BE |
The ID of the request. |
Examples
Sample requests
https://resourcemanager.aliyuncs.com/?Action=RemoveCloudAccount
&AccountId=12323344****
&<Common request parameters>
Sample success responses
XML
format
<RemoveCloudAccountResponse>
<RequestId>9B34724D-54B0-4A51-B34D-4512372FE1BE</RequestId>
</RemoveCloudAccountResponse>
JSON
format
{
"RequestId": "9B34724D-54B0-4A51-B34D-4512372FE1BE"
}
Error codes
HTTP status code | Error code | Error message | Description |
---|---|---|---|
400 | MissingParameter.AccountId | You must specify AccountId. | The error message returned because the AccountId parameter is not specified. |
400 | InvalidParameter.AccountId | The AccountId is invalid. | The error message returned because the value of the AccountId parameter is invalid. Specify a 16-digit ID. |
404 | EntityNotExists.Account | This resource directory account does not exist. | The error message returned because the member account does not exist. Create the member account first. |
409 | AccountTypeOrStatusMismatch | You cannot perform the action on the member account. | The error message returned because you cannot perform the operation on the member account. |
404 | EntityNotExists.ResourceDirectory | The resource directory for the account is not enabled. We recommend that you first enable the resource directory for the account. | The error message returned because the resource directory for the account is not enabled. Enable the resource directory for the account. |
For a list of error codes, visit the API Error Center.