Call the ListDefaultCollectorConfigurations to obtain the default configuration file of the collector.
Debugging
Request header
This operation uses only the common request header. For more information, see Common request parameters.
Request structure
GET /openapi/beats/default-configurations HTTP/1.1
Request parameters
Parameter | Type | Position | Required | Example | Description |
---|---|---|---|---|---|
resType | String | Query | Yes | fileBeat |
The collector type. Valid values:
|
resVersion | String | Query | Yes | 6.8.5_with_community |
The collector version. The type of machine deployed by the collector is different, and the optional version is also different. The specific description is as follows:
|
sourceType | String | Query | No | ECS |
Specifies the type of the collector to deploy the machine, and returns all if not. Valid values:
|
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
RequestId | String | 8BAE3C32-8E4A-47D6-B4B0-95B5DE643BF5 |
The ID of the request. |
Result | Array of Result |
The return results. |
|
content | String | - key: log\n title: Log file content\n description: >\n Contains log file lines.\n fields:\n ...... |
The configuration file content. |
fileName | String | fields.yml |
The name of the configuration file. |
Examples
Sample requests
GET /openapi/beats/default-configurations?ResVersion=6.8.5 _with_community&resType=fileBeat&sourceType=ECS HTTP/1.1 public request header
Sample success responses
JSON
format
{ "Result": [ { "fileName": "fields.yml", "content": "- key: log\n title: Log file content\n description: >\n Contains log file lines.\n fields:\n ......" }, { "fileName": "filebeat.yml", "content": "###################### Filebeat Configuration Example #########################\n\n# This file is an example configuration file ......" } ], "RequestId": "8BAE3C32-8E4A-47D6-B4B0-95B5DE643BF5" }
Error codes
For a list of error codes, visit the API Error Center.