Copy ShareFile folder to another ShareFile folder with Powershell

  • 1
  • Question
  • Updated 6 months ago
I can easily copy to/from a local folder to/from ShareFile, but I cannot find a way to copy one folder to another location within ShareFile using Powershell.  Is there a way to do this without having to sync to a local location?
Photo of Jon MacDonald

Jon MacDonald

  • 1 Post
  • 0 Reply Likes

Posted 6 months ago

  • 1
Photo of Andrew Finger

Andrew Finger

  • 11 Posts
  • 1 Reply Like
From https://api.sharefile.com/rest/docs/resource.aspx?name=Items

You can use a direct API call.  I do not know if PowerShell offers a method through the SDK, but at the very least you should be able to use a direct API call.



https://github.com/citrix/ShareFile-PowerShell/blob/master/ShareFileSnapIn/CopySfItem.cs

Looks like there might be some support?  I don't interact with ShareFile using PowerShell, so this may or may not be helpful.
(Edited)
Photo of Jeremiah Strong

Jeremiah Strong

  • 30 Posts
  • 2 Reply Likes
Hi Jon,

Extending off of Andrew's comments, you find this helpful if using the ShareFile Snap-in: https://github.com/citrix/ShareFile-PowerShell

See the code here: https://gist.github.com/jstrong013/bc5fd9e3f3e86738e81f73bfbc6fd25b

Cheers,