# GitLab plugin

GitLab plugin
=============

The GitLab plugin provides integration with the [GitLab REST API](https://gitlab.com/) to create, manage, and manipulate Git repositories. This plugin also adds support for GitLab CI/CD:

*   Continuous Integration (CI)
    
*   Continuous Delivery (CD)
    
*   Continuous Deployment (CD)
    
*   Trigger GitLab Pipeline
    
*   [Webhook event processing support](#_gitlab_webhook_support)
    

While the [Git plugin](/docs/cloudbees-cd-plugin-docs/latest/ec-git/) provides the core functionality for managing Git repositories and associated data, the GitLab plugin provides the following, additional functionality:

  

Supported features

Git plugin

GitLab plugin

[Clone](/docs/cloudbees-cd-plugin-docs/latest/ec-git/create-procedures#_clone)

[Commit](/docs/cloudbees-cd-plugin-docs/latest/ec-git/create-procedures#_commit)

[Delete branch](/docs/cloudbees-cd-plugin-docs/latest/ec-git/create-procedures#_deletebranch)

[Configure polling triggers](/docs/cloudbees-cd/latest/triggers/polling-triggers)

[Pull](/docs/cloudbees-cd-plugin-docs/latest/ec-git/create-procedures#_pull)

Reporting data: [Build](/docs/cloudbees-cd-plugin-docs/latest/gitlab/collect-reporting-data#_build)

Reporting data: [Code commit](/docs/cloudbees-cd-plugin-docs/latest/ec-git/collect-reporting-data)

Reporting data: [Deployment](/docs/cloudbees-cd-plugin-docs/latest/gitlab/collect-reporting-data#_deployment)

Reporting data: [Feature](/docs/cloudbees-cd-plugin-docs/latest/gitlab/collect-reporting-data#_feature)

Reporting data: [Incident](/docs/cloudbees-cd-plugin-docs/latest/gitlab/collect-reporting-data#_incident)

[Trigger GitLab Pipeline](/docs/cloudbees-cd-plugin-docs/latest/gitlab/create-procedures#_trigger_gitlab_pipeline)

Webhook triggers

[](#_prerequisites)Prerequisites
--------------------------------

Because of the Java versions supported by CloudBees CD/RO, you can only use GitLab v1.1.0 and later with CloudBees CD/RO agents v10.11 and later.

[](#_gitlab_rest_api_support)GitLab REST API support
----------------------------------------------------

The GitLab plugin has been tested with the [GitLab REST API v4](https://gitlab.com/).

[](#_gitlab_webhook_support)GitLab webhook support
--------------------------------------------------

The GitLab plugin provides the ability to automate the launch of the CloudBees CD/RO runtimes for:

*   Confidential issue events
    
*   Issue events
    
*   Merge request events
    
*   Pipeline events
    
*   Push events
    

For more information, refer to [Configure webhook triggers](/docs/cloudbees-cd/latest/triggers/webhook-triggers).

### [](#_supported_runtime_values_according_to_the_event_type)Supported runtime values according to the event type

When the procedure or pipeline is started by a webhook event, additional properties are available under the `/myWebhook` property sheet. These properties are parsed from the event payload, which itself is saved under `/my(Job|PipelineRuntime|etc.)/webhookData`. The list of parsed properties depends on the event type. In some cases, the event payload may not contain the data for a property, and it is missing.

The branch names in the **Include Branches** and **Exclude Branches** parameters are patterns; the value `main` corresponds to any branch that contains `main` (for example, `test-main-data`). To specify the exact branch, you must use line start and line end symbols (for example, `^main$`).

Table 1. Supported runtime values according to the event type      

Runtime property

Confidential issue event

Issue event

Merge request event

Pipeline event

Push event

branch

commitAuthorEmail

commitAuthorName

commitId

commitMessage

eventType

repository

webhookData/action

webhookData/branch

webhookData/description

webhookData/name

webhookData/number

webhookData/ref

webhookData/stage

webhookData/state

webhookData/status

webhookData/title

webhookData/url