facebook redirect_uri not working for mobile -
i have facebook canvas app , i'm running both same code , same redirect_uri web , mobile, works without issue in web configuration mobile version doesn't. app responsive app, urls within facebook configuration identical.
the method i'm using both generate url
list<namevaluepair> qparams = new arraylist<>(); qparams.add(new basicnamevaluepair("client_id", facebookclientid)); qparams.add(new basicnamevaluepair("redirect_uri", "https://apps.facebook.com/customdomain")); qparams.add(new basicnamevaluepair("client_secret", facebookclientsecret)); qparams.add(new basicnamevaluepair("code", code)); uri = new uribuilder() .setscheme("https") .sethost("graph.facebook.com") .setpath("/oauth/access_token") .setparameters(qparams) .build(); website url https://local.mydomain.com:8443/test/facebook/auth mobile url https://local.mydomain.com:8443/test/facebook/auth
canvas url
https://local.mydomain.com:8443/test/facebook/auth/
auth urls
https://local.mydomain.com:8443/test/facebook/auth/ https://apps.facebook.com/customdomain
app domain
https://apps.facebook.com/customdomain
working url website
https://graph.facebook.com/oauth/access_token?client_id=578152068997908&redirect_uri=https%3a%2f%2fapps.facebook.com%2fmydomain&client_secret=xxxx&code=aqbq_vzlxkwqmfmc2neu8dillor0lrp1wvlvtsd5do3pymfo_jxiejcgebz-a0bejbe6ya9noh9esxm2mgmgw0zp9oqom-2h7vbykruix0o7iskwwykksfai-i2qpumtbcb0yxaqrn5y2aewk8gxmhevagsw3gglksntndhzr3nyds5mi4gtmsjmkjbo8dtzepdrh4isz_qv0fmgalkdhirmm7zsjodfpkytl4rlzg9q4on14qehpbumisnu8caqclvolyacd17nfqhyq-bovmx8ppunrfdohdk9kutuv7c8pbfvgobmwejjkxwdz0ncuu0
non working mobile
https://graph.facebook.com/oauth/access_token?client_id=578152068997908&redirect_uri=https%3a%2f%2fapps.facebook.com%2fmydomain&client_secret=xxxx&code=aqbq_vzlxkwqmfmc2neu8dillor0lrp1wvlvtsd5do3pymfo_jxiejcgebz-a0bejbe6ya9noh9esxm2mgmgw0zp9oqom-2h7vbykruix0o7iskwwykksfai-i2qpumtbcb0yxaqrn5y2aewk8gxmhevagsw3gglksntndhzr3nyds5mi4gtmsjmkjbo8dtzepdrh4isz_qv0fmgalkdhirmm7zsjodfpkytl4rlzg9q4on14qehpbumisnu8caqclvolyacd17nfqhyq-bovmx8ppunrfdohdk9kutuv7c8pbfvgobmwejjkxwdz0ncuu0
response
internalmodule.pageloader loaded page 'facebook/auth' (en) in 112.543 ms response httpresponseproxy{http/1.1 400 bad request [www-authenticate: oauth "facebook platform" "invalid_code" "error validating verification code. please make sure redirect_uri identical 1 used in oauth dialog request", facebook-api-version: v1.0, content-type: text/javascript; charset=utf-8, pragma: no-cache, access-control-allow-origin: *, x-fb-rev: 1514665, cache-control: no-store, expires: sat, 01 jan 2000 00:00:00 gmt, x-fb-debug: wpyeyyw/bis08hkafbwcrkbu5ticvgehtkrpbaitzzeqjgp3ogcp8eqwnvx2lx6b0ih9ggqirir3s4igu7vaiw==, date: tue, 02 dec 2014 09:21:50 gmt, connection: keep-alive, content-length: 190]} facebook.facebookauth com.mydomain.test.pages.facebook.facebookauth 400 httpresponseproxy{http/1.1 400 bad request [www-authenticate: oauth "facebook platform" "invalid_code" "error validating verification code. please make sure redirect_uri identical 1 used in oauth dialog request", facebook-api-version: v1.0, content-type: text/javascript; charset=utf-8, pragma: no-cache, access-control-allow-origin: *, x-fb-rev: 1514665, cache-control: no-store, expires: sat, 01 jan 2000 00:00:00 gmt, x-fb-debug: wpyeyyw/bis08hkafbwcrkbu5ticvgehtkrpbaitzzeqjgp3ogcp8eqwnvx2lx6b0ih9ggqirir3s4igu7vaiw==, date: tue, 02 dec 2014 09:21:50 gmt, connection: keep-alive, content-length: 190]} facebook.facebookauth com.mydomain.test.pages.facebook.facebookauth
what possible causing issue? have canvas , mobile?
Comments
Post a Comment