Redirect_uri is not an absolute URI

I use the Scribe API for facebook sign functions, but I get the following error after sending facebook authentication URL.

callback_url = http://localhost:18080/example/pub/social/facebook/signup/step2 OAuthService service = new ServiceBuilder().provider(FacebookApi.class) .apiKey(apiKey).apiSecret(apiSecret) .scope("email") .callback(callbackUrl).build(); String authorizationUrl = service.getAuthorizationUrl(EMPTY_TOKEN); return "redirect:" + map.get("AUTHORIZATION_URL"); OAuthService service = new ServiceBuilder().provider(FacebookApi.class) .apiKey(apiKey).apiSecret(apiSecret).build(); Verifier verifierObj = new Verifier(verifier); //String s = getAccesstoken(verifier); Token accessToken = service.getAccessToken(EMPTY_TOKEN, verifierObj) 

I get below error @last line

The body of the answer is incorrect. Unable to extract token from this: '{"error": {"message": "redirect_uri is not an absolute URI. Check RFC 3986.", "Type": "OAuthException", "code": 191}}

Settings n facebook app:

 **Website with Facebook Login** : http://localhost:18080/example/ App domain : localhost 

Please let me know if I'm wrong somewhere ... New for the scribe and facebook platform.

Thanks Raj

+6
source share
2 answers

Make sure you specify https or http before redirect_uri . And make sure you refer to it as redirect_uri .

-1
source

callback_url is different from the site by logging in to facebook, change your website url by logging in to facebook with the same name as your callback_url.

Be careful with applications on the local host, always use one server for testing.

sorry for my bad english

-1
source

All Articles