全部產品
Search
文件中心

Resource Orchestration Service:User資源

更新時間:Mar 17, 2026

AssociationProperty取值

說明

對應的AssociationPropertyMetadata

ALIYUN::User::Account::AccountIds

使用者帳號ID。

樣本如下:

  • 範例程式碼

    JSON樣本:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "AccountIds": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::User::Account::AccountIds"
        }
      }
    }

    YAML樣本:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      AccountIds:
        Type: String
        AssociationProperty: ALIYUN::User::Account::AccountIds
  • 樣本說明

    樣本中通過指定參數AccountIds的AssociationProperty屬性為ALIYUN::User::Account::AccountIds,擷取使用者帳號ID。

ALIYUN::User::AccountId

擷取阿里雲主帳號ID。

範例程式碼

JSON樣本:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "MasterAccountId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::User::AccountId"
    }
  }
}

YAML樣本:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  MasterAccountId:
    Type: String
    AssociationProperty: ALIYUN::User::AccountId

ALIYUN::User::UserId

擷取當前阿里雲使用者ID。

範例程式碼

JSON樣本:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "CurrentAccountId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::User::UserId"
    }
  }
}

YAML樣本:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  CurrentAccountId:
    Type: String
    AssociationProperty: ALIYUN::User::UserId