Deleting a Query Job
To stop and delete a running Query Job, you can issue a
DELETE
request to the URL of the Query Job.
Description | Delete a previously created query job | ||
Method | DELETE /api/v1/repositories/ | ||
Authentication Required | yes | ||
Path Arguments | Description | Data type | Required? |
id | ID of the query job | string | required |
repo | Name of repository to be searched | string | required |
Return Codes | |||
200 | Request complete | ||
400 | Request is malformed and either missing critical fields or the JSON is badly structured | ||
500 | Request failed |
The request will return a standard HTTP response code indicating whether the operation was successful. See Standard HTTP response codes for more information on standard HTTP response codes.
For example, to delete a running query job:
shell
$ curl https://$YOUR_LOGSCALE_URL/api/v1/repositories/$REPOSITORY_NAME/queryjobs/$ID \
-X DELETE \
-H "Authorization: Bearer $API_TOKEN"