Modify the user data retrieved during social login

The object returned by the auth_info call can contain a number of object fields, and these will vary depending on several factors, including identity provider and service level. You can use that information to greet the user by name, display the user’sΒ photo from an identity provider (for example, their Twitter photo), send an email to the user using his/herΒ verified email address, and so on.

One profile object that is always included is a string field calledΒ identifier. The exact format of this field varies, but a given application is guaranteed to get a unique identifier value for each user. That makesΒ identifierΒ ideal for use as a key value for user records. For example, if you want to store user information that you gather above and beyond the social login process in a database, you might want to useΒ identifierΒ as the unique ID for users.

Note thatΒ identifierΒ is not guaranteed to have the same value for the same user and provider combination on all applications (do not share the user identifier between applications).