Sonarcloud Web API - Insufficient privileges

I tried access the SONARCloud report via Web API but I received “Insufficient privileges” when I’m accessing “https://sonarcloud.io/api/project_analyses

URL: https://sonarcloud.io/api/project_analyses/search?project= with token in the request Header.

Project: Private Mode

Accessing the API via token and able to access other service and tested on the API and returned true in response (api/authentication/validate)

Verified the permission details as recommended in the forum and user id configured as owner group and enabled all the options (Browse, Administer, Execute Analysis, Administer Issues, See Source Code) but still I’m getting the response as “Insufficient privileges”

Let me know any other section need to be verified before triggering the request. I’m using Postman to validate the API and response

Hi!

And welcome to the community!

Are you correctly using the token to authenticate in Postman ?

Your token should be passed in the Basic Authorization request header. In Postman you can set in the Authorization tab, using the Basic Auth type and fill the Username value with your token.

Thank your very much, it works and able to fetch the details.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.