Need to see if your shared folder is taking up space on your dropbox 👨‍💻? Find out how to check here.

Forum Discussion

vished's avatar
vished
Explorer | Level 3
7 years ago
Solved

Redirect without "Enter this code into" -> redirect not working (JAVA SDK)

Hi all, 

I have a problem to integrate Dorpbox in my app.
I have entered in the GUI a redirect URL: 

http://localhost:8080/portal/cloudHoster.jsf

I´m generating the url which I´m using to redirect to Dropbox to login / approve:

	public String generateAuthorizeUrl() {

		// Read app info file (contains app key and app secret)
		DbxAppInfo appInfo;
		appInfo = new DbxAppInfo(APP_KEY, APP_SECRET);

		// Run through Dropbox API authorization process
		DbxRequestConfig requestConfig = new DbxRequestConfig("foo");
		DbxWebAuth webAuth = new DbxWebAuth(requestConfig, appInfo);
		
		
		DbxWebAuth.Request webAuthRequest = DbxWebAuth.newRequestBuilder().build();
		
		String authorizeUrl = webAuth.authorize(webAuthRequest);

		return authorizeUrl;
	}

After I approve it, I get again another screen:
Enter this code into MyApp to finish the process.

How can I avoid this? I would like to redirect directly again to my page?

Thank you for your help

 

5 Replies

Replies have been turned off for this discussion

About Dropbox API Support & Feedback

Node avatar for 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!