• Direct Connect

dc
  1. Help Center
  2. Direct Connect
  3. API Reference
  4. API
  5. Virtual Gateway
  6. Querying a Virtual Gateway

Querying a Virtual Gateway

Function

This API is used to query a virtual gateway.

URI

GET /v2.0/dcaas/virtual-gateways/{virtual_gateway_id}

Table 1 Parameter description

Parameter

Type

Mandatory

Description

virtual_gateway_id

String

Yes

Specifies the virtual gateway ID.

Request

Table 2 lists the request parameter.

Table 2 Request parameter

Parameter

Type

Mandatory

Description

virtual_gateway_id

String

Yes

Specifies the virtual gateway ID.

Response

Table 3 lists the response parameter.

Table 3 Response parameter

Parameter

Type

Mandatory

Description

virtual_gateway

Dictionary data structure

Yes

Specifies the virtual_gateway object.

Description of field virtual_gateway

Parameter

Type

Mandatory

Description

id

String

Yes

Specifies the virtual gateway ID.

tenant_id

String

Yes

Specifies the project ID.

name

String

No

Specifies the virtual gateway name.

description

String

No

Provides supplementary information about the virtual gateway.

vpc_id

String

Yes

Specifies the ID of the VPC to be accessed.

local_ep_group_id

String

Yes

Specifies the ID of the local endpoint group that records CIDRs of the VPC.

device_id

String

No

Specifies the ID of the physical device used by the virtual gateway.

redundant_device_id

String

No

Specifies the ID of the redundant physical device used by the virtual gateway.

type

String

No

Specifies the virtual gateway type. The value can be default or double ipsec.

ipsec_bandwidth

Integer

No

Specifies the IPsec VPN access bandwidth in Mbit/s.

bgp_asn

Integer

No

Specifies the AS number of the BGP peer.

status

String

No

Specifies the virtual gateway status.

The value can be ACTIVE, DOWN, BUILD, ERROR, PENDING_CREATE, PENDING_UPDATE, or PENDING_DELETE.

admin_state_up

Boolean

No

Specifies the administrative state of the virtual gateway.

The value can be true or false.

Examples

  • Example request
    GET /v2.0/dcaas/virtual-gateways/{virtual_gateway_id}
  • Example response
    {    
        "virtual_gateway" : {
            "id" : "7ec892f3-ca64-46c7-863f-a2eb1b9e8389", 
            "tenant_id" : "6fbe9263116a4b68818cf1edce16bc4f",
            "name" : "virtual gateway1",
            "description" : "",
            "vpc_id" : "908d9cf3-da64-4acb-393f-e5eb6b9e838a",
            "local_ep_group_id" : "f8834cf1-5468-87c7-223d-56e78b9699ab",
            "device_id" : "aaa_01"
        }
    }

Returned Value

For details, see section Common Returned Values.