Posts

Showing posts with the label Flow

Overcoming OpenAPI 2.0 `multi` CollectionFormat Challenges in Power Automate Custom Connectors

Image
Integrating APIs into Power Automate flows often requires creating custom connectors, a process that can encounter challenges with certain API specifications. Specifically, the OpenAPI 2.0 specification allows array and multi-value parameters to be passed in various formats, including the multi collection format. This format is particularly troublesome for Power Automate’s Custom Connector wizard, which does not support it natively. This article outlines the issue and provides a detailed workaround using custom code components and modifying input parameters, ensuring seamless API integration. The Challenge with multi CollectionFormat The OpenAPI 2.0 specification introduces several collection formats for array parameters, with multi being one of them. This format allows multiple values for the same parameter to be passed by repeating the parameter’s name in the query string, which is not directly supported in Power Automate Custom Connectors. Attempting to import an OpenAPI speci...

How to Create SharePoint Items with Power Automate Desktop

Image
Overview Power Automate Desktop is a great way to automate many of your daily task so you can focus on real work. A prime example of this is getting data from one place to another, especially when those data sources do not have an API such as a legacy desktop application or a file. In this example I demonstrate several ways in which an Excel sheet containing fictitious customer data could be loaded into a SharePoint list. In order to do this I first generated some fake data for my customers using Mockaroo . I then created a new SharePoint list and added some columns to match my spreadsheet. Methods My original plan was to just use the PAD recorder , which I did, but after creating that Flow I decided to find other possible ways to accomplish the task. The list below is not a complete list but should provide some ideas. The flexibility of PAD allows for an even wider range of possibilities for carrying out tasks such as these. At the end of each section I have placed the s...

Power Automate Desktop Example - Downloading Image From Email To Network Drive

Image
After watching the RPA (Robotic Process Automation) demo from Steve Winward Real-Life Use case using AI Builder Form Processing with Power Automate Desktop I have been looking for ways to utilize Power Automate Desktop Flows in order to make my life a little easier. Yesterday like every day I started clicking through the emails that I receive from my kids schools. I open each email, download the image, then move the image to a network drive on my computer. This takes me a few minutes every day but my kids are worth it :) This scenario was a perfect one for me to automate using Desktop Flows since they can access the network drive on my desktop. The basic flow of the solution will be as follows: A Power Automate Cloud Flow will be triggered to run whenever a new email comes into my Gmail account with a specific tag. The Cloud Flow will gather up all the information needed to run the Desktop Flow The Cloud Flow call the Desktop Flow by connecting through an On-Premise Data Gate...

Return Error in Power Automate When Using Try/Catch Scopes

Image
When utilizing scopes within Power Automate to create a try/catch/finally statement it can be useful to provide additional details about any errors that occurred within the try block. The example below shows how to get the results of a try block after it has failed and return that information. To replicate this do the following: Add a Control - Scope action called ‘Try’ Add another Control - Scope action below Try called ‘Catch’ Click the (…) on the Catch action and select the Configure after run settings . Then click the ‘has failed’ checkbox. Follow the screen shot below which will get the results array of the Try block then filter it down to the Failed result. You can then utilize the filtered result to return errors. The iamge belows shows the output after a completed run. We can now see the Action name which failed as well as the error message. In this scenario I am using that information to populate a JSON object which will be used later for returning information b...

Custom Flow Connector For Parsing Address

Image
While working on a demo of the Business Cards Scanner component for PowerApps I found that the component only returns the address as a single line and not as parsed address components ( UPDATE : The Business Card Scanner does not split the address fields into the same level of detail as the Contact/Account entities).  After looking around for flow connectors that could parse the data I only found one from Pitney Bowes.  Looking around there are a lot APIs available for address parsing but they are not currently available on Flow so I decided to build my first custom Flow connector to utilize one of these APIs. Address Labs ( http://www.addresslabs.com/ ) does not require an API key to use and since I'm only doing a few calls for my demos it worked well for me.  You can also check out their document on GitHub ( https://github.com/addresslabs/api-docs/blob/master/README.md ). One of the easiest ways to create a custom connector to flow is to use a Postman collection....

Get Dynamics/CDS Base URL in Flow To Generate Links To Record

Image
When sending emails or approvals in flow it can be helpful to also include a link to the record which is being referenced.  In order to send those links though we need the environment URL of the Dynamics/CDS environment.  This article shows an example of how to get the base URL for the environment and how to build a link based upon it.  This will be demonstrated within a Flow created for the App In A Day Workshop . In this Flow we are attempting to get an approval when a Device Order entity record is created from our Canvas App.  The Approval step allows us to include a link to the item and we will also be sending out emails to the requester based upon the Approval outcome which will include the link. The first Action we need to add to our existing workflow is the CDS Get record step.  Why do we need this step?  Well unfortunately the Output that is provided from the Flow Trigger of when a record is created does not include the URL to the record....