Installing the Connector using the Cyclr API
This only applies to the OAuth 2.0 Authorization Code Authentication Type.
To install the Microsoft Dynamics CRM Connector with the Cyclr API as part of an automated process, you need to set the domain of the Dynamics CRM Online instance as follows before you get a sign-in token. Create an Account Connector Property named Resource, which holds the Instance URL value, and provide its value:
curl -X POST \
-H 'Authorization: Bearer {AccessToken}' \
-H 'X-Cyclr-Account: {AccountId}' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-d '{"Name": "Resource", "Value": "https://example.crm.dynamics.com"}' \
'https://{CyclrAPIDomain}/v1.0/account/connectors/{AccountConnectorId}/properties'
After creating this Account Connector Property, you can continue and have your customer authenticate the Connector as described in this article.
Authentication Errors
AADSTS500011
If you encounter the following error and are using Microsoft Entra ID-based authentication types:
AADSTS500011: The resource principal named {resource URL} was not found in the tenant named {tenant ID}. This can happen if the application has not been installed by the administrator of the tenant or consented to by any user in the tenant. You might have sent your authentication request to the wrong tenant.
Ensure you’re using the correct Instance URL when installing the Connector in Cyclr.
This is the URL of your customer’s Microsoft Dynamics account and should be similar to https://mycompany.crm11.dynamics.com. If unsure, go to your customer’s Microsoft Dynamics account through a web browser and copy it directly from the address bar.
AADSTS65001
If you encounter this error:
AADSTS65001: The user or administrator has not consented to use the application with ID '{app ID}' named '{app name}'. Send an interactive authorization request for this user and resource.:
Follow these steps:
- In your customer’s Microsoft Entra admin center, go to Enterprise applications > your app > Permissions
- Select the Grant admin consent for… button to allow the app to be installed into their directory.
- If the button is greyed out, the user you are logged in as doesn’t have the appropriate permission – you may require an administrator to do this.
Additional Filter Condition
Some Connector Methods provide the Additional Filter Condition field which you can use to filter results.
This must start with and, for example: and revenue gt 2000.
Operators in this field must be lowercase.
For more information, see Microsoft’s documentation on using OData to query.
Additional Fields
Some Connector Methods provide the Additional Fields parameter which you can use to return additional data in the response by providing the field name.
Multiple additional fields can be retrieved with a comma-separated list of field names.
For example, if you want to return the new_mycustomdata1 and new_mycustomdata2 fields, you would set the parameter as follows:
new_mycustomdata1,new_mycustomdata2
Audit Connector Methods
To be able to use the following “audit” Connector Methods, auditing must be enabled within Microsoft Dynamics CRM for the organization and for each table used:
- Accounts > List New Deleted Accounts
- Contacts > List New Deleted Contacts
- Leads > List New Deleted Leads
- Custom Objects > List New Deleted Custom Entity Record
- Static Marketing Lists > List New Deleted Static List Members
Find more information in Microsoft’s Power Platform auditing guide for Dynamics 365 online setups, and Microsoft’s Dynamics 365 Customer Engagement auditing guide for on-premises setups.
For on-premises, these sections describe the steps: