How does PCloud API uploadtransfer endpoint work?

32 views Asked by At

I've been trying to use PCloud API for a few days, until now everything was well documented but right now I am trying to transfer a file through their service: PCloud transfer (https://transfer.pcloud.com/ if you are curious). It is done using the "/uploadtransfer" endpoint but I can't figure out how it works.

Currently, I've only tried this request through Postman, I found out you have to use ppaccepted=yes so you don't have the 2303 error, but now I am trying everything and I get an 1101 error (Invalid request). As I want to upload files, I use a POST request with multipart/form-data as I did previously with the "/uploadfile" endpoint and found this that makes me think it is the right way but I couldn't make the script work. So here is basically what I tried in plain HTML :

POST /[email protected]&[email protected]&ppaccepted=yes HTTP/1.1 Host: eapi.pcloud.com Content-Length: 246 Content-Type: multipart/form-data; boundary=----WebKitFormBoundary7MA4YWxkTrZu0gW ------WebKitFormBoundary7MA4YWxkTrZu0gW Content-Disposition: form-data; name="file1"; filename="filename" Content-Type: (data) ------WebKitFormBoundary7MA4YWxkTrZu0gW--

I tried deleting some parameters, I get a 1074 error (Please provide valid 'sendermail') if I skip the sendermail, but still the same error for skipping any other parameter (1101).

0

There are 0 answers