Lists all tags.
Try it now
Test
RAM authorization
Request syntax
GET /api/v1/tag HTTP/1.1
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| RegionId |
string |
No |
The region ID. |
cn-hangzhou |
| tagsOnly |
boolean |
No |
Specifies whether to return tags. Valid values:
|
true |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| RequestId |
string |
The request ID. |
14E2358E-0499-509E-8E22-CA30EC474A9A |
| Success |
boolean |
Indicates whether the request succeeded. This parameter is independent of the business logic. Valid values:
|
true |
| ErrorCode |
string |
The error code. |
404 |
| ErrorMessage |
string |
The error message. |
Internal server error. |
| HttpStatusCode |
string |
The HTTP status code. |
200 |
| TagResources |
array<object> |
The list of resources. |
|
|
object |
|||
| ResourceId |
string |
The instance ID. |
hgprecn-cn-0ju2uaanj001 |
| ResourceType |
string |
The resource type. Valid values:
|
Instance |
| TagKey |
string |
The tag key. |
acs:rm:rgId |
| TagValue |
array |
A list of values for the corresponding tag key. |
|
|
string |
The tag value. |
rg-acfm4lsp23l7jti |
Examples
Success response
JSON format
{
"RequestId": "14E2358E-0499-509E-8E22-CA30EC474A9A",
"Success": true,
"ErrorCode": "404",
"ErrorMessage": "Internal server error.",
"HttpStatusCode": "200",
"TagResources": [
{
"ResourceId": "hgprecn-cn-0ju2uaanj001",
"ResourceType": "Instance",
"TagKey": "acs:rm:rgId",
"TagValue": [
"rg-acfm4lsp23l7jti"
]
}
]
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.