How to move email attachment to SharePoint document library with Microsoft flow

This video will demonstrate, how you can create a basic flow for moving the email attachments to SharePoint document Library. Microsoft flow, is the new service provided by Microsoft. Flow is basically a type of trigger That we can associate with the objects (SharePoint List/Library, Google Sheets, Twitter, Salesforce and many more). There are certain pre-defined templates that are ready to use. We can just configure that templates and they are ready to go, with less efforts and less development time. We can also write a flow from the blank, by using the existing flow actions that they provide. This flow, will move the attachment associated with the email (office 365) to the document library. Microsoft Flow also allows us to move the attachment to a specific folder in the document library, based on certain criteria. For Ex.: if the email comes with the specific tag like “Project Requirements” in the subject, we can move it to the “Requirement Document” Folder, else if the subject contains “Project Test Cases” we can move it to the “Test Cases” Folder. So, in this flow I will not move all the email attachments to the SharePoint document library, I will just move only those, which is having a specific tag in the subject. Below are the mail steps for creating the Microsoft Flow: 1. Logged in with your office 365 account on 2. Select the template “Save my email attachments to a SharePoint document library”. 3. In the next window, authenticate with office 365 outlook and SharePoint. 4. In the “On New Email” template, if we kept all the fields blank, then it will read all incoming emails, regardless of who sent it. If we need to apply filters like, if the email comes from this address only, then proceed further, we can do it with flow. For now, we will keep all the fields blank. 5. In the next step, as we also need to organize our email attachments in the proper folder structure in SharePoint. I will delete the auto populated create a file flow action and will add the condition there for validating the specific tag in the subject. 6. Add a condition (If the subject contains “Dynamics” then move all the email attachments to a library, else do nothing). 7. Add a “create a file” action of SharePoint to move the email attachments. a. Configure the Site URL, Folder Path (Library Name/Folder Name). b. File Name: It will be same as the attachment name, so we will take the data from the previous steps (Name object from the previous steps). c. File Content: It will be a content object from the previous step (On new email). 8. Add an action “Office 365 - Send an Email” for sending the notification to the project team, that new requirement document has been received from the client. 9. Now, just name your flow and published it. 10. Send an email with attachment to the account for which you have written the flow, with the “Dynamics” keyword in the subject. Please do watch the video, and subscribe us at @Paragyte YouTube Channel. Visit:

Video Owner : Paragyte

Post a Comment

0 Comments