Changes the display name or type of a member.
Operation description
-
To ensure that management operations are traceable, call this operation by using a RAM user or RAM role that has the AliyunResourceDirectoryFullAccess policy attached within the management account of your resource directory.
-
Before you switch a member from resource account to cloud account, make sure that specific conditions are met. For more information, see Switch a resource account to a cloud account.
-
Before you switch a member from cloud account to resource account, make sure that specific conditions are met. For more information, see Switch a cloud account to a resource account.
Try it now
Test
RAM authorization
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| NewDisplayName |
string |
No |
The new display name of the member. Note
You can specify either |
admin |
| NewAccountType |
string |
No |
The new type of the member. Valid values:
Note
You can specify either |
ResourceAccount |
| AccountId |
string |
Yes |
The Alibaba Cloud account ID of the member. |
12323344**** |
| DryRun |
boolean |
No |
Whether to perform only a dry run without performing the actual request. Valid values:
|
false |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
The returned result. |
||
| Account |
object |
The information of the member. |
|
| Status |
string |
The status of the member. Valid values:
|
CreateSuccess |
| Type |
string |
The type of the member. Valid values:
|
ResourceAccount |
| DisplayName |
string |
The display name of the member. |
admin |
| FolderId |
string |
The ID of the folder. |
fd-bVaRIG**** |
| ResourceDirectoryId |
string |
The ID of the resource directory. |
rd-k3**** |
| JoinTime |
string |
The time when the member joined the resource directory, in UTC. |
2015-01-23T12:33:18Z |
| AccountId |
string |
The Alibaba Cloud account ID of the member. |
12323344**** |
| JoinMethod |
string |
How the member joined the resource directory. Valid values:
|
created |
| ModifyTime |
string |
The time when the member was last modified, in UTC. |
2015-01-23T12:33:18Z |
| AccountName |
string |
The Alibaba Cloud account name of the member. |
ecs-manager@aliyun.com |
| RequestId |
string |
The ID of the request. |
9B34724D-54B0-4A51-B34D-4512372FE1BE |
Examples
Success response
JSON format
{
"Account": {
"Status": "CreateSuccess",
"Type": "ResourceAccount",
"DisplayName": "admin",
"FolderId": "fd-bVaRIG****",
"ResourceDirectoryId": "rd-k3****",
"JoinTime": "2015-01-23T12:33:18Z",
"AccountId": "12323344****",
"JoinMethod": "created",
"ModifyTime": "2015-01-23T12:33:18Z",
"AccountName": "ecs-manager@aliyun.com"
},
"RequestId": "9B34724D-54B0-4A51-B34D-4512372FE1BE"
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 404 | EntityNotExists.ResourceDirectory | The resource directory for the account is not enabled. We recommend that you first enable the resource directory for the account. | |
| 404 | EntityNotExists.Account | This resource directory account does not exist. | |
| 409 | InvalidParameter.Account.DisplayName.AlreadyUsed | The displayname of account has been used. | |
| 409 | MissingDisplayNameOrAccountType | Either display name or account type must be specified. | |
| 409 | AccountTypeMismatch | The type or status of the member account cannot satisfy the current operation. | |
| 409 | PrimaryAkInUse | The account has the primary AK in use. | |
| 409 | MissingSecurityInfo | Security information is missing. | |
| 409 | LegalEntityDifferent | The account legal entity is different from the one of the Management Account. | |
| 409 | CallerIdentityError | Please use the RAM user or role of the Management Account. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.