Class: TD::Types::User

Inherits:
Base
  • Object
show all
Defined in:
lib/tdlib/types/user.rb

Overview

Represents a user.

Instance Attribute Summary collapse

Method Summary

Methods inherited from Base

#to_hash, #to_json

Instance Attribute Details

#first_nameString

First name of the user.

Returns:

  • (String)

    the current value of first_name



24
25
26
# File 'lib/tdlib/types/user.rb', line 24

def first_name
  @first_name
end

#have_accessBoolean

If false, the user is inaccessible, and the only information known about the user is inside this class. It can't be passed to any method except GetUser.

Returns:

  • (Boolean)

    the current value of have_access



24
25
26
# File 'lib/tdlib/types/user.rb', line 24

def have_access
  @have_access
end

#idInteger

User identifier.

Returns:

  • (Integer)

    the current value of id



24
25
26
# File 'lib/tdlib/types/user.rb', line 24

def id
  @id
end

#is_contactBoolean

The user is a contact of the current user.

Returns:

  • (Boolean)

    the current value of is_contact



24
25
26
# File 'lib/tdlib/types/user.rb', line 24

def is_contact
  @is_contact
end

#is_mutual_contactBoolean

The user is a contact of the current user and the current user is a contact of the user.

Returns:

  • (Boolean)

    the current value of is_mutual_contact



24
25
26
# File 'lib/tdlib/types/user.rb', line 24

def is_mutual_contact
  @is_mutual_contact
end

#is_scamBoolean

True, if many users reported this user as a scam.

Returns:

  • (Boolean)

    the current value of is_scam



24
25
26
# File 'lib/tdlib/types/user.rb', line 24

def is_scam
  @is_scam
end

#is_supportBoolean

True, if the user is Telegram support account.

Returns:

  • (Boolean)

    the current value of is_support



24
25
26
# File 'lib/tdlib/types/user.rb', line 24

def is_support
  @is_support
end

#is_verifiedBoolean

True, if the user is verified.

Returns:

  • (Boolean)

    the current value of is_verified



24
25
26
# File 'lib/tdlib/types/user.rb', line 24

def is_verified
  @is_verified
end

#language_codeString

IETF language tag of the user's language; only available to bots.

Returns:

  • (String)

    the current value of language_code



24
25
26
# File 'lib/tdlib/types/user.rb', line 24

def language_code
  @language_code
end

#last_nameString

Last name of the user.

Returns:

  • (String)

    the current value of last_name



24
25
26
# File 'lib/tdlib/types/user.rb', line 24

def last_name
  @last_name
end

#phone_numberString

Phone number of the user.

Returns:

  • (String)

    the current value of phone_number



24
25
26
# File 'lib/tdlib/types/user.rb', line 24

def phone_number
  @phone_number
end

#profile_photoTD::Types::ProfilePhoto?

Profile photo of the user; may be null.

Returns:



24
25
26
# File 'lib/tdlib/types/user.rb', line 24

def profile_photo
  @profile_photo
end

#restriction_reasonString

If non-empty, it contains a human-readable description of the reason why access to this user must be restricted.

Returns:

  • (String)

    the current value of restriction_reason



24
25
26
# File 'lib/tdlib/types/user.rb', line 24

def restriction_reason
  @restriction_reason
end

#statusTD::Types::UserStatus

Current online status of the user.

Returns:



24
25
26
# File 'lib/tdlib/types/user.rb', line 24

def status
  @status
end

#typeTD::Types::UserType

Type of the user.

Returns:



24
25
26
# File 'lib/tdlib/types/user.rb', line 24

def type
  @type
end

#usernameString

Username of the user.

Returns:

  • (String)

    the current value of username



24
25
26
# File 'lib/tdlib/types/user.rb', line 24

def username
  @username
end