pub struct User {
pub id: i64,
pub is_bot: bool,
pub first_name: String,
pub last_name: Option<String>,
pub username: Option<String>,
pub language_code: Option<String>,
pub is_premium: Option<bool>,
pub added_to_attachment_menu: Option<bool>,
pub can_join_groups: Option<bool>,
pub can_read_all_group_messages: Option<bool>,
pub supports_inline_queries: Option<bool>,
}
Expand description
This object represents a Telegram user or bot.
Fields§
§id: i64
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_bot: bool
True, if this user is a bot
first_name: String
User’s or bot’s first name
last_name: Option<String>
Optional. User’s or bot’s last name
username: Option<String>
Optional. User’s or bot’s username
language_code: Option<String>
Optional. IETF language tag of the user’s language
Optional. True, if this user is a Telegram Premium user
Optional. True, if this user added the bot to the attachment menu
can_join_groups: Option<bool>
Optional. True, if the bot can be invited to groups. Returned only in getMe.
can_read_all_group_messages: Option<bool>
Optional. True, if privacy mode is disabled for the bot. Returned only in getMe.
supports_inline_queries: Option<bool>
Optional. True, if the bot supports inline queries. Returned only in getMe.