Creates and binds tags to specified Bastionhost instances.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | TagResources |
The operation that you want to perform. Set the value to TagResources. |
RegionId | String | Yes | cn-hangzhou |
The region ID of the Bastionhost instances to which tags need to be created and bound. |
ResourceId.N | RepeatList | Yes | bastionhost-cn-78v1gc**** |
The ID of Bastionhost instance N. Valid values of N: 1 to 20. Note You can call the DescribeInstances operation to obtain the ID of the Bastionhost instance.
|
ResourceType | String | Yes | INSTANCE |
The type of the resource. Set the value to INSTANCE, which indicates that the resource is a Bastionhost instance. |
Tag.N.Key | String | No | operation |
The key of tag N of the instance. Valid values of N: 1 to 20. Note
|
Tag.N.Value | String | No | operation_test |
The value of tag N of the instance. Valid values of N: 1 to 20. Note
|
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
RequestId | String | 2F24F0A8-4C69-4E89-9392-457D107E2D4A |
The ID of the request. |
Examples
Sample requests
http(s)://[Endpoint]/?Action=TagResources
&RegionId=cn-hangzhou
&ResourceId.1=bastionhost-cn-78v1gc****
&ResourceType=INSTANCE
&<Common request parameters>
Sample success responses
XML
format
<TagResourcesResponse>
<RequestId>2F24F0A8-4C69-4E89-9392-457D107E2D4A</RequestId>
</TagResourcesResponse>
JSON
format
{
"RequestId":"2F24F0A8-4C69-4E89-9392-457D107E2D4A"
}
Error codes
For a list of error codes, visit the API Error Center.