Disable Scheduled Query

Disables a specified scheduled query. Administrator privileges are required to call this API.

HTTP Request

POST /api/sonar/scheduled-queries/:guid/disable

Request using cURL

curl -H "Authorization: Bearer <API_KEY>" \
     -X POST https://HOSTNAME/api/sonar/scheduled-queries/:guid/disable

Request Parameter

guidOStringScheduled query GUID36 characters

Success Response


Error Responses

Identifier is not in valid GUID format

HTTP status code 400

  "error_code": "null-argument",
  "error_msg": "guid should be not null"
GUID is not found

HTTP status code 200

  "result": false,
  "error_msg": "scheduled query not found: 0fb16aff-dbc1-458a-9769-342de5cf9219"
No administrator privileges

HTTP status code 500

  "error_code": "illegal-state",
  "error_msg": "no-permission"