Page 1 of 1

How to copy a file via API from web directory to a directory on the NAS

Posted: Sat Apr 25, 2020 2:25 am
by jasonw75

I'm trying to call the copy file API on my QNAP NAS to copy an image file from an online directory to a directory on the NAS.

Regarding the following GET URL, pointing to my NAS:
&source_total=1&source_path=<SOURCE thePATH>&dest_path=<DESTINATIONPATH>&mode=1

If I point to a local source (/ShrData/CustomerArtwork), file copy via API works:
&source_total=1&source_path=/ShrData/CustomerArtwork&dest_path=/ShrData/Digilase Transfer&mode=1

The file is copied successfully.

But if I point to a path in a web directory as the source:
( ... /p0/7w/b9/),

keeping the filename and source exactly the same, it fails:
&source_total=1&source_path= ... /p0/7w/b9/
&dest_path=/ShrData/Digilase Transfer&mode=1

Here's the web directory and file: ... 7wb9xk.jpg

Is there a different syntax when pointing to a web directory as the source path/file?

Thanks for any advice!