telegram.ChatMemberRestricted¶
- class telegram.ChatMemberRestricted(user, is_member, can_change_info, can_invite_users, can_pin_messages, can_send_messages, can_send_media_messages, can_send_polls, can_send_other_messages, can_add_web_page_previews, can_manage_topics, until_date, *, api_kwargs=None)[source]¶
Bases:
telegram.ChatMember
Represents a chat member that is under certain restrictions in the chat. Supergroups only.
New in version 13.7.
Changed in version 20.0: The argument
can_manage_topics
was added, which changes the position of the optional argumentuntil_date
.- Parameters
user (
telegram.User
) – Information about the user.is_member (
bool
) –True
, if the user is a member of the chat at the moment of the request.can_change_info (
bool
) –True
, if the user can change the chat title, photo and other settings.can_invite_users (
bool
) –True
, if the user can invite new users to the chat.can_pin_messages (
bool
) –True
, if the user is allowed to pin messages; groups and supergroups only.can_send_messages (
bool
) –True
, if the user is allowed to send text messages, contacts, locations and venues.can_send_media_messages (
bool
) –True
, if the user is allowed to send audios, documents, photos, videos, video notes and voice notes.can_send_polls (
bool
) –True
, if the user is allowed to send polls.can_send_other_messages (
bool
) –True
, if the user is allowed to send animations, games, stickers and use inline bots.can_add_web_page_previews (
bool
) –True
, if the user is allowed to add web page previews to their messages.True
, if the user is allowed to create forum topics.New in version 20.0.
until_date (
datetime.datetime
) – Date when restrictions will be lifted for this user.
- status[source]¶
The member’s status in the chat, always
'restricted'
.- Type
- can_change_info[source]¶
True
, if the user can change the chat title, photo and other settings.- Type
- can_pin_messages[source]¶
True
, if the user is allowed to pin messages; groups and supergroups only.- Type
- can_send_messages[source]¶
True
, if the user is allowed to send text messages, contacts, locations and venues.- Type
- can_send_media_messages[source]¶
True
, if the user is allowed to send audios, documents, photos, videos, video notes and voice notes.- Type
- can_send_other_messages[source]¶
True
, if the user is allowed to send animations, games, stickers and use inline bots.- Type
- can_add_web_page_previews[source]¶
True
, if the user is allowed to add web page previews to their messages.- Type
- can_manage_topics[source]¶
True
, if the user is allowed to create forum topics.New in version 20.0.
- Type