pub struct Chat {
Show 22 fields pub id: i64, pub title: Option<String>, pub username: Option<String>, pub first_name: Option<String>, pub last_name: Option<String>, pub photo: Option<ChatPhoto>, pub bio: Option<String>, pub has_private_forwards: Option<bool>, pub has_restricted_voice_and_video_messages: Option<bool>, pub join_to_send_messages: Option<bool>, pub join_by_request: Option<bool>, pub description: Option<String>, pub invite_link: Option<String>, pub pinned_message: Option<Message>, pub permissions: Option<ChatPermissions>, pub slow_mode_delay: Option<i64>, pub message_auto_delete_time: Option<i64>, pub has_protected_content: Option<bool>, pub sticker_set_name: Option<String>, pub can_set_sticker_set: Option<bool>, pub linked_chat_id: Option<i64>, pub location: Option<ChatLocation>, /* private fields */
}
Expand description

This object represents a chat.

Fields

id: i64

Unique identifier for this chat. 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 signed 64-bit integer or double-precision float type are safe for storing this identifier.

title: Option<String>

Optional. Title, for supergroups, channels and group chats

username: Option<String>

Optional. Username, for private chats, supergroups and channels if available

first_name: Option<String>

Optional. First name of the other party in a private chat

last_name: Option<String>

Optional. Last name of the other party in a private chat

photo: Option<ChatPhoto>

Optional. Chat photo. Returned only in getChat.

bio: Option<String>

Optional. Bio of the other party in a private chat. Returned only in getChat.

has_private_forwards: Option<bool>

Optional. True, if privacy settings of the other party in the private chat allows to use tg://user?id=<user_id> links only in chats with the user. Returned only in getChat.

has_restricted_voice_and_video_messages: Option<bool>

Optional. True, if the privacy settings of the other party restrict sending voice and video note messages in the private chat. Returned only in getChat.

join_to_send_messages: Option<bool>

Optional. True, if users need to join the supergroup before they can send messages. Returned only in getChat.

join_by_request: Option<bool>

Optional. True, if all users directly joining the supergroup need to be approved by supergroup administrators. Returned only in getChat.

description: Option<String>

Optional. Description, for groups, supergroups and channel chats. Returned only in getChat.

invite_link: Option<String>

Optional. Primary invite link, for groups, supergroups and channel chats. Returned only in getChat.

pinned_message: Option<Message>

Optional. The most recent pinned message (by sending date). Returned only in getChat.

permissions: Option<ChatPermissions>

Optional. Default chat member permissions, for groups and supergroups. Returned only in getChat.

slow_mode_delay: Option<i64>

Optional. For supergroups, the minimum allowed delay between consecutive messages sent by each unpriviledged user; in seconds. Returned only in getChat.

message_auto_delete_time: Option<i64>

Optional. The time after which all messages sent to the chat will be automatically deleted; in seconds. Returned only in getChat.

has_protected_content: Option<bool>

Optional. True, if messages from the chat can’t be forwarded to other chats. Returned only in getChat.

sticker_set_name: Option<String>

Optional. For supergroups, name of group sticker set. Returned only in getChat.

can_set_sticker_set: Option<bool>

Optional. True, if the bot can change the group sticker set. Returned only in getChat.

linked_chat_id: Option<i64>

Optional. Unique identifier for the linked chat, i.e. the discussion group identifier for a channel and vice versa; for supergroups and channel chats. This identifier may be greater than 32 bits and some programming languages may have difficulty/silent defects in interpreting it. But it is smaller than 52 bits, so a signed 64 bit integer or double-precision float type are safe for storing this identifier. Returned only in getChat.

location: Option<ChatLocation>

Optional. For supergroups, the location to which the supergroup is connected. Returned only in getChat.

Implementations

Trait Implementations

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more
Deserialize this value from the given Serde deserializer. Read more
Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.
Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more