## Introduction

SonarQube Server is a self-managed platform for code quality and security analysis. SonarQube uses **User Tokens** for API authentication. This guide shows you how to create a user token and gather the values you need to configure the integration.

## Prerequisites

Before you begin, ensure that you have:

- A SonarQube Server instance, and the address you use to reach it
- A SonarQube account with the permissions listed in [Required Permissions](#required-permissions). The user token you create has the same permissions as this account


## Required Permissions

| Permission | Purpose |
|  --- | --- |
| Browse Project | Read the projects and their issues. You need this permission on each private project |
| Administer System | List the projects in the instance, so the integration can find the issues in each one |


## Generating Credentials

1. Log in to SonarQube with the account from the [Prerequisites](#prerequisites) section
2. Select the account menu, then select **My account**
3. Select the **Security** tab
4. In the form at the top of the page, set the token type to *User*
5. Select an expiration date, or select **No expiration**
  - **No expiration** is not available when your instance has a maximum token lifetime
6. Select **Generate**
7. Copy the token value and store it in a safe location. You cannot see the value again after you close the notification
8. You have now created a user token. Proceed to the next section titled [Configuring the Integration](#configuring-the-integration)


For more information on SonarQube tokens, see the [SonarQube managing your tokens docs page](https://docs.sonarsource.com/sonarqube-server/latest/user-guide/managing-tokens/)

## Configuring the Integration

To configure a new SonarQube integration, provide each of the values as defined below:

| Integration Parameter | Description |
|  --- | --- |
| Secret | This is the user token you created and stored above |
| Base URL | This is the address of your SonarQube Server instance  Example `https://sonarqube.example.com` |