开发者

Internal Server Error in Dropbox from Android

开发者 https://www.devze.com 2023-02-10 22:31 出处:网络
Tried on Dropbox forum but no luck: I\'m reaching Dropbox API from Android, i do a HttpPost request to \"https://api.dropbox.com/0/fileops/create_folder\" and i pass as para开发者_运维百科meters:

Tried on Dropbox forum but no luck:

I'm reaching Dropbox API from Android,

i do a HttpPost request to "https://api.dropbox.com/0/fileops/create_folder" and i pass as para开发者_运维百科meters:

List <NameValuePair> parameters = new ArrayList <NameValuePair>();
parameters.add(new BasicNameValuePair("path", "xxx"));
parameters.add(new BasicNameValuePair("root", "xxx"));
parameters.add(new BasicNameValuePair("oauth_consumer_key", "xxx"));
parameters.add(new BasicNameValuePair("oauth_token", "xxx"));
parameters.add(new BasicNameValuePair("oauth_secret", "xxx"));
parameters.add(new BasicNameValuePair("oauth_timestamp", "xxx"));
parameters.add(new BasicNameValuePair("oauth_nonce", "xxx"));

And well, the thing is i get an Internal Server Error although with the same code (different parameters, of course) i manage to authenticate. Any idea why?


To create folder please use this code

 private DropboxAPI api = new DropboxAPI();

Entry entry = api.createFolder("dropbox", "NameOfFolder");  

with dropbox-android-sdk-0.1

Hope it helps you.


I may have not understood quite well your problem but why do you need different parameter names? Often in this kind of requests you need the exact parameter name.

Hope it helps you.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号