We’re Still Here to Help (Even Over the Holidays!) - find out more here.
Forum Discussion
Maithili P.
10 years agoNew member | Level 1
upload File: update operation in mode field is not working
Hi,
I am working on developing an integration, would like to know the behaviour of upload file activity for mode field. Below are the steps
1. I have defined valid Path and upload a file
2. fil...
田畑浩平
10 years agoNew member | Level 1
Hi, Steve.
I also encountered exactly same problem.
I'm developing iOS app and switching from dropbox-ios-sdk to SwiftyDropbox(v1 -> v2).
And almost features works fine, but I can't resolve this problem with upload feature.
I check upload feature with SwiftyDropbox and curl command.
And when I try to upload some files with curl command, it won't work as I expected.
So I suspect upload api.
```
curl -X POST https://content.dropboxapi.com/2/files/upload \
--header "Authorization: Bearer ***********************************************************************************************” \
--header "Dropbox-API-Arg: {\"path\": \”/sample.jpg\",\"mode\": \”add\”,\”autorename\": true,\"mute\": false}" \
--header "Content-Type: application/octet-stream" \
--data-binary @sample.jpg
```
{"name": "sample.jpg", "path_lower": "/sample.jpg", "path_display": "/sample.jpg", "id": "id:********************", "client_modified": "2016-08-27T13:55:11Z", "server_modified": "2016-08-27T13:55:11Z", "rev": "135cc0934ed6f", "size": 527359}
I expect that file name which is included within response changes like below when I call api several times, but api returns above result when I call api several times.
Is my expectation is wrong?
sample.jpg
sample1.jpg
sample2.jpg
sample3.jpg
...
About Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
The Dropbox Community team is active from Monday to Friday. We try to respond to you as soon as we can, usually within 2 hours.
If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X, Facebook or Instagram.
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!