查看VPC通道列表
功能介绍
查看VPC通道列表。
URI
HTTP/HTTPS请求方法以及URI如下表所示。
|
请求方法 |
URI |
|---|---|
|
GET |
/v1/{project_id}/apigw/instances/{instance_id}/vpc-channels[?page_size, page_no, id, name, vpc_type] |
o
- 可以在URI后面用‘?’和‘&’添加不同的查询条件组合。
- 查询条件可为以下字段以及对应的值:id、name、vpc_type、page_size、page_no。
|
名称 |
是否必选 |
类型 |
说明 |
|---|---|---|---|
|
project_id |
是 |
String |
项目ID。可从控制台“我的凭证”中获取region下项目ID,只有管理员权限可以查询。 |
|
instance_id |
是 |
String |
实例ID,可从API网关控制台的专享版实例信息中获取。 |
|
id |
否 |
String |
VPC通道的编号。 |
|
name |
否 |
String |
VPC通道的名称。 |
|
vpc_type |
否 |
Integer |
VPC通道的类型。 |
|
page_size |
否 |
Integer |
每页显示的VPC通道数量,默认值:20。 |
|
page_no |
否 |
Integer |
页码,默认值:1。 |
|
precise_search |
否 |
String |
指定需要精确匹配查找的参数名称,目前仅支持name |
请求消息
无
响应消息
|
名称 |
类型 |
说明 |
|---|---|---|
|
total |
Integer |
符合条件的VPC通道总数。 |
|
size |
Integer |
本次查询返回的列表长度。 |
|
vpcs |
字典数据类型 |
本次查询到的VPC通道列表。 |
|
名称 |
类型 |
说明 |
|---|---|---|
|
id |
String |
VPC通道的编号。 |
|
name |
String |
VPC通道的名称。 |
|
type |
Integer |
VPC通道的类型。
|
|
member_type |
String |
VPC通道的成员类型。
|
|
status |
Integer |
VPC通道的状态。
|
|
port |
Integer |
VPC通道中主机的端口号。 |
|
balance_strategy |
Integer |
分发算法。
|
|
create_time |
Timestamp |
VPC通道的创建时间。 |
响应消息样例:
{
"total": 2,
"size": 2,
"vpcs": [
{
"name": "通道1",
"type": 1,
"member_type": "instance",
"port": 8080,
"balance_strategy": 1,
"id": "39c62689302a48fe9f4bd7cf5c052064",
"create_time": "2018-04-24T12:07:58Z",
"status": 1
},
{
"name": "通道2",
"type": 2,
"member_type": "instance",
"port": 8088,
"balance_strategy": 1,
"id": "e6831cbcbe2b45bbbc6318c2892f060b",
"create_time": "2018-04-24T11:57:03Z",
"status": 1
}
]
}
状态码
|
状态码 |
说明 |
|---|---|
|
200 |
OK |
|
400 |
Bad Request |
|
401 |
Unauthorized |
|
403 |
Forbidden |
|
404 |
Not Found |
|
500 |
Server Internal Error |