1

I m trying to copy folder with REST api like this

/_api/SP.MoveCopyUtil.CopyFolder

POST data is

{
    "srcUrl": "https://test.sharepoint.com/_api/Shared Documents/CONS0006/PermWPS",
    "destUrl": "https://test.sharepoint.com/_api/Shared Documents/CONS0006/6"
}

In response it is showing

CopyFolder=(null)

And no folder copied

Any idea?

3
  • 2
    Your URL seems invalid. Try removing /_api from your URLs Commented Nov 25, 2016 at 10:20
  • also is your site collection at root level without managed path ? Commented Nov 25, 2016 at 10:28
  • @AtishDipongkor thanks a lot for pointing the exact issue, working fine now Commented Nov 25, 2016 at 10:44

1 Answer 1

1

_api should not be include in srcUrl or destUrl.

{
    "srcUrl": "https://test.sharepoint.com/Shared Documents/CONS0006/PermWPS",
    "destUrl": "https://test.sharepoint.com/Shared Documents/CONS0006/6"
}
1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.