Skip to content

Modify Index Speed Field Configuration



POST /api/v1/workspace/index_speed_field/modify

Overview

Configure index query speed fields.
Currently only supports log type indices under the ScopeDB storage engine.
Index information comes from the Log - Index - List endpoint.
Index field information can be queried via the DQL statement SHOW_LOGGING_FIELD(index='xx').

Body Request Parameters

Parameter Name Type Required Description
fieldSpeedConfig array Field speed configuration
Allow empty: False
fieldSpeedConfig[*] None
fieldSpeedConfig[*].index string Index name, from the name field in the log index list
Example: default
Allow empty: False
fieldSpeedConfig[*].field string Y Field
Example: dest_host
Allow empty: False
fieldSpeedConfig[*].enable boolean Y Whether to enable
Example: False
Allow empty: False
fieldSpeedConfig[*].indexType string Index type. Empty or materialized indicates a normal/materialized index, search indicates adding an inverted index.
Example: search
Allow empty: True
Allow empty string: True
namespace string Namespace, all lowercase from the namespace in DQL
Allow empty: False
source string Source
Allow empty: False

Parameter Supplementary Notes

Request Example

curl 'https://openapi.truewatch.com/api/v1/workspace/index_speed_field/modify' \
  -H 'Content-Type: application/json;charset=UTF-8' \
  -H 'DF-API-KEY: <DF-API-KEY>' \
  --data-raw '{"namespace":"logging","fieldSpeedConfig":[{"index":"default","field":"dest_host","enable":false}]}' \
  --insecure

Response

{
    "code": 200,
    "content": true,
    "errorCode": "",
    "message": "",
    "success": true,
    "traceId": "xxxxxx"
}