> For the complete documentation index, see [llms.txt](https://developer.harness.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.harness.io/ai-dlc-insights/3.0/use-ai-dlc-insights/setup/integrations/jenkins/index.md).

# Jenkins Plugin

The **Harness - SEI Jenkins Plugin** is a tool, written in Java, to send reports about builds to Harness SEI.

{% hint style="info" %}
The SEI Jenkins integration provides basic CI/CD insights, but it doesn’t support lead time tracking out-of-the-box. To enable this metric, you’ll need to send artifact details using the Custom CI/CD API.

For more information, see [DORA CI/CD Correlation](/software-engineering-insights/use-software-engineering-insights/analytics-and-reporting/efficiency/dora-metrics/dora-ci-cd-correlation.md).
{% endhint %}

### Setup <a href="#setup" id="setup"></a>

#### Step 1: Configure the integration in the Harness platform <a href="#step-1-configure-the-integration-in-the-harness-platform" id="step-1-configure-the-integration-in-the-harness-platform"></a>

1. Select **Integrations** under the **Data Settings**.
2. Select **Available Integrations**, and locate the **Jenkins integration**, and select **Install**.
3. Add a **Name** for the integration.
4. The **Description** and **Tags** are optional.
5. Click on **Next: Create and Add Nodes**. This will display all the available Jenkins instances.
6. Click on **+Add Instance**. This will generate the **SEI API KEY** which will be used in the **Jenkins Plugin Configuration**.

{% hint style="info" %}
Newly added instances will show up under the **Available Instances Tab**.
{% endhint %}

#### Step 2: Generate Jenkins User Credentials <a href="#step-2-generate-jenkins-user-credentials" id="step-2-generate-jenkins-user-credentials"></a>

The SEI plugin requires authentication via a Jenkins API token. Ensure the user account has one of the following roles:

* Admin
* Overall Read and Job Read

To generate the API token:

1. In the Jenkins banner frame, click your username to open the user menu.
2. Navigate to **Your Username** > **Configure** > **API Token**.
3. Click **Add new Token**.
4. Click **Generate**.
5. Copy the generated API token for use in the plugin configuration.

#### Step 3: Install the plugin <a href="#step-3-install-the-plugin" id="step-3-install-the-plugin"></a>

To install this plugin, follow the steps below.

1. Sign-in to **Jenkins** and select **Manage Jenkins**.
2. Select **Manage Plugins**.
3. Select the **Available plugins** tab.
4. In the **Search** plugin, type in **Harness - SEI Jenkins Plugin**.
5. Install the **Harness - SEI Job Reporter Plugin** and click on **Install without restart**.
6. Once the plugin installation is complete, the status will change to **Success**. If it doesn't change to Success, then a restart might be needed.
7. Set the **Instance Name** and use the **API KEY** you generated earlier as the value for the **Manage Jenkins >> Harness - SEI Job Reporter >> SEI API KEY** field.
8. Set the **Application Type** to the environment where you are configuring the **Plugin** (i.e. the environment where your Harness Account is hosted on).
9. Add the [Jenkins Username](#step-1-configure-the-integration-in-the-harness-platform) and [Jenkins User Token (Jenkins API Token)](#step-1-configure-the-integration-in-the-harness-platform).
10. Save the plugin settings.

{% hint style="info" %}
If you have enabled an allowlist in your Jenkins account, certain Harness IP addresses must be added to it in order to allow communication between the Harness Platform and Jenkins. If the necessary IPs are not whitelisted, the integration may fail to authenticate or sync data properly.

To ensure your integration can work correctly, refer to the list of [Harness Platform IPs](/harness-ai/use-harness-platform/references/allowlist-harness-domains-and-ips.md) that may need to be whitelisted in your firewall.
{% endhint %}
