roughike / flutter_facebook_login

A Flutter plugin for allowing users to authenticate with native Android & iOS Facebook login SDKs.
BSD 2-Clause "Simplified" License
405 stars 331 forks source link

Cannot request for graph API scopes #199

Closed mr-muhammad-rehan closed 4 years ago

mr-muhammad-rehan commented 4 years ago

With current example given for graph 2.12 API may work fine for name profile and email but i need more info e.g birthday, gender and friends etc. final result = await facebookSignIn .logInWithReadPermissions(["basic_info","email", "user_gender", "user_birthday"]); final token = result.accessToken.token;

switch (result.status) { case FacebookLoginStatus.loggedIn: String grapApi ='https://graph.facebook.com/v4.0/me?fields=id,first_name,last_name,birthday,email,gender,picture&access_token=$token'; image

The Token i get in response from Graph API don't have scope for gender

image

The Default token provided by Facebook API debugger:

image

adolfdsilva commented 4 years ago

Having the same issue.. did you manage to solve this ?

adolfdsilva commented 4 years ago

Ok so after digging a lot... it seems we just cannot get gender, birthday directly. We have to complete app review on facebook.

https://developers.facebook.com/docs/facebook-login/permissions/v2.0#reference-user_gender