Hi all,
I need to upload a large file to Google Drive and I succeeded:
B4X:
Dim h_ul As HttpJob
h_ul.Initialize("",Me)
h_ul.PostFile("https://www.googleapis.com/upload/drive/v3/files",localPath,localFilename)
h_ul.GetRequest.SetHeader("Authorization", "Bearer " & mytoken)
Wait For (h_ul) JobDone(h_ul As HttpJob)
If h_ul.Success Then
.........
but the file received from GD is "Untitled".
How can I send the file with a name?
you'll need to look into postmultipart
you also need to know how google drive expects you to identify the files you're uploading (eg "name=...", "file=...")
how you described your problem in the first place was not helpful.
your implementation of postmultipart does not correspond to instructions readily available with a little googling
(including https://developers.google.com/drive/api/v3/manage-uploads).
my guess would be that's why it didn't work.
and it works great for small files, but not for files over 200 Mb and I don't know why (I'm inexperienced).
So I was looking for another solution.
I tried that proposal (postmultipart) but I am not able to configure the required parameters.
I will try another solution.
Thanks anyway