You can create a GiLab Cloud integration with Flow using OAuth or an access token.
Important: Use a service account to create this integration. Learn more about creating service accounts.
Git host permission requirements
Flow only requires read access to your repositories. This permission is needed to process the metadata used to generate our reports. In order to use all services and webhooks when integrating with Flow, the service account must be a maintainer or owner at the project and repository level. If you don't want to enable webhooks, then the minimum permission needed in GitLab is reporter at the project and repository level.
Connect via OAuth
Connecting via OAuth is the fastest and easiest method to connect your repos.
- Click Settings in the top navigation. In the left navigation under Integrations, click Integrations.
- Click Add Integration in the top right corner of your Integrations page.
- On the following page, select GitLab from the Integration Provider list.
- Under theOAuth tab, click Connect to GitLab.
- If you're already logged into your GitLab account, a pop-up will prompt you to confirm access.
Note: If you are not already logged in, you will be prompted to login and authorize the connection.
- If the connection was successful you will receive a success message.
- Once you've connected, you may proceed to the Finishing up section of this article to complete the integration process.
Connect via personal access token
To connect via a personal access token, use the Access Token authentication method.
- In GitLab, navigate to your Access Tokens page. For information on personal access tokens, and where to find Access Tokens page, see Gitlab’s help document (opens in new tab).
- On the Personal Access Tokens (PAT) page, fill out the following information:
- Name: Give the PAT a unique name so you can identify what it is being used for.
- Expires at: This is optional. Note that if the PAT expires before you update it, Flow will not be able to continue to update and process your data.
-
Scopes: The minimum scopes needed are:
api
read_user
read_repository
- Click Create personal access token.
- Copy your access token into the access token field in Flow.
- Click Test connection.
- If the connection was successful you will receive a success message.
Finishing up
Once you have a successful connection, you can finalize your integration and begin importing repos.
- Click Next.
- On the next screen, select the services you want turned on for this integration. Selecting all three services allows Flow to ingest repo, PR, and ticket data. You can turn services on and off at any time. Click Next.
- Name your integration so you can identify the account. Click Create.
You have successfully created a new cloud integration.
From the Groups column on the Repo tab, you can view which groups of repos Flow can access. If any groups are missing, double-check your GitLab permissions.
Click the repo import page link to begin importing repos.
Learn more about managing integrations.