Your workflow is unique 👨💻 - tell us how you use Dropbox here.
Forum Discussion
MathanKumar
7 years agoExplorer | Level 4
getting access token via api in unity
Hi i want to get access token via api in unity with UnityWebRequest method.
"https://www.dropbox.com/1/oauth2/authorize?response_type=token&redirect_uri={1}&client_id={0}" how can i get access...
Greg-DB
Dropbox Community Moderator
7 years agoI recommend first reading the OAuth guide to see how the OAuth app authorization flow works:
https://www.dropbox.com/developers/reference/oauth-guide
The /oauth2/authorize address is a web page, not an API call. You should send the user there in their browser, where they'll be prompted to chooser whether or not to authorize your app.
When using /oauth2/authorize with the "token" flow (i.e., with `response_type=token`), the access token is returned to the redirect URI you specify (via the `redirect_uri` parameter value you supply) on the URL fragment. You should specify a redirect URI that is accessible to your app, so your app can then pull the access token from the URL fragment.
We don't have any resources, e.g., code samples, for Unity in particular, but you can find the full documentation for the OAuth app authorization flow here:
https://www.dropbox.com/developers/documentation/http/documentation#authorization
https://www.dropbox.com/developers/reference/oauth-guide
The /oauth2/authorize address is a web page, not an API call. You should send the user there in their browser, where they'll be prompted to chooser whether or not to authorize your app.
When using /oauth2/authorize with the "token" flow (i.e., with `response_type=token`), the access token is returned to the redirect URI you specify (via the `redirect_uri` parameter value you supply) on the URL fragment. You should specify a redirect URI that is accessible to your app, so your app can then pull the access token from the URL fragment.
We don't have any resources, e.g., code samples, for Unity in particular, but you can find the full documentation for the OAuth app authorization flow here:
https://www.dropbox.com/developers/documentation/http/documentation#authorization
MathanKumar
7 years agoExplorer | Level 4
without browser or web browser control it is possible to get access token ?
- Greg-DB7 years ago
Dropbox Community Moderator
No, the OAuth app authorization flow requires a browser. You can store and re-use the resulting access token after the fact though.- MathanKumar7 years agoExplorer | Level 4
ok thanks for your information.......
About Dropbox API Support and Feedback
Get help with the Dropbox API from fellow developers and experts.
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!