ResolveIndex
Updated at:2025-11-03
Description
Query index list
API restriction
- Only path parameters are supported for input; other parameters (e.g., expand_wildcards, ignore_unavailable, allow_no_indices, mode) are not supported
- All BLS are of the DataStream type. Therefore, only the data_streams field in the response body may have values, while the indices and aliases fields will return empty lists
Request
- Request syntax
Text
1GET /_resolve/index/<name> HTTP/1.1
2Host: <Endpoint>
3Authorization: <Authorization String>
- Request headers
No additional headers are required beyond the standard request headers.
- Request parameters
| Parameter name | Types | Required or not | Parameter location | Description |
|---|---|---|---|---|
| name | String | Yes | Path | Index names support fuzzy matching |
Successful response
- Response headers
No additional headers are required beyond the standard response headers.
- Response parameters
| Field | Types | Description |
|---|---|---|
| data_streams | Object | Index list |
The element structure of data_streams object in the above table is as follows:
| Field | Types | Description |
|---|---|---|
| name | String | Project and logstore name: For the default project, only the name is displayed; for non-default projects, the format is ProjectName$LogStoreName |
| backing_indices | List<String> | Currently, it is the same as name and contains only a single element |
| timestamp_field | String | Time field: Value is @timestamp |
Anomaly response
- Response headers
No additional headers are required beyond the standard response headers.
- Response parameters
| Field | Types | Description |
|---|---|---|
| error | Error | Error reason |
| status | Int | HTTP status code: e.g., 500 |
The element structure of Error object in the above table is as follows:
| Field | Types | Description |
|---|---|---|
| root_cause | List<Error> | Root cause |
| type | String | Error type |
| reason | String | Error reason |
Example
- Request example
Text
1GET /_resolve/index/* HTTP/1.1
2Host: bls-log.bj.baidubce.com
3Authorization:bce-auth-v1/18717522d39411e9b721df098b0b908c/2019-09-10T07:00:20Z/1800/content-type;host;x-bce-date;x-bce-request-id/6a7cb6c9ac7ec156c805e55e7d0bcfc443b47feee97cf099c1c0d93a0b4c8304
4Content-Type: application/json; charset=utf-8
- Response example
Text
1HTTP/1.1 204
2Content-Type: application/json; charset=utf-8
3X-Bce-Request-Id: 2eeba101-4cc7-4cfe-b5ac-a3be8d060e33
4Date: Fri, 10 Apr 2020 04:42:37 GMT
5// Success example
6{
7 "indices": [],
8 "aliases": [],
9 "data_streams": [
10 {
11 // Project and logstore name: For the default project, only the name is displayed; for non-default projects, the format is ProjectName$LogStoreName
12 "name": "project$logStoreName", // Format for default project: logStoreName
13 // For BLS, it is the same as name
14 "backing_indices": ["project$logStoreName"],
15 // Time field
16 "timestamp_field": "@timestamp"
17 }
18 ]
19}
20// Exception example
21{
22 "error": {
23 "root_cause": [
24 {
25 "type": "invalid_index_name_exception",
26 "reason": "invalid_index_name_exception",
27 }
28 ],
29 "type": "invalid_index_name_exception",
30 "reason": "invalid_index_name_exception"
31 },
32 "status": 500
33}
