# SonarQube

> Find and create SonarQube projects, check quality gates, read coverage and other measures, search and triage issues, and review security hotspots. Start a workflow when a quality gate fails, for each new issue, or when an analysis finishes.

App · 20 actions. Web page: https://docs.lodol.com/docs/integrations/sonarqube

## Actions

### Add issue comment

Comment on an issue, such as a link to the ticket it was filed as.

**Inputs**

- Issue (`issue`, text, required): The issue's key, such as the key from Search issues or the New issue trigger.
- Comment (`text`, text, required): The comment. Markdown works.

**Outputs**

- `author` (text): The login of the token's user, who added it
- `comment_key` (text): The comment's key
- `created_at` (text): When it was added, in UTC (ISO 8601)
- `issue` (object): One issue
- `text` (text): The comment as added

**Example output**

```json
{
  "author": "lodol",
  "comment_key": "54b20cb4-9445-4acc-b315-1a7da4d2e17c",
  "created_at": "2026-11-12T22:38:32Z",
  "issue": {
    "assignee": "",
    "author": "dev@example.com",
    "branch": "",
    "created_at": "2026-11-12T22:35:17Z",
    "effort": "2min",
    "file": "app/billing.py",
    "impacts": [
      {
        "severity": "Medium",
        "software_quality": "Reliability"
      }
    ],
    "key": "7290575f-bf5c-417b-b0e2-7139fb47710f",
    "legacy_severity": "Major",
    "line": 38,
    "message": "Correct one of the identical sub-expressions on both sides of \"is\".",
    "project": "billing-api",
    "rule": "python:S1764",
    "severity": "Medium",
    "software_qualities": [
      "Reliability"
    ],
    "status": "Open",
    "tags": [
      "suspicious"
    ],
    "type": "Bug",
    "updated_at": "2026-11-12T22:35:17Z",
    "url": "https://sonarqube.example.com/project/issues?id=billing-api&open=7290575f-bf5c-417b-b0e2-7139fb47710f"
  },
  "text": "Filed as JIRA-1234"
}
```

### Assign issue

Assign an issue to someone, or leave it unassigned.

**Inputs**

