Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is Facebook app-scoped id global unique?

Since Facebook make different ids for same user in different apps in API V2.0, we should change our attaching systems to fit this.

For the reason that I wanna make less change on our system, I need to know whether the Facebook app-scoped id global unique, in another word, there were have two apps, will the ids conflict when I save only the user app-scoped id in a same hash?

More details following.

I have two apps in a business, so each app could get the app-scoped id for another. I already have a system storing user's information unique index by the user app-scoped id of First app. Now I need to save these two apps user data in the same MySQL table, and we use the ids_for_business API to confirm whether the same user has registered in another app, to decide make a new register or login as a new user of our system. If the app-scoped id is globally unique, we could just act as what I am saying. But if the app-scoped id will be same for different user, that our user system will identify different user as a same user in our system, so we have to make a big change to follow Facebook.

Help me please...

Example like this, id of UserA on AppC is 33, would the id of UserB on AppD be 33?

like image 967
Zagfai Avatar asked Feb 12 '23 16:02

Zagfai


1 Answers

Yes, The IDs are globally unique:

The ID you get for a specific user who has logged into your app / granted you permission will not change, Two apps never get the same ID to reference different users - an app scoped ID is globally unique and references a specific {app, user} pair

like image 114
Igy Avatar answered Feb 27 '23 05:02

Igy