DescribeTagKeys - 查詢標籤鍵
調用DescribeTagKeys介面返回標籤鍵。
調試
您可以在OpenAPI Explorer中直接運行該介面,免去您計算簽名的困擾。運行成功後,OpenAPI Explorer可以自動產生SDK程式碼範例。
調試
授權資訊
|
操作 |
存取層級 |
資源類型 |
條件關鍵字 |
關聯操作 |
|
vpc:DescribeTagKeys |
get |
*全部資源
|
無 | 無 |
請求參數
|
名稱 |
類型 |
必填 |
描述 |
樣本值 |
| ResourceType |
string |
否 |
資源類型。取值:
|
VPC |
| Keyword |
string |
否 |
標籤鍵。 |
keyword |
| RegionId |
string |
是 |
資源所屬的地區 ID。 您可以通過調用 DescribeRegions 介面擷取地區 ID。 |
cn-hangzhou |
| NextToken |
string |
否 |
是否擁有下一次查詢的令牌(Token)。取值:
|
FFmyTO70tTpLG6I3FmYAXGKPd**** |
| MaxResult |
integer |
否 |
分頁大小,取值範圍:1~50,預設值:50。 |
50 |
| ResourceId |
array |
否 |
資源 ID。最多支援輸入 50 個資源 ID。 |
|
|
string |
否 |
資源 ID。最多支援輸入 50 個資源 ID。 說明
當輸入該參數時,必須輸入 ResourceType 參數。 |
vpc-bp16qjewdsunr41m1**** |
返回參數
|
名稱 |
類型 |
描述 |
樣本值 |
|
object |
object |
||
| NextToken |
string |
是否擁有下一次查詢的令牌(Token)。取值:
|
FFmyTO70tTpLG6I3FmYAXGKPd**** |
| RequestId |
string |
請求 ID。 |
DE65F6B7-7566-4802-9007-96F2494AC512 |
| TagKeys |
object |
||
| TagKey |
array<object> |
標籤鍵集合。 |
|
|
object |
標籤鍵集合。 |
||
| Type |
string |
標籤鍵的類型。取值:
|
Custom |
| TagKey |
string |
標籤鍵。 |
FinanceDept |
樣本
正常返回樣本
JSON格式
{
"NextToken": "FFmyTO70tTpLG6I3FmYAXGKPd****",
"RequestId": "DE65F6B7-7566-4802-9007-96F2494AC512",
"TagKeys": {
"TagKey": [
{
"Type": "Custom",
"TagKey": "FinanceDept"
}
]
}
}
錯誤碼
|
HTTP status code |
錯誤碼 |
錯誤資訊 |
描述 |
|---|---|---|---|
| 400 | BothEmpty.TagsAndResources | The specified Tags and ResourcesIds are not allow to both empty. | 標籤和資源群組不能同時為空白 |
| 400 | MissingParameter.TagKey | The input parameter TagKey that is mandatory for processing this request is not supplied. | 缺少參數TagKey |
| 400 | MissingParameter.TagValue | The input parameter TagValue that is mandatory for processing this request is not supplied. | 缺少參數TagValue |
| 400 | InvalidTagKey | The tag keys are not valid. | 無效的標籤索引 |
| 400 | InvalidTagValue | The tag values are not valid. | 無效的標籤值 |
| 400 | MissingParam | %s | |
| 400 | InvalidInstanceType.NotFound | The instance type is not found | 執行個體類型沒有找到 |
| 400 | InvalidInstanceIds.NotFound | The instanceIds are not found | 執行個體ID沒有找到 |
| 400 | Forbidden.TagKeys | The request do not allow to operate the tag keys | 沒有許可權操作TagKeys |
| 400 | QuotaExceeded.TagNum | Custom Tags quota exceeded | quota超限 |
| 400 | Forbidden.NotAllowedCategary | The System tag is not valid | 系統tag無效 |
| 400 | Forbidden.TagKey.Duplicated | The specified tag key already exists. | 標籤資源重複 |
| 400 | SizeLimitExceeded.TagNum | The maximum number of tags is exceeded. | 標籤數量超限 |
| 400 | SizeLimitExceeded.ResourceId | The maximum number of resource IDs is exceeded. | 資源群組ID數目超限 |
| 403 | Forbidden | User not authorized to operate on the specified resource. | 您沒有許可權操作指定資源,請申請許可權後再操作。 |
訪問錯誤中心查看更多錯誤碼。
變更歷史
更多資訊,參考變更詳情。