Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Facebook - fb graph api js sdk giving wrong response for user-id

I'm using facebook graph api using javascript sdk. I'm fetching page feed with their likes count and user and same for comment. but after some time I'm getting wrong user_id for all the page post like and comments.

when I'm trying to get this using facebook graph explorer it is giving me right result. I've used app_access_token and user-access-token.. what is wrong with facebook graph api.

like image 637
Pratik Shah Avatar asked May 26 '14 18:05

Pratik Shah


1 Answers

You are probably talking about "App Scoped IDs": https://developers.facebook.com/docs/apps/upgrading#upgrading_v2_0_user_ids

Apps don´t return real User IDs anymore, only IDs bound to one specific App. The Graph API Explorer should return the exact same ID for a User, as long as you select the same App before making an API call.

like image 76
andyrandy Avatar answered Oct 22 '22 19:10

andyrandy