- Issue (`issue`, text, required): The issue's key, such as the key from Search issues or the New issue trigger.
- Assign to (`assignee`, text): The user to assign it to, or me (the token's user). Leave empty to unassign it.

**Outputs**

- `assignee` (text): The login of whoever it is assigned to; empty if no one
- `author` (text): Who last changed the line, from the code's history
- `branch` (text): The branch it is on, when not the main one
- `created_at` (text): When SonarQube found it, in UTC (ISO 8601)
- `effort` (text): How long it should take to fix, such as 30min
- `file` (text): The file it is in, from the project's root
- `impacts` (list): Each software quality it affects, with its severity
- `key` (text): The issue's key
- `legacy_severity` (text): Its older severity: Blocker, Critical, Major, Minor, Info
- `line` (number): The line it is on
- `message` (text): What is wrong, as SonarQube says it
- `project` (text): The project's key
- `rule` (text): The rule it breaks, such as python:S1764
- `severity` (text): Its highest severity: Blocker, High, Medium, Low or Info
- `software_qualities` (list): The software qualities it affects
- `status` (text): Open, Confirmed, Accepted, False positive or Fixed
- `tags` (list): The issue's tags
- `type` (text): Its older type: Bug, Vulnerability or Code smell
- `updated_at` (text): When it last changed, in UTC (ISO 8601)
- `url` (text): The issue's page in SonarQube

**Example output**

```json
{
  "assignee": "jane",
  "author": "dev@example.com",
  "branch": "",
  "created_at": "2026-11-12T22:35:17Z",
  "effort": "2min",
  "file": "app/billing.py",
  "impacts": [
    {
      "severity": "Medium",
      "software_quality": "Reliability"
    }
  ],
  "key": "7290575f-bf5c-417b-b0e2-7139fb47710f",
  "legacy_severity": "Major",
  "line": 38,
  "message": "Correct one of the identical sub-expressions on both sides of \"is\".",
  "project": "billing-api",
  "rule": "python:S1764",
  "severity": "Medium",
  "software_qualities": [
    "Reliability"
  ],
  "status": "Open",
  "tags": [
    "suspicious"
  ],
  "type": "Bug",
  "updated_at": "2026-11-12T22:35:17Z",
  "url": "https://sonarqube.example.com/project/issues?id=billing-api&open=7290575f-bf5c-417b-b0e2-7139fb47710f"
}
```

### Change issue status

Accept an issue (it stays, on purpose), mark it a false positive, or reopen it, with an optional comment saying why. Accepting and false positive need the Administer Issues permission.

**Inputs**

- Issue (`issue`, text, required): The issue's key, such as the key from Search issues or the New issue trigger.
- Change to (`status`, text, required): Accept, False positive, or Reopen. One of: `accept`, `false_positive` (False positive), `reopen`.
- Comment (`comment`, text): Why, added to the issue as a comment.

**Outputs**

- `assignee` (text): The login of whoever it is assigned to; empty if no one
- `author` (text): Who last changed the line, from the code's history
- `branch` (text): The branch it is on, when not the main one
- `created_at` (text): When SonarQube found it, in UTC (ISO 8601)
- `effort` (text): How long it should take to fix, such as 30min
- `file` (text): The file it is in, from the project's root
- `impacts` (list): Each software quality it affects, with its severity
- `key` (text): The issue's key
- `legacy_severity` (text): Its older severity: Blocker, Critical, Major, Minor, Info
- `line` (number): The line it is on
- `message` (text): What is wrong, as SonarQube says it
- `project` (text): The project's key
- `rule` (text): The rule it breaks, such as python:S1764
- `severity` (text): Its highest severity: Blocker, High, Medium, Low or Info
- `software_qualities` (list): The software qualities it affects
- `status` (text): Open, Confirmed, Accepted, False positive or Fixed
- `tags` (list): The issue's tags
- `type` (text): Its older type: Bug, Vulnerability or Code smell
- `updated_at` (text): When it last changed, in UTC (ISO 8601)
- `url` (text): The issue's page in SonarQube

**Example output**

```json
{
  "assignee": "",
  "author": "dev@example.com",
  "branch": "",
  "created_at": "2026-11-12T22:35:17Z",
  "effort": "2min",
  "file": "app/billing.py",
  "impacts": [
    {
      "severity": "Medium",
      "software_quality": "Reliability"
    }
  ],
  "key": "7290575f-bf5c-417b-b0e2-7139fb47710f",
  "legacy_severity": "Major",
  "line": 38,
  "message": "Correct one of the identical sub-expressions on both sides of \"is\".",
  "project": "billing-api",
  "rule": "python:S1764",
  "severity": "Medium",
  "software_qualities": [
    "Reliability"
  ],
  "status": "Accepted",
  "tags": [
    "suspicious"
  ],
  "type": "Bug",
  "updated_at": "2026-11-12T22:35:17Z",
  "url": "https://sonarqube.example.com/project/issues?id=billing-api&open=7290575f-bf5c-417b-b0e2-7139fb47710f"
}
```

### Create project

Create an empty project, ready for its first analysis, such as one for each new repository. The token's user needs the Create Projects permission.

**Inputs**

- Name (`name`, text, required): The project's name, such as Billing API.
- Project key (`project_key`, text): Its key, which the scanner names it by: letters, digits, - _ . and :. Leave empty to make one from the name, such as billing-api.
- Visibility (`visibility`, text): Private (only people given access can see it) or public. Defaults to SonarQube's default for new projects. One of: `default` (SonarQube's default), `private`, `public`. Default: `default`.
- Main branch (`main_branch`, text): The main branch's name, such as main or master. Leave empty for SonarQube's default.

**Outputs**

- `key` (text): The new project's key
- `name` (text): Its name
- `url` (text): Its page in SonarQube
- `visibility` (text): private or public

**Example output**

```json
{
  "key": "billing-api",
  "name": "Billing API",
  "url": "https://sonarqube.example.com/dashboard?id=billing-api",
  "visibility": "private"
}
```

