Querying Tags of a Type of Resources in a Cloud Eye Project
Function
Querying tags of a type of resources in a Cloud Eye project.
Debugging
You can debug this API through automatic authentication in API Explorer or use the SDK sample code generated by API Explorer.
URI
GET /v2/{project_id}/{resource_type}/tags
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
project_id |
Yes |
String |
Specifies the tenant ID. Minimum: 1 Maximum: 64 Regex Pattern: ^[a-zA-Z0-9-]{1,64}$ |
resource_type |
Yes |
String |
Specifies the resource type, which can be CES-alarm (alarm rule), CES-dashboard, or CES-resourceGroup. Minimum: 1 Maximum: 32 Enumeration values:
|
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
Content-Type |
No |
String |
Specifies the MIME type of the request body. The default type is application/json; charset=UTF-8. Default: application/json; charset=UTF-8 Minimum: 1 Maximum: 64 |
X-Auth-Token |
Yes |
String |
Specifies the user token. Minimum: 1 Maximum: 16384 |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
tags |
Array of Tag objects |
Specifies tenant tags. Array Length: 0 - 20 |
Parameter |
Type |
Description |
---|---|---|
key |
String |
Specifies a tag key. A tag key can contain up to 128 Unicode characters. key must be specified. Minimum: 0 Maximum: 128 |
values |
Array of strings |
Specifies tag values. Each value can contain up to 255 Unicode characters. If values is not specified, any parameter value can be queried. Minimum: 0 Maximum: 255 Array Length: 0 - 20 |
Status code: 404
Parameter |
Type |
Description |
---|---|---|
http_code |
Integer |
Specifies the HTTP status code. 200: OK 404: Resource not found. Minimum: 3 Maximum: 3 Enumeration values:
|
message |
GoAPIErrorResponseMsg object |
Specifies the error message. |
Example Requests
None
Example Responses
Status code: 200
OK
{ "tags" : [ { "key" : "key1", "values" : [ "value1", "value2" ] }, { "key" : "key2", "values" : [ "value1", "value2" ] } ] }
Status Codes
Status Code |
Description |
---|---|
200 |
OK |
404 |
Resource not found. |
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.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot