When you work with large files in Power Automate you will find that there are some things that you need to consider when you copy large files.
In this post I’m looking at a few common issues. I’ve created a document library to which I upload a very large file.
My flow identifies that a file is being uploaded and on creation my flow starts. Note that my file is still uploading at this time.
Get file content file size limits
After a while I get the following error when I try to get the content
BadRequest. Http request failed as there is an error: ‘Cannot write more bytes to the buffer than the configured maximum buffer size: 104857600.’.
I then made my file slightly smaller.
Create file, file size limits
Once I uploaded a slightly smaller but still large file my get file content worked fine, but now when I tried to create anew file with the content I got a RequestEntityTooLarge.
In the details I was given a 413 error with the description of The request is larger than 94371840 bytes.
Copy large files
As I’m trying to copy a file with the get file content and create file actions I could also consider the copy file action.
The copy file action simply works. Why? the answer is quite simple. The API is struggling when we first collect all the content of the file and then send the content back through the two actions.
This means that the content of the file will twice travel between your flow and SharePoint. When a copy file is used only a file reference is sent.