web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / SharePoint - Copy Fold...
Power Automate
Answered

SharePoint - Copy Folder BadRequest error

(0) ShareShare
ReportReport
Posted on by 8

Hi,

I am getting a !BadRequest error when trying to use SharePoint Copy Folder to copy series of template folders (inside same SharePoint site).  The source is "/Shared Documents/00 Current Event/Public Information Management" and the destination is "/Shared Documents/00 20211203 Flood - Whangaehu 01/Public Information Management".  I am doing a Create folder previously to create 00 20211203 Flood - Whangaehu 01 (which works) and then a  List Folder on /Shared Documents/00 Current Event to get the subfolders and then Apply to Each to try and Copy the folder structure.  Must be a syntax issue but I cannot figure out where.  The Flow and the error are listed below (same error for all 14 folders in 00 Current Events)

 

snow77245_1-1638562847618.png

 

 

Categories:
I have the same question (0)
  • iltoningui Profile Picture
    247 on at

    Hi @snow77245 

     

    I made a test and to copy a file you need to make sure the destination folder exists.

     

    Hope this helps

    Consider marking this post as resolved

     

     

  • snow77245 Profile Picture
    8 on at

    The folder I am copying it to 00 20211203 Flood - Whangaehu 01 exists.  Are you suggesting that I need to create Public Information Management in order to copy to it.  That seems more like Copy Files than Copy Folders?

  • Verified answer
    iltoningui Profile Picture
    247 on at

    Yes, I did a test and copying to a non exiting folder gave me an error.

     

    You can set the path manually just to test this for yourself

  • snow77245 Profile Picture
    8 on at

    Thanks for your help.  I added a Create Folder call before the Copy Folder call and it worked (mostly).  Fell over when the looping found a file in a folder and didn't know what to do.  I must be missing something though as all I want to do is copy 1 set of folders (and its contents) into another folder and it shouldn't be this hard.  I will keep trying

  • snow77245 Profile Picture
    8 on at

    Got it working - as long as there were no documents in the top level of the folder that was being copied.  Still seems odd though - most other languages you can just say "Copy folder A to folder B and you get /B/A" - no need to create the A folders first

  • iltoningui Profile Picture
    247 on at

    They must have set it up this way on purpose.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 112 Super User 2026 Season 1

#2
Haque Profile Picture

Haque 52

#3
Ellis Karim Profile Picture

Ellis Karim 51 Super User 2026 Season 1

Last 30 days Overall leaderboard