You might see that the Dropbox Community team have been busy working on some major updates to the Community itself! So, here is some info on what’s changed, what’s staying the same and what you can expect from the Dropbox Community overall.
Forum Discussion
TheSecurity
2 years agoNew member | Level 2
API Redirect URI allow multiple ports on localhost
Hello,
I am developing an application that uses the Dropbox API. I would like the application to choose a port that is currently open on the device and based on that create User Authorization link for user to authorize this application.
I have not found the way whether/how it can be achieved because Redirect URIs seem like only accept the full URI - exact match.
Thank you for your help
Hi TheSecurity,
You can register multiple URIs (actually only port can differs) and use whatever appropriate in every particular case. Usually trying 3 different sequential ports above 1000 is enough. It's pretty unlikely all be engaged at the same time. If such almost impossible situation happens (by any chance), just inform your user. Certainly the next try will be successful. 😉
Hope this helps.
- ЗдравкоLegendary | Level 20
Hi TheSecurity,
You can register multiple URIs (actually only port can differs) and use whatever appropriate in every particular case. Usually trying 3 different sequential ports above 1000 is enough. It's pretty unlikely all be engaged at the same time. If such almost impossible situation happens (by any chance), just inform your user. Certainly the next try will be successful. 😉
Hope this helps.
- TheSecurityNew member | Level 2
Hi there,
Thanks for your advice. At first I was a bit sceptical about this idea. But after some research I agree that the likelihood of all 3 ports being used is quite low.
- Greg-DBDropbox Staff
TheSecurity That's correct, Dropbox requires OAuth 2 redirect URIs to be registered exactly, including the port, but I'll pass this along as a feature request. I can't promise if or when that might be implemented though.
As Здравко noted though, you can instead register multiple redirect URIs to support multiple ports.
- TheSecurityNew member | Level 2
Hi there,
Thanks for the clarification. I would appreciate it if you could pass this on as a feature request.
About Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
5,882 PostsLatest Activity: 24 hours agoIf 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 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!