Save attachment from Outlook to Sharepoint and Check In

Copper Contributor

I have a Flow running that saves files from email attachments into a SharePoint Folder. I am trying to add a step to subsequently check that file in. I have added the "Check in File" step using the ItemId from the previous Create file step, but it fails as 'List not found
clientRequestId: 94a878ae-1d3e-49f0-8a6b-01e5a463019a
serviceRequestId: 94a878ae-1d3e-49f0-8a6b-01e5a463019a"


Any help with checking in files once extracted from Outlook would be great

5 Replies
I'd recommend verifying the library used in the "Check In File" step. Seems like there's a disconnect. Are these attachments large files?

@jefmeyer Hi, thanks for replying. The library is the same location copied from the "save file" step. The attachments aren't large, but there are a lot of them in the folder. I tried setting up the Check In step as a totally separate Flow, but it fails if there are any files in the folder that aren't checked out

Do you have any required metadata not being populated when the files are created? Have you tried to recreate the check-in step? I'd recommend keeping the check-in step in the same flow that creates the files. Do you need to have check out/in enabled on the library?
best response confirmed by vww01 (Copper Contributor)

I'm not entirely sure why you are getting List not found, but this is how I would go about copying email attachments to a SharePoint folder and checking them in (if currently checked out).


Note that for this example, my trigger only includes emails with a Subject "Files to copy" and only if they contain attachments, plus getting actual attachments. I assume you already have something like this.



Next is the main flow. Here I would loop over each of the attachments (could be one or more) and for each one:

  • Create the file in SharePoint
  • Get the file properties so we can check if it's checked out
  • Condition to check that it's checked out using the file properties
  • If it is checked out then check it in



@GrantJenkins you are a life saver, adding the get file properties and condition steps worked. Thanks for your help on this, and my other post :)