I'm using Satellizer to do a Facebook login, it works great except that Facebook is not returning all the users info. I'm only getting a name and ID but no email when I inculde in my scope email and public_profile.
Here is my FB config on the client side, and as you can see, I'm asking for email and public_profile:
facebook: {
clientId: 'xxxxxxx',
url: '/api/public/authentication/facebook',
authorizationEndpoint: 'https://www.facebook.com/v2.3/dialog/oauth',
redirectUri: window.location.protocol + '//' + window.location.host + '/', // window.location.origin || window.location.protocol + '//' + window.location.host + '/'
scope: 'email,public_profile',
scopeDelimiter: ',',
requiredUrlParams: ['display', 'scope'],
display: 'popup',
type: '2.0',
popupOptions: { width: 481, height: 269 }
},
On the server, this:
request.get( { url: graphApiUrl, qs: accessToken, json: true }, function( err, response, profile ) { ....
Only gives for the profile the id and name like so:
profile = Object {name: Denis, id: xxx}
No idea what I'm doing wrong and why I'm not getting the email, the avatar...
Thanks.