### Delete project

Delete a project with all its analyses, issues and measures. This can't be undone. The token's user needs Administer on the project.

**Inputs**

- Project (`project`, text, required): The project, picked by name or as its key.

**Outputs**

- `deleted` (true/false): True once SonarQube deleted the project
- `key` (text): The deleted project's key

**Example output**

```json
{
  "deleted": true,
  "key": "billing-api"
}
```

### Get project

Get a project's name, tags, visibility, version, when it was last analysed and its quality gate status.

**Inputs**

- Project (`project`, text, required): The project, picked by name or as its key.

**Outputs**

- `description` (text): The project's description
- `key` (text): The project's key
- `last_analysis_date` (text): When it was last analysed, in UTC (ISO 8601); empty if never
- `name` (text): The project's name
- `quality_gate_passed` (true/false): True when the quality gate passed
- `quality_gate_status` (text): The quality gate's status: Passed, Failed, No quality gate, or Not analyzed
- `tags` (list): The project's tags
- `url` (text): The project's page in SonarQube
- `version` (text): The version of its last analysis
- `visibility` (text): private or public

**Example output**

```json
{
  "description": "",
  "key": "billing-api",
  "last_analysis_date": "2026-11-12T22:35:17Z",
  "name": "Billing API",
  "quality_gate_passed": false,
  "quality_gate_status": "Failed",
  "tags": [
    "payments",
    "team-a"
  ],
  "url": "https://sonarqube.example.com/dashboard?id=billing-api",
  "version": "2.4.0",
  "visibility": "private"
}
```

### Get project measures

Get a project's measures: coverage, issues by software quality, bugs, vulnerabilities, code smells, duplications, ratings and technical debt, overall and on new code, for a weekly report or a check.

**Inputs**

- Project (`project`, text, required): The project, picked by name or as its key.
- Branch (`branch`, text): The branch. Leave empty for the main branch.
- Other metrics (`metrics`, text): More metrics to get, by key, separated by commas, such as complexity, cognitive_complexity. Leave empty for the usual ones.

**Outputs**

- `accepted_issues` (number): Issues accepted as they are
- `branch` (text): The branch, or empty for the main branch
- `bugs` (number): Bugs (the older count of reliability issues)
- `code_smells` (number): Code smells (the older count of maintainability issues)
- `coverage` (number): Test coverage, in percent
- `duplicated_lines_density` (number): Duplicated lines, in percent
- `lines_of_code` (number): Lines of code, not counting comments and blank lines
- `maintainability_issues` (number): Open issues affecting maintainability
- `maintainability_rating` (text): Maintainability rating, A (best) to E
- `measures` (object): Every measure read, by metric key, including any asked for
- `new_coverage` (number): Test coverage of new code, in percent
- `new_duplicated_lines_density` (number): Duplicated lines in new code, in percent
- `new_issues` (number): Issues in new code
- `open_issues` (number): All open issues
- `project` (text): The project's key
- `quality_gate_status` (text): The quality gate's status: Passed, Failed, No quality gate, or Not analyzed
- `reliability_issues` (number): Open issues affecting reliability
- `reliability_rating` (text): Reliability rating, A (best) to E; empty if unknown
- `security_hotspots` (number): Security hotspots
- `security_issues` (number): Open issues affecting security
- `security_rating` (text): Security rating, A (best) to E
- `security_review_rating` (text): Security review rating, A (best) to E
- `technical_debt_minutes` (number): The effort to fix the maintainability issues, in minutes
- `url` (text): The project's measures page in SonarQube
- `vulnerabilities` (number): Vulnerabilities (the older count of security issues)

**Example output**

