> For the complete documentation index, see [llms.txt](https://docs.brainboard.co/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.brainboard.co/settings/integrations/git-configuration/gitlab.md).

# GitLab

### Add Git connection

To add GitLab personal Git token in Brainboard, you first need to generate it in your GitLab account.

<details>

<summary>Steps to generate a personal Git token on your GitLab account.</summary>

1. Go to your GitLab[ personal tokens page](https://gitlab.com/-/profile/personal_access_tokens).
2. Add a name and specify `API` rights, then click on `Create personal access token` button:<br>

   <figure><img src="/files/v2mpmBkl98jId6Kwld6U" alt=""><figcaption></figcaption></figure>
3. The token is generated, you can copy it to add to Brainboard:<br>

   <figure><img src="/files/bJXSQ2zT8yleRAD3LL5g" alt=""><figcaption></figcaption></figure>

</details>

To add the generated token in Brainboard:

1. Go to the [Git integration](https://app.brainboard.co/settings/integrations/git) settings page.
2. Click on `Integrations`
3. In the section `Personal connections` Click on `Add connection`
4. Select `GitLab` tab<br>

   <figure><img src="/files/MNgxsmoeaahWOnlRUmAR" alt=""><figcaption></figcaption></figure>
5. Add your credentials in the displayed window:
   * Name of the token. This is only for Brainboard, it will not be used when you do a pull request.
   * The URL of your GitLab server: by default Brainboard uses `https://gitlab.com`, but if you have a private Gitlab instance accessible through the internet or if you use a single-tenant Brainboard offering, you can specify a different URL.
6. Then click on `Save and close` button.
7. Brainboard will verify if the credentials are valid:
   1. If they are valid, Brainboard displays a success message and you can see the integration now in the Git connection page<br>

      <figure><img src="/files/oDsSJn5eH00l3XcZnKqT" alt=""><figcaption></figcaption></figure>
   2. If they are not, you'll receive an error about what is wrong. For example:<br>

      <figure><img src="/files/91NTWYSCT8tUWxi8PHSj" alt=""><figcaption></figcaption></figure>

      <figure><img src="/files/9lmyrr5xu1a6wy4cA51T" alt=""><figcaption></figcaption></figure>

### How to use

Please refer to the page [How to use](/settings/integrations/git-configuration/pull-requests.md) to understand how you can use your git connections whether you want to do a pull request and import your code from Git.

### Edit or delete connection

1. Go to the [Git integration](https://app.brainboard.co/settings/integrations/git) settings page.
2. Click on `Integrations`
3. In the section `Personal connections` Click on `GitLab` integration that you want to edit or delete
4. Select the action you want to perform from the view

<figure><img src="/files/RL94BHgBnsvEesWTnFhI" alt=""><figcaption></figcaption></figure>
