---
sourceDocument: Brazil Workflow Data Fabric
sourceDocumentLink: https://www.servicenow.com/docs/r/integrate-applications

 Release :

    - brazil

ft:locale :

    - en-US

ft:publication_title :

    - Brazil Workflow Data Fabric

ft:clusterId :

    - crint

bundleId :

    - crint

workflow :

    - Creator


---

# Set up bi-directional webhook for the GitLab spoke

# Set up bi-directional webhook for the GitLab spoke {#ariaid-title1}

Release version: Brazil  
Updated March 12, 2026  
![](https://www.servicenow.com/docs/portal-asset/ico-clock) 2 minutes to read  
Configure a webhook to subscribe to GitLab with a ServiceNow callback
URL.

## Before you begin

* Request Integration Hub subscription
* Activate the GitLab spoke
* Role required: admin
{#setup-webhook-gitlab__ul_p5t_3zr_h5b}

## Register GitLab webhook in ServiceNow instance {#ariaid-title2}

Register GitLab in ServiceNow to notify the ServiceNow app when certain events occur
in GitLab.

### Before you begin

Role required: admin

### Procedure

1. Navigate to AllGitLab WebhooksGitLab Webhook Registries.
2. To retrieve the existing webhooks GitLab account, click Get All Webhooks.
3. To create a webhook, click New.
4. On the form, fill in the fields:  
   {#register-webhook-gitlab__table_br3_14h_bvb__entry__2}

   | Fields | Description |
   |-|-|
   | Name | Name of the webhook. For example, <kbd class="ph userinput">Job webhook</kbd>. |
   | Description | Description of the record. |
   | Project ID | Unique identifier of the project for which the webhook should be created. |
   | Trigger and SSL | Events in the projects you want to subscribe to. When one of these events occurs, the webhook is triggered. |
   [ ]

   {#register-webhook-gitlab__table_br3_14h_bvb}
5. Click the Generate Secret Token related link.  
   The secret token is generated and displayed. Also, the date on which the secret expires is populated in Secret Expires.  
   Note:  
   The secret is regenerated and updated every 30 days. This secret is also updated in GitLab.
6. Right-click the form header and click Save.
7. Click Create Webhook.  
   The webhook is created in GitLab and its ID is populated in Webhook ID.

### What to do next

To update details of the webhooks or change the subscribed events, click Update Webhook.

## Customize a bi-directional webhook in the GitLab spoke {#ariaid-title3}

Create webhook routing policy and subflow as per your requirement in the GitLab
spoke.

### Before you begin

Role required: admin

### About this task

The default routing policy in the GitLab WebHook Routing Policies modules triggers
the relevant GitLab subflow and notifies the ServiceNow app when certain events
occur in GitLab. To use any other fields in your custom subflow and customize
conditions in the routing policy, perform these steps.

### Procedure

1. Navigate to AllFlow DesignerDesigner.
2. Click Subflows.
3. Create a copy of the required subflow.
4. Customize the required subflow as per your requirement and publish it.  
   See [Building subflows](https://www.servicenow.com/docs/access?context=subflows&version=brazil&pubname=brazil-build-workflows&ft:locale=en-US) for more information about creating and using subflows and [GitLab spoke](https://www.servicenow.com/docs/xIIq99dvFTdNuansMhQYFA "Manage the DevOps lifecycle in GitLab from your ServiceNow instance. Create flows in ServiceNow to manage branches, groups, issues, merge requests, projects, and source code in GitLab.") for information about the GitLab fields that the default routing policy supports and the GitLab events that the subflows support.
5. Navigate to AllGitLab WebhooksGitLab Webhook Routing Policies.  
   Five routing policies are available along with the spoke. You can configure them as per your requirement or create a routing policy.
6. To create a routing policy, click New.
7. On the form, fill in the fields.  
   {#customize-webhook-gitlab__table_iqz_j5s_h5b__entry__2}

   | Field | Description |
   |-|-|
   | Label | Unique label to identify the routing policy. |
   | Default answer | Option to specify if this is the default answer. Default answer is applicable when the conditions are not met. 1. Click the Lookup icon. 2. Select the required subflow from the Document: list. Note: Ensure that the Table name is <kbd class="ph userinput">Flow [sys_hub_flow]</kbd>. |
   | Condition | Conditions to be met when the required events occur in GitLab. |
   | Answer | Subflow that has to be triggered when the specified conditions are met. |
   [ ]

   {#customize-webhook-gitlab__table_iqz_j5s_h5b}
8. Click Submit.  
   Note:  
   These routing policies are saved in the Decision tables. Users are cautioned against directly updating or modifying data in these tables.

### Result

Routing policy and subflow are created.

*[\>]: and then


