Quaestor Lucem
Quaestor Lucem

Reputation: 627

SonarQube web api: retrieving number of "won't fix" issues on TimeMachine API

I would like to retrieve the number of "false positives" and "won't fix" a project has along the time, so I am using the TimeMachine API.

I am able to list the "false positives", but not the "won't fix", using below URL:

api/timemachine/index?metrics=false_positive_issues

But I did not see a metric for "Won't fix" on the Metric Definitions documentation.

There is a REST service, GET api/issue_filters/search, that allows retrieving info for both "false positives" and "won't fix", but only for current user.

I have two questions:

  1. is there any way to get "Won't fix" numbers on the SonarQube web api?
  2. if not, what would be the best way to get these numbers per project?

Thanks!

Upvotes: 0

Views: 452

Answers (1)

Quaestor Lucem
Quaestor Lucem

Reputation: 627

The metric to be used is "wont_fix_issues".

Example:

http://localhost:9000/api/timemachine/index?resource=1&metrics=wont_fix_issues

Thanks a lot to G. Ann - SonarSource Team for providing this answer through their support group!

Upvotes: 0

Related Questions