Querying VPN Services

Function

This API is used to query VPN services.

URI

GET /v2.0/vpn/vpnservices

Request

Table 1 describes the request parameter.

Table 1 Request parameter

Parameter

Type

Mandatory

Description

fields

String

No

Controls which parameters are returned. If this parameter is not specified, all parameters will be returned.

Note

Parameter project_id is not supported.

Response

Table 2 describes the response parameters.

Table 2 Response parameters

Parameter

Type

Description

vpnservices

List<Object>

Specifies the VPN service list.

status

String

Specifies whether the VPN service is operational. The value can be ACTIVE, DOWN, BUILD, ERROR, PENDING_CREATE, PENDING_UPDATE, or PENDING_DELETE.

router_id

String

Specifies the router ID.

name

String

Specifies the VPN service name.

external_v6_ip

String

Specifies the IPv6 address of the VPN service external gateway.

admin_state_up

Boolean

Specifies the administrative status, which can be true or false.

subnet_id

String

Specifies the subnet ID.

tenant_id

String

Specifies the project ID.

external_v4_ip

String

Specifies the IPv4 address of the VPN service external gateway.

id

String

Specifies the VPN service ID.

description

String

Provides supplementary information about the VPN service.

order_id

String

Specifies the ID of a yearly/monthly order.

product_id

String

Specifies the ID of a product that is billed on a yearly/monthly basis.

prepay_connection_num

Integer

Specifies the number of connections of the yearly/monthly VPN service.

resource_speccode

String

Specifies the specifications of the product that is billed on a yearly/monthly basis.

created_at

String

Specifies the time when the VPN service was created.

tags

List<Object>

Specifies the tags.

Example

  • Example request

GET /v2.0/vpn/vpnservices
  • Example response

    {
        "vpnservices": [
            {
                "router_id": "66e3b16c-8ce5-40fb-bb49-ab6d8dc3f2aa",
                "status": "PENDING_CREATE",
                "name": "myservice",
                "external_v6_ip": "2001:db8::1",
                "admin_state_up": true,
                "subnet_id": null,
                "tenant_id": "10039663455a446d8ba2cbb058b0f578",
                "external_v4_ip": "172.32.1.11",
                "id": "5c561d9d-eaea-45f6-ae3e-08d1a7080828",
                "description": "",
                "product_id": "",
                "order_id": "",
                "created_at": "2020-08-05 12:36:35.921257",
                "prepay_connection_num": 0,
                "tags": [],
                "resource_speccode": ""
            }
        ]
    }
    

Returned Values

For details, see Common Returned Values.