```json
{
  "accepted_issues": 3,
  "branch": "",
  "bugs": 4,
  "code_smells": 132,
  "coverage": 71.3,
  "duplicated_lines_density": 2.1,
  "lines_of_code": 12840,
  "maintainability_issues": 132,
  "maintainability_rating": "A",
  "measures": {
    "alert_status": "ERROR",
    "coverage": 71.3,
    "ncloc": 12840
  },
  "new_coverage": 64.0,
  "new_duplicated_lines_density": 0.0,
  "new_issues": 7,
  "open_issues": 137,
  "project": "billing-api",
  "quality_gate_status": "Failed",
  "reliability_issues": 4,
  "reliability_rating": "C",
  "security_hotspots": 0,
  "security_issues": 1,
  "security_rating": "D",
  "security_review_rating": "A",
  "technical_debt_minutes": 1260,
  "url": "https://sonarqube.example.com/component_measures?id=billing-api",
  "vulnerabilities": 1
}
```

### Get project's quality gate

Find out which quality gate a project uses, and whether it is the default one.

**Inputs**

- Project (`project`, text, required): The project, picked by name or as its key.

**Outputs**

- `is_default` (true/false): True when it is the default quality gate
- `project` (text): The project's key
- `quality_gate` (text): The name of the quality gate the project uses

**Example output**

```json
{
  "is_default": false,
  "project": "billing-api",
  "quality_gate": "Strict"
}
```

### Get quality gate status

Check whether a project, branch or pull request passes its quality gate, with the conditions that failed, such as before a release.

**Inputs**

- Project (`project`, text, required): The project, picked by name or as its key.
- Branch (`branch`, text): The branch. Leave empty for the main branch.
- Pull request (`pull_request`, text): A pull request's number, instead of a branch.

**Outputs**

- `branch` (text): The branch, or empty for the main branch
- `conditions` (list): Every condition of the quality gate
- `failed_conditions` (list): The conditions that failed
- `passed` (true/false): True when the quality gate passed
- `project` (text): The project's key
- `pull_request` (text): The pull request, or empty
- `status` (text): Passed, Failed, Warning, or No quality gate
- `summary` (text): The status and each failed condition, as one line of text
- `url` (text): The project's page in SonarQube

**Example output**

```json
{
  "branch": "",
  "conditions": [
    {
      "actual": "7",
      "comparator": ">",
      "metric": "new_violations",
      "metric_name": "New issues",
      "passed": false,
      "status": "Failed",
      "threshold": "0"
    },
    {
      "actual": "86.5",
      "comparator": "<",
      "metric": "new_coverage",
      "metric_name": "Coverage on new code",
      "passed": true,
      "status": "Passed",
      "threshold": "80"
    }
  ],
  "failed_conditions": [
    {
      "actual": "7",
      "comparator": ">",
      "metric": "new_violations",
      "metric_name": "New issues",
      "passed": false,
      "status": "Failed",
      "threshold": "0"
    }
  ],
  "passed": false,
  "project": "billing-api",
  "pull_request": "",
  "status": "Failed",
  "summary": "Failed: New issues is 7 (must not be > 0)",
  "url": "https://sonarqube.example.com/dashboard?id=billing-api"
}
```

### List analyses

List a project's analyses, newest first, with what changed at each: the quality gate passing or failing, a new version, and more.

**Inputs**

- Project (`project`, text, required): The project, picked by name or as its key.
- Branch (`branch`, text): The branch. Leave empty for the main branch.
- Show (`category`, text): Every analysis (the default), or only those where the quality gate changed, or a new version was analysed. One of: `any` (Every analysis), `quality_gate` (Quality gate changes), `version` (New versions). Default: `any`.
- Since (`since`, date and time): Only analyses from this time on.
- Limit (`limit`, number): The most to return. Defaults to 100, up to 500. From 1 to 500.

**Outputs**

- `analyses` (list): The analyses, newest first
- `branch` (text): The branch, or empty for the main branch
- `count` (number): How many were returned
- `project` (text): The project's key
- `total` (number): How many match in all

**Example output**

```json
{
  "analyses": [
    {
      "branch": "",
      "date": "2026-11-12T22:35:17Z",
      "events": [
        {
          "category": "Quality gate",
          "description": "New issues > 0",
          "name": "Failed"
        }
      ],
      "key": "e86b6fee-eb31-44bc-a3d7-e815bd9b3add",
      "project": "billing-api",
      "quality_gate_change": "Failed",
      "revision": "9f1c2ab",
      "url": "https://sonarqube.example.com/project/activity?id=billing-api",
      "version": "2.4.0"
    }
  ],
  "branch": "",
  "count": 1,
  "project": "billing-api",
  "total": 1
}
```

