Using ASP.NET Core MVC RC2 I am trying to get a Facebook user profile picture. To do this, I have the following lines in the Configure method of the Startup class
app.UseFacebookAuthentication(new FacebookOptions()
{
AppId = Configuration["Authentication:Facebook:AppId"],
AppSecret = Configuration["Authentication:Facebook:AppSecret"],
Scope = { "user_birthday" },
Fields = { "birthday", "picture" },
});
In the AccountControllers ExternalLoginCallback method, I expected to see the data for the image in the ClaimsPrincipal collection, which can be accessed through info.Principal, but I do not see any claims related to the image.
Is this the right way to get a Facebook user profile picture or am I missing something?
source
share