获取日志索引列表¶
GET /api/v1/metric_info/log/indexes
概述¶
获取所有日志索引的列表
Query 请求参数¶
| 参数名 | 类型 | 必选 | 说明 |
|---|---|---|---|
| limit | integer | 限制返回结果数量,默认100 允许为空: True $default: 100 |
|
| offset | integer | 偏移量,用于分页,默认0 允许为空: True $default: 0 |
参数补充说明¶
获取日志索引列表,支持分页。
- 接口内部复用
log_index_cfg.list的索引过滤逻辑 - 固定过滤条件:
isBindCustomStore=false - 固定过滤条件:
queryType=logging,standard - 返回结果仅保留日志索引对象的
name字段
请求例子¶
curl -k 'https://openapi.guance.com/api/v1/metric_info/log/indexes?limit=10&offset=0' \
-H 'DF-API-KEY: <DF-API-KEY>' \
--compressed
响应¶
{
"code": 200,
"content": {
"data": [
{
"name": "a-123"
},
{
"name": "aus7"
},
{
"name": "dbindex"
},
{
"name": "front_backend"
},
{
"name": "gary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary-testgary"
},
{
"name": "hdt_0121_12321-------"
},
{
"name": "hdt_0325_2_no_key"
},
{
"name": "hdt_0625_s_index_1"
},
{
"name": "hdt_0722_i2_off"
},
{
"name": "hdt_0723_cn1_index_1"
}
],
"declaration": {
"business": "",
"organization": "663dbba102482200070bbb02"
}
},
"errorCode": "",
"message": "",
"success": true,
"traceId": "69ba6c7800000000519924e2a972444f"
}