1. 内网VIP列表
1.1. 描述
获取内网VIP列表
1.2. 请求地址
请求地址的格式如下:
https://<区域服务地址>/v1/vip/list
1.3. 请求参数
Name | Type | Description | Required |
---|---|---|---|
projectId | String | 项目ID | 是 |
curPage | Integer | 当前页码,默认值1 | 否 |
perPage | Integer | 每页显示条数,默认值10 | 否 |
1.4. 请求示例
以查询华东一区某项目的内网VIP列表为例:
1.4.1. 请求地址
POST https://cn-east-1.api.yovole.com/v1/vip/list HTTP/1.1
x-ycs-timestamp: 2019-06-19T14:26:26Z
x-ycs-requestid: 2a49cfa2-925b-11e9-bb3a-6c96cfdcd6b9
x-ycs-security-authorization: Authorization: YCS1-HMAC-SHA1 Credential=08e206fb-7b41-45b7-8076-8d43e8aeea89,SignedHeaders=content-type;x-ycs-requestid;x-ycs-timestamp,Signature=2RFjU7C9gICCrQfpAIfAJHqRRlQ=
1.4.2. 接口请求参数
{
"projectId": "8a83a0906b692378016b6d5ec5f40250",
"curPage":1,
"perPage":10
}
1.5. 返回结果示例
1.5.1. 返回正确结果示例
{
"requestId": "43e31824-38cb-4be2-9e3a-86a90a98ae4f",
"success": true,
"code": 200,
"message": null,
"model": null,
"pager": {
"curPage": 1,
"perPage": 10,
"totalRecords": 3,
"totalPages": 1,
"pageData": [
{
"id": "f769458f-f048-4917-a6e3-0b3736d272b7",
"name": "test-vip",
"sn": "VIP-218KP29",
"regionSn": "CN-EAST-1",
"azSn": "az2",
"created": "2019-05-24 10:38:11",
"subnetId": "9c5d9d2a-aa7e-4d50-90a4-3e0abdb16c79",
"subnetSn": "SN-21B-8KP59",
"vpcId": "f14c4e48-006f-42e6-94e1-ca40865c297c",
"ipAddress": "10.1.1.6",
"bindCount": 0
},
{
"id": "7f7091e4-1215-449f-bb24-e6b3d25b2124",
"name": "test-api",
"sn": "VIP-21-8KP28",
"regionSn": "CN-EAST-1",
"azSn": "az2",
"created": "2019-05-24 10:37:06",
"subnetId": "bb4251f3-40ce-49a9-88ce-a7866d1be8ac",
"subnetSn": "SN-218KP5A",
"vpcId": "cf9f6aef-4613-4586-a084-8eead34d7f34",
"ipAddress": "172.16.10.8",
"bindCount": 0
},
{
"id": "8808f3b9-5ebc-4bc4-bd7e-b3eecaa5ba99",
"name": "test-vip",
"sn": "VIP-218KP26",
"regionSn": "CN-EAST-1",
"azSn": "az2",
"created": "2019-05-24 10:05:55",
"subnetId": "9c5d9d2a-aa7e-4d50-90a4-3e0abdb16c79",
"subnetSn": "SN-21B-8KP59",
"vpcId": "f14c4e48-006f-42e6-94e1-ca40865c297c",
"ipAddress": "10.1.1.10",
"bindCount": 0
}
]
}
}
1.5.2. 返回错误结果示例
{
"requestId": "19c0e7ff-5554-4e90-b3a5-3aab644a8e30",
"success": false,
"code": 401,
"message": "client enabled is false",
"errorCode": "InvalidUserAccount"
}
1.6. 错误码
可以通过错误返回结果中的code、errorCode和message字段了解错误分类和具体的错误原因。
该接口没有特殊错误码,错误码信息和简单的错误分析方法可以参考公共错误码。