VPN网关查询
更新时间 2023-12-28 15:00:10
最近更新时间: 2023-12-28 15:00:10
查询账户下已创建的VPN网关。
接口功能介绍
查询账户下已创建的VPN网关。
接口约束
支持主备模式资源池
URI
GET /v4/vpn/gateway/list
路径参数
无
Query 参数
无
请求参数
请求头 header 参数
无
请求体 body 参数
| 参数 | 是否必填 | 参数类型 | 说明 | 示例 | 下级对象 |
|---|---|---|---|---|---|
| regionID | 是 | String | 资源池ID | ||
| pageNo | 否 | String | 页码 | 1 | |
| pageSize | 否 | String | 页大小 | 10 | |
| vpnGatewayID | 否 | String | VPN网关ID | ||
| vpnGatewayName | 否 | String | VPN网关名称 | ||
| queryContent | 否 | String | 模糊查询 |
响应参数
| 参数 | 参数类型 | 说明 | 示例 | 下级对象 |
|---|---|---|---|---|
| statusCode | Integer | 返回状态码(800为成功,900为失败) | ||
| message | String | 失败时的错误描述,一般为英文描述 | ||
| description | String | 失败时的错误描述,一般为中文描述 | ||
| returnObj | Object | 返回对象 | returnObj | |
| errorCode | String | 业务细分码,为product.module.code三段式码 | ||
| errorDetail | Object | 错误明细 |
表returnObj
| 参数 | 参数类型 | 说明 | 示例 | 下级对象 |
|---|---|---|---|---|
| currentCount | Integer | 当前数据量 | ||
| totalCount | Integer | 总数据量 | ||
| totalPage | Integer | 总页数 | ||
| results | Array of Object | VPN网关列表 | Gateway | |
| errorCode | String | 错误码 | ||
| message | String | 错误信息 | ||
| description | String | 描述 | ||
| statusCode | String | 800成功,900失败 |
表Gateway
| 参数 | 参数类型 | 说明 | 示例 | 下级对象 |
|---|---|---|---|---|
| vpnConnectionID | String | VPN连接ID | ||
| type | String | 本参数表示VPN类型。 取值范围: IPSec SSL |
||
| linkSpec | Integer | VPN连接数限制 | ||
| vpnLinkID | String | VPN连接ID | ||
| linkResourceID | String | VPN连接资源ID | ||
| vpcID | String | VPC ID | ||
| vpnConnectionCount | Integer | VPN连接数 | ||
| bandwidth | Interger | VPN网关带宽 | ||
| vpnGatewayName | String | VPN网关名字 | ||
| vpnGatewayID | String | VPN网关ID | ||
| vpcName | String | VPC 名字 | ||
| resourceID | String | VPN网关资源ID | ||
| ipAddress | String | IP地址 | ||
| azName | String | 可能区名字 | ||
| dataID | String | 数据ID | ||
| isMaz | Boolean | 是否多可用区 | ||
| isPaas | Boolean | 是否为Paas | ||
| description | String | 描述 | ||
| azID | String | 可用区ID | ||
| isExpire | Boolean | 是否过期 | ||
| regionId | String | 资源池ID | ||
| availabilityZone | String | 可用区 | ||
| isTalkOrder | Boolean | 是否按需单 | ||
| status | String | 本参数表示VPN网关状态。 取值范围: normal creating expired |
||
| azDisplayName | String | 可用区展示名字 | ||
| paymentType | String | 本参数表示付款类型。 取值范围: MONTH YEAR onDemand |
||
| projectIDEcs | String | Project ID | ||
| customerId | String | 客户ID | ||
| createDate | String | 创建时间 | ||
| expiredTime | String | 过期时间 | ||
| updatedTime | String | 更新时间 |
请求示例
请求头
无
请求体 body
{
"regionID": "81f7728662dd11ec810800155d307d5b",
"pageNo": "1",
"pageSize": "2"
}
响应示例
{
"returnObj": {
"currentCount": 1,
"totalCount": 1,
"totalPage": 1,
"results": [{
"vpnConnectionID": "",
"dataID": null,
"availabilityZone": null,
"description": "for api test",
"azID": null,
"type": "IPsec",
"linkSpec": 20,
"bandwidth": 10,
"regionId": "b73e3ad4-417f-11ed-bad1-525400cc3b79",
"expiredTime": "2023-03-05T02:40:48Z",
"linkResourceID": "e060c7b355754dda921b61d4ae377c8d",
"isTalkOrder": false,
"vpcName": "vpc-for-api-vpn-test01",
"status": "normal",
"isExpire": false,
"azName": null,
"tenantId": null,
"vpnGatewayID": "fadf6f54-6fbd-5d5a-9c99-392de68e919e",
"vpnLinkID": "bbcc41a4-934a-4f5d-aadc-e6b6c067c227",
"isMaz": false,
"updatedTime": "2022-11-05T02:41:49Z",
"vpcID": "vpc-iyj4b6tmh0",
"isPaas": false,
"vpnGatewayName": "vpn-gateway-forAPI-test01",
"paymentType": null,
"resourceID": "7d7568aeabe8453e8aba002eb7628af1",
"vpnConnectionCount": 0,
"customerId": "84e0ef66-b86d-5927-b144-95f47f63a91f",
"createDate": "2022-11-05T02:40:48Z",
"projectIDEcs": "0",
"ipAddress": "100.124.5.171/32",
"azDisplayName": ""
}]
},
"errorCode": "",
"message": "",
"description": "",
"statusCode": 800
}
状态码
| 状态码 | 描述 |
|---|---|
| 800 | 表示请求成功 |
| 900 | 表示请求未成功 |
错误码
| errorCode | 描述 |
|---|---|
| OPENAPI.PatternCheck.NotValid | 请求参数无效 |
| OPENAPI.VPN.AccessFailed | 内部错误,请重试。如果多次尝试失败,请提交工单 |