class Firebase::Admin::Auth::UserInfo

Standard profile information for a user.

Also used to expose profile information returned by an identity provider.

Public Class Methods

new(data) click to toggle source

Constructs a new UserInfo.

@param [Hash] data

A hash of profile information
# File lib/firebase/admin/auth/user_info.rb, line 14
def initialize(data)
  @data = data || {}
end

Public Instance Methods

display_name() click to toggle source

Gets the display name of this user.

# File lib/firebase/admin/auth/user_info.rb, line 24
def display_name
  @data["displayName"]
end
email() click to toggle source

Gets the email address associated with this user.

# File lib/firebase/admin/auth/user_info.rb, line 29
def email
  @data["email"]
end
phone_number() click to toggle source

Gets the phone number associated with this user.

# File lib/firebase/admin/auth/user_info.rb, line 34
def phone_number
  @data["phoneNumber"]
end
photo_url() click to toggle source

Gets the photo url of this user.

# File lib/firebase/admin/auth/user_info.rb, line 39
def photo_url
  @data["photoUrl"]
end
provider_id() click to toggle source

Gets the id of the identity provider.

This can be a short domain name (e.g. google.com), or the identity of an OpenID identity provider.

# File lib/firebase/admin/auth/user_info.rb, line 47
def provider_id
  @data["providerId"]
end
to_h() click to toggle source

Converts the object into a hash.

@return [Hash]

# File lib/firebase/admin/auth/user_info.rb, line 54
def to_h
  @data.dup
end
uid() click to toggle source

Gets the ID of this user.

# File lib/firebase/admin/auth/user_info.rb, line 19
def uid
  @data["rawId"]
end