Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
I have the following function that upload files to Dropbox:
private async Task<string> Upload(DropboxClient dbx, string localPath, string remotePath) { const int ChunkSize = 4096 * 1024; using (var fileStream = File.Open(localPath, FileMode.Open)) { if (fileStream.Length <= ChunkSize) { await dbx.Files.UploadAsync(remotePath, body: fileStream); //set the expiry date var settings = new SharedLinkSettings(expires: DateTime.Today.AddDays(7)); SharedLinkMetadata sharedLinkMetadata = await dbx.Sharing.CreateSharedLinkWithSettingsAsync(remotePath, settings); return sharedLinkMetadata.Url; } else { await this.ChunkUpload(dbx, remotePath, fileStream, ChunkSize); } return "error"; } }
That works fine, but I need to upload many documents in one time and it takes long to loop through the documents and to upload them one by one, is there any option to upload a few documents at the same time?
Thanks in advance.
Thank you.
Hi there!
If you need more help you can view your support options (expected response time for a ticket is 24 hours), or contact us on X or Facebook.
For more info on available support options for your Dropbox plan, see this article.
If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!