Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
May I know what is the " auth_code" here. how can I get it?
authorize_url = auth_flow.start()
print("1. Go to: " + authorize_url)
print("2. Click \"Allow\" (you might have to log in first).")
print("3. Copy the authorization code.")
auth_code = input("Enter the authorization code here: ").strip()
try:
oauth_result = auth_flow.finish(auth_code)
except Exception as e:
print('Error: %s' % (e,))
exit(1)
When you run the script, a link is provided to you via the console, which you have to paste into a browser window. Once you go to the link, a code is provided. That code is the auth_code, which has to be pasted into the console to finish the authentication sequence.
That's correct, the "auth_code" variable there should contain the "authorization code", which is a single-use code from the app authorization page that the app then exchanges for an access token and optional refresh token, by calling /oauth2/token. I recommend reading the OAuth Guide and authorization documentation for more information.
Hi there!
If you need more help you can view your support options (expected response time for a ticket is 24 hours), or contact us on X or Facebook.
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!