Change default branch for projects

When we create a new project using the web api, the default branch is set to ‘master’. This is old fashioned and has been replaced with ‘main’ on many platforms like GitHub.

We are using the API call
POST api/projects/create

We cannot find an org-wide setting to set the default branch for all projects (to ‘main’).
Can you help?

Hello @misterwhiskers ,

This is not supported as of today. We are looking to improve the onboarding/creation of new projects in an automated way and it would very valuable to add your feedback to the following entry on our roadmap: https://portal.productboard.com/sonarsource/1-sonarcloud/c/51-automatic-provisioning-of-bound-projects .

That way you will also stay up to date in case anything changes in this regard.