Automation Action: Dynamics - Entity
This action is intended for use with an on premises version of Dynamics 365.
Within the Dynamics Entity action you have the ability to perform the following operations on all entities within the platform:
The action is dependent on an entity schema being provided. This schema lets the action know all the information about the entity you wish to perform operations on. Without a schema, the action will not be able to correctly send requests to your Dynamics environment.
The action handles schema downloads when configuring the settings. In order to download a schema, provide the relevant connection information and change the "Schema Options" field to "Download Schema". The action will they make a request to your Dynamics environment and store the schema in a local directory. Changing the "Schema Options" field to "Update Schema" will make a request and update the schema file.
Providing a file manually
If a schema file needs to be provided manually, this can be done by adding the schema in the following directory C:\ProgramData\Parker Software\ThinkAutomation.NET\DynamicsOnPrem ensuring the file name is dynamics_schema.xml.
There are 5 required fields when connecting to your dynamics instance. These are as follows:
- Host: e.g. https://parkersoftware.com
- Username: the username used to login
- Password: the password used to login
- Instance: this is the name of your Dynamics installation. To find out what your instance is called within Dynamics, go to Settings > Customizations > Developer Resources. The instance name is then shown in the "Unique Name" field.
- APIVersion: this is the version of the API Dynamics is using e.g. 8.0. To find what version your instance is using within Dynamics, go to Settings > Customizations > Developer Resources. The API version will be shown in the "Service Root URL" field. Please provide the version as follows: 8.0 not v8.0.
Making a request
When making a request multiple fields are required. These are as follows:
- Request Type: the type of request you wish to make.
- Entity Type: the entity type you wish to perform the action on
- Entity Values: the values you wish to assign to the entity. If you are performing a type of "Get", this field will allow you to extract properties to specific variables. To do this, select the relevant property in the first column and select the variable in the second (NOTE: the action will automatically remove any % from your variable names - this is normal).
If a successful request is made the EntityID will be returned from the action. This value can then be used in subsequent requests. For "Get" requests, the raw JSON value returned from Dynamics will be returned, with any custom extractions taking place.
If an error occurs the response will be blank and any errors added to the log.