• Virtual Private Cloud

vpc
  1. Help Center
  2. Virtual Private Cloud
  3. API Reference
  4. APIs
  5. VPC Tag Management
  6. Querying VPC Tags

Querying VPC Tags

Function

This interface is used to query tags of a specified VPC. In the URI, project_id indicates the project ID, and vpc_id indicates the target VPC ID.

URI

GET /v2.0/{project_id}/vpcs/{vpc_id}/tags

Request Message

  • Request parameter

    None

  • Example request
    GET /v2.0/{project_id}/vpcs/{vpc_id}/tags

Response Message

  • Response parameter
    Table 1 Response parameter

    Parameter

    Type

    Description

    tags

    List<resource_tag>

    Specifies the tag list.

  • Example response
    {
        "tags": [
            {
                "key": "key1",
                "value": "value1"
            },
            {
                "key": "key2",
                "value": "value3"
            }
        ]
    }

Status Codes

Normal Response Code

Type

Description

200

OK

Specifies the normal response code for the GET operation.

Error Codes

For details, see section VPC Tag Error Codes.