Sonar API /api/metrics/search missing json tags

There are dozens of metrics that are missing “description” and “domain” tags. Very sloppy. This is supposed to help define what these metrics mean. There is not enough verbosity in the description tags, many are just clones of the key/name tags. Some tags don’t work on various versions of Sonar. These unsupported tags should not be included in this API listing of what is available or at least have an unsupported tag.


Welcome to the community!

Looking at our dogfooding server, I see one metric without a domain, but it’s hidden from the UI, so that’s probably okay. If you’re seeing more than that, then you’re looking at metrics contributed by 3rd-party plugins. Regarding missing description tags, I see some of those as well, mainly on metrics that are either hidden or that have pretty explicit names, such as “Date of Last Commit”. Trying to put a description on that would likely result in the another of the key/name clones you decry.

Perhaps you can give a concrete example of what you’re seeing and how you’ve tried to use it that didn’t work? Off-hand I have to guess that these too were added by 3rd-party plugins.

And by the way, SonarQube is open source. I invite you to submit a PR to fix the problems you see.