What data can be obtained about a user who logs in with Facebook Oauth?

11,399

Solution 1

Here's the list of what I get when accessing https://graph.facebook.com/me:

  • id
  • name
  • first_name
  • last_name
  • link
  • username
  • about
  • work
  • education
  • gender
  • email
  • timezone
  • locale
  • verified
  • updated_time

If you look at https://developer.facebook.com they have a bunch of tools which let you poke around and test URLs.

Solution 2

Check out the Facebook Graph Explorer tool: https://developers.facebook.com/tools/explorer/

By default, this tool let's you query the Facebook graph with default permissions.

There's a button labelled 'get access token' which gives you the option to generate access tokens for every possible combination of Facebook permissions. You can then query the Graph with any set of permissions and see what data is available.

Share:
11,399
Stephen Ostermiller
Author by

Stephen Ostermiller

Contact Me Website GitHub Facebook LinkedIn

Updated on June 04, 2022

Comments

  • Stephen Ostermiller
    Stephen Ostermiller almost 2 years

    I'm currently using OpenID to allow users to login to my website using Google as a provider. I'm thinking about allowing users to use Facebook to login as well. When a user logs in with Google OpenID, Google sends the following data to my website about the user:

    • Full name
    • First name
    • Last name
    • ID
    • Gender
    • Language
    • Email address

    I've done some quick searching, but I can't find a list of attributes that Facebook would provide with an Oauth login. What data does facebook provide by default, and what additional data can you ask for?

  • bgenchel
    bgenchel over 8 years
    I've been trying that route for hours and all I get back are name and id. I have no idea what is wrong.
  • TWONEKSONE
    TWONEKSONE about 5 years
    I'm getting the same of @bgenchel. do we need to set the infos that we want facebook to share in some way?