Get all the facebook Application user details - facebook

Am a facebook game developer. i have developed a game and am using facebook log in facility.but still now i want store the my app user id in my database.
but am interested do Rank the user based on their score. hence i need there all the user of my game.
so it any possibility to get the all registered user ID from Graph API/ or in any other way?

when the user is registering your app or authorizing it, store the user details in your own table. That would be a better option. Or you have to use FQL on insights object to get the application installed users.
https://developers.facebook.com/docs/graph-api/reference/insights
There you have a property called "application_installed_users"

Related

facebook application for login and messenger same ids?

I am building a facebook messenger bot. And the bot is giving user ids. But it is not clear to me if the messenger ids are the same ids that would be returned if I use the same app and add to it a login feature. Because we already have an app and has a login feature, now we need to build a facebook bot and identify the already existing users in our db that are using the bot.
I have read facebook tutorial about linking 2 different applications to the same business to get consistent ids. But what if I use that same application to login users AND for messengers (by using the add products to the application, and so having one application, one app id) would that work? Would I be getting the same user ids?
PS: I would test myself but I am in an awkward position where the page/database/login app owner is a different person, and they are not big on sharing data, and I am supposed to blindly write a messenger code that is supposed to work when they deploy it.
All help is appreciated, thank you.
You need to use Facebook's ID Matching APIs for this purpose:
Here is the details: https://developers.facebook.com/docs/messenger-platform/identity/id-matching

Using FaceBook Sdk in my Unity Game (Login and User's FB_id)

I've been working with integration of Facebook sdk in my unity game. In the first page I kept a fb login option and I'm trying to fetch the player's fb_id(with which I will be making an online leaderboard). I'am facing two problems.They are:
Only my apps developers, test-users and owner(me) can login only first time. If i clear my apps data I face a hash key validation problem. There will be a screenshot below.
I need the fb_ids of all users . But I am getting only the fb_ids of people who has roles (owner, developer and test users) . How can I get the fb_ids of all users?
NB: My game is published in google play and reviewed by Facebook with necessary permissions.
Google Play Link: https://play.google.com/store/apps/details?id=com.BLI.CatchTheBaby&hl=en
Facebook SDK does not allow you to get data of all users.
Their API returns only your friends ids,name etc. Here is an online tester of Graph API: https://developers.facebook.com/tools/explorer/
If you want to get all users FB IDs you have to store them on your online database like this: When user is doing his first login to Facebook from your app, you are sending returned id to database by some kind of webrequest. Then you can fetch data with all users IDs.

Facebook Account Kit and token for business

We have 3 apps using the very same user base. Users are able to use these apps with one account. Hence, we are using token_for_business id of facebook users in graph api to be able to recognise them in all 3 apps. However, we cannot find anything about token_for_business like approach in account kit documentations. Hence, we cannot recognise a user in an app, who registered in another app.
Is there anything like token_for_business in Account Kit, or should I request a feature from Facebook?
There's currently no such feature for AccountKit. Though one way that you can implement this yourself is by storing the phone number (or email, if you use that flow) for each app login and cross reference them in your own data.

How to find out which of your facebook friends are also using your mobile app?

We are building mobile app that uses Facebook for registration (know how to do this).
We would like to have a screen, where all your friends would be listed with indication, if they also use our app.
How should we save data (client, server) that one facebook user is also our app user?
When you're already using Facebook for authentication, you probably already have a column in the user table in your database that holds Facebook profile ids of each user. If you want to distinguish between them, just add a column modeling if that user is also using your mobile app.
By issuing a request to https://graph.facebook.com/PROFILE_ID/friends as described in the Facebook Graph API Documentation you can get the list of friends for a certain user without requiring any additional permissions.
Now just build the intersection between the friends list of the user and your (mobile app) user base and you got the list of his friends that are using your mobile app. You should of course do this comparision on the server, so you don't have to send the Facebook ids of your complete user base around.

What type of application to choose

I want to create facebook application that will allow to insert some data from my site to user's profile. User can choose to set up application. The users enters his ID on my site and when user's profile is viewed there is block of data loaded from my site (specified to the ID).
Is this possible to create such application with facebook ? If no the what type of application is closest to this? My site users want to display their profiles from my site inside their facebook profiles , so facebook friends can see this.
If I understand you correctly you want to add some additional data on the users Facebook profile, something like if Stackoverflow would add their flair on the Facebook profile.
I don't think this is possible, but you have a few alternatives:
Make the user post out a link to his profile on your site to his Facebook Wall, more details here.
Integrate your site to the new Open Graph Objects. Open Graph Objects will create a box on the users profile for your application which shows the users activity in your application. You should check out the demos and documentation for more information about this.
The users enters his ID on my site and when user's profile is viewed there is block of data loaded from my site
You can't do anything like this, you will need to use the authentication flow provided by Facebook in order to get access to the Facebook user data and then tie up the Facebook user to "your user", see documentation.
When it comes to what type of app you should create, there is basically only one type of app with some different options. But you should focus on the "Facebook for websites" documentation.