Facebook Graph API — How to get FB id, name, email and picture by using the access token only

--

After the Facebook Login you get an access token by Facebook. To turn your access token into consumable data you just need to create a GET request with the following URL:

https://graph.facebook.com/me?access_token=<your-fb-token>&
fields=id,name,email,picture.width(640).height(640)

The important aspect of me after graph.facebook.com is that you just need the token, not the explicit Facebook ID. This is useful in social authentication pipelines.

The default picture size is very small. With width(640) and height(640) you ensure to get a good sized image.

That’s it.

#TheExamplesPlatform

--

--

Eugenio Galioto

Builder 🚀 On Deck Fellow 🌎 AR & Generative AI Enthusiast 🧠