Get user data
Here you will learn, how to get user data.
First steps
First, we have to initialize the class and set the user id. After that, we download the data from the API.
Now, we can access the user data.
Get the profile picture
The function returns the URL of the profile picture.
NOTICE: If the user didn't set a profile picture, you'll get an error when accessing this function.
Get the user state
Possible values: USER_STATE_UNSPECIFIED
, USER_STATE_ACTIVE
, USER_STATE_INACTIVE
, USER_STATE_DELETED
, USER_STATE_LOCKED
, USER_STATE_INITIAL
Get the username
Get the login names
This function returns an array with the possible login names.
Get the preferred login name
Get the given name and family name
Get the nickname
Get the display name
Get the preferred language
Get the gender
Possible values: GENDER_UNSPECIFIED
, GENDER_MALE
, GENDER_FEMALE
, GENDER_DIVERSE
Get the email address
The following function returns true, if the email address is verified.
Get the phone number
The following function returns true, if the phone number is verified.
Get the raw user data
This function returns the raw JSON-encoded user data.