Creates and adds tags to specified resources of Data Lake Analytics (DLA) CU Edition.

Note Before you add a tag to a resource, Alibaba Cloud automatically checks the number of existing tags in DLA CU Edition. If the maximum number of tags is reached, an error message is returned.

Debugging

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 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 resource. You can call the DescribeRegions operation to query the most recent region list.

ResourceId.N RepeatList Yes dla-qw4hqmvxrwqdya8m2qq***

The IDs of resources. Valid values of N: 1 to 50.

ResourceType String Yes instance

The type of the resource. Set the value to instance.

Tag.N.Key String Yes tagKey1

The key of tag N. Valid values of N: 1 to 20. The value of this parameter cannot be an empty string. A tag key can be up to 64 characters in length. It cannot start with aliyun or acs: and cannot contain http:// or https://.

Tag.N.Value String Yes tagValue1

The value of tag N. Valid values of N: 1 to 20. The value of this parameter can be an empty string. A tag value can be up to 128 characters in length. It cannot start with aliyun or acs: and cannot contain http:// or https://.

Response parameters

Parameter Type Example Description
RequestId String 25C11EE5-B7E8-481A-A07C-BD619971A570

The ID of the request.

Examples

Sample requests

http(s)://[Endpoint]/?Action=TagResources
&RegionId=cn-hangzhou
&ResourceId.1=dla-qw4hqmvxrwqdya8m2qq***
&ResourceType=instance
&Tag.1.Key=tagKey1
&Tag.1.Value=tagValue1
&<Common request parameters>

Sample success responses

XML format

<requestId>25C11EE5-B7E8-481A-A07C-BD619971A570</requestId>

JSON format

{
  "requestId": "25C11EE5-B7E8-481A-A07C-BD619971A570"
}

Error codes

HTTP status code Error code Error message Description
600 Openanalytics.Internal.Exception An internal error occurred. The error message returned because an internal error has occurred.

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