Running this action requires a SonarQube User Token generated by the user on whose behalf the action will run.

CreateSonarqubeProject — creates a new project in SonarQube. The action uses the SonarQube Web API to create a project with the specified parameters, such as the project key, project name, main branch, new code definition parameters, and project visibility. Authentication is performed using a SonarQube token, which must be provided in the credentials.

Request example

project: example-project
name: example-project
mainBranch: develop
newCodeDefinitionType: NUMBER_OF_DAYS
newCodeDefinitionValue: '30'
visibility: public

Request specification

NameRequiredDescriptionPossible valuesDefault value
projectYesUnique project identifier (Project Key) in SonarQube--
nameYesProject name displayed in the SonarQube interface--
mainBranchNoName of the project’s main branch-master
newCodeDefinitionTypeNoMethod for defining “new code”PREVIOUS_VERSION, NUMBER_OF_DAYS, REFERENCE_BRANCH-
newCodeDefinitionValueNoValue for the “new code” definition (e.g., number of days, if the type is NUMBER_OF_DAYS)--
visibilityNoProject visibilityprivate, publicprivate