Microsoft Dynamics 365 CRM Setup Guide
Follow our setup guide to connect Microsoft Dynamics 365 CRM to Fivetran.
Prerequisites
To connect Microsoft Dynamics 365 CRM to Fivetran, you need:
- A Microsoft Dynamics 365 account
- A Microsoft Entra ID (formerly Azure Active Directory) tenant
Setup instructions
Find domain name
Log in to your Azure account.
Click your account on the top right-hand corner, and then select Switch directory.
On the Directory + subscription pane, choose the Microsoft Entra ID tenant that has a subscription to Dynamics 365.
Go to the Microsoft Entra ID section of the Azure portal dashboard.
In the left-hand navigation menu, select Overview.
In the Overview section, make a note of the primary domain name. You will need it to configure Fivetran.
Find resource URL
Log in to your Dynamics 365 CRM instance.
Click the settings icon, then select Advanced Settings.
In the Settings drop-down, select Customizations.
Select Developer Resources.
In the Developer Resources window, copy the Service Root URL. You will need it to configure Fivetran.
Select authentication method
You can choose one of the following authentication type to connect your Dynamics 365 account to Fivetran:
OAuth2: This is a user interactive method, using the auth code flow. If you select OAuth2, skip to the Finish Fivetran Configuration section.
Service Principal Beta: This is a non-interactive method, using the client credentials flow. If you select service principal, proceed to the next step.
Authenticate using Service Principal Beta
IMPORTANT: Perform this step only if you want to authenticate your account using service principal. Skip to the Finish Fivetran configuration section if you want to use OAuth2 to sync your data.
Expand for instructions
Register application
In your Azure portal dashboard, click Microsoft Entra ID.
Go to App registrations and click + New registration.
Enter a Name for the application.
In the Supported account types section, select Accounts in this organizational directory only and click Register.
NOTE: For more information, see Microsoft's documentation.
Make a note of the Application (client) ID. You will need it to configure Fivetran.
Add API permissions
Select the application you registered.
On the navigation menu, select API Permissions.
Click Add a permission.
In the Request API permissions window, select Dynamics CRM .
In the Permission section, select the user_impersonation checkbox and click Add permissions.
Create client secret
Select the application you registered.
On the navigation menu, select Certificates & secrets.
Click + New client secret.
Enter a Description for your client secret.
In the Expires drop-down menu, select an expiry period for your client secret.
Click Add.
Make a note of the Value. You will need it to configure Fivetran.
Note: We recommend that you create a new client secret and update the credentials before the secret expires. Failing to do so may lead to sync failures.
Add registered app as application user
Log in to Power Platform admin center.
On the navigation menu, select Environments.
Select the environment for your Dynamics instance and click More Options menu > Settings.
In the Users + permissions section, click on Application users.
Click New App User > Add an app.
Search for the application that you registered.
NOTE: If you have duplicate application names, use the App ID you found.
Select the app and click Add.
In the Business unit drop-down menu, select the value corresponding to the Dynamics 365 instance. This might be based on your Dynamics instance's URL. For example, if your dynamics instance URL is
org3d56b123.crm.dynamics.com
, then your Business unit isorg3d56b123
.In Security roles field, click the Edit icon.
Select Service Reader, or any other predefined or custom role that has appropriate Read permissions and click Save.
Click Create.
Finish Fivetran configuration
In the connector setup form, enter your chosen Destination schema name.
Enter the primary domain name that you found.
Enter the resource URL that you found.
Select the auth type: OAuth2 or Service Principal.
If you choose OAuth2 as the authentication method, do the following:
i. Click Authorize to allow Fivetran to access your Dynamics 365 account using OAuth. You will be redirected to your Dynamics 365 account to authorize Fivetran's access.
IMPORTANT: We recommend logging in while in Incognito mode to ensure authorization of the correct account.
ii. Log in to your Dynamics 365 account. Once you have logged in, you will be redirected back to Fivetran.
If you choose Service Principal as the authentication method, do the following:
i. Enter the Client ID you found.
ii. In the Client Secret Value field, enter the value that you found.
Click Save & Test. Fivetran will take it from here and sync your Microsoft Dynamics 365 data.
Related articles
description Connector Overview
account_tree Schema Information
settings API Connector Configuration