
## Set up Microsoft Azure Data Factory

URL: https://docs.atlan.com/apps/connectors/etl-tools/microsoft-azure-data-factory/how-tos/set-up-microsoft-azure-data-factory

> Atlan supports service principal authentication for fetching metadata from Microsoft Azure Data Factory. This method requires a client ID, client secret, and tenant ID to fetch metadata.

Atlan supports service principal authentication for fetching metadata from Microsoft Azure Data Factory. This method requires a client ID, client secret, and tenant ID to fetch metadata.

## Register app with Microsoft Entra ID

:::warning Who can do this?
 To complete these steps, you need your _[Cloud Application Administrator](https://learn.microsoft.com/en-us/entra/identity/role-based-access-control/permissions-reference#cloud-application-administrator)_ or _[Application Administrator](https://learn.microsoft.com/en-us/entra/identity/role-based-access-control/permissions-reference#application-administrator)_ - you may not have access yourself. This is required if the creation of registered applications isn't enabled for the entire organization.

:::

To complete this, you need to [register your service principal application](https://learn.microsoft.com/en-us/azure/healthcare-apis/register-application) with Microsoft Entra ID and note down the values of the tenant ID, client ID, and client secret.

To register your app with Microsoft Entra ID:

1. Log in to the [Azure portal](https://portal.azure.com/).
2. In the search bar, search for **Microsoft Entra ID**, and select it from the dropdown list.
3. From the left menu of the _Microsoft Entra ID_ page, click **App registrations**.
4. From the toolbar on the _App registrations_ page, click **\+ New registration**.
5. On the _Register an application_ page, for _Name_, enter a name for your service principal application and then click **Register**.
6. On the homepage of your newly created application, from the _Overview_ screen, copy the values for the following fields and store them in a secure location:
 - **Application (client) ID**
 - **Directory (tenant) ID**
7. From the left menu of your newly created application page, click **Certificates & secrets**.
8. On the _Certificates & secrets_ page, under _Client secrets_, click **\+ New client secret**.
9. In the _Add a client secret_ screen, enter the following details:
 1. For _Description_, enter a description for your client secret.
 2. For _Expiry_, select when the client secret expires.
 3. Click **Add**.
10. On the _Certificates & secrets_ page, under _Client secrets_, for the newly created client secret, click the clipboard icon to copy the _Value_ and store it in a secure location.

## Set permissions

:::warning Who can do this?
 To complete these steps, you need your Microsoft Azure Data Factory administrator - you may not have access yourself.

:::

To proceed, add the service principal to the [Reader role](https://learn.microsoft.com/en-us/azure/data-factory/concepts-roles-permissions#custom-scenarios-and-custom-roles). This lets the service principal have read-only access to your Microsoft Azure Data Factory account.

To add the service principal to the _Reader_ role:

1. Log in to the [Azure portal](https://portal.azure.com).
2. Open the menu and search for or select **Data factories**.
3. On the _Data factories_ page, select the data factory you want to crawl in Atlan.
4. From the left menu of your data factory page, click **Access control (IAM)**.
5. From the tabs along the top of the _Access control (IAM)_ page, click **Add** and then click **Add role assignment**.
6. On the _Add role assignment_ page, configure the following:
 1. In the _Roles_ tab, from the list of roles under _Job function roles_, select **Reader** - this gives [read-only access to your data factory](https://learn.microsoft.com/en-us/azure/data-factory/concepts-roles-permissions#custom-scenarios-and-custom-roles) - and then click **Next**. Assign this role to all the data factories you want to crawl in Atlan.
 2. In the _Members_ tab, enter the following details:
 1. For _Assign access to_, click **User, group, or service principal**.
 2. For _Members_, click **+ Select members** and then select the service principal you created. Click **Next** to proceed to the next step.
 3. In the _Review + assign_ tab, click **Review + assign** to add role assignment.

Atlan extracts metadata from all the data factories you specified in your Microsoft Azure Data Factory account with _Reader_ access.

---
