全部產品
Search
文件中心

:ALIYUN::ResourceManager::Account

更新時間:Feb 05, 2024

ALIYUN::ResourceManager::Account類型用於建立資源帳號類型的成員。

文法

{
  "Type": "ALIYUN::ResourceManager::Account",
  "Properties": {
    "PayerAccountId": String,
    "DisplayName": String,
    "FolderId": String,
    "DeleteAccount": Boolean
  }
}

屬性

屬性名稱

類型

必須

允許更新

描述

約束

PayerAccountId

String

結算帳號ID。

取值為空白表示採用當前帳號結算。

DisplayName

String

成員名稱。

長度為2~50個字元,可包含漢字、英文字母、數字、底線(_)、英文句點(.)和短劃線(-)。

成員名稱在資來源目錄內必須唯一。

FolderId

String

資源夾ID。

DeleteAccount

Boolean

是否刪除賬戶。 

取值:

  • true:刪除賬戶。

  • false(預設值):不刪除賬戶。

傳回值

Fn::GetAtt

  • FolderId:資源夾ID。

  • ResourceDirectoryId:資來源目錄ID。

  • AccountId:帳號ID。

  • DisplayName:成員名稱。

  • Type:成員類型。ResourceAccount表示資源帳號。

  • JoinMethod:成員加入方式。invited表示邀請,created表示建立。

樣本

YAML格式

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
 PayerAccountId:
  Type: String
  Description: ''
 DisplayName:
  Type: String
  Description: Member name
 FolderId:
  Type: String
  Description: The ID of the parent folder
Resources:
 ResourceManagerAccount:
  Type: 'ALIYUN::ResourceManager::Account'
  Properties:
   PayerAccountId:
    Ref: PayerAccountId
   DisplayName:
    Ref: DisplayName
   FolderId:
    Ref: FolderId
Outputs:
 JoinMethod:
  Description: >-
   Ways for members to join the resource directory. Valid values: invited,
   created
  Value:
   'Fn::GetAtt':
    - ResourceManagerAccount
    - JoinMethod
 ResourceDirectoryId:
  Description: Resource directory ID
  Value:
   'Fn::GetAtt':
    - ResourceManagerAccount
    - ResourceDirectoryId
 Type:
  Description: Member type. The value of ResourceAccount indicates the resource account
  Value:
   'Fn::GetAtt':
    - ResourceManagerAccount
    - Type
 AccountId:
  Description: This ID of Resource Manager Account
  Value:
   'Fn::GetAtt':
    - ResourceManagerAccount
    - AccountId
 DisplayName:
  Description: Member name
  Value:
   'Fn::GetAtt':
    - ResourceManagerAccount
    - DisplayName
 FolderId:
  Description: The ID of the parent folder
  Value:
   'Fn::GetAtt':
    - ResourceManagerAccount
    - FolderId

JSON格式

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "PayerAccountId": {
      "Type": "String",
      "Description": ""
    },
    "DisplayName": {
      "Type": "String",
      "Description": "Member name"
    },
    "FolderId": {
      "Type": "String",
      "Description": "The ID of the parent folder"
    }
  },
  "Resources": {
    "ResourceManagerAccount": {
      "Type": "ALIYUN::ResourceManager::Account",
      "Properties": {
        "PayerAccountId": {
          "Ref": "PayerAccountId"
        },
        "DisplayName": {
          "Ref": "DisplayName"
        },
        "FolderId": {
          "Ref": "FolderId"
        }
      }
    }
  },
  "Outputs": {
    "JoinMethod": {
      "Description": "Ways for members to join the resource directory. Valid values: invited, created",
      "Value": {
        "Fn::GetAtt": [
          "ResourceManagerAccount",
          "JoinMethod"
        ]
      }
    },
    "ResourceDirectoryId": {
      "Description": "Resource directory ID",
      "Value": {
        "Fn::GetAtt": [
          "ResourceManagerAccount",
          "ResourceDirectoryId"
        ]
      }
    },
    "Type": {
      "Description": "Member type. The value of ResourceAccount indicates the resource account",
      "Value": {
        "Fn::GetAtt": [
          "ResourceManagerAccount",
          "Type"
        ]
      }
    },
    "AccountId": {
      "Description": "This ID of Resource Manager Account",
      "Value": {
        "Fn::GetAtt": [
          "ResourceManagerAccount",
          "AccountId"
        ]
      }
    },
    "DisplayName": {
      "Description": "Member name",
      "Value": {
        "Fn::GetAtt": [
          "ResourceManagerAccount",
          "DisplayName"
        ]
      }
    },
    "FolderId": {
      "Description": "The ID of the parent folder",
      "Value": {
        "Fn::GetAtt": [
          "ResourceManagerAccount",
          "FolderId"
        ]
      }
    }
  }
}