stack kb alerting-v2 post-alerting-v2-rules-delete-by-query cli command
Auth required
elastic stack kb alerting-v2 post-alerting-v2-rules-delete-by-query [options]
Delete rules matching a query (dry-run by default)
Behaviour flags:
--dry-run — validate all inputs and exit without performing any action
--filterstring- KQL filter string to match target resources. At most 10000 matching resources are processed per request. Cannot be empty; to target every resource use
match_all: true. --force- When true, executes the operation. When false (default), returns a dry-run preview with
match_countand asampleof matching resource IDs so the client can verify before committing. --match-allenum-
When true, targets every resource. Requires an explicit opt-in. Omitted by default.
Values: true
--searchstring- Free-text search string matched against the resource-defined searchable fields. Cannot be empty; to target every resource use
match_all: true. --input-filestring- path to a JSON file to use as command input
--dry-run- validate all inputs and exit without performing any action (preview changes without applying them)
--json-
output as JSON