DELETE /api/detection_engine/rules

Spaces method and path for this operation:

delete /s/{space_id}/api/detection_engine/rules

Refer to Spaces for more information.

Delete a detection rule using the rule_id or id field.

The URL query must include one of the following:

  • id - DELETE /api/detection_engine/rules?id=<id>
  • rule_id- DELETE /api/detection_engine/rules?rule_id=<rule_id>

The difference between the id and rule_id is that the id is a unique rule identifier that is randomly generated when a rule is created and cannot be set, whereas rule_id is a stable rule identifier that can be assigned during rule creation.

Query parameters

  • id string(uuid)

    The rule's id value.

  • rule_id string

    The rule's rule_id value.

Responses

  • 200 application/json

    Indicates a successful call.

    Any of:
DELETE /api/detection_engine/rules
curl \
  --request DELETE https://localhost:5601/api/detection_engine/rules?rule_id=bfeaf89b-a2a7-48a3-817f-e41829dc61ee \
  --header "Content-Type: application/json; Elastic-Api-Version=2023-10-31"
Response examples (200)
{
  "actions": [],
  "created_at": "2020-02-03T11:19:04.259Z",
  "created_by": "elastic",
  "description": "Process started by MS Office program in user folder",
  "enabled": false,
  "false_positives": [],
  "from": "now-4200s",
  "id": "c41d170b-8ba6-4de6-b8ec-76440a35ace3",
  "immutable": false,
  "interval": "1h",
  "language": "kuery",
  "max_signals": 100,
  "name": "MS Office child process",
  "query": "event.action:Process*",
  "references": [],
  "risk_score": 50,
  "rule_id": "process_started_by_ms_office_user_folder",
  "severity": "low",
  "tags": [
    "tag"
  ],
  "throttle": null,
  "to": "now",
  "type": "query",
  "updated_at": "2020-02-03T11:19:04.462Z",
  "updated_by": "elastic",
  "version": 3
}