### List branches

List a project's analysed branches, the main one first, with each one's quality gate status and last analysis.

**Inputs**

- Project (`project`, text, required): The project, picked by name or as its key.

**Outputs**

- `branches` (list): The project's branches, the main one first
- `count` (number): How many branches
- `main_branch` (text): The main branch's name
- `project` (text): The project's key

**Example output**

```json
{
  "branches": [
    {
      "is_main": true,
      "last_analysis_date": "2026-11-12T22:35:17Z",
      "name": "main",
      "quality_gate_passed": true,
      "quality_gate_status": "Passed",
      "type": "BRANCH",
      "url": "https://sonarqube.example.com/dashboard?id=billing-api"
    }
  ],
  "count": 1,
  "main_branch": "main",
  "project": "billing-api"
}
```

### List projects

Find the projects the token can browse, by name or key, with whether each passes its quality gate, such as every project failing its gate.

**Inputs**

- Name contains (`query`, text): Only projects whose name contains this, or whose key is this. Leave empty for all.
- Quality gate (`quality_gate`, text): Only projects whose quality gate failed, or passed. One of: `any`, `failed`, `passed`. Default: `any`.
- Limit (`limit`, number): The most to return. Defaults to 100, up to 500. From 1 to 500.

**Outputs**

- `count` (number): How many projects were returned
- `projects` (list): The projects found, by name
- `total` (number): How many projects match in all

**Example output**

```json
{
  "count": 1,
  "projects": [
    {
      "key": "billing-api",
      "name": "Billing API",
      "quality_gate_passed": false,
      "quality_gate_status": "Failed",
      "url": "https://sonarqube.example.com/dashboard?id=billing-api"
    }
  ],
  "total": 1
}
```

### List security hotspots

List a project's security hotspots (code to review for security) to review or already reviewed. SonarQube 2026.4 and later raise security issues instead, which Search issues finds.

**Inputs**

- Project (`project`, text, required): The project, picked by name or as its key.
- Branch (`branch`, text): The branch. Leave empty for the main branch.
- Status (`status`, text): To review (the default), reviewed, or any. One of: `to_review` (To review), `reviewed`, `any` (Any status). Default: `to_review`.
- Limit (`limit`, number): The most to return. Defaults to 100, up to 500. From 1 to 500.

**Outputs**

- `count` (number): How many were returned
- `hotspots` (list): The hotspots found
- `project` (text): The project's key
- `total` (number): How many match in all

**Example output**

```json
{
  "count": 1,
  "hotspots": [
    {
      "assignee": "",
      "created_at": "2026-11-12T22:35:17Z",
      "file": "app/billing.py",
      "key": "AZJ1r0wRkS2fV8u3pXyA",
      "line": 15,
      "message": "Make sure that hashing data is safe here.",
      "project": "billing-api",
      "resolution": "",
      "rule": "python:S4790",
      "security_category": "weak-cryptography",
      "status": "To review",
      "updated_at": "2026-11-12T22:35:17Z",
      "url": "https://sonarqube.example.com/security_hotspots?id=billing-api&hotspots=AZJ1r0wRkS2fV8u3pXyA",
      "vulnerability_probability": "Low"
    }
  ],
  "project": "billing-api",
  "total": 1
}
```

### Remove project's quality gate

Stop a project using its own quality gate, so it goes back to the default one. The token's user needs Administer on the project.

**Inputs**

- Project (`project`, text, required): The project, picked by name or as its key.

**Outputs**

- `is_default` (true/false): True when it is the default quality gate
- `project` (text): The project's key
- `quality_gate` (text): The name of the quality gate the project uses

**Example output**

```json
{
  "is_default": true,
  "project": "billing-api",
  "quality_gate": "Sonar way"
}
```

