stack kb security-detections-api perform-rules-bulk-action cli command
elastic stack kb security-detections-api perform-rules-bulk-action \
--action <action> \
[options]
Apply a bulk action to detection rules
--actionenumrequired-
Values: edit
--dry-run-
Enables dry run mode for the request call. Enable dry run mode to verify that bulk actions can be applied to specified rules. Certain rules, such as prebuilt Elastic rules on a Basic subscription, can’t be edited and will return errors in the request response. Error details will contain an explanation, the rule name and/or ID, and additional troubleshooting information. To enable dry run mode on a request, add the query parameter
dry_run=trueto the end of the request URL. Rules specified in the request will be temporarily updated. These updates won’t be written to Elasticsearch.info Dry run mode is not supported for the
exportbulk action. A 400 error will be returned in the request response. --gap-auto-fill-scheduler-idstring- Gap auto fill scheduler ID used to determine gap fill status for rules
--gap-fill-statusesstring[]-
Gap fill statuses to filter rules with gaps by status (used together with gaps_range_*).
Repeatable: pass
--gap-fill-statusesmultiple times to supply more than one value --gaps-range-endstring- Gaps range end, valid only when query is provided
--gaps-range-startstring- Gaps range start, valid only when query is provided
--idsstring[]-
Array of rule
ids to which a bulk action will be applied. Do not use rule'srule_idhere. Only valid when query property is undefined.Repeatable: pass
--idsmultiple times to supply more than one value --querystring- Query to filter rules.
--duplicatestring- Duplicate object that describes applying an update action.
--runstring- Object that describes applying a manual rule run action.
--fill-gapsstring- Object that describes applying a manual gap fill action for the specified time range.
--editstring[]-
Array of objects containing the edit operations
Repeatable: pass
--editmultiple times to supply more than one value --input-filestring- path to a JSON file to use as command input
--json-
output as JSON