Type to search.

Delete an anomaly detection job

  • DELETE /_ml/anomaly_detectors/{job_id}
Auth The Elastic Stack includes Elastic's core products such as Elasticsearch, Kibana, Logstash, and Beats. Availability Generally available since 5.4 This functionality is generally available and ready for production usage. Unless stated otherwise on the page, this functionality is available when your Elastic Stack is deployed on Elastic Cloud Hosted, Elastic Cloud Enterprise, Elastic Cloud on Kubernetes, and self-managed environments. This documentation corresponds to the latest patch available for each minor version. If you're not using the latest patch, check the release notes for changes.

All job configuration, model state and results are deleted. It is not currently possible to delete multiple jobs using wildcards or a comma separated list. If you delete a job that has a datafeed, the request first tries to delete the datafeed. This behavior is equivalent to calling the delete datafeed API with the same timeout and force parameters as the delete job request.

Required privileges

Cluster privileges manage_ml

Path parameters

job_id string required

Identifier for the anomaly detection job.

Query parameters

force boolean · default: false

Use to forcefully delete an opened job; this method is quicker than closing and deleting the job.

delete_user_annotations boolean · default: false

Specifies whether annotations that have been added by the user should be deleted along with any auto-generated annotations when the job is reset.

wait_for_completion boolean · default: true

Specifies whether the request should return immediately or wait until the job deletion completes.

Response

application/json
acknowledged boolean required

For a successful response, this value is always true. On failure, an exception is returned instead.