### Review security hotspot

Mark a security hotspot reviewed: fixed, safe, or acknowledged (a real risk left as it is), with a comment. Needs the Administer Security Hotspots permission.

**Inputs**

- Security hotspot (`hotspot`, text, required): The hotspot's key, from List security hotspots.
- Reviewed as (`resolution`, text, required): Fixed, Safe, or Acknowledged (SonarQube Server only). One of: `fixed`, `safe`, `acknowledged`.
- Comment (`comment`, text): Why, kept with the review.

**Outputs**

- `assignee` (text): The login of whoever it is assigned to
- `created_at` (text): When SonarQube found it, in UTC (ISO 8601)
- `file` (text): The file it is in
- `key` (text): The hotspot's key
- `line` (number): The line it is on
- `message` (text): What to review, as SonarQube says it
- `project` (text): The project's key
- `resolution` (text): Once reviewed: Fixed, Safe or Acknowledged
- `rule` (text): The rule that raised it
- `security_category` (text): Its security category, such as sql-injection
- `status` (text): To review or Reviewed
- `updated_at` (text): When it last changed, in UTC (ISO 8601)
- `url` (text): The hotspot's page in SonarQube
- `vulnerability_probability` (text): High, Medium or Low

**Example output**

```json
{
  "assignee": "",
  "created_at": "2026-11-12T22:35:17Z",
  "file": "app/billing.py",
  "key": "AZJ1r0wRkS2fV8u3pXyA",
  "line": 15,
  "message": "Make sure that hashing data is safe here.",
  "project": "billing-api",
  "resolution": "Safe",
  "rule": "python:S4790",
  "security_category": "weak-cryptography",
  "status": "Reviewed",
  "updated_at": "2026-11-12T22:35:17Z",
  "url": "https://sonarqube.example.com/security_hotspots?id=billing-api&hotspots=AZJ1r0wRkS2fV8u3pXyA",
  "vulnerability_probability": "Low"
}
```

### Search issues

Find issues by project, branch, severity, software quality, status, assignee, tag, rule or when they were found, such as every open high-severity security issue. Get them as a list and as text for an AI step or a message.

**Inputs**

- Project (`project`, text): Only issues in this project. Leave empty for every project the token can browse.
- Branch (`branch`, text): The branch. Leave empty for the main branch.
- Severity (`severity`, text): Only issues of this severity or higher. One of: `any` (Any severity), `low` (Low or higher), `medium` (Medium or higher), `high` (High or higher), `blocker` (Blocker only). Default: `any`.
- Software quality (`software_quality`, text): Only issues affecting this: Security (what was a vulnerability), Reliability (a bug) or Maintainability (a code smell). One of: `any` (Any software quality), `security`, `reliability`, `maintainability`. Default: `any`.
- Status (`status`, text): Open issues (the default), or ones accepted, marked a false positive or fixed. One of: `open` (Open (not yet resolved)), `accepted`, `false_positive` (False positive), `fixed`, `any` (Any status). Default: `open`.
- Assigned to (`assignee`, text): Only issues assigned to this user, or to me (the token's user).
- Tags (`tags`, text): Only issues with one of these tags, separated by commas.
- Rule (`rule`, text): Only issues of these rules, by key, such as python:S1764.
- Found after (`created_after`, date and time): Only issues SonarQube found after this time.
- New code only (`new_code_only`, true/false): Only issues in the project's new code, as its new code definition sets it. Needs a project. Default: `false`.
- Order (`sort`, text): Newest first (the default), oldest first, most severe first, or recently updated first. One of: `newest` (Newest first), `oldest` (Oldest first), `severity` (Most severe first), `updated` (Recently updated first). Default: `newest`.
- Limit (`limit`, number): The most issues to return. Defaults to 100. From 1 to 10000.

**Outputs**

- `count` (number): How many issues were returned
- `issues` (list): The matching issues, in the order asked for
- `limit_reached` (true/false): True when more issues match than were returned
- `text` (text): Every issue as text, one a line with its severity, file and status, ready for an AI step or a message
- `total` (number): How many issues match in all

**Example output**

```json
{
  "count": 1,
  "issues": [
    {
      "assignee": "",
      "author": "dev@example.com",
      "branch": "",
      "created_at": "2026-11-12T22:35:17Z",
      "effort": "2min",
      "file": "app/billing.py",
      "impacts": [
        {
          "severity": "Medium",
          "software_quality": "Reliability"
        }
      ],
      "key": "7290575f-bf5c-417b-b0e2-7139fb47710f",
      "legacy_severity": "Major",
      "line": 38,
      "message": "Correct one of the identical sub-expressions on both sides of \"is\".",
      "project": "billing-api",
      "rule": "python:S1764",
      "severity": "Medium",
      "software_qualities": [
        "Reliability"
      ],
      "status": "Open",
      "tags": [
        "suspicious"
      ],
      "type": "Bug",
      "updated_at": "2026-11-12T22:35:17Z",
      "url": "https://sonarqube.example.com/project/issues?id=billing-api&open=7290575f-bf5c-417b-b0e2-7139fb47710f"
    }
  ],
  "limit_reached": false,
  "text": "[Medium, Reliability] Correct one of the identical sub-expressions on both sides of \"is\". (app/billing.py:38, Open)",
  "total": 1
}
```

### Set issue severity

Change how severe an issue is, such as raising one a team must fix before release. Needs the Administer Issues permission.

**Inputs**

- Issue (`issue`, text, required): The issue's key, such as the key from Search issues or the New issue trigger.
- Severity (`severity`, text, required): Blocker, High, Medium, Low or Info. One of: `blocker`, `high`, `medium`, `low`, `info`.
- For (`software_quality`, text): Which of its software qualities the severity is for. Defaults to the issue's own. One of: `own` (The issue's own), `security`, `reliability`, `maintainability`. Default: `own`.

