cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
RyanM
Frequent Visitor

Extract metadata from email and when saved to SharePoint

Can a Flow extract metadata from an email saved to a SharePoint library, and populate columns in the library with that metadata?

 

I’d like to create columns in a SharePoint library for standard email metadata - eg From, To, Received date etc. when I save an email to the SharePoint library, I’d like the metadata to populate in the SharePoint columns. 

 

Is is this possible with Flow?

2 ACCEPTED SOLUTIONS

Accepted Solutions
Community Support
Community Support

Re: Extract metadata from email and when saved to SharePoint

Hi @RyanM,

 

I am afraid that currently it might be not possible to trigger the flow by dragging emails from Inbox to Subfolders.

You may consider saving the emails to corresponding folders based on the subject. Let’s say that the subject of the email is the library or document set name, then you could configure the Folder path of Create file action likes below.

It will create new folder if there is no one available, or create files in existing folders without affecting others.

A screenshot for your reference:

 1.PNG

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

RyanM
Frequent Visitor

Re: Extract metadata from email and when saved to SharePoint

Thanks Mabel - I will give this a try.

 

Harry_G - thank you also for your advice.

View solution in original post

8 REPLIES 8
Harry_G Kudo Kingpin
Kudo Kingpin

Re: Extract metadata from email and when saved to SharePoint

yes you can do it very easily just create a list and make flow for this list follow pics

1- add Sharepoint List 

1.JPG

 

2- Create flow when new mail arrives 

2.JPG

3- Create Item From Email Data.

 

If you find this helpful please mark it as a solution.

 

Thanks.

 

Regards,

Harry_G

 

 

RyanM
Frequent Visitor

Re: Extract metadata from email and when saved to SharePoint

Hi Harry_G

 

Thank you so much for your response. In your example you have a created a dedicated list for email, so it’s good to know this can work.

 

My situation is a little different in that I have existing document libraries that contain a mix of email, Word, Excel, PDF files etc. I need the emails to stay in the same libraries as the other files for record keeping purposes. Email will be added to the libraries manually via drag/drop from Outlook (using Edge) or Save As from Outlook. 

 

Currently when email is added to these libraries, SharePoint attributes the standard ‘created’ and ‘modified’ dates, which aren’t meaningful for email. What I’d like to do is add as addItional columns to my document libraries for From, To, Sent, Received metadata and have a Flow that will populate them when an email is manually dragged or saved to the library. 

 

Is is this possible with Flow?

 

 

Harry_G Kudo Kingpin
Kudo Kingpin

Re: Extract metadata from email and when saved to SharePoint

@RyanM you can just add some custom columns in library and follow these below step

Capture.JPG

 

Currently i have only one column which is Named as Title, So if you have have multiple column like From, To, Sent etc etc. you can update the file properties using flow.

 

Thanks,

Harry_G

Community Support
Community Support

Re: Extract metadata from email and when saved to SharePoint

Hi @RyanM,

 

It seems that you would like to upload Email to the library manually by dragging from Outlook or Save As from Outlook.

I am afraid that once an email is saved to the library, it would be not able to get metadata such as From, To, Send, Received, etc.

I have figured out a workaround for your reference.

In my scenario, emails would be saved to the library automatically using flow. We can just trigger the flow based on specific properties, such as the subject. Only when the upcoming email matches the condition, move on to the following actions.

Then add the action Export email.

Create file in SharePoint library.

Finally, add the action Update file properties with dynamic content From, To, Received time from the trigger.

1.PNG

Please take the following docs for reference:

https://flow.microsoft.com/en-us/blog/outlook-connector-more/

https://docs.microsoft.com/en-us/flow/email-triggers

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
RyanM
Frequent Visitor

Re: Extract metadata from email and when saved to SharePoint

Hi @v-yamao-msft

 

Thank you for your taking the time to respond - really appreciate your advice.

 

With the workaround you have suggested, I probably couldn’t use triggers like subject or content as I’d have too many variables in my particular situation. Many of my libraries use document sets, so the destination would be hard to anticipate.

 

What might work instead is if I could create a 1:1 relationship between an Outlook sub folder and a document library or document set in SharePoint. So if I drag an email from my inbox to the sub folder, the Flow is triggered and moves the email to the related library or document set. If that is possible in theory, could I use a SharePoint Document ID to create the 1:1 relationship (eg paste the Document ID in the Outlook sub folder Properties field, assuming Flow can read this?)

 

Community Support
Community Support

Re: Extract metadata from email and when saved to SharePoint

Hi @RyanM,

 

I am afraid that currently it might be not possible to trigger the flow by dragging emails from Inbox to Subfolders.

You may consider saving the emails to corresponding folders based on the subject. Let’s say that the subject of the email is the library or document set name, then you could configure the Folder path of Create file action likes below.

It will create new folder if there is no one available, or create files in existing folders without affecting others.

A screenshot for your reference:

 1.PNG

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

RyanM
Frequent Visitor

Re: Extract metadata from email and when saved to SharePoint

Thanks Mabel - I will give this a try.

 

Harry_G - thank you also for your advice.

View solution in original post

Paul-SLIM
New Member

Re: Extract metadata from email and when saved to SharePoint

An alternative approach is to upload the emails to SharePoint using a tool that can extract the email metadata and populate the SharePoint columns. There are quite some add-ins for Outlook. There are also browser-based (e.g. SLIM Companion Explorer) or SharePoint add-ins with this capability. See e.g. https://directory.collab365.community/office365-sharepoint/sharepoint-email-management-software/
Paul | SLIM Applications

Helpful resources

Announcements
MBAS Gallery 2020

MBAS Gallery 2020

Watch Microsoft Business Applications Summit sessions on-demand.

firstImage

New Ranks and Rank Icons released on April 21!

The time has come: We are finally able to share more details on the brand-new ranks coming to the Power Automate Community!

firstImage

Now Live: Power Virtual Agents Community!

We are excited to announce the launch of Power Virtual Agents Community. Check it out now!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Community Summit North America

The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Users online (7,190)