dropbox / dropbox/SwiftyDropbox

How to programmatically upload a file to a Dropbox File Request link from iOS (SwiftUI)?

Open
#446 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Swift
Stars
721
Forks
218
PR merge metrics
No merged PRs in 30d

Description

### Summary

I am building an iOS app using SwiftUI, and I have local file URLs (`[URL]`) generated within the app. I would like to programmatically upload these files to a Dropbox **File Request** URL (e.g. `https://www.dropbox.com/request/XYZ...`).

### What I Tried

- I attempted using `WKWebView` to load the file request link and inject JavaScript to pre-fill or simulate file input selection — but this does not work due to iOS sandboxing and gesture restrictions.
- The `files.upload(path:..., input:...)` API from the Dropbox SDK doesn't work, since File Request URLs are not API-accessible paths.
- I couldn't find any Dropbox API documentation that allows programmatically sending files to a File Request endpoint.

### Question

➡️ Is it possible to upload a file **from an iOS app** (Swift or SwiftUI) to a **Dropbox File Request URL** programmatically?
➡️ If not, is there a recommended workaround to help users complete this flow smoothly?

Thanks in advance for any clarification or guidance!

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.