I want to add a facebook permission to my users. That is how I do it:
Session.openActiveSession(this, true, new Session.StatusCallback() {
@Override
use below code
Session session = getActiveSession();
if(session.isOpened)
{
List<String> permissions = session.getPermissions();
if(!permissions.contain("email"))
{
Session.NewPermissionsRequest newPermissionsRequest = new Session.NewPermissionsRequest(MainActivity.this,
PERMISSIONS);
session.requestNewReadPermissions(newPermissionsRequest);
}
}else
{
Session.openActiveSession(this, true,callback);
}