Queries VPN gateways created in a specified region.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
vpc:DescribeVpnGateways |
list |
VpnGateway
VpnGateway
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| RegionId |
string |
Yes |
The region ID of the VPN gateway. You can call the DescribeRegions operation to query region IDs. |
cn-hangzhou |
| VpcId |
string |
No |
The ID of the virtual private cloud (VPC) to which the VPN gateway belongs. |
vpc-bp1m3i0kn1nd4wiw9**** |
| VpnGatewayId |
string |
No |
The ID of the VPN gateway. |
vpn-bp17lofy9fd0dnvzv**** |
| Status |
string |
No |
The status of the VPN gateway. Valid values:
|
active |
| BusinessStatus |
string |
No |
The billing status of the VPN gateway. Valid values:
|
Normal |
| PageNumber |
integer |
No |
The page number. Default value: 1. |
1 |
| PageSize |
integer |
No |
The number of entries per page for paging queries. Valid values: 1 to 50. Default value: 10. |
10 |
| IncludeReservationData |
boolean |
No |
Specifies whether to include pending order data. Valid values:
|
true |
| Tag |
array<object> |
No |
The list of tags bound to the VPN gateway. |
|
|
object |
No |
The tag bound to the VPN gateway. |
||
| Key |
string |
No |
The tag key. You can specify up to 20 tag keys at a time. |
FinanceDept |
| Value |
string |
No |
The tag value. Each tag key corresponds to one tag value. You can specify up to 20 tag values at a time. |
FinanceJoshua |
| ResourceGroupId |
string |
No |
The ID of the resource group to which the VPN gateway belongs. You can call the ListResourceGroups operation to query resource group IDs. |
rg-acfmzs372yg**** |
| GatewayType |
string |
No |
The VPN gateway type. Valid values:
|
Enhanced.SiteToSite |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
The response parameters. |
||
| PageSize |
integer |
The number of entries per page for paging queries. |
10 |
| RequestId |
string |
The request ID. |
DF11D6F6-E35A-41C3-9B20-6FC8A901FE65 |
| PageNumber |
integer |
The page number. |
1 |
| TotalCount |
integer |
The total number of entries. |
1 |
| VpnGateways |
object |
||
| VpnGateway |
array<object> |
The list of VPN gateways. |
|
|
array<object> |
The information about the VPN gateway. |
||
| VpnType |
string |
The type of the VPN gateway. Valid values: Normal, which indicates the standard type.. |
Normal |
| Status |
string |
The status of the VPN gateway.
|
active |
| VpcId |
string |
The ID of the VPC to which the VPN gateway belongs. |
vpc-bp1m3i0kn1nd4wiw9**** |
| SslMaxConnections |
integer |
The maximum number of SSL-VPN connections for the VPN gateway. |
5 |
| Spec |
string |
The peak bandwidth of the VPN gateway. M indicates the unit Mbit/s. |
5M |
| InternetIp |
string |
|
47.12.XX.XX |
| CreateTime |
integer |
The timestamp when the VPN gateway was created. Unit: milliseconds. The timestamp follows the UNIX time format, which represents the total number of milliseconds that have elapsed since January 1, 1970, 00:00:00 UTC to the time when the VPN gateway instance was created. |
1515383700000 |
| AutoPropagate |
boolean |
Indicates whether the routing automatic propagation feature is enabled for the VPN gateway.
|
true |
| ChargeType |
string |
The billing method of the VPN gateway. The value is POSTPAY, which indicates the pay-as-you-go billing method. |
中国站示例值:Prepay,国际站示例值:POSTPAY |
| VpnGatewayId |
string |
The ID of the VPN gateway. |
vpn-bp17lofy9fd0dnvzv**** |
| Tag |
string |
The system-generated labels of the VPN gateway.
|
{\"VpnEnableBgp\":\"true\",\"VisuallySsl\":\"true\",\"PbrPriority\":\"true\",\"VpnNewImage\":\"true\",\"description\":\"转发1.3.24\",\"VpnVersion\":\"v1.2.4\",\"IDaaSNewVersion\":\"true\"} |
| IpsecVpn |
string |
Indicates whether IPsec-VPN is enabled for the VPN gateway.
|
enable |
| EndTime |
integer |
The timestamp when the VPN gateway expires. Unit: milliseconds. The timestamp follows the UNIX time format, which represents the total number of milliseconds that have elapsed since January 1, 1970, 00:00:00 UTC to the time when the VPN gateway instance expires. |
1518105600000 |
| VSwitchId |
string |
The ID of the vSwitch to which the VPN gateway belongs. |
vsw-bp15lbk8sgtr6r5b0**** |
| Description |
string |
The description of the VPN gateway. |
test |
| EnableBgp |
boolean |
The enabling status of the BGP feature for the VPN gateway.
|
true |
| BusinessStatus |
string |
The billing status of the VPN gateway.
|
Normal |
| SslVpn |
string |
Indicates whether SSL-VPN is enabled for the VPN gateway.
|
enable |
| Name |
string |
The name of the VPN gateway. |
test |
| NetworkType |
string |
The network type of the VPN gateway.
|
public |
| Tags |
object |
||
| Tag |
array<object> |
The list of tags bound to the VPN gateway. |
|
|
object |
The tag information bound to the VPN gateway. |
||
| Key |
string |
The tag key. |
FinanceDept |
| Value |
string |
The tag value. |
FinanceJoshua |
| ReservationData |
object |
The pending order data. Note
This parameter is returned only when IncludeReservationData is set to true. |
|
| Status |
string |
The status of the pending order.
|
1 |
| ReservationOrderType |
string |
The type of the pending order.
|
TEMP_UPGRADE |
| ReservationIpsec |
string |
The enabling status of the IPsec-VPN feature for the pending order.
|
enable |
| ReservationSpec |
string |
The bandwidth specification of the pending order. Unit: Mbit/s. |
5 |
| ReservationSsl |
string |
The enabling status of the SSL-VPN feature for the pending order.
|
enable |
| ReservationMaxConnections |
integer |
The maximum number of concurrent SSL-VPN connections for the pending order. |
5 |
| ReservationEndTime |
string |
If the pending order type is TEMP_UPGRADE (temporary upgrade), this parameter indicates the revert time for the temporary upgrade. If the pending order type is RENEWCHANGE (Upgrade/Downgrade) or RENEW (renewal), this parameter indicates the effective period when the renewal or renewal with specification change takes effect. |
2021-07-20T16:00:00Z |
| DisasterRecoveryInternetIp |
string |
The second IP address assigned by the system to the VPN gateway instance for creating IPsec-VPN connections. This parameter is returned only for VPN gateway instances that support creating dual-tunnel IPsec-VPN connections. |
47.91.XX.XX |
| DisasterRecoveryVSwitchId |
string |
The ID of the second vSwitch associated with the VPN gateway instance. This parameter is returned only for VPN gateway instances that support creating dual-tunnel IPsec-VPN connections. |
vsw-p0w95ql6tmr2ludkt**** |
| SslVpnInternetIp |
string |
The IP address for SSL-VPN connections. This parameter is returned only when SSL-VPN is enabled for a VPN gateway instance that has a public network type and supports creating dual-tunnel IPsec-VPN connections. |
47.74.XX.XX |
| ResourceGroupId |
string |
The ID of the resource group to which the VPN gateway belongs. You can call the ListResourceGroups operation to query resource group information. |
rg-acfmzs372yg**** |
| EniInstanceIds |
object |
||
| EniInstanceId |
array |
The list of elastic network interfaces (ENIs) created by the system for the VPN gateway instance. |
|
|
string |
The ENI ID. This parameter is returned only for VPN gateway instances that support creating dual-tunnel IPsec-VPN connections. |
eni-7xvcxgmd4y2ypibn**** |
|
| GatewayType |
string |
The type of the VPN gateway. Valid values: Traditional: traditional VPN gateway that supports both IPsec and SSL features. Enhance.SiteToSite: enhanced site-to-cloud VPN that supports only IPsec features. |
Enhanced.SiteToSite |
Examples
Success response
JSON format
{
"PageSize": 10,
"RequestId": "DF11D6F6-E35A-41C3-9B20-6FC8A901FE65",
"PageNumber": 1,
"TotalCount": 1,
"VpnGateways": {
"VpnGateway": [
{
"VpnType": "Normal",
"Status": "active",
"VpcId": "vpc-bp1m3i0kn1nd4wiw9****",
"SslMaxConnections": 5,
"Spec": "5M",
"InternetIp": "47.12.XX.XX",
"CreateTime": 1515383700000,
"AutoPropagate": true,
"ChargeType": "中国站示例值:Prepay,国际站示例值:POSTPAY",
"VpnGatewayId": "vpn-bp17lofy9fd0dnvzv****",
"Tag": "{\\\"VpnEnableBgp\\\":\\\"true\\\",\\\"VisuallySsl\\\":\\\"true\\\",\\\"PbrPriority\\\":\\\"true\\\",\\\"VpnNewImage\\\":\\\"true\\\",\\\"description\\\":\\\"转发1.3.24\\\",\\\"VpnVersion\\\":\\\"v1.2.4\\\",\\\"IDaaSNewVersion\\\":\\\"true\\\"}",
"IpsecVpn": "enable",
"EndTime": 1518105600000,
"VSwitchId": "vsw-bp15lbk8sgtr6r5b0****",
"Description": "test",
"EnableBgp": true,
"BusinessStatus": "Normal",
"SslVpn": "enable",
"Name": "test",
"NetworkType": "public",
"Tags": {
"Tag": [
{
"Key": "FinanceDept",
"Value": "FinanceJoshua"
}
]
},
"ReservationData": {
"Status": "1",
"ReservationOrderType": "TEMP_UPGRADE",
"ReservationIpsec": "enable",
"ReservationSpec": "5",
"ReservationSsl": "enable",
"ReservationMaxConnections": 5,
"ReservationEndTime": "2021-07-20T16:00:00Z"
},
"DisasterRecoveryInternetIp": "47.91.XX.XX",
"DisasterRecoveryVSwitchId": "vsw-p0w95ql6tmr2ludkt****",
"SslVpnInternetIp": "47.74.XX.XX",
"ResourceGroupId": "rg-acfmzs372yg****",
"EniInstanceIds": {
"EniInstanceId": [
"eni-7xvcxgmd4y2ypibn****"
]
},
"GatewayType": "Enhanced.SiteToSite"
}
]
}
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | InvalidParameter.TagKey | The specified parameter TagKey is invalid. | The error message returned because the specified tag key is invalid. |
| 400 | InvalidParameter.TagValue | The specified parameter TagValue is invalid. | The error message returned because the specified tag value is invalid. |
| 400 | Duplicated.TagKey | The specified parameter TagKey is duplicated. | The error message returned because the specified tag key already exists. |
| 400 | InternalError | The request processing has failed due to some unknown error, exception or failure. | |
| 403 | Forbidden.SubUser | User not authorized to operate on the specified resource as your account is created by another user. | The error message returned because you are unauthorized to perform this operation on the specified resource. Acquire the required permissions and try again. |
| 403 | Forbidden | User not authorized to operate on the specified resource. | You do not have the permissions to manage the specified resource. Apply for the permissions and try again. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.