cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
Want to learn some quick and useful tips to make your day easier? Check out how Calvin uses Replay to get feedback from other teams at Dropbox here.

Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Create a folder with special characters will get empty response

Create a folder with special characters will get empty response

wen_hsiao
Explorer | Level 4
Go to solution

I tried the following operation and got empty response.

I can't distinguish between "Invalid name" or "Server temporary error"

Is it possible to return detailed message which can indicate invlid file name ?

 

curl -v -X POST https://api.dropboxapi.com/2/files/create_folder_v2 --header "Authorization: Bearer accesstoken" --header "Content-Type: application/json" --data "{\"path\": \"/�}�֌W\",\"autorename\": false}"
Note: Unnecessary use of -X or --request, POST is already inferred.
* TLSv1.3 (OUT), TLS handshake, Client hello (1):
* TLSv1.3 (IN), TLS handshake, Server hello (2):
* TLSv1.2 (IN), TLS handshake, Certificate (11):
* TLSv1.2 (IN), TLS handshake, Server key exchange (12):
* TLSv1.2 (IN), TLS handshake, Server finished (14):
* TLSv1.2 (OUT), TLS handshake, Client key exchange (16):
* TLSv1.2 (OUT), TLS change cipher, Change cipher spec (1):
* TLSv1.2 (OUT), TLS handshake, Finished (20):
* TLSv1.2 (IN), TLS handshake, Finished (20):
> POST /2/files/create_folder_v2 HTTP/2
> Host: api.dropboxapi.com
> User-Agent: curl/7.61.1
> Accept: */*
> Authorization: Bearer accesstoken
> Content-Type: application/json
> Content-Length: 43
>
< HTTP/2 500
< content-security-policy: sandbox allow-forms allow-scripts
< content-type: text/plain; charset=utf-8
< date: Fri, 30 Oct 2020 10:52:43 GMT
< server: envoy
< x-dropbox-request-id: af9ee9f90e494139a89ba5c9eef11ce1
< content-length: 0
<

1 Accepted Solution

Accepted Solutions

Greg-DB
Dropbox Staff
Go to solution

Thanks for following up. I wasn't sure if that was the actual payload the app was sending, or if it got mangled when posting to the forum. I'll work on reproducing this with that and ask the team to fix the error handling.

 

I can't promise if/when they might be able to work on that though, so I recommend also updating your app's code to be able to handle server errors like this.

View solution in original post

3 Replies 3

Greg-DB
Dropbox Staff
Go to solution

A 500 error like this indicates something failed on the Dropbox API servers when processing the request. Unfortunately there isn't a way to retrieve more information about the failure via the API, but we can look into it for you.

 

To help us do so, can you share more information about how to reproduce this? It appears to be due to the path value you'e supplying, but that value appears malformed in your post here. Can you share exactly what data you're sending that results in this error?

wen_hsiao
Explorer | Level 4
Go to solution

The folder with malformated name is exists in one of our customer's NAS device, then our applicatoin on NAS tried to create that folder on his Dropbox but got 500 Internal Server Error.


Unfortunately, I can't tell why he created that name, but you can reproduce the error with the command as I posted previously.

 

I think 500 Internal Server Error can be retried and recovered normal later, but in this case it's not so our application kept loop retrying

 

If it can return any error other than 500, that will help. Thank you.

Greg-DB
Dropbox Staff
Go to solution

Thanks for following up. I wasn't sure if that was the actual payload the app was sending, or if it got mangled when posting to the forum. I'll work on reproducing this with that and ask the team to fix the error handling.

 

I can't promise if/when they might be able to work on that though, so I recommend also updating your app's code to be able to handle server errors like this.

Need more support?
Who's talking

Top contributors to this post

  • User avatar
    Greg-DB Dropbox Staff
  • User avatar
    wen_hsiao Explorer | Level 4
What do Dropbox user levels mean?