根据vnet查询subnet列表
GET
/sdn/{vnet}/getSubnets
最后修改时间:2025-06-29 01:36:12
责任人:mryunqi
请求参数
Path 参数
vnet
string
vnet 名
示例值:
net0
Query 参数
page
integer
可选
示例值:
1
size
integer
可选
示例值:
20
示例代码
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request GET '/sdn/net0/getSubnets?page=1&size=20'
返回响应
🟢200成功
application/json
Body
code
integer
必需
message
string
必需
data
object
必需
records
array [object {13}]
必需
total
integer
必需
size
integer
必需
current
integer
必需
orders
array[string]
必需
optimizeCountSql
boolean
必需
searchCount
boolean
必需
maxLimit
null
必需
countId
null
必需
pages
integer
必需
示例
{
"code": 20000,
"message": "请求成功",
"data": {
"records": [
{
"id": 1,
"nodeid": null,
"subnet": "10.1.2.1",
"type": "subnet",
"vnet": "testnat0",
"gateway": "10.1.2.1",
"mask": 8,
"dns": "114.114.114.114",
"snat": 1,
"available": null,
"used": null,
"disable": null,
"state": "new"
},
{
"id": 2,
"nodeid": null,
"subnet": "10.1.3.1",
"type": "subnet",
"vnet": "testnat0",
"gateway": "10.1.3.1",
"mask": 24,
"dns": "114.114.114.114",
"snat": 1,
"available": null,
"used": null,
"disable": null,
"state": "new"
},
{
"id": 3,
"nodeid": null,
"subnet": "10.1.4.1",
"type": "subnet",
"vnet": "testnat0",
"gateway": "10.1.4.1",
"mask": 14,
"dns": "114.114.114.114",
"snat": 1,
"available": null,
"used": null,
"disable": null,
"state": "new"
},
{
"id": 4,
"nodeid": null,
"subnet": "10.1.5.1",
"type": "subnet",
"vnet": "testnat0",
"gateway": "10.1.5.1",
"mask": 14,
"dns": "114.114.114.114",
"snat": 1,
"available": null,
"used": null,
"disable": null,
"state": "new"
}
],
"total": 4,
"size": 20,
"current": 1,
"orders": [],
"optimizeCountSql": true,
"searchCount": true,
"maxLimit": null,
"countId": null,
"pages": 1
}
}
修改于 2025-06-29 01:36:12