# Adding a custom connector to DataBridgeAgent

> **DataBridgeAgent** is a standalone package that can be used to extract data from your source system for use in **Process Mining**. It contains the **UiPath® Process Mining** build and the on-premises connector used to prepare the dataset. Currently, the following on-premises connectors (`.mvp`) are included in **DataBridgeAgent**:
* **SAP Connector for Purchase-to-Pay Discovery Accelerator**;
* **SAP Connector for Order-to-Cash Discovery Accelerator**;

## Introduction

**DataBridgeAgent** is a standalone package that can be used to extract data from your source system for use in **Process Mining**. It contains the **UiPath® Process Mining** build and the on-premises connector used to prepare the dataset. Currently, the following on-premises connectors (`.mvp`) are included in **DataBridgeAgent**:
* **SAP Connector for Purchase-to-Pay Discovery Accelerator**;
* **SAP Connector for Order-to-Cash Discovery Accelerator**;

If you want to use your own custom connector, you can add it to **DataBridgeAgent**. In this case, you need to configure **DataBrigdeAgent** for use with your connector.

:::note
If you use **DataBridgeAgent 2022.4.1** to upload data for **TemplateOne-SingleFile**, make sure that the output table of the `.mvp` connector that is used is named `Event_log_raw`. If you use **DataBridgeAgent 2022.4.1** to upload data for **TemplateOne-MultiFiles**, make sure that the output tables of the `.mvp` connector that is used are named `Event_log_raw`, `Cases_raw`, (optional) `Tags_raw`, and (optional) `Due_dates_raw`.
:::

### Prerequisites

:::note
The information in the guide is only applicable for **DataBridgeAgent 22.4.1 or higher**.
:::

It is assumed that you have:

* a connector `.mvp` file. If the `.mvp` is dependent on files in the server data or on files in the workspace, these should also be added to **DataBridgeAgent**.
  + Server data files you should put in the `server data` directory.
  + Workspace data you should put next to the `.mvp`.
* a **Process Mining** on-premises (standalone) installation to:
  + determine the application code of module of the connector. See [Modules](https://docs.uipath.com/process-mining/standalone/2021.10/user-guide/modules). The application code must be specified in the `connectorModule` field in the `datarun.json` file. See **Step 4** in the table below.
  + verify that the connector is set up correctly, i.e. the correct tables are set to be an output table.

## Adding the Connector

Follow these steps to add a custom **.mvp** connector to **DataBridgeAgent**.

1. Go to the `workspaces/Connector` directory.
2. Create a new directory for the new connector.
   :::note
   The name you give this directory will be the value you have to fill in for **connectorWorkspace**.
   :::
See the illustration below.

   ![docs image](https://dev-assets.cms.uipath.com/assets/images/process-mining/process-mining-docs-image-14961-662c9d88-555bb89b.webp)
3. Copy the `.mvp` connector file in the new directory.
4. Edit the `datarun.json`, and fill in the **connectorWorkspace** and the **connectorModule** that correspond to the `mvp` connector. See the illustration below.

   ![docs image](https://dev-assets.cms.uipath.com/assets/images/process-mining/process-mining-docs-image-14687-d8a4c11c-ab359873.webp)
5. If not done, and if the recommendation above is followed, complete the rest of the `datarun.json` file with the extraction settings.
