Updated on 2026-06-11 GMT+08:00

Querying Quotas

Function

This API is used to query VPN resource quotas of a tenant, including VPN gateways, customer gateways, and VPN connections.

Calling Method

For details, see Calling APIs.

Authorization Information

Each account has all the permissions required to call all APIs, but IAM users must be assigned the required permissions.

  • If you are using role/policy-based authorization, see Permissions Policies and Supported Actions for details on the required permissions.
  • If you are using identity policy-based authorization, the following identity policy-based permissions are required.

Action

Access Level

Resource Type (*: required)

Condition Key

Alias

Dependencies

vpn:connectionMonitors:delete

write

vpnConnections

  • g:EnterpriseProjectId
  • g:ResourceTag/<tag-key>

-

-

URI

GET /v5/{project_id}/vpn/quotas
Table 1 Parameter description

Parameter

Type

Mandatory

Description

project_id

String

Yes

Specifies a project ID. You can obtain the project ID by referring to Obtaining the Project ID.

Request

  • Request parameters

    None

  • Example request
    GET https://{Endpoint}/v5/{project_id}/vpn/quotas

Response

  • Response parameters

    Returned status code 200: successful query

    Table 2 Parameters in the response body

    Parameter

    Type

    Description

    quotas

    Quotas object

    Specifies the quotas object.

    request_id

    String

    Specifies a request ID.

    Table 3 Quotas

    Parameter

    Type

    Description

    resources

    Array of QuotaInfo objects

    Specifies the resources object.

    Table 4 QuotaInfo

    Parameter

    Type

    Description

    type

    String

    • Specifies a resource type.
    • Value range:
      • customer_gateway: customer gateway of the S2C Enterprise Edition VPN
      • vpn_connection: S2C Enterprise Edition VPN connection
      • vpn_gateway: S2C Enterprise Edition VPN gateway
      • vpn_gateway_local_subnet: local subnet of a single S2C Enterprise Edition VPN gateway
      • vpn_connection_peer_subnet: customer subnet of a single S2C Enterprise Edition VPN connection

    quota

    Integer

    Specifies the quota upper limit.

    used

    Integer

    Specifies the number of resources in use.

  • Example response
    {
        "quotas": {
            "resources": [
                {
                    "type": "customer_gateway",
                    "quota": 100,
                    "used": 13
                },
                {
                    "type": "vpn_connection",
                    "quota": 5000,
                    "used": 306
                },
                {
                    "type": "vpn_gateway",
                    "quota": 50,
                    "used": 23
                },
                {
                    "type": "vpn_gateway_local_subnet",
                    "quota": 50,
                    "used": 0
                },
                {
                    "type": "vpn_connection_peer_subnet",
                    "quota": 50,
                    "used": 0
                }
            ]
        },
        "request_id": "9aeb7f73-e1b6-42eb-96ad-b68aef8186e3"
    }

Status Codes

For details, see Status Codes.