We are trying to move away from personal access tokens and instead use a Scoped Organization Token for SonarCloud.
Our SonarCloud organization contains 109 projects. We created a new Scoped Organization Token and explicitly assigned it to 3 specific projects. All these projects are private projects.
When we apply this token to our SonarCloud service connection in Azure DevOps (Edit Service Connection → paste new token → Verify), the verification fails with a server-side error.
We also waited some time after creating the token (in case propagation or initialization was required), but the error persists consistently.
The error we get is this one: Failed to query service connection API: 'https://sonarcloud.io/api/organizations/search?member=true'. Status Code: 'InternalServerError', Response from server: '{"errors":[{"msg":"An unexpected error occurred. Please try again later."}]}'
Any help would be appreciated, as we would really like to adopt scoped tokens instead of personal ones. What can we do to make this setup work correctly?
Currently, Scoped Organization Tokens are only used to run analyses. So it wouldn’t work when querying https://sonarcloud.io/api/organizations/search?member=true
So.. I must be doing something wrong then? Can you maybe guide me on how to set this up?
I think I’m going through the standard path for doing this. Or can I just ignore that error and continue?
Also, is there a non-community way to getting support for paying customers? I don’t mind doing it here, but there should at least be some minimal SLA on this?
“Verify” uses the candidate token to query our APIs; e.g., /api/organizations/search. SOTs do not yet work for these APIs, hence the InternalServerError.
Also, is there a non-community way to getting support for paying customers? I don’t mind doing it here, but there should at least be some minimal SLA on this?
On Help Center, our commercial SLA is between 1 to 24 hours, depending on the severity of the issue at hand. (There’s nothing like that on Community, of course.)
There was a nice blog post on SOTs this past September. And if you scroll to the bottom, there is an email input box to subscribe if you wish. Personally, I don’t find it too spammy, and it helps me stay on top of product changes, in case I missed something
Hey @FreddyGroen - thanks for sharing here!
I just wanted to chime in and let you know that I captured your need for SOT to support ADO service connection and that we’ve planned to work on this in a few months.
We will definitely share on community when it’s done!