All Products
Search
Document Center

Resource Management:UpdateAccount

Last Updated:Aug 28, 2026

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

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request parameters

Parameter

Type

Required

Description

Example

NewDisplayName

string

No

The new display name of the member.

Note

You can specify either NewDisplayName or NewAccountType.

admin

NewAccountType

string

No

The new type of the member. Valid values:

  • ResourceAccount: resource account

  • CloudAccount: cloud account

Note

You can specify either NewDisplayName or NewAccountType.

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:

  • true: performs only a dry run. The system checks whether the member status can be modified and whether security information is configured for the member. If the request does not pass the dry run, an error code is returned.

  • false (default): performs a dry run and performs the actual request.

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: The member is created.

  • InviteSuccess: The member accepts the invitation.

  • Removed: The member is removed.

  • SwitchSuccess: The type of the member is switched.

CreateSuccess

Type

string

The type of the member. Valid values:

  • CloudAccount: cloud account

  • ResourceAccount: resource account

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:

  • invited: The member is invited to join the resource directory.

  • created: The member is directly created in the resource directory.

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.