Regarding Microsoft Dynamics 365 automation

Greetings all.

I started this post to gather information and address issues with automating Microsoft Dynamics 365 web applications. I have not found a single post on the forum about Dynamics.

A summary about Dynamics (from Wikipedia):

Dynamics 365 is a product line of enterprise resource planning (ERP) and customer relationship management (CRM) applications. The Enterprise Edition comprises Dynamics CRM applications (field service, sales, project service automation, and customer service) plus Microsoft PowerApps, together with Microsoft’s premier ERP product, known as Dynamics 365 for Operations.

It is run via the browser, and utilizes Javascript and AJAX/jQuery greatly. As such, the web page is very dynamic which makes it hard to automate.

I am looking for support or ideas from this great community on how to proceed.

So far my ideas are these:

  • Automate the web page.

This is my current approach. I am facing issues because selectors are unstable due to them becoming invisible or appearing multiple times. After browsing a bit in Dynamics, UiPath Explorer shows up to 8 HTML and BODY tags, most of them having invisible duplicate content, which makes building a stable selector hard. If I inspect the page using Chrome’s developer tools, it only shows one HTML and BODY tag, so I assume that the Chrome UiPath plugin is parsing the HTML DOM and showing additional content added by Javascript, or the plugin might be buggy.

I am using Chrome because it makes the web-page more responsive than using Internet Explorer. I have tried setting WaitForReady to COMPLETE on my selectors, but that does not seem to make any difference. The only way to make it somewhat stable is to look for multiple selectors by working backwards from the highest Idx found.

  • Using REST API.

Dynamics has a REST API and uses OAuth which would be optimal to use instead of automating the web-page, but Microsoft recommends using an authentication library called ADAL, which UiPath does not support. More about it here:

ADAL is available for .Net in C#, Javascript, Node.Js, Java and Python. It would technically be possible to create a custom Activity using the .Net library, but I am not a full fledged C# developer, so I doubt I would be able to do it myself. Since the latest version of UiPath supports Python, another approach would be to use the Python ADAL library, which seems more feasible than creating custom Activities.

Does anyone have experience with Microsoft Dynamics and UiPath? Any input is appreciated.


Hi, have you seen the native Dynamics 365 activities we just released on Uipath GO

Dave Marcus
VP Strategic Alliances - UiPath