Deletes the relationship between tag resources of a user.

When you call this operation, take note of the following items:

  • Only user tags can be deleted.
  • When you delete a tag relationship, if the tag is not associated with any resource, you must also delete the tag.


OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request header

Request syntax

DELETE /openapi/tags HTTPS|HTTP

Request parameters

Parameter Type Required Example Description
ResourceIds String No ["es-cn-aaa","es-cn-bbb"]

The list of IDs of the ECS instances that you want to delete.

ResourceType String No INSTANCE

The type of the resource. Static field INSTANCE.

TagKeys String No ["tagKey1","tagKey2"]

The list of tags that you want to delete. You can specify a maximum of 20 tags.

All Boolean No false

Indicates whether to delete all tags. Only when TagKey valid when empty. Optional values: true, false the default value is false.

  • The TagKeys is empty, and All = true the tag relationships of all resources under the Resource are deleted. If resources without tags exist, the API is not processed and a success message is returned.
  • When you specify TagKeys is empty, at the same time All = false is not processed and returns success.
  • TagKeys not empty, All A value of true or false indicates that this field is ignored.
  • Import multiple tags and multiple TagKeys to delete the specified tag from the resource. If the specified tag does not exist on the resource, the tag is not processed.
  • If the resource does not exist, return InvalidResourceId.NotFound.

Response parameters

Parameter Type Example Description
RequestId String F99407AB-2FA9-489E-A259-40CF6D******

The ID of the instance to be queried.


Sample requests

DELETE /consoleapi/tags?

Sample success responses

XML format


JSON format

    "RequestId": "3D8795D9-8FF5-46B2-86E6-E3B40*******"

Error code

For a list of error codes, visit the API Error Center.