Preview rule alerts generated on specified time range

Server: https://{kibana_url}
  • POST /api/detection_engine/rules/preview
  • POST /s/{space_id}/api/detection_engine/rules/preview

Refer to Spaces for more information.

Simulates a detection rule using the same rule type and query logic as a persisted rule, over a short time window, without persisting a rule or writing alerts. Use the response to validate queries, see sample matching documents, and inspect execution logs. Pair invocationCount and timeframeEnd to cap run time.

Query Parameters

enable_logged_requests boolean

Enables logging and returning in response ES queries, performed during rule execution

Responses