All Products
Search
Document Center

Bastionhost:TagResources

Last Updated:Jan 31, 2023

Creates and binds tags to specified Bastionhost instances.

Authorization information

There is currently no authorization information disclosed in the API.

Request parameters

ParameterTypeRequiredDescriptionExample
RegionIdstringYes

The region ID of the Bastionhost instances to which tags need to be created and bound.

cn-hangzhou
ResourceTypestringYes

The type of the resource.

Set the value to INSTANCE, which indicates that the resource is a Bastionhost instance.

INSTANCE
ResourceIdarrayYes

The resource IDs.

stringNo

The ID of Bastionhost instance N.

Valid values of N: 1 to 20.

NoteYou can call the DescribeInstances operation to obtain the ID of the Bastionhost instance.
bastionhost-cn-78v1gc****
TagarrayNo

The tags.

objectNo
KeystringNo

The key of tag N of the instance.

Valid values of N: 1 to 20.

Note
  • The key can be up to 128 characters in length but cannot be an empty string.
  • The key cannot start with aliyun or acs:. It cannot contain http:// or https://.
operation
ValuestringNo

The value of tag N of the instance.

Valid values of N: 1 to 20.

Note
  • The value can be up to 128 characters in length or an empty string.
  • The value cannot start with aliyun or acs:. It cannot contain http:// or https://.
operation_test

Response parameters

ParameterTypeDescriptionExample
object
RequestIdstring

The ID of the request.

2F24F0A8-4C69-4E89-9392-457D107E2D4A

Example

Normal return example

JSONFormat

{
  "RequestId": "2F24F0A8-4C69-4E89-9392-457D107E2D4A"
}

Error codes

For a list of error codes, visit the API error center.