查询私有网络信息
描述
查询私有网络信息,可根据查询条件检索到多条记录。
请求参数
| 参数名 | 参数类型 | 是否必填 | 参数说明 |
|---|---|---|---|
| Action | String | 是 | 操作方法:DescribeNetworks |
| Region | String | 是 | 机房标识,取值参见地域列表 |
| Offset | Integer | 否 | 记录偏移量,不指定取 0 |
| Count | Integer | 否 | 记录数量,不指定为全部 |
| Id.N | String | 否 | 私有网络标识,支持批量,N为自然数,格式:&Id.0=xxx&Id.1=xxx等 |
| Name | String | 否 | 名称 |
| StartTime | String | 否 | 创建开始时间 格式yyyy-MM-dd HH:mm:ss |
| EndTime | String | 否 | 创建结束时间 格式yyyy-MM-dd HH:mm:ss |
返回参数
| 名称 | 类型 | 说明 |
|---|---|---|
| Action | String | 执行的操作 |
| TaskId | String | 请求标识 |
| TotalCount | Integer | 过滤条件下总共记录数 |
| NetworkSet | NetworktemType | 由NetworktemType组成的数组格式,返回私有网络的信息 |
NetworktemType
私有网络信息的数据类型
| 名称 | 类型 | 说明 |
|---|---|---|
| Id | String | 网络标识 |
| Uuid | String | UUID |
| Name | String | 名称 |
| Description | String | 描述 |
| Cidr | String | IP 地址范围 |
| Type | String | 类型, DEFAULT CUSTOMER,默认为CUSTOMER |
| Dhcp | Boolean | 是否启用 DHCP |
| Gateway | String | 网关地址,主要影响到 DHCP 服务的路由信息 |
| ProductStatus | String | 产品状态,正常:NORMAL 过期:OVERTIMER 欠费:ARREARAGE |
| IpStart | String | 起始 IP 地址 |
| IpEnd | String | 终止 IP 地址 |
| SpecialLineId | String | 所属专线 |
| CreateTime | DateTime | 创建时间 |
| BindingSet | BindingSetItemType | 由BindingSetItemType组成的数组格式,返回绑定了私有网络的资源 |
| UserId | String | 所属用户ID |
| SubnetId | String | 管理员用,私有网络子网标识 |
| SubnetUuid | String | 管理员用,私有子网uuid |
| SubnetLongId | String | 管理员用,私有子网LongId |
BindingSetItemType
绑定了私有网络的资源数据类型
| 名称 | 类型 | 说明 |
|---|---|---|
| ResourceId | String | 资源标识 |
| ResourceName | String | 资源名称 |
| ResourceType | String | 资源类型:INSTANCE,ROUTER,LOADBALANCE |
| ResourceEips | List | 资源绑定对应的IP |
请求示例
https://api.chinac.com/v2/?Action=DescribeNetworks
&Name=Obi-wan
&公共参数
返回示例
{
"code": 10000,
"message": "",
"data": {
"TaskId": "mirrorz0011520170510091646931",
"Action": "DescribeNetworks",
"TotalCount": 1,
"NetworkSet": [{
"Id": "n-169ih3kdh632x",
"Name": "666",
"Description": null,
"Cidr": "10.10.66.0/24",
"Type": "CUSTOMER",
"Dhcp": "true",
"Gateway": "10.10.66.1",
"ProductStatus": "NORMAL",
"IpStart": "10.10.66.2",
"IpEnd": "10.10.66.254",
"CreateTime": "2017-04-20T13:17:06 +0800",
"SpecialLineId": null,
"Ips": ["10.10.66.5",
"10.10.66.2",
"10.10.66.1",
"10.10.66.3"],
"Uuid": "e3df9d1f-0a11-40ce-bc8f-661a639e2e94",
"IdLong": "n-169ih3kdh632x-e3df9d1f-0a11-40ce-bc8f-661a639e2e94",
"UserId": "18359229",
"BindingSet": [{
"ResourceId": "r-il9ih3kder92t",
"ResourceName": "666",
"ResourceUuid": "8437e39e-395b-401e-822f-d5b9669872d4",
"ResourceType": "ROUTER",
"ResourceEips": ["172.16.29.65"]
},
{
"ResourceId": "lb-in9ih3kecj85v",
"ResourceName": "clb1704203fpi",
"ResourceUuid": "5dfa1edc-7339-482b-a90b-f55a39e469a6",
"ResourceType": "LOADBALANCER",
"ResourceEips": ["172.16.29.67"]
}],
"SubnetId": "s-989ih3kdh635q",
"SubnetUuid": "c2cd54ce-cbe4-4a48-8de4-3e434333fdc6",
"SubnetLongId": "s-989ih3kdh635q-c2cd54ce-cbe4-4a48-8de4-3e434333fdc6"
}]
}
}