Adds tags to cloud computers. This allows you to filter and manage cloud computers by tag.
Operation description
If TagKey is specified, the new TagValue value overrides the original TagValue value.
Debugging
Authorization information
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
RegionId | string | Yes | The region ID. You can call the DescribeRegions operation to query the most recent region list. | cn-hangzhou |
ResourceType | string | Yes | The type of the resource. Valid values:
| ALIYUN::GWS::INSTANCE |
ResourceId | array | Yes | The resource IDs, which are cloud computer IDs. You can specify 1 to 50 IDs. | |
string | Yes | The resource ID, which is the cloud computer ID. | ecd-ia2zw38bi6cm7**** | |
Tag | object [] | Yes | The tags that you want to add to the cloud computers. You can specify 1 to 20 tags. | |
Key | string | No | The tag keys. The tag key cannot be an empty string. The tag key can be up to 128 characters in length. It cannot start with | TestKey |
Value | string | No | The tag values. The tag value can be an empty string. The tag value can be up to 128 characters in length. It cannot start with | TestValue |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "1CBAFFAB-B697-4049-A9B1-67E1FC5F****"
}
Error codes
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation | ||
---|---|---|---|---|
2023-04-17 | The internal configuration of the API is changed, but the call is not affected | see changesets | ||
|