Posts

Showing posts with the label Power Automate

Secure Power Automate flow to run from only specific domain

I had a HTTP triggered Power Automate flow and wanted to make it run only when the request comes from specific domain only. There were couple of ways but below suited. Open the Power Automate flow and click settings of the trigger. Put below conditions to check if the origin is same as your target domain. @equals(triggerOutputs()['headers']?['origin'],'https://mycompany.sharepoint.com')  Additionally in the same way, I put couple of more checks like below. @equals(triggerOutputs()['headers']?['mySecretKey'],'theSecretKeyGoesHere') Also, I had to make a check if the requests are generating from a browser only. @or(contains(triggerOutputs()['headers']?['User-Agent'],'Chrome'),contains(triggerOutputs()['headers']?['User-Agent'],'Mozilla'),contains(triggerOutputs()['headers']?['User-Agent'],'Edge')) This helped to to secure the requests generation from a specific client o...

How to update preferred language (MUILanguages) in SharePoint Online using Power Automate

Image
This is pretty much something that I have not found in a direct way on internet so I thought I must write about it and make someone else's life easier someday. Scenario:  I have scenario where my customer has SharePoint Online portal with multilingual support and some custom developed web parts. During the development phase, the tenant was different and I was able to redirect user to MyAccount so he can change the preferred language,  but this setting was not available on customer's tenant. The reason was, we had Azure AD profiles while customer has synced them from local AD so this setting was not available. I recommend you to check out my this post about the language switch issue that I faced. Problem:   Since the manually preferred language change option was not available, we need to find another way where user can switch to any other language. In my case it was switch to Arabic from English. Solution Overview: Since the preferred way to make the language switch should...

How to merge two PDF files using Power Automate

Image
I often get a question that if we can merge some PDF files and make it one using Power Automate. The answer is, Yes that is possible and pretty easy now using Power Automate. Merging two PDF files using MS Flow is now pretty easy job. Specially it helps when there is an automated system and you have to automate the merging process. Lets go straight to the implementation now. Step 1: Get the first file content from the source. In my case, I am taking it from SharePoint online. Step 2: Get the second file content from the source. In my case, I am taking this too from SharePoint online. Step 3: Using Merge action to merge different file’s contents into a single pdf file. You can add multiple file contents for merging the pdfs. Provide a suitable name for the output file. Step4: Now, the merged file is in machine readable format. Saying that, its not a file right now, its just somewhere in the memory of cloud systems. We have to create file from merged file’s content into desired locatio...

Nintex Cloud vs Power Platform Comparison

Every technology comes with its own pros and cons and every business has its own justifications to adopt any specific tool. Microsoft build a huge market in cloud platforms specially by introducing Power Platform which includes PowerApps, Power Automate and Power BI. A combination of all three gives a boost to your business processes. On the other hand, Nintex is also successful in many ways to transform its customers from on-premise version of Nintex Forms and Nintex Workflows to Nintex Cloud. Although Nintex Cloud has some limitations as compared to on-premises versions, however it still provides some new features that keeps the customer stick with their tools. Here is a compact and brief comparison of both, focusing on the presentations and automations. 

How to get User ID by Email in MS Flow (Power Automate) SharePoint

Image
Its pretty straight forward when you know how to do. Going straight to the point. Create a new MS Flow and name it whatever you want. Create Get Items action. and fill the Site Adress, list name etc according to your environment. I am renaming my action to GetUserIDByEmail. Initialize a Variable and set its value to expression as mentioned below. Save and run the Flow. Here is the schema of the returned JSON. { "d" :{ "__metadata" :{ }, "Alerts" :{ }, "Groups" :{ }, "Id" : 280 , "IsHiddenInUI" : false , "LoginName" : "i:0#.f|membership|someone@example.com" , "Title" : "Someone Name" , "PrincipalType" : 1 , "Email" : "someone@exmaple.com" , "Expiration" : "" , "IsEmailAuthenticationGuestUser" : false , "IsShareByEmailGuestUser" : false , "IsSiteAdmin" : false ,...