Best way to know to which social media account is linked to

Hi,

I would like to know what the best way to show users to which social medium his account is linked to?

For example, when the user starts for the first time the game, he’s just connected with device id. But later then he decides to link his account to facebook then how can i know his account is linked to FB.

I could save this in PlayerPrefs but maybe there is a shortcut?

And i wonder, once the account is linked, do I have to manage the login lifecycle of facebook or nakama manages this for me? Do Nakama refreshs the facebook token automatically?

Thanks

Saving this in PlayerPrefs would work but shouldn’t be needed. You can fetch the user’s account and check which social provider fields are set - in your example just check if the Facebook ID field is not empty, if that’s the case then the user has initially authenticated with Facebook when the Nakama user was created or linked a Facebook account to it at some point later.

Nakama does not manage your Facebook authentication flow. When authenticating/linking with Facebook the server checks the token against Facebook’s services, fetches the user’s profile, optionally fetches their friends to enhance the user’s friend graph in Nakama, then only tracks the Facebook account ID. Further access to Facebook is not needed/used from Nakama’s perspective, so the token is not stored.