Microsoft Flow, a component of the Office 365 suite, is a cloud-based tool that enables users to effortlessly automate workflows across various applications and services, without the need for technical assistance from developers. Built on top of the logic app engine, Microsoft Flow is designed for business users with a user-friendly interface. To create a flow, the user simply defines the action that should occur in response to a specific trigger event.
Steps to Create the Flow:
So, our target is to create a flow to create item in SharePoint Online list. And the flow will be triggered when an email will be received in a specific email account. The steps to create the Microsoft flow is given bellow:
- Go to the following link: https://flow.microsoft.com/
- Log in with your credential
- Click in the tab “My Flows”.
- Click in the tab from left side “Create from Blank”
- Now you will get the option to create different type of flow.
- As my target is to trigger the flow by getting an email, so I am selecting the option “When a new email arrives”.
- This will open a window which will get us options to set the settings for the email connector configuration.
- Provide the name of the flow in the position 1.
- Select the folder of your email box in the position 2, default it will be inbox. You can change it if you want.
- In position 3 is optional. You can provide an email address on that position or it will use the login user address as default.
- If you want to trigger the flow only from some specific email address than you need to provide those email address in the position 4.
- In the position 5, you can set a condition based on the importance flag of the email.
- There are several options for this condition you can give. But this condition is optional. So, you can ignore it.
- You can also ignore the 6th and 7th position option as this are optional.
- And in the 8th position, you can set a condition as if the subject line would have a specific string the flow will be triggered.
- After providing these input, the triggering condition will be set. Now, you need to create a new step by clicking the option “New Step” under current portion.
- By clicking this button, some option will be given for add an action, add new condition and more.
- But as we don’t need any further condition, we will select the “Add an action” from position 2.
- A list of action will be given. You can select any one from here.
- As my target is to create a new item in a list, so I select the “SharePoint – Create item” action.
- This will give you some option to configure your action.
- But to get the dynamic content list, you need to click inside any of the field of the list as like “Subject” in this scenario.
- Provide the site name in the portion 1.
- Select the targeted list name where you want to create the new item in the position 2 from drop-down.
- Now you will get the list’s columns from your list. As I got the field “Subject” and “Body” as my list column’s name.
- Now you can insert the dynamic content by putting them from the dynamic content helper as the position 5. Even you can provide static value in your fields.
- As per my business, I provided Email Subject in my Subject field in position 3 and select email body in the position 4, my list column body.
- Now you can add other condition or action if you want. But as my business is completed, I am clicking the option “Create Flow” from the top bar – left side.
- If there is no required field empty, the flow will be created and saved in my flow list.
- You can get your flow any time from your “My Flows” tab.
- You can edit it again or turn it off or else if you want from here.
- Now we can test it by sending an email to the selected email address. As I was selected my email box, I am checking with my email address.
- An email address in arrived in my email address with a previous email history.
- Now we have to wait 5 minute to get the flow work. As we know, Microsoft Flow run in 5-minute interval, the item will be created after 5 minutes.
- So, after 5 minutes, we found a new item has already created in my targeted list.
- Here we can see the list item with the same subject and email body with the email history in the list.
The same result can be achieved using Azure Logic app. But you have the subscription on azure for that. And there are more features in Microsoft flow that can be help for achieving other business.
I hope this article will help. This article has also been published on C# Corner. Be Safe. Happy Coding.