**Outputs**

- `assignee` (text): The login of whoever it is assigned to; empty if no one
- `author` (text): Who last changed the line, from the code's history
- `branch` (text): The branch it is on, when not the main one
- `created_at` (text): When SonarQube found it, in UTC (ISO 8601)
- `effort` (text): How long it should take to fix, such as 30min
- `file` (text): The file it is in, from the project's root
- `impacts` (list): Each software quality it affects, with its severity
- `key` (text): The issue's key
- `legacy_severity` (text): Its older severity: Blocker, Critical, Major, Minor, Info
- `line` (number): The line it is on
- `message` (text): What is wrong, as SonarQube says it
- `project` (text): The project's key
- `rule` (text): The rule it breaks, such as python:S1764
- `severity` (text): Its highest severity: Blocker, High, Medium, Low or Info
- `software_qualities` (list): The software qualities it affects
- `status` (text): Open, Confirmed, Accepted, False positive or Fixed
- `tags` (list): The issue's tags
- `type` (text): Its older type: Bug, Vulnerability or Code smell
- `updated_at` (text): When it last changed, in UTC (ISO 8601)
- `url` (text): The issue's page in SonarQube

**Example output**

```json
{
  "assignee": "",
  "author": "dev@example.com",
  "branch": "",
  "created_at": "2026-11-12T22:35:17Z",
  "effort": "2min",
  "file": "app/billing.py",
  "impacts": [
    {
      "severity": "High",
      "software_quality": "Reliability"
    }
  ],
  "key": "7290575f-bf5c-417b-b0e2-7139fb47710f",
  "legacy_severity": "Major",
  "line": 38,
  "message": "Correct one of the identical sub-expressions on both sides of \"is\".",
  "project": "billing-api",
  "rule": "python:S1764",
  "severity": "High",
  "software_qualities": [
    "Reliability"
  ],
  "status": "Open",
  "tags": [
    "suspicious"
  ],
  "type": "Bug",
  "updated_at": "2026-11-12T22:35:17Z",
  "url": "https://sonarqube.example.com/project/issues?id=billing-api&open=7290575f-bf5c-417b-b0e2-7139fb47710f"
}
```

### Set issue tags

Add, remove or replace an issue's tags, such as triage or a team's name.

