All Products
Search
Document Center

Enterprise Distributed Application Service:TagResources

Last Updated:Mar 01, 2024

Creates tags and adds the tags to resources at a time.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

There is currently no authorization information disclosed in the API.

Request syntax

POST /pop/v5/tag/tags

Request parameters

ParameterTypeRequiredDescriptionExample
ResourceTypestringYes

The type of the resource. Valid values:

  • application: Enterprise Distributed Application Service (EDAS) application
  • cluster: EDAS cluster
application
ResourceIdsstringYes

The IDs of the resources. You can specify up to 20 IDs in the format of a JSON array.

["000e5836-xxxx-xxxx-xxxx-0d6ab2ac4877"]
TagsstringYes

The key-value pairs. When you set this parameter, take note of the following limits:

  • You can add up to 20 tags to a resource.
  • The tag key cannot start with aliyun or acs:. It cannot contain http:// or https://.
  • The tag key or tag value can be up to 128 characters in length, and can contain letters, digits, hyphens (-), commas (,), asterisks (*), forward slashes (/), question marks (?), and colons (:).
  • Set this parameter to a JSON array.
[{"key":"key1","value":"v1"},{"key":"key2","value":"v2"}]
ResourceRegionIdstringYes

The region in which the resource resides.

cn-hangzhou

Response parameters

ParameterTypeDescriptionExample
object
Codeinteger

The HTTP status code that is returned.

200
Messagestring

The additional information that is returned.

success
RequestIdstring

The ID of the request.

000e5836-xxxx-xxxx-xxxx-0d6ab2ac4877

Examples

Sample success responses

JSONformat

{
  "Code": 200,
  "Message": "success",
  "RequestId": "000e5836-xxxx-xxxx-xxxx-0d6ab2ac4877"
}

Error codes

HTTP status codeError codeError messageDescription
500Edas.errorcode.InstanceNotExist.Instance.messageThe instance does not exist.The instance does not exist.

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
No change history