Need to see if your shared folder is taking up space on your dropbox 👨💻? Find out how to check here.
Forum Discussion
george-silva
9 years agoNew member | Level 2
OAuth2 problems with Django and Django Db Backup
Hello all! I'm having a problem regarding the usage of the DropBox API. I'm using dropbox to backup a few of my databases, which it worked perfectly. I'm using Django, Django dbbackup and ...
Greg-DB
Dropbox Community Moderator
9 years agoRegarding the 413 error, can you share the HTTP request being sent? (Just be sure to redact the access token.) A 413 error should indicate that the request payload was too large, so we should first determine what you're sending.
Also, when you refer to your OAuth 2 "key", do you mean your OAuth 2 access token? The access token itself doesn't expire, so the app should store and re-use it. Exactly how the app does that is up to the app though, and since "Django dbbackup" is made by a third party, we can't offer support for Django dbbackup itself.
george-silva
9 years agoNew member | Level 2
Hey Greg,
The error is not that the payload is too large. Here's the title:
Error parsing response body or header
Analyzing your code for your python dropbox implementation, this error occurs if there is no error message returned in the payload. It's the last case of a large if condition, here: https://github.com/dropbox/dropbox-sdk-python/blob/master/dropbox/rest.py#L406-L408
How can I generate a new key for an Dropbox App?
Well, I've created a new app.
There are a bunch of sections, such as:
* Status
* Development Users
* app folder name
* etc
* OAuth2
In that section, (oauth2), there are the following options:
* redirect urls
* allow implicit grant
* generate key
This application, particularly does not comunicate with a lot of users, just one, me. So I've generated the key and used to communicate between my Django application and Dropbox. Each time I click it, it generates a new key. If I hit f5, it will not show that key again. If I hit generate key again, it will give me another key.
Since this worked before, I know this problem is not located in django-dbbackup.
I must be doing something wrong, because this looks like a generic "cant connect error".
What is the correct way to generate a key, for **my user** to be used with oauth2?
- Greg-DB9 years ago
Dropbox Community Moderator
Thanks for the additional information. Can you share the request itself though? That should help show what the issue is.
And yes, if you just need an access token for your own account on your own app, you can use that 'Generate' button to get one. The page will show it to you, and you should then copy it from the page, and then store and re-use it in your app. That page won't show it again if you refresh the page.
- george-silva9 years agoNew member | Level 2
Ok, regarding the token generation.
I'm already doing that.
The request itself is being made in two or three layers of opensource applications. I' ve searched these apps and there is no sign of registered bug in their side (it can be on their side, however).
I'll try to get the full request. I'll just edit my copy of dropbox lib and add a pdb there.
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!