Help Center> Cloud Stream Service> API Reference> APIs> APIs Related to Cluster Management> Querying the List of VPC Peering Connections

Querying the List of VPC Peering Connections

Function

This API is used to query the list of VPC peering connections.

URI

  • URI format

    GET /v1.0/{project_id}/reserved_cluster/{cluster_id}/peering

  • Parameter description
    Table 1 URI parameter description

    Parameter

    Mandatory

    Description

    project_id

    Yes

    Project ID. For details about how to obtain the project ID, see Obtaining a Project ID.

    cluster_id

    Yes

    Cluster ID.

Request

None

Response

  • Example response
    {  
       "peerings":[  
          {  
             "name":"myVpc",
             "id":"7e974044-bcc1-4f25-aff8-5f10cb347b0f",
             "request_vpc_info":{  
                "vpc_id":"83081290-198e-48e2-8e2d-64c50023d136",
                "tenant_id":"8185f87d043f4519a68420a282b5e2fa",
                "vpc_cidr":"172.16.0.0/23",
                "subnet_cidr":"172.16.0.0/23"
             },
             "accept_vpc_info":{  
                "vpc_id":"f4da5a55-fcd9-4a93-8b86-5b81585e14bb",
                "tenant_id":"4f30b9215e054c908d18f2b150131646"
             },
             "status":"PENDING_ACCEPTANCE"
          }
       ]
    }
  • Parameter description
    Table 2 Response parameters

    Parameter

    Mandatory

    Type

    Description

    name

    Yes

    String

    Name of the VPC peering connection.

    id

    Yes

    String

    ID of the VPC peering connection.

    request_vpc_info

    Yes

    Struct

    Information about the local VPC.

    accept_vpc_info

    Yes

    Struct

    Information about the peer VPC.

    vpc_id

    Yes

    String

    ID of the peer VPC.

    tenant_id

    Yes

    String

    ID of the tenant to which the peer VPC belongs.

    status

    Yes

    String

    Status of the VPC peering connection. Available options are as follows: PENDING_ACCEPTANCE, REJECTED, EXPIRED, DELETED, and ACTIVE.

Status Code

Table 3 Status code

Status Code

Description

200

Querying the list of VPC peering connections succeeds.

400

The output parameters are invalid.

500

Failed to complete the request because of an internal service error.

Error Code

For details, see Error Codes.