Facebook 2-phase login but the access tokens are different for each login?

I am using 2-phase Facebook login without problem in most of time, however recently I am running into a weird situation…

First login “facebook.login( fb_id, facebookListener_phase1)” and I print out the access token in the callback:

facebookListener\_phase1 -\> succesfully logged in, access\_token = CAAWGygmDMewBAE6zIfliZBtUoZA1bcM7ceq5uYXsHvkP5CxnWpkqMXRxBdVmuFWcZC736MnHnltUiILO0VWtOKzcRrCl19n0pO3k8mU0Xq5r9cxyB4ex5BGHkk0B2OmXUqERyvcZC5rKjQTVZBr1eOqxo9sjclww3qmj6qNCTROiZCMFjuZCQGV2hVrTUW26G8j9MpZCqIXD79sgerQZBfoWs

And inside the phase 1 listener, I call the second login “acebook.login( fb_id, facebookListener, { “publish_actions” })” and I also print out the access token in the callback:

facebookListener -\> succesfully logged in, access\_token = CAAWGygmDMewBAE35A9eAvTDizEZB6ZClWZCknHPNwrIIpmg19CJjlUcfhS1PUxyIL0o39DAOG3o1C5q0KZCAGG2wFqmbJ6wZAEvCAyZBKUBYDBjgZCbdNqZCzQRFJunXgZCpFe4piBuTFW9UyTIIZA3fYodXl59GDzzFFECZA7ZA5BTTVxIURn4qsU1X9pMAZAOps9pRYkucb9KpCZC4SaUZAZBiunCZA3FEo73snRaZCQ5LnHklD9nRuBdxWExk2X

These two access tokens are different!

 

They are supposed to be the same. I have tried to logout / remove app in the FB account setting, etc. to make sure it’s like a clean first login but I still see the same issue that the access tokens in two logins are different.

 

Any idea?

 

 

 

Sorry, my bad, they don’t need to be the same. 

I just tested again with an account that works, they are different.

However, I do see another problem.

After the first login succeeds and then I call the 2nd login… in successful scenario, the screen will switch to FB app again to ask for “publich_actions” permission, however for one of my account, it does not show that screen but report error immediately

“(#200) The user hasn’t authorized the application to perform this action”

In the FB backend, I check the permission status, there is no POST permission for my app.

I deleted the app and retry, there is still no chance for me to grant the permission (public_actions) when it’s supposed to be there after the 2nd login is called.

Anyone can shed some light?

Thanks.

Yes, now you have to submit your app to facebook and have it approved in order to have some permissions like the publish_actions.

I think the Facebook approval is to post without requesting permission?

Even I don’t have Facebook approval, my app can still ask for posting permission for one of my Facebook accounts and it works without problem.

Only one of my Facebook & some of my users have such a problem that the the permission request screen (called by 2nd facebook.login()) doesn’t appear.

Sorry, my bad, they don’t need to be the same. 

I just tested again with an account that works, they are different.

However, I do see another problem.

After the first login succeeds and then I call the 2nd login… in successful scenario, the screen will switch to FB app again to ask for “publich_actions” permission, however for one of my account, it does not show that screen but report error immediately

“(#200) The user hasn’t authorized the application to perform this action”

In the FB backend, I check the permission status, there is no POST permission for my app.

I deleted the app and retry, there is still no chance for me to grant the permission (public_actions) when it’s supposed to be there after the 2nd login is called.

Anyone can shed some light?

Thanks.

Yes, now you have to submit your app to facebook and have it approved in order to have some permissions like the publish_actions.

I think the Facebook approval is to post without requesting permission?

Even I don’t have Facebook approval, my app can still ask for posting permission for one of my Facebook accounts and it works without problem.

Only one of my Facebook & some of my users have such a problem that the the permission request screen (called by 2nd facebook.login()) doesn’t appear.