查看流控策略绑定的API列表
功能介绍
查询某个流控策略上已经绑定的API列表。
URI
HTTP/HTTPS请求方法以及URI如下表所示。
| 请求方法 | URI |
|---|---|
| GET | /v1.0/apigw/throttle-bindings/binded-apis[?page_size, page_no, throttle_id, env_id, group_id, api_id,api_name] |
- 可以在URI后面用‘?’和‘&’添加不同的查询条件组合。
- 查询条件可为以下字段以及对应的值:group_id、env_id、throttle_id、api_id、api_name、page_size、page_no。
URI中的参数说明如下表所示。
| 名称 | 是否必选 | 类型 | 说明 |
|---|---|---|---|
| throttle_id | 是 | String | 流控策略编号 |
| env_id | 否 | String | 环境的ID |
| group_id | 否 | String | API分组编号 |
| api_id | 否 | String | API编号 |
| api_name | 否 | String | API名称 |
| page_size | 否 | Integer | 每页显示的条数,默认值:20 |
| page_no | 否 | Integer | 页码,默认值:1 |
请求消息
无
响应消息
| 名称 | 类型 | 说明 |
|---|---|---|
| total | Integer | 满足条件的API总数 |
| size | Integer | 本次返回的API列表长度 |
| apis | 字典数据类型 | 本次查询返回的API列表 |
| 参数 | 类型 | 说明 |
|---|---|---|
| id | String | API编号 |
| name | String | API名称 |
| group_id | String | API所属分组的编号 |
| group_name | String | API所属分组的名称 |
| type | Integer | API类型 |
| remark | String | API描述 |
| run_env_name | String | 发布的环境名 |
| run_env_id | String | 发布的环境编号 |
| publish_id | String | 发布记录的编号 |
| throttle_apply_id | String | 与流控策略的绑定关系编号 |
| throttle_name | String | 绑定的流控策略名称 |
| apply_time | Timestamp | 与已绑定的流控策略的绑定时间 |
| auth_type | String | API的认证方式 |
| req_uri | String | API的访问地址 |
响应消息样例:
{
"total": 2,
"size": 2,
"apis": [{
"id": "5bbc47e2-95b0-4a56-904e-a3cdc422f8e9",
"name": "查询分组列表",
"type": 1,
"remark": "查询分组列表",
"group_id": "73c58022-f20d-495a-a188-85d718647f09",
"group_name": "api_group_001",
"run_env_name": "RELEASE",
"run_env_id": "DEFAULT_ENVIRONMENT_RELEASE_ID",
"publish_id": "65e6fe53-1ac3-4481-ba36-9f0bc6f22057",
"throttle_apply_id": "90f05978-06a3-4096-8bea-b5e2fa12b843",
"throttle_name": "throttle1",
"apply_time": "2017-12-29T03:01:11.138456Z",
"auth_type": "APP",
"req_uri": "/test"
},
{
"id": "6632a062-9dcf-4f18-9646-3cabb925a290",
"name": "查询API列表",
"type": 1,
"remark": "查询API列表",
"group_id": "73c58022-f20d-495a-a188-85d718647f09",
"group_name": "api_group_001",
"run_env_name": "RELEASE",
"run_env_id": "DEFAULT_ENVIRONMENT_RELEASE_ID",
"publish_id": "374a6d5a-20c7-4ea1-82e1-19fce4556956",
"throttle_apply_id": "507c6a9f-8322-4dc2-8ba5-b4d74e3690d3",
"throttle_name": "throttle1",
"apply_time": "2017-12-29T03:01:11.138456Z",
"auth_type": "APP",
"req_uri": "/test"
}]
} 状态码
| 状态码 | 说明 |
|---|---|
| 200 | OK |
| 400 | Bad Request |
| 401 | Unauthorized |
| 403 | Forbidden |
| 404 | Not Found |
| 500 | Server Internal Error |