Configuring an ADF Linked Service Connection for Dynamics CRM
For information on how to enable a connection for use with linked services, see Configuring a Linked Service Connection.
Field labels in this walkthrough follow the underlying Azure Data Factory property names, with the connection column that carries each value named alongside. The exact labels shown in the BimlFlex Connection Editor may differ.
After selecting Dynamics CRM from the Linked Service Type dropdown, the form required for creating a Dynamics CRM Linked Service will appear.
Source Only Connector
A Dynamics CRM connection is used as a source. It is not available as a target.
Dynamics CRM and Dynamics 365 connections share the Dynamics CRM System Type, and the Linked Service Type selected in this form is what tells the two apart.
Choosing an Authentication Method
| Method | Credentials | Additional Settings |
|---|---|---|
| AAD Service Principal | Service Principal Id and Service Principal Key | None |
| Office365 | Username and Password | None |
Recommendation: Use AAD Service Principal and store the Service Principal Key in Azure Key Vault rather than entering it as plaintext.
Complete Example: AAD Service Principal with Azure Key Vault
| Field | Example Value |
|---|---|
| Connect via Integration Runtime | AutoResolveIntegrationRuntime |
| Deployment Type | Online |
| Service Uri | https://contoso.crm.dynamics.com |
| Authentication Method | AAD Service Principal |
| Service Principal Id | <client-id-of-app-registration> |
| Azure Key Vault Linked Service | bfx-kv |
| Secret Name (for Service Principal Key) | BFX-SRC-DynamicsCrmClientSecret |
Required Fields
Common Required Fields
Most required fields for a Dynamics CRM Linked Service connection depend on the Authentication Method used. There are some fields that are required regardless of Authentication Method.
These common required fields are:
Authentication Method Dependent Required Fields
The remaining field requirements are dependent on Authentication Method.
Required fields for AAD Service Principal:
- Service Principal Id
- Service Principal Key (or Azure Key Vault)
Required fields for Office365:
- Username
- Password (or Azure Key Vault)
Connect via Integration Runtime
Connect via Integration Runtime names the integration runtime for a Dynamics CRM Linked Service connection.
The default value is AutoResolveIntegrationRuntime.
To use another runtime, select it from the dropdown or choose + New to add one.
When a custom value is saved in the linked service form, it will be added to the custom integration runtimes.
The custom values that appear in this dropdown can be maintained in Settings under Azure - AzureIntegrationRuntime.
Deployment Type
The Deployment Type is stored in the connection's LS_DeploymentType column and maps to the ADF deploymentType property.
Set it to Online, the deployment type that the AAD Service Principal and Office365 methods apply to.
Service Uri
The Service Uri is the address of the Dynamics CRM instance, the same one used to open it in a browser (for example, https://contoso.crm.dynamics.com).
It is stored in the connection's LS_ServiceUri column and maps to the ADF serviceUri property.
Authentication Method
The Authentication Method is stored in the connection's LS_AuthenticationMethod column and maps to the ADF authenticationType property, written without spaces.
The Dynamics CRM Linked Service connection can use AAD Service Principal or Office365 authentication.
For AAD Service Principal, a Service Principal Id and Service Principal Key are required.
For Office365, a Username and Password are required.
AAD Service Principal
AAD Service Principal authentication signs in with a Microsoft Entra application, and BimlFlex writes the Authentication Type AADServicePrincipal.
The Service Principal Id supplies the client ID of the application and is stored in the connection's LS_ServicePrincipalId column. It maps to the ADF servicePrincipalId property.
The Service Principal Key supplies the application key as plaintext in the LS_ServicePrincipalKey column, or as an Azure Key Vault reference held in the LS_ServicePrincipalKeyKVS_ fields that resolves to the key at runtime. It maps to the ADF servicePrincipalCredential property.
When a Service Principal Key is supplied, BimlFlex writes the ADF servicePrincipalCredentialType property as ServicePrincipalKey.
It is suggested that Azure Key Vault be used in place of manually entering the Service Principal Key.
Office365
Office365 authentication signs in to the Dynamics CRM instance with a Username and Password.
The Username is stored in the connection's LS_Username column and maps to the ADF username property.
The Password field accepts the password as plaintext in the LS_Password column, or an Azure Key Vault reference held in the LS_PasswordKVS_ fields that resolves to the password at runtime. It maps to the ADF password property.
Office365 authentication cannot be used when the user is configured in Microsoft Entra ID for conditional access or multifactor authentication. Use AAD Service Principal in that case.
It is suggested that Azure Key Vault be used in place of manually entering the Password.
Azure Data Factory Linked Service Additional Information
For additional information on ADF Dynamics CRM Linked Service and its connection requirements see the Azure Data Factory Dynamics 365 (Microsoft Dataverse) or Dynamics CRM Connector documentation.