Disable App

Disables the specified app.

Required Permissions

Requires the ADMIN role or higher.

HTTP Request

POST /api/sonar/apps/disable
cURL Example
curl -H "Authorization: Bearer <API_KEY>" \
     -H "Content-Type: application/json" \
     -X POST \
     -d '{"app_code": "logpresso-sample-app"}' \
     https://HOSTNAME/api/sonar/apps/disable
Request Parameters
Request Body Parameters
KeyRequiredTypeDescriptionNotes
app_codeYesStringCode of the app to disable

Success Response

{}

Error Responses

app_code is missing

HTTP status code 400

{
  "error_code": "null-argument",
  "error_msg": "app_code should be not null"
}
App code is empty

HTTP status code 500

{
  "error_code": "illegal-state",
  "error_msg": "invalid app code: app code-[]"
}
App is not installed

HTTP status code 500

{
  "error_code": "illegal-state",
  "error_msg": "app is not installed in db: app code-[logpresso-sample-app]"
}
Permission denied

HTTP status code 500

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