全部产品
Search
文档中心

资源管理:PromoteResourceAccount - 将资源账号升级为云账号

更新时间:Apr 24, 2024

将资源账号升级为云账号,异步操作。

调试

您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

授权信息

下表是API对应的授权信息,可以在RAM权限策略语句的Action元素中使用,用来给RAM用户或RAM角色授予调用此API的权限。具体说明如下:

  • 操作:是指具体的权限点。
  • 访问级别:是指每个操作的访问级别,取值为写入(Write)、读取(Read)或列出(List)。
  • 资源类型:是指操作中支持授权的资源类型。具体说明如下:
    • 对于必选的资源类型,用背景高亮的方式表示。
    • 对于不支持资源级授权的操作,用全部资源表示。
  • 条件关键字:是指云产品自身定义的条件关键字。
  • 关联操作:是指成功执行操作所需要的其他权限。操作者必须同时具备关联操作的权限,操作才能成功。
操作访问级别资源类型条件关键字关联操作
resourcemanager:PromoteResourceAccountWrite
  • Account
    acs:resourcemanager:*:{#accountId}:*

请求参数

名称类型必填描述示例值
AccountIdstring

需要升级的资源账号 ID。

12323344****
Emailstring

升级后的云账号登录邮箱。

someone@example.com

返回参数

名称类型描述示例值
object
Accountobject

成员信息。

Statusstring

成员加入状态。

  • CreateSuccess:创建成功。
  • CreateVerifying:创建确认中。
  • CreateFailed:创建失败。
  • CreateExpired:创建过期。
  • CreateCancelled:创建取消。
  • PromoteVerifying:升级确认中。
  • PromoteFailed:升级失败。
  • PromoteExpired:升级过期。
  • PromoteCancelled:升级取消。
  • PromoteSuccess:升级成功。
  • InviteSuccess:邀请成功。
  • Removed:已移出。
PromoteVerifying
Typestring

成员类型。

  • CloudAccount:云账号。
  • ResourceAccount:资源账号。
ResourceAccount
DisplayNamestring

成员名称。

admin
FolderIdstring

资源夹 ID。

fd-bVaRIG****
ResourceDirectoryIdstring

资源目录 ID。

rd-k3****
RecordIdstring

账号记录 ID。

06950264-3f0d-4ca9-82dd-6ee7a3d33d6b
JoinTimestring

成员加入时间。

2015-01-23T12:33:18Z
AccountIdstring

账号 ID。

12323344****
JoinMethodstring

成员加入方式。

  • invited:邀请。
  • created:创建。
created
AccountNamestring

账号名称。

someone@example.com
ModifyTimestring

成员修改时间。

2015-01-23T12:33:18Z
RequestIdstring

请求 ID。

9B34724D-54B0-4A51-B34D-4512372FE1BE

示例

正常返回示例

JSON格式

{
  "Account": {
    "Status": "PromoteVerifying",
    "Type": "ResourceAccount",
    "DisplayName": "admin",
    "FolderId": "fd-bVaRIG****",
    "ResourceDirectoryId": "rd-k3****",
    "RecordId": "06950264-3f0d-4ca9-82dd-6ee7a3d33d6b",
    "JoinTime": "2015-01-23T12:33:18Z",
    "AccountId": "12323344****",
    "JoinMethod": "created",
    "AccountName": "someone@example.com",
    "ModifyTime": "2015-01-23T12:33:18Z"
  },
  "RequestId": "9B34724D-54B0-4A51-B34D-4512372FE1BE"
}

错误码

HTTP status code错误码错误信息描述
400MissingParameter.AccountIdYou must specify AccountId.AccountID不能为空
400InvalidParameter.AccountIdThe AccountId is invalid.成员ID无效,请输入16位账号ID。
400MissingParameter.EmailYou must specify Email.邮箱缺失,请指定邮箱。
400InvalidParameter.EmailThe Email is invalid.邮箱格式错误。
404EntityNotExists.AccountThis resource directory account does not exist.成员不存在,请先创建成员。
404EntityNotExists.ResourceDirectoryThe resource directory for the account is not enabled. We recommend that you first enable the resource directory for the account.当前账号未启用资源目录,请先启用资源目录。
409AccountTypeOrStatusMismatchYou cannot perform the action on the member account.成员类型或状态不匹配。
409InvalidParameter.Email.AlreadyUsedThe email has been used.邮箱已被占用,请更换其他邮箱。

访问错误中心查看更多错误码。

变更历史

变更时间变更内容概要操作
暂无变更历史