Querying Tags of a Specific Resource
Function
This API is used to query tags of a specific resource.
Calling Method
For details, see Calling APIs.
URI
GET /v1/{resource_type}/{resource_id}/tags
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
resource_type |
Yes |
Object |
Specifies the resource type. |
resource_id |
Yes |
String |
Specifies the resource ID. |
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
X-Auth-Token |
Yes |
String |
Specifies the user token. The token can be obtained by calling the IAM API. The value of X-Subject-Token in the response header is the user token. |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
tags |
Array of ResourceTag objects |
Specifies the tags. |
request_id |
String |
Specifies the request ID. |
Parameter |
Type |
Description |
---|---|---|
key |
String |
Specifies the tag key. The key must meet the following requirements:
|
value |
String |
Specifies the tag value. The value must meet the following requirements:
|
Example Requests
Querying tags of a specific resource
GET https://{ga_endpoint}/v1/{resource_type}/{resource_id}/tags
Example Responses
Status code: 200
Operation succeeded.
{ "tags" : [ { "key" : "tagKey", "value" : "tagValue" } ], "request_id" : "915a14a6-867b-4af7-83d1-70efceb146f9" }
Status Codes
Status Code |
Description |
---|---|
200 |
Operation succeeded. |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.