UsersShared¶
- class telegram.UsersShared(request_id, users, *, api_kwargs=None)[source]¶
Bases:
telegram.TelegramObject
This object contains information about the user whose identifier was shared with the bot using a
telegram.KeyboardButtonRequestUsers
button.Objects of this class are comparable in terms of equality. Two objects of this class are considered equal, if their
request_id
andusers
are equal.Available In
Added in version 20.8: Bot API 7.0 replaces
UserShared
with this class. The only difference is that now theuser_ids
is a sequence instead of a single integer.Changed in version 21.1: The argument
users
is now considered for the equality comparison instead ofuser_ids
.Removed in version 21.2: Removed the deprecated argument and attribute
user_ids
.- Parameters:
request_id (
int
) – Identifier of the request.users (Sequence[
telegram.SharedUser
]) –Information about users shared with the bot.
Added in version 21.1.
Changed in version 21.2: This argument is now required.
- users[source]¶
Information about users shared with the bot.
Added in version 21.1.
- Type:
tuple[
telegram.SharedUser
]