I implemented a RESTful API that uses the HTTP status codes to check for success and error conditions. That caused me to use \OCP\App::isEnabled instead of \OCP\JSON::checkAppEnabled.