-
Notifications
You must be signed in to change notification settings - Fork 80
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
InternalOAuthError: Unable to fetch user profile. #54
Comments
I'm seeing this issue as well! Please help. |
Hi, I might have found the issue. Problem is not in this package, but in how facebook handles authentication. Most probably, you are using facebook credentials in testing mode. Your app is not live, so for security reasons, you can only fetch profile of users who are part of your test version of the app. In app settings @ developers.facebook.com, you will find a setting pertaining to roles, just add few of your friends there, then you can fetch there profile via the access token. TL;DR You can fetch profiles of users by there access token only when you app is live not in testing mode. In testing mode, you can only fetch your own profile. Please correct me, i said anything incorrect or made any false assumptions. |
Another thing that you can try is adding your external IP address to the server whitelist for your facebook app. This is found in the advanced section of the settings in the app developer dashboard. |
@Joshuabaker2 can you please elaborate? i tried adding my external ip address to the app settings in Facebook Developers dashboard and i still can't run a unit test from any ideas? |
I'm assuming you mean your server is listening to localhost:3000? That shouldn't matter as far as I know, because it is the outgoing request to Facebook that is failing, which will be via port 80 and to their IP address. If it isn't the whitelist, you might not have the Facebook account added to the list of accounts able to use the app (which you need to do until the app isn't in development mode). You'll find that somewhere in the developer settings as well (on my phone so can't check). |
I am trying to do facebook auth login using passport-facebook-token in loopback. I followed the documentation provided but i am getting the following error message when passing auth token to my api.
But i got this token from facebook graph api, and is a valid token. Can anyone help me?
Also if i use access token provided on my developer account here:
https://developers.facebook.com/tools/access_token/
then i am able to fetch my own user profile. I dont understand where is the problem. I tried integrating google using passport-google-plus-token..it went well, but i am not able to integrate facebook login via access token.
The text was updated successfully, but these errors were encountered: