iOS Question Firebase Auth - Facebook Profile Pic URL signature expired

tufanv

Expert
Licensed User
Longtime User
Hello

After i login with facebook, my profile pic image url comes. When i visit the page via browser i get : URL signature expired error.

Previously i was able to see all the profile pics of people who logged in. How can i fix this _

TY
 

JanPRO

Well-Known Member
Licensed User
Longtime User
Hi,

the following code uses the Facebook's Graph Api to for the picture Url, maybe this works ...

B4X:
Sub GetUrl As String
    Dim NaObj As NativeObject
    NaObj = NaObj.Initialize("FBSDKAccessToken")
    Dim Token As String = NaObj.RunMethod("currentAccessToken",Null).GetField("tokenString").AsString
 
    'More info: https://developers.facebook.com/docs/graph-api/reference/v2.8/user/picture
    Return $"https://graph.facebook.com/me/picture?access_token=${Token}&type=large"$
End Sub

Jan
 
Upvote 0
Top