cancel
Showing results for 
Search instead for 
Did you mean: 
yashag2255

Automation Squared using MS Flow and UiPath

Background on UiPath: If you are aware of what RPA and UiPath are please feel free to skip to the next section. In this section I will give you a small background of what RPA is and how we can build RPA solutions with UiPath. RPA is an acronym for Robotic Process Automation and RPA is the use of software integrated with out of the box capabilities such as machine learning, automated recorded action steps, artificial intelligence etc. to ease repeated tasks such as data entry, handling, scraping, transaction processing etc. The UiPath RPA platform provides us with the capability to build processes and automations that can be used to achieve RPA processes such as automating manual repetitive processes. More at UiPath RPA

In this article I will show you how we can create a simple automation process in UiPath and trigger that automation from MS Flow. We will run an action in Flow and based on the outputs of that, we will pass parameters to the UiPath process and trigger the robot through the UiPath Orchestrator API and achieve the desired automation. More on UiPath Orchestrator API : UiPath Orchestrator API Reference

Let us consider the time card logging task for this automation. ‘A’ is an employee of the ‘XYZ’ organisation. ‘A’ has to log their time card every day and the process is generally to log into the time card portal -> navigate to the timecard page -> select the task and fill up the effort for the task -> save and submit the time card. Considering this problem statement, I divided the automation task into two parts.

1. Performed by Flow: I created a flow where, ‘A’ will just have to select the Task code and the number of hours in the Flow trigger -> Flow will then authenticate to the UiPath orchestrator through an API call (HTTP POST request) -> Flow retrieves the authentication token and gets the process key through another API call (HTTP GET request) -> Flow now uses the authentication token, the process key and the user input to start a job that triggers a robot to run the automation process on the user machine (HTTP POST request).automationSquared2.png

2. Performed by the UiPath Robot: In the UiPath studio, I created a state machine process that has multiple states. Once triggered, the first state is to login to the time card portal using the credentials of ‘A’ (hardcoded in this process) -> once the login is successful, the robot extracts the task code sent as an input argument from flow and compare that with a pre-populated task code. Upon matching the task code, the robot now starts the process of navigating to the time card and selecting the requested task code and filling in the hours (sent as an input argument from the flow trigger). Once done, it saves and submits the form, clicks a screenshot and sends a confirmation email to ‘A’ along with the screenshot. In an event where the task code is not recognised, the robot terminates the process by directly sending an email to ‘A’ stating the invalid task code error reason.automationSquared.png

Although most of the hard work in this scenario was done by the UiPath RPA process, my intention through this post is to show a seamless integration between the two tools using the HTTP action that can automate about anything. This was a simple web recording type scenario but imagine situations where you have custom desktop applications that are accessed through VM’s under various environments. The UiPath studio provides with a capability of automating processes inside of VM’s under Citrix environments and once connected to the UiPath Orchestrator, these processes can be executed based on triggers, actions and plans that are configured in Flow.

I hope you found this interesting and it helped you. Thank you for reading!

Comments

Hey @Anonymous 

 

Here is the expression I used to get the result: 

body('Authenticate_UiPath_Orchestrator')['result']

This gets the authorisation token. 

 

Here, Authenticate_UiPath_Orchestrator is the name of the Send and HTTP request action. 

 

Hope this Helps!

Thank you @yashag2255 for sharing a valuable Article. and kindly read our blog you might be interested. How is Robotic Process Automation Transforming the Digital World

  • HI Thank you yashag, for your blog Automation Squared. please keep sharing updated articles. Here is our blog on How is Robotic Process Automation Transforming the Digital World you might be interested into this article, 
Meet Our Blog Authors
  • Experienced Consultant with a demonstrated history of working in the information technology and services industry. Skilled in Office 365, Azure, SharePoint Online, PowerShell, Nintex, K2, SharePoint Designer workflow automation, PowerApps, Microsoft Flow, PowerShell, Active Directory, Operating Systems, Networking, and JavaScript. Strong consulting professional with a Bachelor of Engineering (B.E.) focused in Information Technology from Mumbai University.
  • I am a Microsoft Business Applications MVP and a Senior Manager at EY. I am a technology enthusiast and problem solver. I work/speak/blog/Vlog on Microsoft technology, including Office 365, Power Apps, Power Automate, SharePoint, and Teams Etc. I am helping global clients on Power Platform adoption and empowering them with Power Platform possibilities, capabilities, and easiness. I am a leader of the Houston Power Platform User Group and Power Automate community superuser. I love traveling , exploring new places, and meeting people from different cultures.
  • Blog site: https://ganeshsanapblogs.wordpress.com/ MCT | SharePoint, Microsoft 365 and Power Platform Consultant | Contributor on SharePoint StackExchange, Techcommunity
  • Encodian Owner / Founder - Ex Microsoft Consulting Services - Architect / Developer - 20 years in SharePoint - PowerPlatform Fan
  • I am the Owner/Principal Architect at Don't Pa..Panic Consulting. I've been working in the information technology industry for over 30 years, and have played key roles in several enterprise SharePoint architectural design review, Intranet deployment, application development, and migration projects. I've been a Microsoft Most Valuable Professional (MVP) 12 consecutive years and am also a Microsoft Certified SharePoint Masters (MCSM) since 2013.
  • Big fan of Power Platform technologies and implemented many solutions.
  • Passionate #Programmer #SharePoint #SPFx #M365 #Power Platform| Microsoft MVP | SharePoint StackOverflow, Github, PnP contributor
  • Web site – https://kamdaryash.wordpress.com Youtube channel - https://www.youtube.com/channel/UCM149rFkLNgerSvgDVeYTZQ/