cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
If you’ve changed your email address, now's the perfect time to update it on your Dropbox account and we’re here to help! Learn more 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: 

Re: Call get_preview http method returning 404 error

Call get_preview http method returning 404 error

Hananel C.
New member | Level 2

I had created the file 'word.docs' under the root folder.

Request the api v2 method get_preview with the path for this file return 400 error.

request details :

headers :

          "Dropbox-API-Arg"  : {"path": "/word.docs"}

          "Authorization" : "Bearer my_securiy_token"

           "Content-Type" : "application/json"

endpoint : "https://content.dropboxapi.com/2/files/get_preview"

method : "POST"

 

response : system.HttpResponse[Status=Bad Request, StatusCode=400]

5 Replies 5

Greg-DB
Dropbox Staff

[Cross-linking for reference: https://stackoverflow.com/questions/39016383/call-get-preview-http-method-returning-404-error ]

What's the response body? It should contain a more useful error.

Hananel C.
New member | Level 2

Only : 'bad data'
Can you give me example for a working request of this type?

Greg-DB
Dropbox Staff

Are you sure that's the actual/entire response body? That doesn't look like an error from the Dropbox API.

Anyway, the documentation includes a curl example:

https://www.dropbox.com/developers/documentation/http/documentation#files-get_preview

Hananel C.
New member | Level 2

Yes, thats all.
Sorry i mistakes the error code is 400 which means bad argument value.

Stephen C.14
Dropbox Staff

@Hananel C.: Could you post the code that you used to make this request?

Need more support?