**Inputs**

- Issue (`issue`, text, required): The issue's key, such as the key from Search issues or the New issue trigger.
- Tags (`tags`, text): Tags separated by commas, such as triage, team-a. Lower-case letters, digits and - _ . + # only.
- Change (`mode`, text): Add the tags to the ones there (the default), remove them, or replace them all. One of: `add` (Add to its tags), `remove` (Remove from its tags), `replace` (Replace its tags). Default: `add`.

**Outputs**

- `assignee` (text): The login of whoever it is assigned to; empty if no one
- `author` (text): Who last changed the line, from the code's history
- `branch` (text): The branch it is on, when not the main one
- `created_at` (text): When SonarQube found it, in UTC (ISO 8601)
- `effort` (text): How long it should take to fix, such as 30min
- `file` (text): The file it is in, from the project's root
- `impacts` (list): Each software quality it affects, with its severity
- `key` (text): The issue's key
- `legacy_severity` (text): Its older severity: Blocker, Critical, Major, Minor, Info
- `line` (number): The line it is on
- `message` (text): What is wrong, as SonarQube says it
- `project` (text): The project's key
- `rule` (text): The rule it breaks, such as python:S1764
- `severity` (text): Its highest severity: Blocker, High, Medium, Low or Info
- `software_qualities` (list): The software qualities it affects
- `status` (text): Open, Confirmed, Accepted, False positive or Fixed
- `tags` (list): The issue's tags
- `type` (text): Its older type: Bug, Vulnerability or Code smell
- `updated_at` (text): When it last changed, in UTC (ISO 8601)
- `url` (text): The issue's page in SonarQube

**Example output**

```json
{
  "assignee": "",
  "author": "dev@example.com",
  "branch": "",
  "created_at": "2026-11-12T22:35:17Z",
  "effort": "2min",
  "file": "app/billing.py",
  "impacts": [
    {
      "severity": "Medium",
      "software_quality": "Reliability"
    }
  ],
  "key": "7290575f-bf5c-417b-b0e2-7139fb47710f",
  "legacy_severity": "Major",
  "line": 38,
  "message": "Correct one of the identical sub-expressions on both sides of \"is\".",
  "project": "billing-api",
  "rule": "python:S1764",
  "severity": "Medium",
  "software_qualities": [
    "Reliability"
  ],
  "status": "Open",
  "tags": [
    "suspicious",
    "triage"
  ],
  "type": "Bug",
  "updated_at": "2026-11-12T22:35:17Z",
  "url": "https://sonarqube.example.com/project/issues?id=billing-api&open=7290575f-bf5c-417b-b0e2-7139fb47710f"
}
```

### Set project tags

Add, remove or replace a project's tags, such as the team that owns it. The token's user needs Administer on the project.

**Inputs**

- Project (`project`, text, required): The project, picked by name or as its key.
- Tags (`tags`, text): Tags separated by commas, such as team-a, payments. Lower-case letters, digits and - _ . + # only.
- Change (`mode`, text): Add the tags to the ones there (the default), remove them, or replace them all. One of: `add` (Add to its tags), `remove` (Remove from its tags), `replace` (Replace its tags). Default: `add`.

**Outputs**

- `key` (text): The project's key
- `previous_tags` (list): Its tags before
- `tags` (list): The project's tags now

**Example output**

```json
{
  "key": "billing-api",
  "previous_tags": [
    "payments"
  ],
  "tags": [
    "payments",
    "team-a"
  ]
}
```

### Set project's quality gate

Make a project use a quality gate, such as a stricter one for a service handling payments. The token's user needs Administer on the project.

**Inputs**

- Project (`project`, text, required): The project, picked by name or as its key.
- Quality gate (`quality_gate`, text, required): The quality gate, by name.

**Outputs**

- `is_default` (true/false): True when it is the default quality gate
- `project` (text): The project's key
- `quality_gate` (text): The name of the quality gate the project uses

**Example output**

```json
{
  "is_default": false,
  "project": "billing-api",
  "quality_gate": "Strict"
}
```
