class Tourmaline::User
inherits Reference
#
This object represents a Telegram user or bot.
Included modules
JSON::Serializable
Constructors#
.new(id, is_bot, first_name, last_name : String? = nil, username : String? = nil, language_code : String? = nil, is_premium : Bool? = nil, added_to_attachment_menu : Bool? = nil, can_join_groups : Bool? = nil, can_read_all_group_messages : Bool? = nil, supports_inline_queries : Bool? = nil, can_connect_to_business : Bool? = nil)
#
(id, is_bot, first_name, last_name : String? = nil, username : String? = nil, language_code : String? = nil, is_premium : Bool? = nil, added_to_attachment_menu : Bool? = nil, can_join_groups : Bool? = nil, can_read_all_group_messages : Bool? = nil, supports_inline_queries : Bool? = nil, can_connect_to_business : Bool? = nil)
Methods#
#added_to_attachment_menu=(added_to_attachment_menu : Bool?)
#
(added_to_attachment_menu : Bool?)
Optional. True, if this user added the bot to the attachment menu
#added_to_attachment_menu? : Bool?
#
: Bool?
Optional. True, if this user added the bot to the attachment menu
#can_connect_to_business=(can_connect_to_business : Bool?)
#
(can_connect_to_business : Bool?)
Optional. True, if the bot can be connected to a Telegram Business account to receive its messages. Returned only in getMe.
#can_connect_to_business? : Bool?
#
: Bool?
Optional. True, if the bot can be connected to a Telegram Business account to receive its messages. Returned only in getMe.
#can_join_groups=(can_join_groups : Bool?)
#
(can_join_groups : Bool?)
Optional. True, if the bot can be invited to groups. Returned only in getMe.
#can_join_groups? : Bool?
#
: Bool?
Optional. True, if the bot can be invited to groups. Returned only in getMe.
#can_read_all_group_messages=(can_read_all_group_messages : Bool?)
#
(can_read_all_group_messages : Bool?)
Optional. True, if privacy mode is disabled for the bot. Returned only in getMe.
#can_read_all_group_messages? : Bool?
#
: Bool?
Optional. True, if privacy mode is disabled for the bot. Returned only in getMe.
#id : Int32 | Int64
#
: Int32 | Int64
Unique identifier for this user or bot. This number may have more than 32 significant bits and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a 64-bit integer or double-precision float type are safe for storing this identifier.
#id=(id : Int32 | Int64)
#
(id : Int32 | Int64)
Unique identifier for this user or bot. This number may have more than 32 significant bits and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a 64-bit integer or double-precision float type are safe for storing this identifier.
#is_premium=(is_premium : Bool?)
#
(is_premium : Bool?)
Optional. True, if this user is a Telegram Premium user
#language_code=(language_code : String?)
#
(language_code : String?)
Optional. IETF language tag of the user's language
#supports_inline_queries=(supports_inline_queries : Bool?)
#
(supports_inline_queries : Bool?)
Optional. True, if the bot supports inline queries. Returned only in getMe.
#supports_inline_queries? : Bool?
#
: Bool?
Optional. True, if the bot supports inline queries. Returned only in getMe.