stefano-Pyrogram 2.0.107__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- pyrogram/__init__.py +42 -0
- pyrogram/client.py +1048 -0
- pyrogram/connection/__init__.py +19 -0
- pyrogram/connection/connection.py +72 -0
- pyrogram/connection/transport/__init__.py +19 -0
- pyrogram/connection/transport/tcp/__init__.py +24 -0
- pyrogram/connection/transport/tcp/tcp.py +123 -0
- pyrogram/connection/transport/tcp/tcp_abridged.py +57 -0
- pyrogram/connection/transport/tcp/tcp_abridged_o.py +86 -0
- pyrogram/connection/transport/tcp/tcp_full.py +64 -0
- pyrogram/connection/transport/tcp/tcp_intermediate.py +45 -0
- pyrogram/connection/transport/tcp/tcp_intermediate_o.py +79 -0
- pyrogram/crypto/__init__.py +17 -0
- pyrogram/crypto/aes.py +130 -0
- pyrogram/crypto/mtproto.py +100 -0
- pyrogram/crypto/prime.py +82 -0
- pyrogram/crypto/rsa.py +259 -0
- pyrogram/dispatcher.py +259 -0
- pyrogram/emoji.py +4019 -0
- pyrogram/enums/__init__.py +49 -0
- pyrogram/enums/auto_name.py +27 -0
- pyrogram/enums/chat_action.py +72 -0
- pyrogram/enums/chat_event_action.py +127 -0
- pyrogram/enums/chat_member_status.py +43 -0
- pyrogram/enums/chat_members_filter.py +42 -0
- pyrogram/enums/chat_type.py +40 -0
- pyrogram/enums/message_entity_type.py +84 -0
- pyrogram/enums/message_media_type.py +70 -0
- pyrogram/enums/message_service_type.py +73 -0
- pyrogram/enums/messages_filter.py +75 -0
- pyrogram/enums/next_code_type.py +39 -0
- pyrogram/enums/parse_mode.py +37 -0
- pyrogram/enums/poll_type.py +31 -0
- pyrogram/enums/sent_code_type.py +45 -0
- pyrogram/enums/user_status.py +43 -0
- pyrogram/errors/__init__.py +65 -0
- pyrogram/errors/exceptions/__init__.py +26 -0
- pyrogram/errors/exceptions/all.py +509 -0
- pyrogram/errors/exceptions/bad_request_400.py +2541 -0
- pyrogram/errors/exceptions/flood_420.py +63 -0
- pyrogram/errors/exceptions/forbidden_403.py +217 -0
- pyrogram/errors/exceptions/internal_server_error_500.py +336 -0
- pyrogram/errors/exceptions/not_acceptable_406.py +112 -0
- pyrogram/errors/exceptions/see_other_303.py +63 -0
- pyrogram/errors/exceptions/service_unavailable_503.py +42 -0
- pyrogram/errors/exceptions/unauthorized_401.py +91 -0
- pyrogram/errors/rpc_error.py +103 -0
- pyrogram/file_id.py +481 -0
- pyrogram/filters.py +929 -0
- pyrogram/handlers/__init__.py +30 -0
- pyrogram/handlers/callback_query_handler.py +49 -0
- pyrogram/handlers/chat_join_request_handler.py +49 -0
- pyrogram/handlers/chat_member_updated_handler.py +49 -0
- pyrogram/handlers/chosen_inline_result_handler.py +50 -0
- pyrogram/handlers/deleted_messages_handler.py +61 -0
- pyrogram/handlers/disconnect_handler.py +43 -0
- pyrogram/handlers/edited_message_handler.py +49 -0
- pyrogram/handlers/handler.py +43 -0
- pyrogram/handlers/inline_query_handler.py +49 -0
- pyrogram/handlers/message_handler.py +49 -0
- pyrogram/handlers/poll_handler.py +50 -0
- pyrogram/handlers/raw_update_handler.py +67 -0
- pyrogram/handlers/user_status_handler.py +47 -0
- pyrogram/methods/__init__.py +45 -0
- pyrogram/methods/advanced/__init__.py +29 -0
- pyrogram/methods/advanced/invoke.py +89 -0
- pyrogram/methods/advanced/resolve_peer.py +125 -0
- pyrogram/methods/advanced/save_file.py +242 -0
- pyrogram/methods/auth/__init__.py +53 -0
- pyrogram/methods/auth/accept_terms_of_service.py +44 -0
- pyrogram/methods/auth/check_password.py +60 -0
- pyrogram/methods/auth/connect.py +51 -0
- pyrogram/methods/auth/disconnect.py +40 -0
- pyrogram/methods/auth/get_password_hint.py +38 -0
- pyrogram/methods/auth/initialize.py +52 -0
- pyrogram/methods/auth/log_out.py +51 -0
- pyrogram/methods/auth/recover_password.py +57 -0
- pyrogram/methods/auth/resend_code.py +64 -0
- pyrogram/methods/auth/send_code.py +79 -0
- pyrogram/methods/auth/send_recovery_code.py +43 -0
- pyrogram/methods/auth/sign_in.py +80 -0
- pyrogram/methods/auth/sign_in_bot.py +79 -0
- pyrogram/methods/auth/sign_up.py +73 -0
- pyrogram/methods/auth/terminate.py +61 -0
- pyrogram/methods/bots/__init__.py +55 -0
- pyrogram/methods/bots/answer_callback_query.py +81 -0
- pyrogram/methods/bots/answer_inline_query.py +112 -0
- pyrogram/methods/bots/answer_web_app_query.py +53 -0
- pyrogram/methods/bots/delete_bot_commands.py +62 -0
- pyrogram/methods/bots/get_bot_commands.py +67 -0
- pyrogram/methods/bots/get_bot_default_privileges.py +59 -0
- pyrogram/methods/bots/get_chat_menu_button.py +66 -0
- pyrogram/methods/bots/get_game_high_scores.py +72 -0
- pyrogram/methods/bots/get_inline_bot_results.py +92 -0
- pyrogram/methods/bots/request_callback_answer.py +77 -0
- pyrogram/methods/bots/send_game.py +100 -0
- pyrogram/methods/bots/send_inline_bot_result.py +75 -0
- pyrogram/methods/bots/set_bot_commands.py +73 -0
- pyrogram/methods/bots/set_bot_default_privileges.py +81 -0
- pyrogram/methods/bots/set_chat_menu_button.py +56 -0
- pyrogram/methods/bots/set_game_score.py +100 -0
- pyrogram/methods/chats/__init__.py +101 -0
- pyrogram/methods/chats/add_chat_members.py +90 -0
- pyrogram/methods/chats/archive_chats.py +71 -0
- pyrogram/methods/chats/ban_chat_member.py +111 -0
- pyrogram/methods/chats/create_channel.py +56 -0
- pyrogram/methods/chats/create_group.py +67 -0
- pyrogram/methods/chats/create_supergroup.py +60 -0
- pyrogram/methods/chats/delete_channel.py +52 -0
- pyrogram/methods/chats/delete_chat_photo.py +70 -0
- pyrogram/methods/chats/delete_supergroup.py +52 -0
- pyrogram/methods/chats/delete_user_history.py +55 -0
- pyrogram/methods/chats/get_chat.py +87 -0
- pyrogram/methods/chats/get_chat_event_log.py +109 -0
- pyrogram/methods/chats/get_chat_member.py +92 -0
- pyrogram/methods/chats/get_chat_members.py +158 -0
- pyrogram/methods/chats/get_chat_members_count.py +69 -0
- pyrogram/methods/chats/get_chat_online_count.py +51 -0
- pyrogram/methods/chats/get_dialogs.py +104 -0
- pyrogram/methods/chats/get_dialogs_count.py +63 -0
- pyrogram/methods/chats/get_nearby_chats.py +78 -0
- pyrogram/methods/chats/get_send_as_chats.py +65 -0
- pyrogram/methods/chats/join_chat.py +74 -0
- pyrogram/methods/chats/leave_chat.py +77 -0
- pyrogram/methods/chats/mark_chat_unread.py +47 -0
- pyrogram/methods/chats/pin_chat_message.py +81 -0
- pyrogram/methods/chats/promote_chat_member.py +101 -0
- pyrogram/methods/chats/restrict_chat_member.py +99 -0
- pyrogram/methods/chats/set_administrator_title.py +85 -0
- pyrogram/methods/chats/set_chat_description.py +66 -0
- pyrogram/methods/chats/set_chat_permissions.py +87 -0
- pyrogram/methods/chats/set_chat_photo.py +121 -0
- pyrogram/methods/chats/set_chat_protected_content.py +53 -0
- pyrogram/methods/chats/set_chat_title.py +78 -0
- pyrogram/methods/chats/set_chat_username.py +68 -0
- pyrogram/methods/chats/set_send_as_chat.py +57 -0
- pyrogram/methods/chats/set_slow_mode.py +63 -0
- pyrogram/methods/chats/unarchive_chats.py +71 -0
- pyrogram/methods/chats/unban_chat_member.py +64 -0
- pyrogram/methods/chats/unpin_all_chat_messages.py +55 -0
- pyrogram/methods/chats/unpin_chat_message.py +61 -0
- pyrogram/methods/contacts/__init__.py +33 -0
- pyrogram/methods/contacts/add_contact.py +78 -0
- pyrogram/methods/contacts/delete_contacts.py +66 -0
- pyrogram/methods/contacts/get_contacts.py +47 -0
- pyrogram/methods/contacts/get_contacts_count.py +41 -0
- pyrogram/methods/contacts/import_contacts.py +58 -0
- pyrogram/methods/decorators/__init__.py +47 -0
- pyrogram/methods/decorators/on_callback_query.py +61 -0
- pyrogram/methods/decorators/on_chat_join_request.py +60 -0
- pyrogram/methods/decorators/on_chat_member_updated.py +60 -0
- pyrogram/methods/decorators/on_chosen_inline_result.py +61 -0
- pyrogram/methods/decorators/on_deleted_messages.py +61 -0
- pyrogram/methods/decorators/on_disconnect.py +43 -0
- pyrogram/methods/decorators/on_edited_message.py +61 -0
- pyrogram/methods/decorators/on_inline_query.py +61 -0
- pyrogram/methods/decorators/on_message.py +61 -0
- pyrogram/methods/decorators/on_poll.py +61 -0
- pyrogram/methods/decorators/on_raw_update.py +55 -0
- pyrogram/methods/decorators/on_user_status.py +59 -0
- pyrogram/methods/invite_links/__init__.py +58 -0
- pyrogram/methods/invite_links/approve_all_chat_join_requests.py +55 -0
- pyrogram/methods/invite_links/approve_chat_join_request.py +57 -0
- pyrogram/methods/invite_links/create_chat_invite_link.py +87 -0
- pyrogram/methods/invite_links/decline_all_chat_join_requests.py +55 -0
- pyrogram/methods/invite_links/decline_chat_join_request.py +57 -0
- pyrogram/methods/invite_links/delete_chat_admin_invite_links.py +54 -0
- pyrogram/methods/invite_links/delete_chat_invite_link.py +52 -0
- pyrogram/methods/invite_links/edit_chat_invite_link.py +92 -0
- pyrogram/methods/invite_links/export_chat_invite_link.py +65 -0
- pyrogram/methods/invite_links/get_chat_admin_invite_links.py +100 -0
- pyrogram/methods/invite_links/get_chat_admin_invite_links_count.py +62 -0
- pyrogram/methods/invite_links/get_chat_admins_with_invite_links.py +56 -0
- pyrogram/methods/invite_links/get_chat_invite_link.py +56 -0
- pyrogram/methods/invite_links/get_chat_invite_link_joiners.py +87 -0
- pyrogram/methods/invite_links/get_chat_invite_link_joiners_count.py +56 -0
- pyrogram/methods/invite_links/get_chat_join_requests.py +88 -0
- pyrogram/methods/invite_links/revoke_chat_invite_link.py +68 -0
- pyrogram/methods/messages/__init__.py +119 -0
- pyrogram/methods/messages/copy_media_group.py +140 -0
- pyrogram/methods/messages/copy_message.py +121 -0
- pyrogram/methods/messages/delete_messages.py +84 -0
- pyrogram/methods/messages/download_media.py +187 -0
- pyrogram/methods/messages/edit_inline_caption.py +65 -0
- pyrogram/methods/messages/edit_inline_media.py +244 -0
- pyrogram/methods/messages/edit_inline_reply_markup.py +69 -0
- pyrogram/methods/messages/edit_inline_text.py +88 -0
- pyrogram/methods/messages/edit_message_caption.py +76 -0
- pyrogram/methods/messages/edit_message_media.py +287 -0
- pyrogram/methods/messages/edit_message_reply_markup.py +77 -0
- pyrogram/methods/messages/edit_message_text.py +98 -0
- pyrogram/methods/messages/forward_messages.py +110 -0
- pyrogram/methods/messages/get_chat_history.py +121 -0
- pyrogram/methods/messages/get_chat_history_count.py +72 -0
- pyrogram/methods/messages/get_custom_emoji_stickers.py +55 -0
- pyrogram/methods/messages/get_discussion_message.py +65 -0
- pyrogram/methods/messages/get_discussion_replies.py +86 -0
- pyrogram/methods/messages/get_discussion_replies_count.py +62 -0
- pyrogram/methods/messages/get_media_group.py +73 -0
- pyrogram/methods/messages/get_messages.py +119 -0
- pyrogram/methods/messages/inline_session.py +64 -0
- pyrogram/methods/messages/read_chat_history.py +73 -0
- pyrogram/methods/messages/retract_vote.py +61 -0
- pyrogram/methods/messages/search_global.py +117 -0
- pyrogram/methods/messages/search_global_count.py +62 -0
- pyrogram/methods/messages/search_messages.py +151 -0
- pyrogram/methods/messages/search_messages_count.py +84 -0
- pyrogram/methods/messages/send_animation.py +271 -0
- pyrogram/methods/messages/send_audio.py +242 -0
- pyrogram/methods/messages/send_cached_media.py +124 -0
- pyrogram/methods/messages/send_chat_action.py +80 -0
- pyrogram/methods/messages/send_contact.py +121 -0
- pyrogram/methods/messages/send_dice.py +116 -0
- pyrogram/methods/messages/send_document.py +220 -0
- pyrogram/methods/messages/send_location.py +113 -0
- pyrogram/methods/messages/send_media_group.py +417 -0
- pyrogram/methods/messages/send_message.py +177 -0
- pyrogram/methods/messages/send_photo.py +204 -0
- pyrogram/methods/messages/send_poll.py +181 -0
- pyrogram/methods/messages/send_reaction.py +73 -0
- pyrogram/methods/messages/send_sticker.py +179 -0
- pyrogram/methods/messages/send_venue.py +137 -0
- pyrogram/methods/messages/send_video.py +261 -0
- pyrogram/methods/messages/send_video_note.py +203 -0
- pyrogram/methods/messages/send_voice.py +204 -0
- pyrogram/methods/messages/stop_poll.py +77 -0
- pyrogram/methods/messages/stream_media.py +106 -0
- pyrogram/methods/messages/vote_poll.py +69 -0
- pyrogram/methods/password/__init__.py +29 -0
- pyrogram/methods/password/change_cloud_password.py +82 -0
- pyrogram/methods/password/enable_cloud_password.py +88 -0
- pyrogram/methods/password/remove_cloud_password.py +64 -0
- pyrogram/methods/users/__init__.py +49 -0
- pyrogram/methods/users/block_user.py +54 -0
- pyrogram/methods/users/delete_profile_photos.py +63 -0
- pyrogram/methods/users/get_chat_photos.py +135 -0
- pyrogram/methods/users/get_chat_photos_count.py +74 -0
- pyrogram/methods/users/get_common_chats.py +67 -0
- pyrogram/methods/users/get_default_emoji_statuses.py +47 -0
- pyrogram/methods/users/get_me.py +49 -0
- pyrogram/methods/users/get_users.py +71 -0
- pyrogram/methods/users/set_emoji_status.py +58 -0
- pyrogram/methods/users/set_profile_photo.py +75 -0
- pyrogram/methods/users/set_username.py +57 -0
- pyrogram/methods/users/unblock_user.py +54 -0
- pyrogram/methods/users/update_profile.py +72 -0
- pyrogram/methods/utilities/__init__.py +39 -0
- pyrogram/methods/utilities/add_handler.py +67 -0
- pyrogram/methods/utilities/compose.py +78 -0
- pyrogram/methods/utilities/export_session_string.py +40 -0
- pyrogram/methods/utilities/idle.py +87 -0
- pyrogram/methods/utilities/remove_handler.py +63 -0
- pyrogram/methods/utilities/restart.py +72 -0
- pyrogram/methods/utilities/run.py +86 -0
- pyrogram/methods/utilities/start.py +76 -0
- pyrogram/methods/utilities/stop.py +69 -0
- pyrogram/methods/utilities/stop_transmission.py +43 -0
- pyrogram/mime_types.py +1881 -0
- pyrogram/parser/__init__.py +19 -0
- pyrogram/parser/html.py +243 -0
- pyrogram/parser/markdown.py +173 -0
- pyrogram/parser/parser.py +61 -0
- pyrogram/parser/utils.py +41 -0
- pyrogram/py.typed +0 -0
- pyrogram/raw/__init__.py +26 -0
- pyrogram/raw/all.py +1706 -0
- pyrogram/raw/base/__init__.py +310 -0
- pyrogram/raw/base/access_point_rule.py +53 -0
- pyrogram/raw/base/account/__init__.py +44 -0
- pyrogram/raw/base/account/authorization_form.py +63 -0
- pyrogram/raw/base/account/authorizations.py +63 -0
- pyrogram/raw/base/account/auto_download_settings.py +63 -0
- pyrogram/raw/base/account/auto_save_settings.py +63 -0
- pyrogram/raw/base/account/content_settings.py +63 -0
- pyrogram/raw/base/account/email_verified.py +64 -0
- pyrogram/raw/base/account/emoji_statuses.py +65 -0
- pyrogram/raw/base/account/password.py +63 -0
- pyrogram/raw/base/account/password_input_settings.py +53 -0
- pyrogram/raw/base/account/password_settings.py +63 -0
- pyrogram/raw/base/account/privacy_rules.py +64 -0
- pyrogram/raw/base/account/reset_password_result.py +65 -0
- pyrogram/raw/base/account/saved_ringtone.py +64 -0
- pyrogram/raw/base/account/saved_ringtones.py +64 -0
- pyrogram/raw/base/account/sent_email_code.py +63 -0
- pyrogram/raw/base/account/takeout.py +63 -0
- pyrogram/raw/base/account/themes.py +65 -0
- pyrogram/raw/base/account/tmp_password.py +63 -0
- pyrogram/raw/base/account/wall_papers.py +64 -0
- pyrogram/raw/base/account/web_authorizations.py +63 -0
- pyrogram/raw/base/account_days_ttl.py +63 -0
- pyrogram/raw/base/app_web_view_result.py +63 -0
- pyrogram/raw/base/attach_menu_bot.py +53 -0
- pyrogram/raw/base/attach_menu_bot_icon.py +53 -0
- pyrogram/raw/base/attach_menu_bot_icon_color.py +53 -0
- pyrogram/raw/base/attach_menu_bots.py +64 -0
- pyrogram/raw/base/attach_menu_bots_bot.py +63 -0
- pyrogram/raw/base/attach_menu_peer_type.py +57 -0
- pyrogram/raw/base/auth/__init__.py +32 -0
- pyrogram/raw/base/auth/authorization.py +70 -0
- pyrogram/raw/base/auth/code_type.py +57 -0
- pyrogram/raw/base/auth/exported_authorization.py +63 -0
- pyrogram/raw/base/auth/logged_out.py +63 -0
- pyrogram/raw/base/auth/login_token.py +66 -0
- pyrogram/raw/base/auth/password_recovery.py +63 -0
- pyrogram/raw/base/auth/sent_code.py +69 -0
- pyrogram/raw/base/auth/sent_code_type.py +61 -0
- pyrogram/raw/base/authorization.py +63 -0
- pyrogram/raw/base/auto_download_settings.py +53 -0
- pyrogram/raw/base/auto_save_exception.py +53 -0
- pyrogram/raw/base/auto_save_settings.py +53 -0
- pyrogram/raw/base/available_reaction.py +53 -0
- pyrogram/raw/base/bad_msg_notification.py +54 -0
- pyrogram/raw/base/bank_card_open_url.py +53 -0
- pyrogram/raw/base/base_theme.py +57 -0
- pyrogram/raw/base/bind_auth_key_inner.py +53 -0
- pyrogram/raw/base/bot_app.py +54 -0
- pyrogram/raw/base/bot_command.py +63 -0
- pyrogram/raw/base/bot_command_scope.py +59 -0
- pyrogram/raw/base/bot_info.py +53 -0
- pyrogram/raw/base/bot_inline_message.py +58 -0
- pyrogram/raw/base/bot_inline_result.py +54 -0
- pyrogram/raw/base/bot_menu_button.py +65 -0
- pyrogram/raw/base/bots/__init__.py +25 -0
- pyrogram/raw/base/bots/bot_info.py +63 -0
- pyrogram/raw/base/cdn_config.py +63 -0
- pyrogram/raw/base/cdn_public_key.py +53 -0
- pyrogram/raw/base/channel_admin_log_event.py +53 -0
- pyrogram/raw/base/channel_admin_log_event_action.py +95 -0
- pyrogram/raw/base/channel_admin_log_events_filter.py +53 -0
- pyrogram/raw/base/channel_location.py +54 -0
- pyrogram/raw/base/channel_messages_filter.py +54 -0
- pyrogram/raw/base/channel_participant.py +58 -0
- pyrogram/raw/base/channel_participants_filter.py +60 -0
- pyrogram/raw/base/channels/__init__.py +28 -0
- pyrogram/raw/base/channels/admin_log_results.py +63 -0
- pyrogram/raw/base/channels/channel_participant.py +63 -0
- pyrogram/raw/base/channels/channel_participants.py +64 -0
- pyrogram/raw/base/channels/send_as_peers.py +63 -0
- pyrogram/raw/base/chat.py +57 -0
- pyrogram/raw/base/chat_admin_rights.py +53 -0
- pyrogram/raw/base/chat_admin_with_invites.py +53 -0
- pyrogram/raw/base/chat_banned_rights.py +53 -0
- pyrogram/raw/base/chat_full.py +54 -0
- pyrogram/raw/base/chat_invite.py +65 -0
- pyrogram/raw/base/chat_invite_importer.py +53 -0
- pyrogram/raw/base/chat_onlines.py +63 -0
- pyrogram/raw/base/chat_participant.py +55 -0
- pyrogram/raw/base/chat_participants.py +54 -0
- pyrogram/raw/base/chat_photo.py +54 -0
- pyrogram/raw/base/chat_reactions.py +55 -0
- pyrogram/raw/base/chatlists/__init__.py +28 -0
- pyrogram/raw/base/chatlists/chatlist_invite.py +64 -0
- pyrogram/raw/base/chatlists/chatlist_updates.py +63 -0
- pyrogram/raw/base/chatlists/exported_chatlist_invite.py +63 -0
- pyrogram/raw/base/chatlists/exported_invites.py +63 -0
- pyrogram/raw/base/client_dh_inner_data.py +53 -0
- pyrogram/raw/base/code_settings.py +53 -0
- pyrogram/raw/base/config.py +63 -0
- pyrogram/raw/base/contact.py +53 -0
- pyrogram/raw/base/contact_status.py +63 -0
- pyrogram/raw/base/contacts/__init__.py +30 -0
- pyrogram/raw/base/contacts/blocked.py +64 -0
- pyrogram/raw/base/contacts/contacts.py +64 -0
- pyrogram/raw/base/contacts/found.py +63 -0
- pyrogram/raw/base/contacts/imported_contacts.py +63 -0
- pyrogram/raw/base/contacts/resolved_peer.py +64 -0
- pyrogram/raw/base/contacts/top_peers.py +65 -0
- pyrogram/raw/base/data_json.py +64 -0
- pyrogram/raw/base/dc_option.py +53 -0
- pyrogram/raw/base/default_history_ttl.py +63 -0
- pyrogram/raw/base/destroy_auth_key_res.py +65 -0
- pyrogram/raw/base/destroy_session_res.py +64 -0
- pyrogram/raw/base/dialog.py +54 -0
- pyrogram/raw/base/dialog_filter.py +65 -0
- pyrogram/raw/base/dialog_filter_suggested.py +63 -0
- pyrogram/raw/base/dialog_peer.py +64 -0
- pyrogram/raw/base/document.py +67 -0
- pyrogram/raw/base/document_attribute.py +60 -0
- pyrogram/raw/base/draft_message.py +54 -0
- pyrogram/raw/base/email_verification.py +55 -0
- pyrogram/raw/base/email_verify_purpose.py +55 -0
- pyrogram/raw/base/emoji_group.py +53 -0
- pyrogram/raw/base/emoji_keyword.py +54 -0
- pyrogram/raw/base/emoji_keywords_difference.py +64 -0
- pyrogram/raw/base/emoji_language.py +63 -0
- pyrogram/raw/base/emoji_list.py +66 -0
- pyrogram/raw/base/emoji_status.py +55 -0
- pyrogram/raw/base/emoji_url.py +63 -0
- pyrogram/raw/base/encrypted_chat.py +68 -0
- pyrogram/raw/base/encrypted_file.py +64 -0
- pyrogram/raw/base/encrypted_message.py +54 -0
- pyrogram/raw/base/exported_chat_invite.py +64 -0
- pyrogram/raw/base/exported_chatlist_invite.py +63 -0
- pyrogram/raw/base/exported_contact_token.py +63 -0
- pyrogram/raw/base/exported_message_link.py +63 -0
- pyrogram/raw/base/file_hash.py +65 -0
- pyrogram/raw/base/folder.py +53 -0
- pyrogram/raw/base/folder_peer.py +53 -0
- pyrogram/raw/base/forum_topic.py +54 -0
- pyrogram/raw/base/game.py +53 -0
- pyrogram/raw/base/geo_point.py +54 -0
- pyrogram/raw/base/global_privacy_settings.py +64 -0
- pyrogram/raw/base/group_call.py +54 -0
- pyrogram/raw/base/group_call_participant.py +53 -0
- pyrogram/raw/base/group_call_participant_video.py +53 -0
- pyrogram/raw/base/group_call_participant_video_source_group.py +53 -0
- pyrogram/raw/base/group_call_stream_channel.py +53 -0
- pyrogram/raw/base/help/__init__.py +41 -0
- pyrogram/raw/base/help/app_config.py +64 -0
- pyrogram/raw/base/help/app_update.py +64 -0
- pyrogram/raw/base/help/config_simple.py +53 -0
- pyrogram/raw/base/help/countries_list.py +64 -0
- pyrogram/raw/base/help/country.py +53 -0
- pyrogram/raw/base/help/country_code.py +53 -0
- pyrogram/raw/base/help/deep_link_info.py +64 -0
- pyrogram/raw/base/help/invite_text.py +63 -0
- pyrogram/raw/base/help/passport_config.py +64 -0
- pyrogram/raw/base/help/premium_promo.py +63 -0
- pyrogram/raw/base/help/promo_data.py +64 -0
- pyrogram/raw/base/help/recent_me_urls.py +63 -0
- pyrogram/raw/base/help/support.py +63 -0
- pyrogram/raw/base/help/support_name.py +63 -0
- pyrogram/raw/base/help/terms_of_service.py +53 -0
- pyrogram/raw/base/help/terms_of_service_update.py +64 -0
- pyrogram/raw/base/help/user_info.py +65 -0
- pyrogram/raw/base/high_score.py +53 -0
- pyrogram/raw/base/http_wait.py +53 -0
- pyrogram/raw/base/imported_contact.py +53 -0
- pyrogram/raw/base/inline_bot_switch_pm.py +53 -0
- pyrogram/raw/base/inline_bot_web_view.py +53 -0
- pyrogram/raw/base/inline_query_peer_type.py +58 -0
- pyrogram/raw/base/input_app_event.py +53 -0
- pyrogram/raw/base/input_bot_app.py +54 -0
- pyrogram/raw/base/input_bot_inline_message.py +59 -0
- pyrogram/raw/base/input_bot_inline_message_id.py +54 -0
- pyrogram/raw/base/input_bot_inline_result.py +56 -0
- pyrogram/raw/base/input_channel.py +55 -0
- pyrogram/raw/base/input_chat_photo.py +55 -0
- pyrogram/raw/base/input_chatlist.py +53 -0
- pyrogram/raw/base/input_check_password_srp.py +54 -0
- pyrogram/raw/base/input_client_proxy.py +53 -0
- pyrogram/raw/base/input_contact.py +53 -0
- pyrogram/raw/base/input_dialog_peer.py +54 -0
- pyrogram/raw/base/input_document.py +54 -0
- pyrogram/raw/base/input_encrypted_chat.py +53 -0
- pyrogram/raw/base/input_encrypted_file.py +56 -0
- pyrogram/raw/base/input_file.py +54 -0
- pyrogram/raw/base/input_file_location.py +62 -0
- pyrogram/raw/base/input_folder_peer.py +53 -0
- pyrogram/raw/base/input_game.py +54 -0
- pyrogram/raw/base/input_geo_point.py +54 -0
- pyrogram/raw/base/input_group_call.py +53 -0
- pyrogram/raw/base/input_invoice.py +54 -0
- pyrogram/raw/base/input_media.py +67 -0
- pyrogram/raw/base/input_message.py +56 -0
- pyrogram/raw/base/input_notify_peer.py +57 -0
- pyrogram/raw/base/input_payment_credentials.py +56 -0
- pyrogram/raw/base/input_peer.py +59 -0
- pyrogram/raw/base/input_peer_notify_settings.py +53 -0
- pyrogram/raw/base/input_phone_call.py +53 -0
- pyrogram/raw/base/input_photo.py +54 -0
- pyrogram/raw/base/input_privacy_key.py +61 -0
- pyrogram/raw/base/input_privacy_rule.py +60 -0
- pyrogram/raw/base/input_secure_file.py +54 -0
- pyrogram/raw/base/input_secure_value.py +53 -0
- pyrogram/raw/base/input_single_media.py +53 -0
- pyrogram/raw/base/input_sticker_set.py +62 -0
- pyrogram/raw/base/input_sticker_set_item.py +53 -0
- pyrogram/raw/base/input_stickered_media.py +54 -0
- pyrogram/raw/base/input_store_payment_purpose.py +54 -0
- pyrogram/raw/base/input_theme.py +54 -0
- pyrogram/raw/base/input_theme_settings.py +53 -0
- pyrogram/raw/base/input_user.py +56 -0
- pyrogram/raw/base/input_wall_paper.py +55 -0
- pyrogram/raw/base/input_web_document.py +53 -0
- pyrogram/raw/base/input_web_file_location.py +55 -0
- pyrogram/raw/base/invoice.py +53 -0
- pyrogram/raw/base/ip_port.py +54 -0
- pyrogram/raw/base/json_object_value.py +53 -0
- pyrogram/raw/base/json_value.py +58 -0
- pyrogram/raw/base/keyboard_button.py +68 -0
- pyrogram/raw/base/keyboard_button_row.py +53 -0
- pyrogram/raw/base/labeled_price.py +53 -0
- pyrogram/raw/base/lang_pack_difference.py +64 -0
- pyrogram/raw/base/lang_pack_language.py +64 -0
- pyrogram/raw/base/lang_pack_string.py +65 -0
- pyrogram/raw/base/mask_coords.py +53 -0
- pyrogram/raw/base/message.py +55 -0
- pyrogram/raw/base/message_action.py +91 -0
- pyrogram/raw/base/message_entity.py +73 -0
- pyrogram/raw/base/message_extended_media.py +54 -0
- pyrogram/raw/base/message_fwd_header.py +53 -0
- pyrogram/raw/base/message_interaction_counters.py +53 -0
- pyrogram/raw/base/message_media.py +77 -0
- pyrogram/raw/base/message_peer_reaction.py +53 -0
- pyrogram/raw/base/message_range.py +63 -0
- pyrogram/raw/base/message_reactions.py +53 -0
- pyrogram/raw/base/message_replies.py +53 -0
- pyrogram/raw/base/message_reply_header.py +53 -0
- pyrogram/raw/base/message_user_vote.py +55 -0
- pyrogram/raw/base/message_views.py +53 -0
- pyrogram/raw/base/messages/__init__.py +72 -0
- pyrogram/raw/base/messages/affected_found_messages.py +63 -0
- pyrogram/raw/base/messages/affected_history.py +68 -0
- pyrogram/raw/base/messages/affected_messages.py +66 -0
- pyrogram/raw/base/messages/all_stickers.py +66 -0
- pyrogram/raw/base/messages/archived_stickers.py +63 -0
- pyrogram/raw/base/messages/available_reactions.py +64 -0
- pyrogram/raw/base/messages/bot_app.py +63 -0
- pyrogram/raw/base/messages/bot_callback_answer.py +63 -0
- pyrogram/raw/base/messages/bot_results.py +63 -0
- pyrogram/raw/base/messages/chat_admins_with_invites.py +63 -0
- pyrogram/raw/base/messages/chat_full.py +64 -0
- pyrogram/raw/base/messages/chat_invite_importers.py +63 -0
- pyrogram/raw/base/messages/chats.py +70 -0
- pyrogram/raw/base/messages/checked_history_import_peer.py +63 -0
- pyrogram/raw/base/messages/dh_config.py +64 -0
- pyrogram/raw/base/messages/dialogs.py +65 -0
- pyrogram/raw/base/messages/discussion_message.py +63 -0
- pyrogram/raw/base/messages/emoji_groups.py +66 -0
- pyrogram/raw/base/messages/exported_chat_invite.py +65 -0
- pyrogram/raw/base/messages/exported_chat_invites.py +63 -0
- pyrogram/raw/base/messages/faved_stickers.py +64 -0
- pyrogram/raw/base/messages/featured_stickers.py +66 -0
- pyrogram/raw/base/messages/forum_topics.py +64 -0
- pyrogram/raw/base/messages/found_sticker_sets.py +64 -0
- pyrogram/raw/base/messages/high_scores.py +64 -0
- pyrogram/raw/base/messages/history_import.py +63 -0
- pyrogram/raw/base/messages/history_import_parsed.py +63 -0
- pyrogram/raw/base/messages/inactive_chats.py +63 -0
- pyrogram/raw/base/messages/message_edit_data.py +63 -0
- pyrogram/raw/base/messages/message_reactions_list.py +63 -0
- pyrogram/raw/base/messages/message_views.py +63 -0
- pyrogram/raw/base/messages/messages.py +78 -0
- pyrogram/raw/base/messages/peer_dialogs.py +64 -0
- pyrogram/raw/base/messages/peer_settings.py +63 -0
- pyrogram/raw/base/messages/reactions.py +65 -0
- pyrogram/raw/base/messages/recent_stickers.py +64 -0
- pyrogram/raw/base/messages/saved_gifs.py +64 -0
- pyrogram/raw/base/messages/search_counter.py +63 -0
- pyrogram/raw/base/messages/search_results_calendar.py +63 -0
- pyrogram/raw/base/messages/search_results_positions.py +63 -0
- pyrogram/raw/base/messages/sent_encrypted_message.py +66 -0
- pyrogram/raw/base/messages/sponsored_messages.py +64 -0
- pyrogram/raw/base/messages/sticker_set.py +71 -0
- pyrogram/raw/base/messages/sticker_set_install_result.py +64 -0
- pyrogram/raw/base/messages/stickers.py +64 -0
- pyrogram/raw/base/messages/transcribed_audio.py +63 -0
- pyrogram/raw/base/messages/translated_text.py +63 -0
- pyrogram/raw/base/messages/votes_list.py +63 -0
- pyrogram/raw/base/messages_filter.py +69 -0
- pyrogram/raw/base/msg_detailed_info.py +54 -0
- pyrogram/raw/base/msg_resend_req.py +54 -0
- pyrogram/raw/base/msgs_ack.py +53 -0
- pyrogram/raw/base/msgs_all_info.py +53 -0
- pyrogram/raw/base/msgs_state_info.py +53 -0
- pyrogram/raw/base/msgs_state_req.py +53 -0
- pyrogram/raw/base/nearest_dc.py +63 -0
- pyrogram/raw/base/new_session.py +53 -0
- pyrogram/raw/base/notification_sound.py +56 -0
- pyrogram/raw/base/notify_peer.py +57 -0
- pyrogram/raw/base/page.py +53 -0
- pyrogram/raw/base/page_block.py +81 -0
- pyrogram/raw/base/page_caption.py +53 -0
- pyrogram/raw/base/page_list_item.py +54 -0
- pyrogram/raw/base/page_list_ordered_item.py +54 -0
- pyrogram/raw/base/page_related_article.py +53 -0
- pyrogram/raw/base/page_table_cell.py +53 -0
- pyrogram/raw/base/page_table_row.py +53 -0
- pyrogram/raw/base/password_kdf_algo.py +54 -0
- pyrogram/raw/base/payment_charge.py +53 -0
- pyrogram/raw/base/payment_form_method.py +53 -0
- pyrogram/raw/base/payment_requested_info.py +53 -0
- pyrogram/raw/base/payment_saved_credentials.py +53 -0
- pyrogram/raw/base/payments/__init__.py +31 -0
- pyrogram/raw/base/payments/bank_card_data.py +63 -0
- pyrogram/raw/base/payments/exported_invoice.py +63 -0
- pyrogram/raw/base/payments/payment_form.py +63 -0
- pyrogram/raw/base/payments/payment_receipt.py +63 -0
- pyrogram/raw/base/payments/payment_result.py +64 -0
- pyrogram/raw/base/payments/saved_info.py +63 -0
- pyrogram/raw/base/payments/validated_requested_info.py +63 -0
- pyrogram/raw/base/peer.py +65 -0
- pyrogram/raw/base/peer_blocked.py +53 -0
- pyrogram/raw/base/peer_located.py +54 -0
- pyrogram/raw/base/peer_notify_settings.py +63 -0
- pyrogram/raw/base/peer_settings.py +53 -0
- pyrogram/raw/base/phone/__init__.py +31 -0
- pyrogram/raw/base/phone/exported_group_call_invite.py +63 -0
- pyrogram/raw/base/phone/group_call.py +63 -0
- pyrogram/raw/base/phone/group_call_stream_channels.py +63 -0
- pyrogram/raw/base/phone/group_call_stream_rtmp_url.py +63 -0
- pyrogram/raw/base/phone/group_participants.py +63 -0
- pyrogram/raw/base/phone/join_as_peers.py +63 -0
- pyrogram/raw/base/phone/phone_call.py +65 -0
- pyrogram/raw/base/phone_call.py +58 -0
- pyrogram/raw/base/phone_call_discard_reason.py +56 -0
- pyrogram/raw/base/phone_call_protocol.py +53 -0
- pyrogram/raw/base/phone_connection.py +54 -0
- pyrogram/raw/base/photo.py +54 -0
- pyrogram/raw/base/photo_size.py +58 -0
- pyrogram/raw/base/photos/__init__.py +26 -0
- pyrogram/raw/base/photos/photo.py +65 -0
- pyrogram/raw/base/photos/photos.py +64 -0
- pyrogram/raw/base/poll.py +53 -0
- pyrogram/raw/base/poll_answer.py +53 -0
- pyrogram/raw/base/poll_answer_voters.py +53 -0
- pyrogram/raw/base/poll_results.py +53 -0
- pyrogram/raw/base/pong.py +64 -0
- pyrogram/raw/base/popular_contact.py +53 -0
- pyrogram/raw/base/post_address.py +53 -0
- pyrogram/raw/base/pq_inner_data.py +56 -0
- pyrogram/raw/base/premium_gift_option.py +53 -0
- pyrogram/raw/base/premium_subscription_option.py +53 -0
- pyrogram/raw/base/privacy_key.py +61 -0
- pyrogram/raw/base/privacy_rule.py +60 -0
- pyrogram/raw/base/reaction.py +55 -0
- pyrogram/raw/base/reaction_count.py +53 -0
- pyrogram/raw/base/read_participant_date.py +63 -0
- pyrogram/raw/base/received_notify_message.py +63 -0
- pyrogram/raw/base/recent_me_url.py +57 -0
- pyrogram/raw/base/reply_markup.py +56 -0
- pyrogram/raw/base/report_reason.py +62 -0
- pyrogram/raw/base/request_peer_type.py +55 -0
- pyrogram/raw/base/res_pq.py +64 -0
- pyrogram/raw/base/restriction_reason.py +53 -0
- pyrogram/raw/base/rich_text.py +68 -0
- pyrogram/raw/base/rpc_drop_answer.py +65 -0
- pyrogram/raw/base/rpc_error.py +53 -0
- pyrogram/raw/base/rpc_result.py +53 -0
- pyrogram/raw/base/saved_contact.py +63 -0
- pyrogram/raw/base/search_results_calendar_period.py +53 -0
- pyrogram/raw/base/search_results_position.py +53 -0
- pyrogram/raw/base/secure_credentials_encrypted.py +53 -0
- pyrogram/raw/base/secure_data.py +53 -0
- pyrogram/raw/base/secure_file.py +54 -0
- pyrogram/raw/base/secure_password_kdf_algo.py +55 -0
- pyrogram/raw/base/secure_plain_data.py +54 -0
- pyrogram/raw/base/secure_required_type.py +54 -0
- pyrogram/raw/base/secure_secret_settings.py +53 -0
- pyrogram/raw/base/secure_value.py +65 -0
- pyrogram/raw/base/secure_value_error.py +61 -0
- pyrogram/raw/base/secure_value_hash.py +53 -0
- pyrogram/raw/base/secure_value_type.py +65 -0
- pyrogram/raw/base/send_as_peer.py +53 -0
- pyrogram/raw/base/send_message_action.py +70 -0
- pyrogram/raw/base/server_dh_inner_data.py +53 -0
- pyrogram/raw/base/server_dh_params.py +64 -0
- pyrogram/raw/base/set_client_dh_params_answer.py +65 -0
- pyrogram/raw/base/shipping_option.py +53 -0
- pyrogram/raw/base/simple_web_view_result.py +63 -0
- pyrogram/raw/base/sponsored_message.py +53 -0
- pyrogram/raw/base/stats/__init__.py +27 -0
- pyrogram/raw/base/stats/broadcast_stats.py +63 -0
- pyrogram/raw/base/stats/megagroup_stats.py +63 -0
- pyrogram/raw/base/stats/message_stats.py +63 -0
- pyrogram/raw/base/stats_abs_value_and_prev.py +53 -0
- pyrogram/raw/base/stats_date_range_days.py +53 -0
- pyrogram/raw/base/stats_graph.py +65 -0
- pyrogram/raw/base/stats_group_top_admin.py +53 -0
- pyrogram/raw/base/stats_group_top_inviter.py +53 -0
- pyrogram/raw/base/stats_group_top_poster.py +53 -0
- pyrogram/raw/base/stats_percent_value.py +53 -0
- pyrogram/raw/base/stats_url.py +53 -0
- pyrogram/raw/base/sticker_keyword.py +53 -0
- pyrogram/raw/base/sticker_pack.py +53 -0
- pyrogram/raw/base/sticker_set.py +53 -0
- pyrogram/raw/base/sticker_set_covered.py +66 -0
- pyrogram/raw/base/stickers/__init__.py +25 -0
- pyrogram/raw/base/stickers/suggested_short_name.py +63 -0
- pyrogram/raw/base/storage/__init__.py +25 -0
- pyrogram/raw/base/storage/file_type.py +62 -0
- pyrogram/raw/base/text_with_entities.py +53 -0
- pyrogram/raw/base/theme.py +65 -0
- pyrogram/raw/base/theme_settings.py +53 -0
- pyrogram/raw/base/top_peer.py +53 -0
- pyrogram/raw/base/top_peer_category.py +60 -0
- pyrogram/raw/base/top_peer_category_peers.py +53 -0
- pyrogram/raw/base/update.py +163 -0
- pyrogram/raw/base/updates/__init__.py +27 -0
- pyrogram/raw/base/updates/channel_difference.py +65 -0
- pyrogram/raw/base/updates/difference.py +66 -0
- pyrogram/raw/base/updates/state.py +63 -0
- pyrogram/raw/base/updates_t.py +155 -0
- pyrogram/raw/base/upload/__init__.py +27 -0
- pyrogram/raw/base/upload/cdn_file.py +64 -0
- pyrogram/raw/base/upload/file.py +64 -0
- pyrogram/raw/base/upload/web_file.py +63 -0
- pyrogram/raw/base/url_auth_result.py +66 -0
- pyrogram/raw/base/user.py +68 -0
- pyrogram/raw/base/user_full.py +53 -0
- pyrogram/raw/base/user_profile_photo.py +54 -0
- pyrogram/raw/base/user_status.py +58 -0
- pyrogram/raw/base/username.py +53 -0
- pyrogram/raw/base/users/__init__.py +25 -0
- pyrogram/raw/base/users/user_full.py +63 -0
- pyrogram/raw/base/video_size.py +55 -0
- pyrogram/raw/base/wall_paper.py +66 -0
- pyrogram/raw/base/wall_paper_settings.py +53 -0
- pyrogram/raw/base/web_authorization.py +53 -0
- pyrogram/raw/base/web_document.py +54 -0
- pyrogram/raw/base/web_page.py +66 -0
- pyrogram/raw/base/web_page_attribute.py +53 -0
- pyrogram/raw/base/web_view_message_sent.py +63 -0
- pyrogram/raw/base/web_view_result.py +63 -0
- pyrogram/raw/core/__init__.py +31 -0
- pyrogram/raw/core/future_salt.py +53 -0
- pyrogram/raw/core/future_salts.py +63 -0
- pyrogram/raw/core/gzip_packed.py +62 -0
- pyrogram/raw/core/list.py +26 -0
- pyrogram/raw/core/message.py +56 -0
- pyrogram/raw/core/msg_container.py +53 -0
- pyrogram/raw/core/primitives/__init__.py +24 -0
- pyrogram/raw/core/primitives/bool.py +48 -0
- pyrogram/raw/core/primitives/bytes.py +55 -0
- pyrogram/raw/core/primitives/double.py +32 -0
- pyrogram/raw/core/primitives/int.py +45 -0
- pyrogram/raw/core/primitives/string.py +31 -0
- pyrogram/raw/core/primitives/vector.py +59 -0
- pyrogram/raw/core/tl_object.py +82 -0
- pyrogram/raw/functions/__init__.py +42 -0
- pyrogram/raw/functions/account/__init__.py +111 -0
- pyrogram/raw/functions/account/accept_authorization.py +104 -0
- pyrogram/raw/functions/account/cancel_password_email.py +67 -0
- pyrogram/raw/functions/account/change_authorization_settings.py +92 -0
- pyrogram/raw/functions/account/change_phone.py +88 -0
- pyrogram/raw/functions/account/check_username.py +72 -0
- pyrogram/raw/functions/account/clear_recent_emoji_statuses.py +67 -0
- pyrogram/raw/functions/account/confirm_password_email.py +72 -0
- pyrogram/raw/functions/account/confirm_phone.py +80 -0
- pyrogram/raw/functions/account/create_theme.py +102 -0
- pyrogram/raw/functions/account/decline_password_reset.py +67 -0
- pyrogram/raw/functions/account/delete_account.py +84 -0
- pyrogram/raw/functions/account/delete_auto_save_exceptions.py +67 -0
- pyrogram/raw/functions/account/delete_secure_value.py +72 -0
- pyrogram/raw/functions/account/finish_takeout_session.py +72 -0
- pyrogram/raw/functions/account/get_account_ttl.py +67 -0
- pyrogram/raw/functions/account/get_all_secure_values.py +67 -0
- pyrogram/raw/functions/account/get_authorization_form.py +88 -0
- pyrogram/raw/functions/account/get_authorizations.py +67 -0
- pyrogram/raw/functions/account/get_auto_download_settings.py +67 -0
- pyrogram/raw/functions/account/get_auto_save_settings.py +67 -0
- pyrogram/raw/functions/account/get_chat_themes.py +72 -0
- pyrogram/raw/functions/account/get_contact_sign_up_notification.py +67 -0
- pyrogram/raw/functions/account/get_content_settings.py +67 -0
- pyrogram/raw/functions/account/get_default_emoji_statuses.py +72 -0
- pyrogram/raw/functions/account/get_default_group_photo_emojis.py +72 -0
- pyrogram/raw/functions/account/get_default_profile_photo_emojis.py +72 -0
- pyrogram/raw/functions/account/get_global_privacy_settings.py +67 -0
- pyrogram/raw/functions/account/get_multi_wall_papers.py +72 -0
- pyrogram/raw/functions/account/get_notify_exceptions.py +82 -0
- pyrogram/raw/functions/account/get_notify_settings.py +72 -0
- pyrogram/raw/functions/account/get_password.py +67 -0
- pyrogram/raw/functions/account/get_password_settings.py +72 -0
- pyrogram/raw/functions/account/get_privacy.py +72 -0
- pyrogram/raw/functions/account/get_recent_emoji_statuses.py +72 -0
- pyrogram/raw/functions/account/get_saved_ringtones.py +72 -0
- pyrogram/raw/functions/account/get_secure_value.py +72 -0
- pyrogram/raw/functions/account/get_theme.py +80 -0
- pyrogram/raw/functions/account/get_themes.py +80 -0
- pyrogram/raw/functions/account/get_tmp_password.py +80 -0
- pyrogram/raw/functions/account/get_wall_paper.py +72 -0
- pyrogram/raw/functions/account/get_wall_papers.py +72 -0
- pyrogram/raw/functions/account/get_web_authorizations.py +67 -0
- pyrogram/raw/functions/account/init_takeout_session.py +111 -0
- pyrogram/raw/functions/account/install_theme.py +101 -0
- pyrogram/raw/functions/account/install_wall_paper.py +80 -0
- pyrogram/raw/functions/account/register_device.py +112 -0
- pyrogram/raw/functions/account/reorder_usernames.py +72 -0
- pyrogram/raw/functions/account/report_peer.py +88 -0
- pyrogram/raw/functions/account/report_profile_photo.py +96 -0
- pyrogram/raw/functions/account/resend_password_email.py +67 -0
- pyrogram/raw/functions/account/reset_authorization.py +72 -0
- pyrogram/raw/functions/account/reset_notify_settings.py +67 -0
- pyrogram/raw/functions/account/reset_password.py +67 -0
- pyrogram/raw/functions/account/reset_wall_papers.py +67 -0
- pyrogram/raw/functions/account/reset_web_authorization.py +72 -0
- pyrogram/raw/functions/account/reset_web_authorizations.py +67 -0
- pyrogram/raw/functions/account/save_auto_download_settings.py +86 -0
- pyrogram/raw/functions/account/save_auto_save_settings.py +102 -0
- pyrogram/raw/functions/account/save_ringtone.py +80 -0
- pyrogram/raw/functions/account/save_secure_value.py +80 -0
- pyrogram/raw/functions/account/save_theme.py +80 -0
- pyrogram/raw/functions/account/save_wall_paper.py +88 -0
- pyrogram/raw/functions/account/send_change_phone_code.py +80 -0
- pyrogram/raw/functions/account/send_confirm_phone_code.py +80 -0
- pyrogram/raw/functions/account/send_verify_email_code.py +80 -0
- pyrogram/raw/functions/account/send_verify_phone_code.py +80 -0
- pyrogram/raw/functions/account/set_account_ttl.py +72 -0
- pyrogram/raw/functions/account/set_authorization_ttl.py +72 -0
- pyrogram/raw/functions/account/set_contact_sign_up_notification.py +72 -0
- pyrogram/raw/functions/account/set_content_settings.py +72 -0
- pyrogram/raw/functions/account/set_global_privacy_settings.py +72 -0
- pyrogram/raw/functions/account/set_privacy.py +80 -0
- pyrogram/raw/functions/account/toggle_username.py +80 -0
- pyrogram/raw/functions/account/unregister_device.py +88 -0
- pyrogram/raw/functions/account/update_device_locked.py +72 -0
- pyrogram/raw/functions/account/update_emoji_status.py +72 -0
- pyrogram/raw/functions/account/update_notify_settings.py +80 -0
- pyrogram/raw/functions/account/update_password_settings.py +80 -0
- pyrogram/raw/functions/account/update_profile.py +93 -0
- pyrogram/raw/functions/account/update_status.py +72 -0
- pyrogram/raw/functions/account/update_theme.py +120 -0
- pyrogram/raw/functions/account/update_username.py +72 -0
- pyrogram/raw/functions/account/upload_ringtone.py +88 -0
- pyrogram/raw/functions/account/upload_theme.py +100 -0
- pyrogram/raw/functions/account/upload_wall_paper.py +96 -0
- pyrogram/raw/functions/account/verify_email.py +80 -0
- pyrogram/raw/functions/account/verify_phone.py +88 -0
- pyrogram/raw/functions/auth/__init__.py +46 -0
- pyrogram/raw/functions/auth/accept_login_token.py +72 -0
- pyrogram/raw/functions/auth/bind_temp_auth_key.py +96 -0
- pyrogram/raw/functions/auth/cancel_code.py +80 -0
- pyrogram/raw/functions/auth/check_password.py +72 -0
- pyrogram/raw/functions/auth/check_recovery_password.py +72 -0
- pyrogram/raw/functions/auth/drop_temp_auth_keys.py +72 -0
- pyrogram/raw/functions/auth/export_authorization.py +72 -0
- pyrogram/raw/functions/auth/export_login_token.py +88 -0
- pyrogram/raw/functions/auth/import_authorization.py +80 -0
- pyrogram/raw/functions/auth/import_bot_authorization.py +96 -0
- pyrogram/raw/functions/auth/import_login_token.py +72 -0
- pyrogram/raw/functions/auth/import_web_token_authorization.py +88 -0
- pyrogram/raw/functions/auth/log_out.py +67 -0
- pyrogram/raw/functions/auth/recover_password.py +84 -0
- pyrogram/raw/functions/auth/request_firebase_sms.py +100 -0
- pyrogram/raw/functions/auth/request_password_recovery.py +67 -0
- pyrogram/raw/functions/auth/resend_code.py +80 -0
- pyrogram/raw/functions/auth/reset_authorizations.py +67 -0
- pyrogram/raw/functions/auth/reset_login_email.py +80 -0
- pyrogram/raw/functions/auth/send_code.py +96 -0
- pyrogram/raw/functions/auth/sign_in.py +101 -0
- pyrogram/raw/functions/auth/sign_up.py +96 -0
- pyrogram/raw/functions/bots/__init__.py +37 -0
- pyrogram/raw/functions/bots/answer_webhook_json_query.py +80 -0
- pyrogram/raw/functions/bots/get_bot_commands.py +80 -0
- pyrogram/raw/functions/bots/get_bot_info.py +84 -0
- pyrogram/raw/functions/bots/get_bot_menu_button.py +72 -0
- pyrogram/raw/functions/bots/reorder_usernames.py +80 -0
- pyrogram/raw/functions/bots/reset_bot_commands.py +80 -0
- pyrogram/raw/functions/bots/send_custom_request.py +80 -0
- pyrogram/raw/functions/bots/set_bot_broadcast_default_admin_rights.py +72 -0
- pyrogram/raw/functions/bots/set_bot_commands.py +88 -0
- pyrogram/raw/functions/bots/set_bot_group_default_admin_rights.py +72 -0
- pyrogram/raw/functions/bots/set_bot_info.py +111 -0
- pyrogram/raw/functions/bots/set_bot_menu_button.py +80 -0
- pyrogram/raw/functions/bots/toggle_username.py +88 -0
- pyrogram/raw/functions/channels/__init__.py +79 -0
- pyrogram/raw/functions/channels/check_username.py +80 -0
- pyrogram/raw/functions/channels/convert_to_gigagroup.py +72 -0
- pyrogram/raw/functions/channels/create_channel.py +134 -0
- pyrogram/raw/functions/channels/create_forum_topic.py +118 -0
- pyrogram/raw/functions/channels/deactivate_all_usernames.py +72 -0
- pyrogram/raw/functions/channels/delete_channel.py +72 -0
- pyrogram/raw/functions/channels/delete_history.py +88 -0
- pyrogram/raw/functions/channels/delete_messages.py +80 -0
- pyrogram/raw/functions/channels/delete_participant_history.py +80 -0
- pyrogram/raw/functions/channels/delete_topic_history.py +80 -0
- pyrogram/raw/functions/channels/edit_admin.py +96 -0
- pyrogram/raw/functions/channels/edit_banned.py +88 -0
- pyrogram/raw/functions/channels/edit_creator.py +88 -0
- pyrogram/raw/functions/channels/edit_forum_topic.py +118 -0
- pyrogram/raw/functions/channels/edit_location.py +88 -0
- pyrogram/raw/functions/channels/edit_photo.py +80 -0
- pyrogram/raw/functions/channels/edit_title.py +80 -0
- pyrogram/raw/functions/channels/export_message_link.py +94 -0
- pyrogram/raw/functions/channels/get_admin_log.py +126 -0
- pyrogram/raw/functions/channels/get_admined_public_channels.py +78 -0
- pyrogram/raw/functions/channels/get_channels.py +72 -0
- pyrogram/raw/functions/channels/get_forum_topics.py +115 -0
- pyrogram/raw/functions/channels/get_forum_topics_by_id.py +80 -0
- pyrogram/raw/functions/channels/get_full_channel.py +72 -0
- pyrogram/raw/functions/channels/get_groups_for_discussion.py +67 -0
- pyrogram/raw/functions/channels/get_inactive_channels.py +67 -0
- pyrogram/raw/functions/channels/get_left_channels.py +72 -0
- pyrogram/raw/functions/channels/get_messages.py +80 -0
- pyrogram/raw/functions/channels/get_participant.py +80 -0
- pyrogram/raw/functions/channels/get_participants.py +104 -0
- pyrogram/raw/functions/channels/get_send_as.py +72 -0
- pyrogram/raw/functions/channels/get_sponsored_messages.py +72 -0
- pyrogram/raw/functions/channels/invite_to_channel.py +80 -0
- pyrogram/raw/functions/channels/join_channel.py +72 -0
- pyrogram/raw/functions/channels/leave_channel.py +72 -0
- pyrogram/raw/functions/channels/read_history.py +80 -0
- pyrogram/raw/functions/channels/read_message_contents.py +80 -0
- pyrogram/raw/functions/channels/reorder_pinned_forum_topics.py +88 -0
- pyrogram/raw/functions/channels/reorder_usernames.py +80 -0
- pyrogram/raw/functions/channels/report_anti_spam_false_positive.py +80 -0
- pyrogram/raw/functions/channels/report_spam.py +88 -0
- pyrogram/raw/functions/channels/set_discussion_group.py +80 -0
- pyrogram/raw/functions/channels/set_stickers.py +80 -0
- pyrogram/raw/functions/channels/toggle_anti_spam.py +80 -0
- pyrogram/raw/functions/channels/toggle_forum.py +80 -0
- pyrogram/raw/functions/channels/toggle_join_request.py +80 -0
- pyrogram/raw/functions/channels/toggle_join_to_send.py +80 -0
- pyrogram/raw/functions/channels/toggle_participants_hidden.py +80 -0
- pyrogram/raw/functions/channels/toggle_pre_history_hidden.py +80 -0
- pyrogram/raw/functions/channels/toggle_signatures.py +80 -0
- pyrogram/raw/functions/channels/toggle_slow_mode.py +80 -0
- pyrogram/raw/functions/channels/toggle_username.py +88 -0
- pyrogram/raw/functions/channels/update_pinned_forum_topic.py +88 -0
- pyrogram/raw/functions/channels/update_username.py +80 -0
- pyrogram/raw/functions/channels/view_sponsored_message.py +80 -0
- pyrogram/raw/functions/chatlists/__init__.py +35 -0
- pyrogram/raw/functions/chatlists/check_chatlist_invite.py +72 -0
- pyrogram/raw/functions/chatlists/delete_exported_invite.py +80 -0
- pyrogram/raw/functions/chatlists/edit_exported_invite.py +101 -0
- pyrogram/raw/functions/chatlists/export_chatlist_invite.py +88 -0
- pyrogram/raw/functions/chatlists/get_chatlist_updates.py +72 -0
- pyrogram/raw/functions/chatlists/get_exported_invites.py +72 -0
- pyrogram/raw/functions/chatlists/get_leave_chatlist_suggestions.py +72 -0
- pyrogram/raw/functions/chatlists/hide_chatlist_updates.py +72 -0
- pyrogram/raw/functions/chatlists/join_chatlist_invite.py +80 -0
- pyrogram/raw/functions/chatlists/join_chatlist_updates.py +80 -0
- pyrogram/raw/functions/chatlists/leave_chatlist.py +80 -0
- pyrogram/raw/functions/contacts/__init__.py +47 -0
- pyrogram/raw/functions/contacts/accept_contact.py +72 -0
- pyrogram/raw/functions/contacts/add_contact.py +104 -0
- pyrogram/raw/functions/contacts/block.py +72 -0
- pyrogram/raw/functions/contacts/block_from_replies.py +92 -0
- pyrogram/raw/functions/contacts/delete_by_phones.py +72 -0
- pyrogram/raw/functions/contacts/delete_contacts.py +72 -0
- pyrogram/raw/functions/contacts/export_contact_token.py +67 -0
- pyrogram/raw/functions/contacts/get_blocked.py +80 -0
- pyrogram/raw/functions/contacts/get_contact_i_ds.py +72 -0
- pyrogram/raw/functions/contacts/get_contacts.py +72 -0
- pyrogram/raw/functions/contacts/get_located.py +89 -0
- pyrogram/raw/functions/contacts/get_saved.py +67 -0
- pyrogram/raw/functions/contacts/get_statuses.py +67 -0
- pyrogram/raw/functions/contacts/get_top_peers.py +138 -0
- pyrogram/raw/functions/contacts/import_contact_token.py +72 -0
- pyrogram/raw/functions/contacts/import_contacts.py +72 -0
- pyrogram/raw/functions/contacts/reset_saved.py +67 -0
- pyrogram/raw/functions/contacts/reset_top_peer_rating.py +80 -0
- pyrogram/raw/functions/contacts/resolve_phone.py +72 -0
- pyrogram/raw/functions/contacts/resolve_username.py +72 -0
- pyrogram/raw/functions/contacts/search.py +80 -0
- pyrogram/raw/functions/contacts/toggle_top_peers.py +72 -0
- pyrogram/raw/functions/contacts/unblock.py +72 -0
- pyrogram/raw/functions/contest/__init__.py +25 -0
- pyrogram/raw/functions/contest/save_developer_info.py +104 -0
- pyrogram/raw/functions/destroy_auth_key.py +67 -0
- pyrogram/raw/functions/destroy_session.py +72 -0
- pyrogram/raw/functions/folders/__init__.py +25 -0
- pyrogram/raw/functions/folders/edit_peer_folders.py +72 -0
- pyrogram/raw/functions/get_future_salts.py +72 -0
- pyrogram/raw/functions/help/__init__.py +47 -0
- pyrogram/raw/functions/help/accept_terms_of_service.py +72 -0
- pyrogram/raw/functions/help/dismiss_suggestion.py +80 -0
- pyrogram/raw/functions/help/edit_user_info.py +88 -0
- pyrogram/raw/functions/help/get_app_changelog.py +72 -0
- pyrogram/raw/functions/help/get_app_config.py +72 -0
- pyrogram/raw/functions/help/get_app_update.py +72 -0
- pyrogram/raw/functions/help/get_cdn_config.py +67 -0
- pyrogram/raw/functions/help/get_config.py +67 -0
- pyrogram/raw/functions/help/get_countries_list.py +80 -0
- pyrogram/raw/functions/help/get_deep_link_info.py +72 -0
- pyrogram/raw/functions/help/get_invite_text.py +67 -0
- pyrogram/raw/functions/help/get_nearest_dc.py +67 -0
- pyrogram/raw/functions/help/get_passport_config.py +72 -0
- pyrogram/raw/functions/help/get_premium_promo.py +67 -0
- pyrogram/raw/functions/help/get_promo_data.py +67 -0
- pyrogram/raw/functions/help/get_recent_me_urls.py +72 -0
- pyrogram/raw/functions/help/get_support.py +67 -0
- pyrogram/raw/functions/help/get_support_name.py +67 -0
- pyrogram/raw/functions/help/get_terms_of_service_update.py +67 -0
- pyrogram/raw/functions/help/get_user_info.py +72 -0
- pyrogram/raw/functions/help/hide_promo_data.py +72 -0
- pyrogram/raw/functions/help/save_app_log.py +72 -0
- pyrogram/raw/functions/help/set_bot_updates_status.py +80 -0
- pyrogram/raw/functions/init_connection.py +150 -0
- pyrogram/raw/functions/invoke_after_msg.py +80 -0
- pyrogram/raw/functions/invoke_after_msgs.py +80 -0
- pyrogram/raw/functions/invoke_with_layer.py +80 -0
- pyrogram/raw/functions/invoke_with_messages_range.py +80 -0
- pyrogram/raw/functions/invoke_with_takeout.py +80 -0
- pyrogram/raw/functions/invoke_without_updates.py +72 -0
- pyrogram/raw/functions/langpack/__init__.py +29 -0
- pyrogram/raw/functions/langpack/get_difference.py +88 -0
- pyrogram/raw/functions/langpack/get_lang_pack.py +80 -0
- pyrogram/raw/functions/langpack/get_language.py +80 -0
- pyrogram/raw/functions/langpack/get_languages.py +72 -0
- pyrogram/raw/functions/langpack/get_strings.py +88 -0
- pyrogram/raw/functions/messages/__init__.py +212 -0
- pyrogram/raw/functions/messages/accept_encryption.py +88 -0
- pyrogram/raw/functions/messages/accept_url_auth.py +109 -0
- pyrogram/raw/functions/messages/add_chat_user.py +88 -0
- pyrogram/raw/functions/messages/check_chat_invite.py +72 -0
- pyrogram/raw/functions/messages/check_history_import.py +72 -0
- pyrogram/raw/functions/messages/check_history_import_peer.py +72 -0
- pyrogram/raw/functions/messages/clear_all_drafts.py +67 -0
- pyrogram/raw/functions/messages/clear_recent_reactions.py +67 -0
- pyrogram/raw/functions/messages/clear_recent_stickers.py +72 -0
- pyrogram/raw/functions/messages/create_chat.py +91 -0
- pyrogram/raw/functions/messages/delete_chat.py +72 -0
- pyrogram/raw/functions/messages/delete_chat_user.py +88 -0
- pyrogram/raw/functions/messages/delete_exported_chat_invite.py +80 -0
- pyrogram/raw/functions/messages/delete_history.py +112 -0
- pyrogram/raw/functions/messages/delete_messages.py +80 -0
- pyrogram/raw/functions/messages/delete_phone_call_history.py +72 -0
- pyrogram/raw/functions/messages/delete_revoked_exported_chat_invites.py +80 -0
- pyrogram/raw/functions/messages/delete_scheduled_messages.py +80 -0
- pyrogram/raw/functions/messages/discard_encryption.py +80 -0
- pyrogram/raw/functions/messages/edit_chat_about.py +80 -0
- pyrogram/raw/functions/messages/edit_chat_admin.py +88 -0
- pyrogram/raw/functions/messages/edit_chat_default_banned_rights.py +80 -0
- pyrogram/raw/functions/messages/edit_chat_photo.py +80 -0
- pyrogram/raw/functions/messages/edit_chat_title.py +80 -0
- pyrogram/raw/functions/messages/edit_exported_chat_invite.py +124 -0
- pyrogram/raw/functions/messages/edit_inline_bot_message.py +119 -0
- pyrogram/raw/functions/messages/edit_message.py +136 -0
- pyrogram/raw/functions/messages/export_chat_invite.py +113 -0
- pyrogram/raw/functions/messages/fave_sticker.py +80 -0
- pyrogram/raw/functions/messages/forward_messages.py +162 -0
- pyrogram/raw/functions/messages/get_admins_with_invites.py +72 -0
- pyrogram/raw/functions/messages/get_all_chats.py +72 -0
- pyrogram/raw/functions/messages/get_all_drafts.py +67 -0
- pyrogram/raw/functions/messages/get_all_stickers.py +72 -0
- pyrogram/raw/functions/messages/get_archived_stickers.py +94 -0
- pyrogram/raw/functions/messages/get_attach_menu_bot.py +72 -0
- pyrogram/raw/functions/messages/get_attach_menu_bots.py +72 -0
- pyrogram/raw/functions/messages/get_attached_stickers.py +72 -0
- pyrogram/raw/functions/messages/get_available_reactions.py +72 -0
- pyrogram/raw/functions/messages/get_bot_app.py +80 -0
- pyrogram/raw/functions/messages/get_bot_callback_answer.py +107 -0
- pyrogram/raw/functions/messages/get_chat_invite_importers.py +122 -0
- pyrogram/raw/functions/messages/get_chats.py +72 -0
- pyrogram/raw/functions/messages/get_common_chats.py +88 -0
- pyrogram/raw/functions/messages/get_custom_emoji_documents.py +72 -0
- pyrogram/raw/functions/messages/get_default_history_ttl.py +67 -0
- pyrogram/raw/functions/messages/get_dh_config.py +80 -0
- pyrogram/raw/functions/messages/get_dialog_filters.py +67 -0
- pyrogram/raw/functions/messages/get_dialog_unread_marks.py +67 -0
- pyrogram/raw/functions/messages/get_dialogs.py +121 -0
- pyrogram/raw/functions/messages/get_discussion_message.py +80 -0
- pyrogram/raw/functions/messages/get_document_by_hash.py +88 -0
- pyrogram/raw/functions/messages/get_emoji_groups.py +72 -0
- pyrogram/raw/functions/messages/get_emoji_keywords.py +72 -0
- pyrogram/raw/functions/messages/get_emoji_keywords_difference.py +80 -0
- pyrogram/raw/functions/messages/get_emoji_keywords_languages.py +72 -0
- pyrogram/raw/functions/messages/get_emoji_profile_photo_groups.py +72 -0
- pyrogram/raw/functions/messages/get_emoji_status_groups.py +72 -0
- pyrogram/raw/functions/messages/get_emoji_stickers.py +72 -0
- pyrogram/raw/functions/messages/get_emoji_url.py +72 -0
- pyrogram/raw/functions/messages/get_exported_chat_invite.py +80 -0
- pyrogram/raw/functions/messages/get_exported_chat_invites.py +114 -0
- pyrogram/raw/functions/messages/get_extended_media.py +80 -0
- pyrogram/raw/functions/messages/get_faved_stickers.py +72 -0
- pyrogram/raw/functions/messages/get_featured_emoji_stickers.py +72 -0
- pyrogram/raw/functions/messages/get_featured_stickers.py +72 -0
- pyrogram/raw/functions/messages/get_full_chat.py +72 -0
- pyrogram/raw/functions/messages/get_game_high_scores.py +88 -0
- pyrogram/raw/functions/messages/get_history.py +128 -0
- pyrogram/raw/functions/messages/get_inline_bot_results.py +108 -0
- pyrogram/raw/functions/messages/get_inline_game_high_scores.py +80 -0
- pyrogram/raw/functions/messages/get_mask_stickers.py +72 -0
- pyrogram/raw/functions/messages/get_message_edit_data.py +80 -0
- pyrogram/raw/functions/messages/get_message_reactions_list.py +109 -0
- pyrogram/raw/functions/messages/get_message_read_participants.py +80 -0
- pyrogram/raw/functions/messages/get_messages.py +72 -0
- pyrogram/raw/functions/messages/get_messages_reactions.py +80 -0
- pyrogram/raw/functions/messages/get_messages_views.py +88 -0
- pyrogram/raw/functions/messages/get_old_featured_stickers.py +88 -0
- pyrogram/raw/functions/messages/get_onlines.py +72 -0
- pyrogram/raw/functions/messages/get_peer_dialogs.py +72 -0
- pyrogram/raw/functions/messages/get_peer_settings.py +72 -0
- pyrogram/raw/functions/messages/get_pinned_dialogs.py +72 -0
- pyrogram/raw/functions/messages/get_poll_results.py +80 -0
- pyrogram/raw/functions/messages/get_poll_votes.py +108 -0
- pyrogram/raw/functions/messages/get_recent_locations.py +88 -0
- pyrogram/raw/functions/messages/get_recent_reactions.py +80 -0
- pyrogram/raw/functions/messages/get_recent_stickers.py +80 -0
- pyrogram/raw/functions/messages/get_replies.py +136 -0
- pyrogram/raw/functions/messages/get_saved_gifs.py +72 -0
- pyrogram/raw/functions/messages/get_scheduled_history.py +80 -0
- pyrogram/raw/functions/messages/get_scheduled_messages.py +80 -0
- pyrogram/raw/functions/messages/get_search_counters.py +91 -0
- pyrogram/raw/functions/messages/get_search_results_calendar.py +96 -0
- pyrogram/raw/functions/messages/get_search_results_positions.py +96 -0
- pyrogram/raw/functions/messages/get_split_ranges.py +67 -0
- pyrogram/raw/functions/messages/get_sticker_set.py +80 -0
- pyrogram/raw/functions/messages/get_stickers.py +80 -0
- pyrogram/raw/functions/messages/get_suggested_dialog_filters.py +67 -0
- pyrogram/raw/functions/messages/get_top_reactions.py +80 -0
- pyrogram/raw/functions/messages/get_unread_mentions.py +123 -0
- pyrogram/raw/functions/messages/get_unread_reactions.py +123 -0
- pyrogram/raw/functions/messages/get_web_page.py +80 -0
- pyrogram/raw/functions/messages/get_web_page_preview.py +84 -0
- pyrogram/raw/functions/messages/hide_all_chat_join_requests.py +89 -0
- pyrogram/raw/functions/messages/hide_chat_join_request.py +88 -0
- pyrogram/raw/functions/messages/hide_peer_settings_bar.py +72 -0
- pyrogram/raw/functions/messages/import_chat_invite.py +72 -0
- pyrogram/raw/functions/messages/init_history_import.py +88 -0
- pyrogram/raw/functions/messages/install_sticker_set.py +80 -0
- pyrogram/raw/functions/messages/mark_dialog_unread.py +80 -0
- pyrogram/raw/functions/messages/migrate_chat.py +72 -0
- pyrogram/raw/functions/messages/prolong_web_view.py +124 -0
- pyrogram/raw/functions/messages/rate_transcribed_audio.py +96 -0
- pyrogram/raw/functions/messages/read_discussion.py +88 -0
- pyrogram/raw/functions/messages/read_encrypted_history.py +80 -0
- pyrogram/raw/functions/messages/read_featured_stickers.py +72 -0
- pyrogram/raw/functions/messages/read_history.py +80 -0
- pyrogram/raw/functions/messages/read_mentions.py +83 -0
- pyrogram/raw/functions/messages/read_message_contents.py +72 -0
- pyrogram/raw/functions/messages/read_reactions.py +83 -0
- pyrogram/raw/functions/messages/received_messages.py +72 -0
- pyrogram/raw/functions/messages/received_queue.py +72 -0
- pyrogram/raw/functions/messages/reorder_pinned_dialogs.py +88 -0
- pyrogram/raw/functions/messages/reorder_sticker_sets.py +86 -0
- pyrogram/raw/functions/messages/report.py +96 -0
- pyrogram/raw/functions/messages/report_encrypted_spam.py +72 -0
- pyrogram/raw/functions/messages/report_reaction.py +88 -0
- pyrogram/raw/functions/messages/report_spam.py +72 -0
- pyrogram/raw/functions/messages/request_app_web_view.py +115 -0
- pyrogram/raw/functions/messages/request_encryption.py +88 -0
- pyrogram/raw/functions/messages/request_simple_web_view.py +106 -0
- pyrogram/raw/functions/messages/request_url_auth.py +103 -0
- pyrogram/raw/functions/messages/request_web_view.py +158 -0
- pyrogram/raw/functions/messages/save_default_send_as.py +80 -0
- pyrogram/raw/functions/messages/save_draft.py +116 -0
- pyrogram/raw/functions/messages/save_gif.py +80 -0
- pyrogram/raw/functions/messages/save_recent_sticker.py +88 -0
- pyrogram/raw/functions/messages/search.py +173 -0
- pyrogram/raw/functions/messages/search_custom_emoji.py +80 -0
- pyrogram/raw/functions/messages/search_global.py +139 -0
- pyrogram/raw/functions/messages/search_sent_media.py +88 -0
- pyrogram/raw/functions/messages/search_sticker_sets.py +88 -0
- pyrogram/raw/functions/messages/send_bot_requested_peer.py +96 -0
- pyrogram/raw/functions/messages/send_encrypted.py +96 -0
- pyrogram/raw/functions/messages/send_encrypted_file.py +104 -0
- pyrogram/raw/functions/messages/send_encrypted_service.py +88 -0
- pyrogram/raw/functions/messages/send_inline_bot_result.py +159 -0
- pyrogram/raw/functions/messages/send_media.py +185 -0
- pyrogram/raw/functions/messages/send_message.py +183 -0
- pyrogram/raw/functions/messages/send_multi_media.py +149 -0
- pyrogram/raw/functions/messages/send_reaction.py +104 -0
- pyrogram/raw/functions/messages/send_scheduled_messages.py +80 -0
- pyrogram/raw/functions/messages/send_screenshot_notification.py +88 -0
- pyrogram/raw/functions/messages/send_vote.py +88 -0
- pyrogram/raw/functions/messages/send_web_view_data.py +96 -0
- pyrogram/raw/functions/messages/send_web_view_result_message.py +80 -0
- pyrogram/raw/functions/messages/set_bot_callback_answer.py +106 -0
- pyrogram/raw/functions/messages/set_bot_precheckout_results.py +89 -0
- pyrogram/raw/functions/messages/set_bot_shipping_results.py +93 -0
- pyrogram/raw/functions/messages/set_chat_available_reactions.py +80 -0
- pyrogram/raw/functions/messages/set_chat_theme.py +80 -0
- pyrogram/raw/functions/messages/set_chat_wall_paper.py +103 -0
- pyrogram/raw/functions/messages/set_default_history_ttl.py +72 -0
- pyrogram/raw/functions/messages/set_default_reaction.py +72 -0
- pyrogram/raw/functions/messages/set_encrypted_typing.py +80 -0
- pyrogram/raw/functions/messages/set_game_score.py +110 -0
- pyrogram/raw/functions/messages/set_history_ttl.py +80 -0
- pyrogram/raw/functions/messages/set_inline_bot_results.py +131 -0
- pyrogram/raw/functions/messages/set_inline_game_score.py +102 -0
- pyrogram/raw/functions/messages/set_typing.py +91 -0
- pyrogram/raw/functions/messages/start_bot.py +96 -0
- pyrogram/raw/functions/messages/start_history_import.py +80 -0
- pyrogram/raw/functions/messages/toggle_bot_in_attach_menu.py +88 -0
- pyrogram/raw/functions/messages/toggle_dialog_pin.py +80 -0
- pyrogram/raw/functions/messages/toggle_no_forwards.py +80 -0
- pyrogram/raw/functions/messages/toggle_peer_translations.py +80 -0
- pyrogram/raw/functions/messages/toggle_sticker_sets.py +92 -0
- pyrogram/raw/functions/messages/transcribe_audio.py +80 -0
- pyrogram/raw/functions/messages/translate_text.py +104 -0
- pyrogram/raw/functions/messages/uninstall_sticker_set.py +72 -0
- pyrogram/raw/functions/messages/unpin_all_messages.py +83 -0
- pyrogram/raw/functions/messages/update_dialog_filter.py +84 -0
- pyrogram/raw/functions/messages/update_dialog_filters_order.py +72 -0
- pyrogram/raw/functions/messages/update_pinned_message.py +100 -0
- pyrogram/raw/functions/messages/upload_encrypted_file.py +80 -0
- pyrogram/raw/functions/messages/upload_imported_media.py +96 -0
- pyrogram/raw/functions/messages/upload_media.py +80 -0
- pyrogram/raw/functions/payments/__init__.py +35 -0
- pyrogram/raw/functions/payments/assign_app_store_transaction.py +80 -0
- pyrogram/raw/functions/payments/assign_play_market_transaction.py +80 -0
- pyrogram/raw/functions/payments/can_purchase_premium.py +72 -0
- pyrogram/raw/functions/payments/clear_saved_info.py +78 -0
- pyrogram/raw/functions/payments/export_invoice.py +72 -0
- pyrogram/raw/functions/payments/get_bank_card_data.py +72 -0
- pyrogram/raw/functions/payments/get_payment_form.py +84 -0
- pyrogram/raw/functions/payments/get_payment_receipt.py +80 -0
- pyrogram/raw/functions/payments/get_saved_info.py +67 -0
- pyrogram/raw/functions/payments/send_payment_form.py +117 -0
- pyrogram/raw/functions/payments/validate_requested_info.py +88 -0
- pyrogram/raw/functions/phone/__init__.py +55 -0
- pyrogram/raw/functions/phone/accept_call.py +88 -0
- pyrogram/raw/functions/phone/check_group_call.py +80 -0
- pyrogram/raw/functions/phone/confirm_call.py +96 -0
- pyrogram/raw/functions/phone/create_group_call.py +106 -0
- pyrogram/raw/functions/phone/discard_call.py +104 -0
- pyrogram/raw/functions/phone/discard_group_call.py +72 -0
- pyrogram/raw/functions/phone/edit_group_call_participant.py +136 -0
- pyrogram/raw/functions/phone/edit_group_call_title.py +80 -0
- pyrogram/raw/functions/phone/export_group_call_invite.py +80 -0
- pyrogram/raw/functions/phone/get_call_config.py +67 -0
- pyrogram/raw/functions/phone/get_group_call.py +80 -0
- pyrogram/raw/functions/phone/get_group_call_join_as.py +72 -0
- pyrogram/raw/functions/phone/get_group_call_stream_channels.py +72 -0
- pyrogram/raw/functions/phone/get_group_call_stream_rtmp_url.py +80 -0
- pyrogram/raw/functions/phone/get_group_participants.py +104 -0
- pyrogram/raw/functions/phone/invite_to_group_call.py +80 -0
- pyrogram/raw/functions/phone/join_group_call.py +111 -0
- pyrogram/raw/functions/phone/join_group_call_presentation.py +80 -0
- pyrogram/raw/functions/phone/leave_group_call.py +80 -0
- pyrogram/raw/functions/phone/leave_group_call_presentation.py +72 -0
- pyrogram/raw/functions/phone/received_call.py +72 -0
- pyrogram/raw/functions/phone/request_call.py +104 -0
- pyrogram/raw/functions/phone/save_call_debug.py +80 -0
- pyrogram/raw/functions/phone/save_call_log.py +80 -0
- pyrogram/raw/functions/phone/save_default_group_call_join_as.py +80 -0
- pyrogram/raw/functions/phone/send_signaling_data.py +80 -0
- pyrogram/raw/functions/phone/set_call_rating.py +96 -0
- pyrogram/raw/functions/phone/start_scheduled_group_call.py +72 -0
- pyrogram/raw/functions/phone/toggle_group_call_record.py +104 -0
- pyrogram/raw/functions/phone/toggle_group_call_settings.py +89 -0
- pyrogram/raw/functions/phone/toggle_group_call_start_subscription.py +80 -0
- pyrogram/raw/functions/photos/__init__.py +29 -0
- pyrogram/raw/functions/photos/delete_photos.py +72 -0
- pyrogram/raw/functions/photos/get_user_photos.py +96 -0
- pyrogram/raw/functions/photos/update_profile_photo.py +90 -0
- pyrogram/raw/functions/photos/upload_contact_profile_photo.py +125 -0
- pyrogram/raw/functions/photos/upload_profile_photo.py +121 -0
- pyrogram/raw/functions/ping.py +72 -0
- pyrogram/raw/functions/ping_delay_disconnect.py +80 -0
- pyrogram/raw/functions/req_dh_params.py +112 -0
- pyrogram/raw/functions/req_pq.py +72 -0
- pyrogram/raw/functions/req_pq_multi.py +72 -0
- pyrogram/raw/functions/rpc_drop_answer.py +72 -0
- pyrogram/raw/functions/set_client_dh_params.py +88 -0
- pyrogram/raw/functions/stats/__init__.py +29 -0
- pyrogram/raw/functions/stats/get_broadcast_stats.py +80 -0
- pyrogram/raw/functions/stats/get_megagroup_stats.py +80 -0
- pyrogram/raw/functions/stats/get_message_public_forwards.py +112 -0
- pyrogram/raw/functions/stats/get_message_stats.py +88 -0
- pyrogram/raw/functions/stats/load_async_graph.py +83 -0
- pyrogram/raw/functions/stickers/__init__.py +34 -0
- pyrogram/raw/functions/stickers/add_sticker_to_set.py +80 -0
- pyrogram/raw/functions/stickers/change_sticker.py +102 -0
- pyrogram/raw/functions/stickers/change_sticker_position.py +80 -0
- pyrogram/raw/functions/stickers/check_short_name.py +72 -0
- pyrogram/raw/functions/stickers/create_sticker_set.py +147 -0
- pyrogram/raw/functions/stickers/delete_sticker_set.py +72 -0
- pyrogram/raw/functions/stickers/remove_sticker_from_set.py +72 -0
- pyrogram/raw/functions/stickers/rename_sticker_set.py +80 -0
- pyrogram/raw/functions/stickers/set_sticker_set_thumb.py +93 -0
- pyrogram/raw/functions/stickers/suggest_short_name.py +72 -0
- pyrogram/raw/functions/updates/__init__.py +27 -0
- pyrogram/raw/functions/updates/get_channel_difference.py +104 -0
- pyrogram/raw/functions/updates/get_difference.py +99 -0
- pyrogram/raw/functions/updates/get_state.py +67 -0
- pyrogram/raw/functions/upload/__init__.py +32 -0
- pyrogram/raw/functions/upload/get_cdn_file.py +88 -0
- pyrogram/raw/functions/upload/get_cdn_file_hashes.py +80 -0
- pyrogram/raw/functions/upload/get_file.py +102 -0
- pyrogram/raw/functions/upload/get_file_hashes.py +80 -0
- pyrogram/raw/functions/upload/get_web_file.py +88 -0
- pyrogram/raw/functions/upload/reupload_cdn_file.py +80 -0
- pyrogram/raw/functions/upload/save_big_file_part.py +96 -0
- pyrogram/raw/functions/upload/save_file_part.py +88 -0
- pyrogram/raw/functions/users/__init__.py +27 -0
- pyrogram/raw/functions/users/get_full_user.py +72 -0
- pyrogram/raw/functions/users/get_users.py +72 -0
- pyrogram/raw/functions/users/set_secure_value_errors.py +80 -0
- pyrogram/raw/types/__init__.py +959 -0
- pyrogram/raw/types/access_point_rule.py +88 -0
- pyrogram/raw/types/account/__init__.py +52 -0
- pyrogram/raw/types/account/authorization_form.py +116 -0
- pyrogram/raw/types/account/authorizations.py +89 -0
- pyrogram/raw/types/account/auto_download_settings.py +97 -0
- pyrogram/raw/types/account/auto_save_settings.py +121 -0
- pyrogram/raw/types/account/content_settings.py +87 -0
- pyrogram/raw/types/account/email_verified.py +81 -0
- pyrogram/raw/types/account/email_verified_login.py +89 -0
- pyrogram/raw/types/account/emoji_statuses.py +90 -0
- pyrogram/raw/types/account/emoji_statuses_not_modified.py +77 -0
- pyrogram/raw/types/account/password.py +181 -0
- pyrogram/raw/types/account/password_input_settings.py +113 -0
- pyrogram/raw/types/account/password_settings.py +94 -0
- pyrogram/raw/types/account/privacy_rules.py +98 -0
- pyrogram/raw/types/account/reset_password_failed_wait.py +81 -0
- pyrogram/raw/types/account/reset_password_ok.py +76 -0
- pyrogram/raw/types/account/reset_password_requested_wait.py +81 -0
- pyrogram/raw/types/account/saved_ringtone.py +76 -0
- pyrogram/raw/types/account/saved_ringtone_converted.py +81 -0
- pyrogram/raw/types/account/saved_ringtones.py +89 -0
- pyrogram/raw/types/account/saved_ringtones_not_modified.py +76 -0
- pyrogram/raw/types/account/sent_email_code.py +89 -0
- pyrogram/raw/types/account/takeout.py +81 -0
- pyrogram/raw/types/account/themes.py +90 -0
- pyrogram/raw/types/account/themes_not_modified.py +77 -0
- pyrogram/raw/types/account/tmp_password.py +89 -0
- pyrogram/raw/types/account/wall_papers.py +89 -0
- pyrogram/raw/types/account/wall_papers_not_modified.py +76 -0
- pyrogram/raw/types/account/web_authorizations.py +89 -0
- pyrogram/raw/types/account_days_ttl.py +81 -0
- pyrogram/raw/types/app_web_view_result_url.py +81 -0
- pyrogram/raw/types/attach_menu_bot.py +116 -0
- pyrogram/raw/types/attach_menu_bot_icon.py +92 -0
- pyrogram/raw/types/attach_menu_bot_icon_color.py +80 -0
- pyrogram/raw/types/attach_menu_bots.py +97 -0
- pyrogram/raw/types/attach_menu_bots_bot.py +89 -0
- pyrogram/raw/types/attach_menu_bots_not_modified.py +76 -0
- pyrogram/raw/types/attach_menu_peer_type_bot_pm.py +67 -0
- pyrogram/raw/types/attach_menu_peer_type_broadcast.py +67 -0
- pyrogram/raw/types/attach_menu_peer_type_chat.py +67 -0
- pyrogram/raw/types/attach_menu_peer_type_pm.py +67 -0
- pyrogram/raw/types/attach_menu_peer_type_same_bot_pm.py +67 -0
- pyrogram/raw/types/auth/__init__.py +48 -0
- pyrogram/raw/types/auth/authorization.py +122 -0
- pyrogram/raw/types/auth/authorization_sign_up_required.py +91 -0
- pyrogram/raw/types/auth/code_type_call.py +67 -0
- pyrogram/raw/types/auth/code_type_flash_call.py +67 -0
- pyrogram/raw/types/auth/code_type_fragment_sms.py +67 -0
- pyrogram/raw/types/auth/code_type_missed_call.py +67 -0
- pyrogram/raw/types/auth/code_type_sms.py +67 -0
- pyrogram/raw/types/auth/exported_authorization.py +89 -0
- pyrogram/raw/types/auth/logged_out.py +84 -0
- pyrogram/raw/types/auth/login_token.py +90 -0
- pyrogram/raw/types/auth/login_token_migrate_to.py +90 -0
- pyrogram/raw/types/auth/login_token_success.py +82 -0
- pyrogram/raw/types/auth/password_recovery.py +81 -0
- pyrogram/raw/types/auth/sent_code.py +115 -0
- pyrogram/raw/types/auth/sent_code_success.py +86 -0
- pyrogram/raw/types/auth/sent_code_type_app.py +72 -0
- pyrogram/raw/types/auth/sent_code_type_call.py +72 -0
- pyrogram/raw/types/auth/sent_code_type_email_code.py +112 -0
- pyrogram/raw/types/auth/sent_code_type_firebase_sms.py +101 -0
- pyrogram/raw/types/auth/sent_code_type_flash_call.py +72 -0
- pyrogram/raw/types/auth/sent_code_type_fragment_sms.py +80 -0
- pyrogram/raw/types/auth/sent_code_type_missed_call.py +80 -0
- pyrogram/raw/types/auth/sent_code_type_set_up_email_required.py +78 -0
- pyrogram/raw/types/auth/sent_code_type_sms.py +72 -0
- pyrogram/raw/types/authorization.py +201 -0
- pyrogram/raw/types/auto_download_settings.py +122 -0
- pyrogram/raw/types/auto_save_exception.py +80 -0
- pyrogram/raw/types/auto_save_settings.py +87 -0
- pyrogram/raw/types/available_reaction.py +154 -0
- pyrogram/raw/types/bad_msg_notification.py +88 -0
- pyrogram/raw/types/bad_server_salt.py +96 -0
- pyrogram/raw/types/bank_card_open_url.py +80 -0
- pyrogram/raw/types/base_theme_arctic.py +67 -0
- pyrogram/raw/types/base_theme_classic.py +67 -0
- pyrogram/raw/types/base_theme_day.py +67 -0
- pyrogram/raw/types/base_theme_night.py +67 -0
- pyrogram/raw/types/base_theme_tinted.py +67 -0
- pyrogram/raw/types/bind_auth_key_inner.py +104 -0
- pyrogram/raw/types/bot_app.py +132 -0
- pyrogram/raw/types/bot_app_not_modified.py +67 -0
- pyrogram/raw/types/bot_command.py +89 -0
- pyrogram/raw/types/bot_command_scope_chat_admins.py +67 -0
- pyrogram/raw/types/bot_command_scope_chats.py +67 -0
- pyrogram/raw/types/bot_command_scope_default.py +67 -0
- pyrogram/raw/types/bot_command_scope_peer.py +72 -0
- pyrogram/raw/types/bot_command_scope_peer_admins.py +72 -0
- pyrogram/raw/types/bot_command_scope_peer_user.py +80 -0
- pyrogram/raw/types/bot_command_scope_users.py +67 -0
- pyrogram/raw/types/bot_info.py +124 -0
- pyrogram/raw/types/bot_inline_media_result.py +128 -0
- pyrogram/raw/types/bot_inline_message_media_auto.py +94 -0
- pyrogram/raw/types/bot_inline_message_media_contact.py +108 -0
- pyrogram/raw/types/bot_inline_message_media_geo.py +111 -0
- pyrogram/raw/types/bot_inline_message_media_invoice.py +130 -0
- pyrogram/raw/types/bot_inline_message_media_venue.py +124 -0
- pyrogram/raw/types/bot_inline_message_text.py +100 -0
- pyrogram/raw/types/bot_inline_result.py +137 -0
- pyrogram/raw/types/bot_menu_button.py +89 -0
- pyrogram/raw/types/bot_menu_button_commands.py +76 -0
- pyrogram/raw/types/bot_menu_button_default.py +76 -0
- pyrogram/raw/types/bots/__init__.py +25 -0
- pyrogram/raw/types/bots/bot_info.py +97 -0
- pyrogram/raw/types/cdn_config.py +81 -0
- pyrogram/raw/types/cdn_public_key.py +80 -0
- pyrogram/raw/types/channel.py +299 -0
- pyrogram/raw/types/channel_admin_log_event.py +96 -0
- pyrogram/raw/types/channel_admin_log_event_action_change_about.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_change_available_reactions.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_change_history_ttl.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_change_linked_chat.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_change_location.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_change_photo.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_change_sticker_set.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_change_title.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_change_username.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_change_usernames.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_create_topic.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_default_banned_rights.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_delete_message.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_delete_topic.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_discard_group_call.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_edit_message.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_edit_topic.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_exported_invite_delete.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_exported_invite_edit.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_exported_invite_revoke.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_participant_invite.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_participant_join.py +67 -0
- pyrogram/raw/types/channel_admin_log_event_action_participant_join_by_invite.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_participant_join_by_request.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_participant_leave.py +67 -0
- pyrogram/raw/types/channel_admin_log_event_action_participant_mute.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_participant_toggle_admin.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_participant_toggle_ban.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_participant_unmute.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_participant_volume.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_pin_topic.py +86 -0
- pyrogram/raw/types/channel_admin_log_event_action_send_message.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_start_group_call.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_stop_poll.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_toggle_anti_spam.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_toggle_forum.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_toggle_group_call_setting.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_toggle_invites.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_toggle_no_forwards.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_toggle_pre_history_hidden.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_toggle_signatures.py +72 -0
- pyrogram/raw/types/channel_admin_log_event_action_toggle_slow_mode.py +80 -0
- pyrogram/raw/types/channel_admin_log_event_action_update_pinned.py +72 -0
- pyrogram/raw/types/channel_admin_log_events_filter.py +174 -0
- pyrogram/raw/types/channel_forbidden.py +111 -0
- pyrogram/raw/types/channel_full.py +457 -0
- pyrogram/raw/types/channel_location.py +80 -0
- pyrogram/raw/types/channel_location_empty.py +67 -0
- pyrogram/raw/types/channel_messages_filter.py +80 -0
- pyrogram/raw/types/channel_messages_filter_empty.py +67 -0
- pyrogram/raw/types/channel_participant.py +80 -0
- pyrogram/raw/types/channel_participant_admin.py +128 -0
- pyrogram/raw/types/channel_participant_banned.py +104 -0
- pyrogram/raw/types/channel_participant_creator.py +91 -0
- pyrogram/raw/types/channel_participant_left.py +72 -0
- pyrogram/raw/types/channel_participant_self.py +96 -0
- pyrogram/raw/types/channel_participants_admins.py +67 -0
- pyrogram/raw/types/channel_participants_banned.py +72 -0
- pyrogram/raw/types/channel_participants_bots.py +67 -0
- pyrogram/raw/types/channel_participants_contacts.py +72 -0
- pyrogram/raw/types/channel_participants_kicked.py +72 -0
- pyrogram/raw/types/channel_participants_mentions.py +84 -0
- pyrogram/raw/types/channel_participants_recent.py +67 -0
- pyrogram/raw/types/channel_participants_search.py +72 -0
- pyrogram/raw/types/channels/__init__.py +29 -0
- pyrogram/raw/types/channels/admin_log_results.py +97 -0
- pyrogram/raw/types/channels/channel_participant.py +97 -0
- pyrogram/raw/types/channels/channel_participants.py +105 -0
- pyrogram/raw/types/channels/channel_participants_not_modified.py +76 -0
- pyrogram/raw/types/channels/send_as_peers.py +97 -0
- pyrogram/raw/types/chat.py +180 -0
- pyrogram/raw/types/chat_admin_rights.py +138 -0
- pyrogram/raw/types/chat_admin_with_invites.py +88 -0
- pyrogram/raw/types/chat_banned_rights.py +194 -0
- pyrogram/raw/types/chat_empty.py +72 -0
- pyrogram/raw/types/chat_forbidden.py +80 -0
- pyrogram/raw/types/chat_full.py +231 -0
- pyrogram/raw/types/chat_invite.py +148 -0
- pyrogram/raw/types/chat_invite_already.py +81 -0
- pyrogram/raw/types/chat_invite_exported.py +171 -0
- pyrogram/raw/types/chat_invite_importer.py +112 -0
- pyrogram/raw/types/chat_invite_peek.py +89 -0
- pyrogram/raw/types/chat_invite_public_join_requests.py +76 -0
- pyrogram/raw/types/chat_onlines.py +81 -0
- pyrogram/raw/types/chat_participant.py +88 -0
- pyrogram/raw/types/chat_participant_admin.py +88 -0
- pyrogram/raw/types/chat_participant_creator.py +72 -0
- pyrogram/raw/types/chat_participants.py +88 -0
- pyrogram/raw/types/chat_participants_forbidden.py +84 -0
- pyrogram/raw/types/chat_photo.py +97 -0
- pyrogram/raw/types/chat_photo_empty.py +67 -0
- pyrogram/raw/types/chat_reactions_all.py +72 -0
- pyrogram/raw/types/chat_reactions_none.py +67 -0
- pyrogram/raw/types/chat_reactions_some.py +72 -0
- pyrogram/raw/types/chatlists/__init__.py +29 -0
- pyrogram/raw/types/chatlists/chatlist_invite.py +116 -0
- pyrogram/raw/types/chatlists/chatlist_invite_already.py +113 -0
- pyrogram/raw/types/chatlists/chatlist_updates.py +97 -0
- pyrogram/raw/types/chatlists/exported_chatlist_invite.py +89 -0
- pyrogram/raw/types/chatlists/exported_invites.py +97 -0
- pyrogram/raw/types/client_dh_inner_data.py +96 -0
- pyrogram/raw/types/code_settings.py +124 -0
- pyrogram/raw/types/config.py +453 -0
- pyrogram/raw/types/contact.py +80 -0
- pyrogram/raw/types/contact_status.py +89 -0
- pyrogram/raw/types/contacts/__init__.py +34 -0
- pyrogram/raw/types/contacts/blocked.py +97 -0
- pyrogram/raw/types/contacts/blocked_slice.py +105 -0
- pyrogram/raw/types/contacts/contacts.py +97 -0
- pyrogram/raw/types/contacts/contacts_not_modified.py +76 -0
- pyrogram/raw/types/contacts/found.py +105 -0
- pyrogram/raw/types/contacts/imported_contacts.py +105 -0
- pyrogram/raw/types/contacts/resolved_peer.py +98 -0
- pyrogram/raw/types/contacts/top_peers.py +97 -0
- pyrogram/raw/types/contacts/top_peers_disabled.py +76 -0
- pyrogram/raw/types/contacts/top_peers_not_modified.py +76 -0
- pyrogram/raw/types/data_json.py +82 -0
- pyrogram/raw/types/dc_option.py +135 -0
- pyrogram/raw/types/default_history_ttl.py +81 -0
- pyrogram/raw/types/destroy_auth_key_fail.py +76 -0
- pyrogram/raw/types/destroy_auth_key_none.py +76 -0
- pyrogram/raw/types/destroy_auth_key_ok.py +76 -0
- pyrogram/raw/types/destroy_session_none.py +81 -0
- pyrogram/raw/types/destroy_session_ok.py +81 -0
- pyrogram/raw/types/dh_gen_fail.py +97 -0
- pyrogram/raw/types/dh_gen_ok.py +97 -0
- pyrogram/raw/types/dh_gen_retry.py +97 -0
- pyrogram/raw/types/dialog.py +179 -0
- pyrogram/raw/types/dialog_filter.py +172 -0
- pyrogram/raw/types/dialog_filter_chatlist.py +122 -0
- pyrogram/raw/types/dialog_filter_default.py +76 -0
- pyrogram/raw/types/dialog_filter_suggested.py +89 -0
- pyrogram/raw/types/dialog_folder.py +128 -0
- pyrogram/raw/types/dialog_peer.py +81 -0
- pyrogram/raw/types/dialog_peer_folder.py +81 -0
- pyrogram/raw/types/document.py +162 -0
- pyrogram/raw/types/document_attribute_animated.py +67 -0
- pyrogram/raw/types/document_attribute_audio.py +107 -0
- pyrogram/raw/types/document_attribute_custom_emoji.py +94 -0
- pyrogram/raw/types/document_attribute_filename.py +72 -0
- pyrogram/raw/types/document_attribute_has_stickers.py +67 -0
- pyrogram/raw/types/document_attribute_image_size.py +80 -0
- pyrogram/raw/types/document_attribute_sticker.py +98 -0
- pyrogram/raw/types/document_attribute_video.py +102 -0
- pyrogram/raw/types/document_empty.py +84 -0
- pyrogram/raw/types/draft_message.py +107 -0
- pyrogram/raw/types/draft_message_empty.py +75 -0
- pyrogram/raw/types/email_verification_apple.py +72 -0
- pyrogram/raw/types/email_verification_code.py +72 -0
- pyrogram/raw/types/email_verification_google.py +72 -0
- pyrogram/raw/types/email_verify_purpose_login_change.py +67 -0
- pyrogram/raw/types/email_verify_purpose_login_setup.py +80 -0
- pyrogram/raw/types/email_verify_purpose_passport.py +67 -0
- pyrogram/raw/types/emoji_group.py +88 -0
- pyrogram/raw/types/emoji_keyword.py +80 -0
- pyrogram/raw/types/emoji_keyword_deleted.py +80 -0
- pyrogram/raw/types/emoji_keywords_difference.py +106 -0
- pyrogram/raw/types/emoji_language.py +81 -0
- pyrogram/raw/types/emoji_list.py +91 -0
- pyrogram/raw/types/emoji_list_not_modified.py +78 -0
- pyrogram/raw/types/emoji_status.py +72 -0
- pyrogram/raw/types/emoji_status_empty.py +67 -0
- pyrogram/raw/types/emoji_status_until.py +80 -0
- pyrogram/raw/types/emoji_url.py +81 -0
- pyrogram/raw/types/encrypted_chat.py +130 -0
- pyrogram/raw/types/encrypted_chat_discarded.py +90 -0
- pyrogram/raw/types/encrypted_chat_empty.py +82 -0
- pyrogram/raw/types/encrypted_chat_requested.py +133 -0
- pyrogram/raw/types/encrypted_chat_waiting.py +114 -0
- pyrogram/raw/types/encrypted_file.py +113 -0
- pyrogram/raw/types/encrypted_file_empty.py +76 -0
- pyrogram/raw/types/encrypted_message.py +104 -0
- pyrogram/raw/types/encrypted_message_service.py +96 -0
- pyrogram/raw/types/exported_chatlist_invite.py +100 -0
- pyrogram/raw/types/exported_contact_token.py +89 -0
- pyrogram/raw/types/exported_message_link.py +89 -0
- pyrogram/raw/types/file_hash.py +99 -0
- pyrogram/raw/types/folder.py +110 -0
- pyrogram/raw/types/folder_peer.py +80 -0
- pyrogram/raw/types/forum_topic.py +211 -0
- pyrogram/raw/types/forum_topic_deleted.py +72 -0
- pyrogram/raw/types/game.py +124 -0
- pyrogram/raw/types/geo_point.py +99 -0
- pyrogram/raw/types/geo_point_empty.py +67 -0
- pyrogram/raw/types/global_privacy_settings.py +85 -0
- pyrogram/raw/types/group_call.py +199 -0
- pyrogram/raw/types/group_call_discarded.py +88 -0
- pyrogram/raw/types/group_call_participant.py +206 -0
- pyrogram/raw/types/group_call_participant_video.py +97 -0
- pyrogram/raw/types/group_call_participant_video_source_group.py +80 -0
- pyrogram/raw/types/group_call_stream_channel.py +88 -0
- pyrogram/raw/types/help/__init__.py +49 -0
- pyrogram/raw/types/help/app_config.py +89 -0
- pyrogram/raw/types/help/app_config_not_modified.py +76 -0
- pyrogram/raw/types/help/app_update.py +142 -0
- pyrogram/raw/types/help/config_simple.py +88 -0
- pyrogram/raw/types/help/countries_list.py +89 -0
- pyrogram/raw/types/help/countries_list_not_modified.py +76 -0
- pyrogram/raw/types/help/country.py +105 -0
- pyrogram/raw/types/help/country_code.py +94 -0
- pyrogram/raw/types/help/deep_link_info.py +99 -0
- pyrogram/raw/types/help/deep_link_info_empty.py +76 -0
- pyrogram/raw/types/help/invite_text.py +81 -0
- pyrogram/raw/types/help/no_app_update.py +76 -0
- pyrogram/raw/types/help/passport_config.py +89 -0
- pyrogram/raw/types/help/passport_config_not_modified.py +76 -0
- pyrogram/raw/types/help/premium_promo.py +121 -0
- pyrogram/raw/types/help/promo_data.py +131 -0
- pyrogram/raw/types/help/promo_data_empty.py +81 -0
- pyrogram/raw/types/help/recent_me_urls.py +97 -0
- pyrogram/raw/types/help/support.py +89 -0
- pyrogram/raw/types/help/support_name.py +81 -0
- pyrogram/raw/types/help/terms_of_service.py +105 -0
- pyrogram/raw/types/help/terms_of_service_update.py +89 -0
- pyrogram/raw/types/help/terms_of_service_update_empty.py +81 -0
- pyrogram/raw/types/help/user_info.py +106 -0
- pyrogram/raw/types/help/user_info_empty.py +77 -0
- pyrogram/raw/types/high_score.py +88 -0
- pyrogram/raw/types/http_wait.py +88 -0
- pyrogram/raw/types/imported_contact.py +80 -0
- pyrogram/raw/types/inline_bot_switch_pm.py +80 -0
- pyrogram/raw/types/inline_bot_web_view.py +80 -0
- pyrogram/raw/types/inline_query_peer_type_bot_pm.py +67 -0
- pyrogram/raw/types/inline_query_peer_type_broadcast.py +67 -0
- pyrogram/raw/types/inline_query_peer_type_chat.py +67 -0
- pyrogram/raw/types/inline_query_peer_type_megagroup.py +67 -0
- pyrogram/raw/types/inline_query_peer_type_pm.py +67 -0
- pyrogram/raw/types/inline_query_peer_type_same_bot_pm.py +67 -0
- pyrogram/raw/types/input_app_event.py +96 -0
- pyrogram/raw/types/input_bot_app_id.py +80 -0
- pyrogram/raw/types/input_bot_app_short_name.py +80 -0
- pyrogram/raw/types/input_bot_inline_message_game.py +76 -0
- pyrogram/raw/types/input_bot_inline_message_id.py +88 -0
- pyrogram/raw/types/input_bot_inline_message_id64.py +96 -0
- pyrogram/raw/types/input_bot_inline_message_media_auto.py +94 -0
- pyrogram/raw/types/input_bot_inline_message_media_contact.py +108 -0
- pyrogram/raw/types/input_bot_inline_message_media_geo.py +111 -0
- pyrogram/raw/types/input_bot_inline_message_media_invoice.py +134 -0
- pyrogram/raw/types/input_bot_inline_message_media_venue.py +124 -0
- pyrogram/raw/types/input_bot_inline_message_text.py +100 -0
- pyrogram/raw/types/input_bot_inline_result.py +137 -0
- pyrogram/raw/types/input_bot_inline_result_document.py +116 -0
- pyrogram/raw/types/input_bot_inline_result_game.py +88 -0
- pyrogram/raw/types/input_bot_inline_result_photo.py +96 -0
- pyrogram/raw/types/input_channel.py +80 -0
- pyrogram/raw/types/input_channel_empty.py +67 -0
- pyrogram/raw/types/input_channel_from_message.py +88 -0
- pyrogram/raw/types/input_chat_photo.py +72 -0
- pyrogram/raw/types/input_chat_photo_empty.py +67 -0
- pyrogram/raw/types/input_chat_uploaded_photo.py +105 -0
- pyrogram/raw/types/input_chatlist_dialog_filter.py +72 -0
- pyrogram/raw/types/input_check_password_empty.py +67 -0
- pyrogram/raw/types/input_check_password_srp.py +88 -0
- pyrogram/raw/types/input_client_proxy.py +80 -0
- pyrogram/raw/types/input_dialog_peer.py +72 -0
- pyrogram/raw/types/input_dialog_peer_folder.py +72 -0
- pyrogram/raw/types/input_document.py +88 -0
- pyrogram/raw/types/input_document_empty.py +67 -0
- pyrogram/raw/types/input_document_file_location.py +96 -0
- pyrogram/raw/types/input_encrypted_chat.py +80 -0
- pyrogram/raw/types/input_encrypted_file.py +80 -0
- pyrogram/raw/types/input_encrypted_file_big_uploaded.py +88 -0
- pyrogram/raw/types/input_encrypted_file_empty.py +67 -0
- pyrogram/raw/types/input_encrypted_file_location.py +80 -0
- pyrogram/raw/types/input_encrypted_file_uploaded.py +96 -0
- pyrogram/raw/types/input_file.py +96 -0
- pyrogram/raw/types/input_file_big.py +88 -0
- pyrogram/raw/types/input_file_location.py +96 -0
- pyrogram/raw/types/input_folder_peer.py +80 -0
- pyrogram/raw/types/input_game_id.py +80 -0
- pyrogram/raw/types/input_game_short_name.py +80 -0
- pyrogram/raw/types/input_geo_point.py +91 -0
- pyrogram/raw/types/input_geo_point_empty.py +67 -0
- pyrogram/raw/types/input_group_call.py +80 -0
- pyrogram/raw/types/input_group_call_stream.py +108 -0
- pyrogram/raw/types/input_invoice_message.py +80 -0
- pyrogram/raw/types/input_invoice_slug.py +72 -0
- pyrogram/raw/types/input_keyboard_button_url_auth.py +105 -0
- pyrogram/raw/types/input_keyboard_button_user_profile.py +80 -0
- pyrogram/raw/types/input_media_contact.py +96 -0
- pyrogram/raw/types/input_media_dice.py +72 -0
- pyrogram/raw/types/input_media_document.py +98 -0
- pyrogram/raw/types/input_media_document_external.py +89 -0
- pyrogram/raw/types/input_media_empty.py +67 -0
- pyrogram/raw/types/input_media_game.py +72 -0
- pyrogram/raw/types/input_media_geo_live.py +107 -0
- pyrogram/raw/types/input_media_geo_point.py +72 -0
- pyrogram/raw/types/input_media_invoice.py +143 -0
- pyrogram/raw/types/input_media_photo.py +89 -0
- pyrogram/raw/types/input_media_photo_external.py +89 -0
- pyrogram/raw/types/input_media_poll.py +103 -0
- pyrogram/raw/types/input_media_uploaded_document.py +137 -0
- pyrogram/raw/types/input_media_uploaded_photo.py +99 -0
- pyrogram/raw/types/input_media_venue.py +112 -0
- pyrogram/raw/types/input_message_callback_query.py +80 -0
- pyrogram/raw/types/input_message_entity_mention_name.py +88 -0
- pyrogram/raw/types/input_message_id.py +72 -0
- pyrogram/raw/types/input_message_pinned.py +67 -0
- pyrogram/raw/types/input_message_reply_to.py +72 -0
- pyrogram/raw/types/input_messages_filter_chat_photos.py +67 -0
- pyrogram/raw/types/input_messages_filter_contacts.py +67 -0
- pyrogram/raw/types/input_messages_filter_document.py +67 -0
- pyrogram/raw/types/input_messages_filter_empty.py +67 -0
- pyrogram/raw/types/input_messages_filter_geo.py +67 -0
- pyrogram/raw/types/input_messages_filter_gif.py +67 -0
- pyrogram/raw/types/input_messages_filter_music.py +67 -0
- pyrogram/raw/types/input_messages_filter_my_mentions.py +67 -0
- pyrogram/raw/types/input_messages_filter_phone_calls.py +72 -0
- pyrogram/raw/types/input_messages_filter_photo_video.py +67 -0
- pyrogram/raw/types/input_messages_filter_photos.py +67 -0
- pyrogram/raw/types/input_messages_filter_pinned.py +67 -0
- pyrogram/raw/types/input_messages_filter_round_video.py +67 -0
- pyrogram/raw/types/input_messages_filter_round_voice.py +67 -0
- pyrogram/raw/types/input_messages_filter_url.py +67 -0
- pyrogram/raw/types/input_messages_filter_video.py +67 -0
- pyrogram/raw/types/input_messages_filter_voice.py +67 -0
- pyrogram/raw/types/input_notify_broadcasts.py +67 -0
- pyrogram/raw/types/input_notify_chats.py +67 -0
- pyrogram/raw/types/input_notify_forum_topic.py +80 -0
- pyrogram/raw/types/input_notify_peer.py +72 -0
- pyrogram/raw/types/input_notify_users.py +67 -0
- pyrogram/raw/types/input_payment_credentials.py +80 -0
- pyrogram/raw/types/input_payment_credentials_apple_pay.py +72 -0
- pyrogram/raw/types/input_payment_credentials_google_pay.py +72 -0
- pyrogram/raw/types/input_payment_credentials_saved.py +80 -0
- pyrogram/raw/types/input_peer_channel.py +80 -0
- pyrogram/raw/types/input_peer_channel_from_message.py +88 -0
- pyrogram/raw/types/input_peer_chat.py +72 -0
- pyrogram/raw/types/input_peer_empty.py +67 -0
- pyrogram/raw/types/input_peer_notify_settings.py +103 -0
- pyrogram/raw/types/input_peer_photo_file_location.py +88 -0
- pyrogram/raw/types/input_peer_self.py +67 -0
- pyrogram/raw/types/input_peer_user.py +80 -0
- pyrogram/raw/types/input_peer_user_from_message.py +88 -0
- pyrogram/raw/types/input_phone_call.py +80 -0
- pyrogram/raw/types/input_phone_contact.py +96 -0
- pyrogram/raw/types/input_photo.py +88 -0
- pyrogram/raw/types/input_photo_empty.py +67 -0
- pyrogram/raw/types/input_photo_file_location.py +96 -0
- pyrogram/raw/types/input_photo_legacy_file_location.py +112 -0
- pyrogram/raw/types/input_privacy_key_added_by_phone.py +67 -0
- pyrogram/raw/types/input_privacy_key_chat_invite.py +67 -0
- pyrogram/raw/types/input_privacy_key_forwards.py +67 -0
- pyrogram/raw/types/input_privacy_key_phone_call.py +67 -0
- pyrogram/raw/types/input_privacy_key_phone_number.py +67 -0
- pyrogram/raw/types/input_privacy_key_phone_p2_p.py +67 -0
- pyrogram/raw/types/input_privacy_key_profile_photo.py +67 -0
- pyrogram/raw/types/input_privacy_key_status_timestamp.py +67 -0
- pyrogram/raw/types/input_privacy_key_voice_messages.py +67 -0
- pyrogram/raw/types/input_privacy_value_allow_all.py +67 -0
- pyrogram/raw/types/input_privacy_value_allow_chat_participants.py +72 -0
- pyrogram/raw/types/input_privacy_value_allow_contacts.py +67 -0
- pyrogram/raw/types/input_privacy_value_allow_users.py +72 -0
- pyrogram/raw/types/input_privacy_value_disallow_all.py +67 -0
- pyrogram/raw/types/input_privacy_value_disallow_chat_participants.py +72 -0
- pyrogram/raw/types/input_privacy_value_disallow_contacts.py +67 -0
- pyrogram/raw/types/input_privacy_value_disallow_users.py +72 -0
- pyrogram/raw/types/input_report_reason_child_abuse.py +67 -0
- pyrogram/raw/types/input_report_reason_copyright.py +67 -0
- pyrogram/raw/types/input_report_reason_fake.py +67 -0
- pyrogram/raw/types/input_report_reason_geo_irrelevant.py +67 -0
- pyrogram/raw/types/input_report_reason_illegal_drugs.py +67 -0
- pyrogram/raw/types/input_report_reason_other.py +67 -0
- pyrogram/raw/types/input_report_reason_personal_details.py +67 -0
- pyrogram/raw/types/input_report_reason_pornography.py +67 -0
- pyrogram/raw/types/input_report_reason_spam.py +67 -0
- pyrogram/raw/types/input_report_reason_violence.py +67 -0
- pyrogram/raw/types/input_secure_file.py +80 -0
- pyrogram/raw/types/input_secure_file_location.py +80 -0
- pyrogram/raw/types/input_secure_file_uploaded.py +104 -0
- pyrogram/raw/types/input_secure_value.py +144 -0
- pyrogram/raw/types/input_single_media.py +100 -0
- pyrogram/raw/types/input_sticker_set_animated_emoji.py +67 -0
- pyrogram/raw/types/input_sticker_set_animated_emoji_animations.py +67 -0
- pyrogram/raw/types/input_sticker_set_dice.py +72 -0
- pyrogram/raw/types/input_sticker_set_emoji_default_statuses.py +67 -0
- pyrogram/raw/types/input_sticker_set_emoji_default_topic_icons.py +67 -0
- pyrogram/raw/types/input_sticker_set_emoji_generic_animations.py +67 -0
- pyrogram/raw/types/input_sticker_set_empty.py +67 -0
- pyrogram/raw/types/input_sticker_set_id.py +80 -0
- pyrogram/raw/types/input_sticker_set_item.py +101 -0
- pyrogram/raw/types/input_sticker_set_premium_gifts.py +67 -0
- pyrogram/raw/types/input_sticker_set_short_name.py +72 -0
- pyrogram/raw/types/input_sticker_set_thumb.py +80 -0
- pyrogram/raw/types/input_stickered_media_document.py +72 -0
- pyrogram/raw/types/input_stickered_media_photo.py +72 -0
- pyrogram/raw/types/input_store_payment_gift_premium.py +88 -0
- pyrogram/raw/types/input_store_payment_premium_subscription.py +78 -0
- pyrogram/raw/types/input_takeout_file_location.py +67 -0
- pyrogram/raw/types/input_theme.py +80 -0
- pyrogram/raw/types/input_theme_settings.py +127 -0
- pyrogram/raw/types/input_theme_slug.py +72 -0
- pyrogram/raw/types/input_user.py +80 -0
- pyrogram/raw/types/input_user_empty.py +67 -0
- pyrogram/raw/types/input_user_from_message.py +88 -0
- pyrogram/raw/types/input_user_self.py +67 -0
- pyrogram/raw/types/input_wall_paper.py +80 -0
- pyrogram/raw/types/input_wall_paper_no_file.py +72 -0
- pyrogram/raw/types/input_wall_paper_slug.py +72 -0
- pyrogram/raw/types/input_web_document.py +96 -0
- pyrogram/raw/types/input_web_file_audio_album_thumb_location.py +100 -0
- pyrogram/raw/types/input_web_file_geo_point_location.py +112 -0
- pyrogram/raw/types/input_web_file_location.py +80 -0
- pyrogram/raw/types/invoice.py +164 -0
- pyrogram/raw/types/ip_port.py +80 -0
- pyrogram/raw/types/ip_port_secret.py +88 -0
- pyrogram/raw/types/json_array.py +72 -0
- pyrogram/raw/types/json_bool.py +72 -0
- pyrogram/raw/types/json_null.py +67 -0
- pyrogram/raw/types/json_number.py +72 -0
- pyrogram/raw/types/json_object.py +72 -0
- pyrogram/raw/types/json_object_value.py +80 -0
- pyrogram/raw/types/json_string.py +72 -0
- pyrogram/raw/types/keyboard_button.py +72 -0
- pyrogram/raw/types/keyboard_button_buy.py +72 -0
- pyrogram/raw/types/keyboard_button_callback.py +88 -0
- pyrogram/raw/types/keyboard_button_game.py +72 -0
- pyrogram/raw/types/keyboard_button_request_geo_location.py +72 -0
- pyrogram/raw/types/keyboard_button_request_peer.py +88 -0
- pyrogram/raw/types/keyboard_button_request_phone.py +72 -0
- pyrogram/raw/types/keyboard_button_request_poll.py +83 -0
- pyrogram/raw/types/keyboard_button_row.py +72 -0
- pyrogram/raw/types/keyboard_button_simple_web_view.py +80 -0
- pyrogram/raw/types/keyboard_button_switch_inline.py +98 -0
- pyrogram/raw/types/keyboard_button_url.py +80 -0
- pyrogram/raw/types/keyboard_button_url_auth.py +99 -0
- pyrogram/raw/types/keyboard_button_user_profile.py +80 -0
- pyrogram/raw/types/keyboard_button_web_view.py +80 -0
- pyrogram/raw/types/labeled_price.py +80 -0
- pyrogram/raw/types/lang_pack_difference.py +106 -0
- pyrogram/raw/types/lang_pack_language.py +159 -0
- pyrogram/raw/types/lang_pack_string.py +89 -0
- pyrogram/raw/types/lang_pack_string_deleted.py +81 -0
- pyrogram/raw/types/lang_pack_string_pluralized.py +136 -0
- pyrogram/raw/types/mask_coords.py +96 -0
- pyrogram/raw/types/message.py +311 -0
- pyrogram/raw/types/message_action_bot_allowed.py +91 -0
- pyrogram/raw/types/message_action_channel_create.py +72 -0
- pyrogram/raw/types/message_action_channel_migrate_from.py +80 -0
- pyrogram/raw/types/message_action_chat_add_user.py +72 -0
- pyrogram/raw/types/message_action_chat_create.py +80 -0
- pyrogram/raw/types/message_action_chat_delete_photo.py +67 -0
- pyrogram/raw/types/message_action_chat_delete_user.py +72 -0
- pyrogram/raw/types/message_action_chat_edit_photo.py +72 -0
- pyrogram/raw/types/message_action_chat_edit_title.py +72 -0
- pyrogram/raw/types/message_action_chat_joined_by_link.py +72 -0
- pyrogram/raw/types/message_action_chat_joined_by_request.py +67 -0
- pyrogram/raw/types/message_action_chat_migrate_to.py +72 -0
- pyrogram/raw/types/message_action_contact_sign_up.py +67 -0
- pyrogram/raw/types/message_action_custom_action.py +72 -0
- pyrogram/raw/types/message_action_empty.py +67 -0
- pyrogram/raw/types/message_action_game_score.py +80 -0
- pyrogram/raw/types/message_action_geo_proximity_reached.py +88 -0
- pyrogram/raw/types/message_action_gift_premium.py +108 -0
- pyrogram/raw/types/message_action_group_call.py +83 -0
- pyrogram/raw/types/message_action_group_call_scheduled.py +80 -0
- pyrogram/raw/types/message_action_history_clear.py +67 -0
- pyrogram/raw/types/message_action_invite_to_group_call.py +80 -0
- pyrogram/raw/types/message_action_payment_sent.py +103 -0
- pyrogram/raw/types/message_action_payment_sent_me.py +129 -0
- pyrogram/raw/types/message_action_phone_call.py +99 -0
- pyrogram/raw/types/message_action_pin_message.py +67 -0
- pyrogram/raw/types/message_action_requested_peer.py +80 -0
- pyrogram/raw/types/message_action_screenshot_taken.py +67 -0
- pyrogram/raw/types/message_action_secure_values_sent.py +72 -0
- pyrogram/raw/types/message_action_secure_values_sent_me.py +80 -0
- pyrogram/raw/types/message_action_set_chat_theme.py +72 -0
- pyrogram/raw/types/message_action_set_chat_wall_paper.py +72 -0
- pyrogram/raw/types/message_action_set_messages_ttl.py +83 -0
- pyrogram/raw/types/message_action_set_same_chat_wall_paper.py +72 -0
- pyrogram/raw/types/message_action_suggest_profile_photo.py +72 -0
- pyrogram/raw/types/message_action_topic_create.py +91 -0
- pyrogram/raw/types/message_action_topic_edit.py +102 -0
- pyrogram/raw/types/message_action_web_view_data_sent.py +72 -0
- pyrogram/raw/types/message_action_web_view_data_sent_me.py +80 -0
- pyrogram/raw/types/message_empty.py +84 -0
- pyrogram/raw/types/message_entity_bank_card.py +80 -0
- pyrogram/raw/types/message_entity_blockquote.py +80 -0
- pyrogram/raw/types/message_entity_bold.py +80 -0
- pyrogram/raw/types/message_entity_bot_command.py +80 -0
- pyrogram/raw/types/message_entity_cashtag.py +80 -0
- pyrogram/raw/types/message_entity_code.py +80 -0
- pyrogram/raw/types/message_entity_custom_emoji.py +88 -0
- pyrogram/raw/types/message_entity_email.py +80 -0
- pyrogram/raw/types/message_entity_hashtag.py +80 -0
- pyrogram/raw/types/message_entity_italic.py +80 -0
- pyrogram/raw/types/message_entity_mention.py +80 -0
- pyrogram/raw/types/message_entity_mention_name.py +88 -0
- pyrogram/raw/types/message_entity_phone.py +80 -0
- pyrogram/raw/types/message_entity_pre.py +88 -0
- pyrogram/raw/types/message_entity_spoiler.py +80 -0
- pyrogram/raw/types/message_entity_strike.py +80 -0
- pyrogram/raw/types/message_entity_text_url.py +88 -0
- pyrogram/raw/types/message_entity_underline.py +80 -0
- pyrogram/raw/types/message_entity_unknown.py +80 -0
- pyrogram/raw/types/message_entity_url.py +80 -0
- pyrogram/raw/types/message_extended_media.py +72 -0
- pyrogram/raw/types/message_extended_media_preview.py +103 -0
- pyrogram/raw/types/message_fwd_header.py +145 -0
- pyrogram/raw/types/message_interaction_counters.py +88 -0
- pyrogram/raw/types/message_media_contact.py +115 -0
- pyrogram/raw/types/message_media_dice.py +91 -0
- pyrogram/raw/types/message_media_document.py +108 -0
- pyrogram/raw/types/message_media_empty.py +78 -0
- pyrogram/raw/types/message_media_game.py +83 -0
- pyrogram/raw/types/message_media_geo.py +83 -0
- pyrogram/raw/types/message_media_geo_live.py +111 -0
- pyrogram/raw/types/message_media_invoice.py +158 -0
- pyrogram/raw/types/message_media_photo.py +102 -0
- pyrogram/raw/types/message_media_poll.py +91 -0
- pyrogram/raw/types/message_media_unsupported.py +78 -0
- pyrogram/raw/types/message_media_venue.py +123 -0
- pyrogram/raw/types/message_media_web_page.py +83 -0
- pyrogram/raw/types/message_peer_reaction.py +102 -0
- pyrogram/raw/types/message_range.py +89 -0
- pyrogram/raw/types/message_reactions.py +96 -0
- pyrogram/raw/types/message_replies.py +125 -0
- pyrogram/raw/types/message_reply_header.py +105 -0
- pyrogram/raw/types/message_service.py +163 -0
- pyrogram/raw/types/message_user_vote.py +88 -0
- pyrogram/raw/types/message_user_vote_input_option.py +80 -0
- pyrogram/raw/types/message_user_vote_multiple.py +88 -0
- pyrogram/raw/types/message_views.py +94 -0
- pyrogram/raw/types/messages/__init__.py +94 -0
- pyrogram/raw/types/messages/affected_found_messages.py +105 -0
- pyrogram/raw/types/messages/affected_history.py +102 -0
- pyrogram/raw/types/messages/affected_messages.py +92 -0
- pyrogram/raw/types/messages/all_stickers.py +91 -0
- pyrogram/raw/types/messages/all_stickers_not_modified.py +78 -0
- pyrogram/raw/types/messages/archived_stickers.py +89 -0
- pyrogram/raw/types/messages/available_reactions.py +89 -0
- pyrogram/raw/types/messages/available_reactions_not_modified.py +76 -0
- pyrogram/raw/types/messages/bot_app.py +95 -0
- pyrogram/raw/types/messages/bot_callback_answer.py +119 -0
- pyrogram/raw/types/messages/bot_results.py +142 -0
- pyrogram/raw/types/messages/channel_messages.py +150 -0
- pyrogram/raw/types/messages/chat_admins_with_invites.py +89 -0
- pyrogram/raw/types/messages/chat_full.py +98 -0
- pyrogram/raw/types/messages/chat_invite_importers.py +97 -0
- pyrogram/raw/types/messages/chats.py +87 -0
- pyrogram/raw/types/messages/chats_slice.py +95 -0
- pyrogram/raw/types/messages/checked_history_import_peer.py +81 -0
- pyrogram/raw/types/messages/dh_config.py +105 -0
- pyrogram/raw/types/messages/dh_config_not_modified.py +81 -0
- pyrogram/raw/types/messages/dialogs.py +105 -0
- pyrogram/raw/types/messages/dialogs_not_modified.py +81 -0
- pyrogram/raw/types/messages/dialogs_slice.py +113 -0
- pyrogram/raw/types/messages/discussion_message.py +134 -0
- pyrogram/raw/types/messages/emoji_groups.py +91 -0
- pyrogram/raw/types/messages/emoji_groups_not_modified.py +78 -0
- pyrogram/raw/types/messages/exported_chat_invite.py +90 -0
- pyrogram/raw/types/messages/exported_chat_invite_replaced.py +98 -0
- pyrogram/raw/types/messages/exported_chat_invites.py +97 -0
- pyrogram/raw/types/messages/faved_stickers.py +97 -0
- pyrogram/raw/types/messages/faved_stickers_not_modified.py +76 -0
- pyrogram/raw/types/messages/featured_stickers.py +115 -0
- pyrogram/raw/types/messages/featured_stickers_not_modified.py +83 -0
- pyrogram/raw/types/messages/forum_topics.py +130 -0
- pyrogram/raw/types/messages/found_sticker_sets.py +89 -0
- pyrogram/raw/types/messages/found_sticker_sets_not_modified.py +76 -0
- pyrogram/raw/types/messages/high_scores.py +90 -0
- pyrogram/raw/types/messages/history_import.py +81 -0
- pyrogram/raw/types/messages/history_import_parsed.py +96 -0
- pyrogram/raw/types/messages/inactive_chats.py +97 -0
- pyrogram/raw/types/messages/message_edit_data.py +81 -0
- pyrogram/raw/types/messages/message_reactions_list.py +116 -0
- pyrogram/raw/types/messages/message_views.py +97 -0
- pyrogram/raw/types/messages/messages.py +109 -0
- pyrogram/raw/types/messages/messages_not_modified.py +93 -0
- pyrogram/raw/types/messages/messages_slice.py +143 -0
- pyrogram/raw/types/messages/peer_dialogs.py +114 -0
- pyrogram/raw/types/messages/peer_settings.py +97 -0
- pyrogram/raw/types/messages/reactions.py +90 -0
- pyrogram/raw/types/messages/reactions_not_modified.py +77 -0
- pyrogram/raw/types/messages/recent_stickers.py +105 -0
- pyrogram/raw/types/messages/recent_stickers_not_modified.py +76 -0
- pyrogram/raw/types/messages/saved_gifs.py +89 -0
- pyrogram/raw/types/messages/saved_gifs_not_modified.py +76 -0
- pyrogram/raw/types/messages/search_counter.py +97 -0
- pyrogram/raw/types/messages/search_results_calendar.py +146 -0
- pyrogram/raw/types/messages/search_results_positions.py +89 -0
- pyrogram/raw/types/messages/sent_encrypted_file.py +91 -0
- pyrogram/raw/types/messages/sent_encrypted_message.py +83 -0
- pyrogram/raw/types/messages/sponsored_messages.py +108 -0
- pyrogram/raw/types/messages/sponsored_messages_empty.py +76 -0
- pyrogram/raw/types/messages/sticker_set.py +112 -0
- pyrogram/raw/types/messages/sticker_set_install_result_archive.py +81 -0
- pyrogram/raw/types/messages/sticker_set_install_result_success.py +76 -0
- pyrogram/raw/types/messages/sticker_set_not_modified.py +83 -0
- pyrogram/raw/types/messages/stickers.py +89 -0
- pyrogram/raw/types/messages/stickers_not_modified.py +76 -0
- pyrogram/raw/types/messages/transcribed_audio.py +97 -0
- pyrogram/raw/types/messages/translate_result.py +81 -0
- pyrogram/raw/types/messages/votes_list.py +108 -0
- pyrogram/raw/types/msg_detailed_info.py +96 -0
- pyrogram/raw/types/msg_new_detailed_info.py +88 -0
- pyrogram/raw/types/msg_resend_ans_req.py +72 -0
- pyrogram/raw/types/msg_resend_req.py +72 -0
- pyrogram/raw/types/msgs_ack.py +72 -0
- pyrogram/raw/types/msgs_all_info.py +80 -0
- pyrogram/raw/types/msgs_state_info.py +80 -0
- pyrogram/raw/types/msgs_state_req.py +72 -0
- pyrogram/raw/types/nearest_dc.py +97 -0
- pyrogram/raw/types/new_session_created.py +88 -0
- pyrogram/raw/types/notification_sound_default.py +67 -0
- pyrogram/raw/types/notification_sound_local.py +80 -0
- pyrogram/raw/types/notification_sound_none.py +67 -0
- pyrogram/raw/types/notification_sound_ringtone.py +72 -0
- pyrogram/raw/types/notify_broadcasts.py +67 -0
- pyrogram/raw/types/notify_chats.py +67 -0
- pyrogram/raw/types/notify_forum_topic.py +80 -0
- pyrogram/raw/types/notify_peer.py +72 -0
- pyrogram/raw/types/notify_users.py +67 -0
- pyrogram/raw/types/page.py +125 -0
- pyrogram/raw/types/page_block_anchor.py +72 -0
- pyrogram/raw/types/page_block_audio.py +80 -0
- pyrogram/raw/types/page_block_author_date.py +80 -0
- pyrogram/raw/types/page_block_blockquote.py +80 -0
- pyrogram/raw/types/page_block_channel.py +72 -0
- pyrogram/raw/types/page_block_collage.py +80 -0
- pyrogram/raw/types/page_block_cover.py +72 -0
- pyrogram/raw/types/page_block_details.py +88 -0
- pyrogram/raw/types/page_block_divider.py +67 -0
- pyrogram/raw/types/page_block_embed.py +131 -0
- pyrogram/raw/types/page_block_embed_post.py +120 -0
- pyrogram/raw/types/page_block_footer.py +72 -0
- pyrogram/raw/types/page_block_header.py +72 -0
- pyrogram/raw/types/page_block_kicker.py +72 -0
- pyrogram/raw/types/page_block_list.py +72 -0
- pyrogram/raw/types/page_block_map.py +104 -0
- pyrogram/raw/types/page_block_ordered_list.py +72 -0
- pyrogram/raw/types/page_block_paragraph.py +72 -0
- pyrogram/raw/types/page_block_photo.py +100 -0
- pyrogram/raw/types/page_block_preformatted.py +80 -0
- pyrogram/raw/types/page_block_pullquote.py +80 -0
- pyrogram/raw/types/page_block_related_articles.py +80 -0
- pyrogram/raw/types/page_block_slideshow.py +80 -0
- pyrogram/raw/types/page_block_subheader.py +72 -0
- pyrogram/raw/types/page_block_subtitle.py +72 -0
- pyrogram/raw/types/page_block_table.py +94 -0
- pyrogram/raw/types/page_block_title.py +72 -0
- pyrogram/raw/types/page_block_unsupported.py +67 -0
- pyrogram/raw/types/page_block_video.py +94 -0
- pyrogram/raw/types/page_caption.py +80 -0
- pyrogram/raw/types/page_list_item_blocks.py +72 -0
- pyrogram/raw/types/page_list_item_text.py +72 -0
- pyrogram/raw/types/page_list_ordered_item_blocks.py +80 -0
- pyrogram/raw/types/page_list_ordered_item_text.py +80 -0
- pyrogram/raw/types/page_related_article.py +127 -0
- pyrogram/raw/types/page_table_cell.py +124 -0
- pyrogram/raw/types/page_table_row.py +72 -0
- pyrogram/raw/types/password_kdf_algo_sha256_sha256_pbkdf2_hmacsha512iter100000_sha256_mod_pow.py +96 -0
- pyrogram/raw/types/password_kdf_algo_unknown.py +67 -0
- pyrogram/raw/types/payment_charge.py +80 -0
- pyrogram/raw/types/payment_form_method.py +80 -0
- pyrogram/raw/types/payment_requested_info.py +103 -0
- pyrogram/raw/types/payment_saved_credentials_card.py +80 -0
- pyrogram/raw/types/payments/__init__.py +32 -0
- pyrogram/raw/types/payments/bank_card_data.py +89 -0
- pyrogram/raw/types/payments/exported_invoice.py +81 -0
- pyrogram/raw/types/payments/payment_form.py +210 -0
- pyrogram/raw/types/payments/payment_receipt.py +194 -0
- pyrogram/raw/types/payments/payment_result.py +81 -0
- pyrogram/raw/types/payments/payment_verification_needed.py +81 -0
- pyrogram/raw/types/payments/saved_info.py +91 -0
- pyrogram/raw/types/payments/validated_requested_info.py +94 -0
- pyrogram/raw/types/peer_blocked.py +80 -0
- pyrogram/raw/types/peer_channel.py +81 -0
- pyrogram/raw/types/peer_chat.py +81 -0
- pyrogram/raw/types/peer_located.py +88 -0
- pyrogram/raw/types/peer_notify_settings.py +132 -0
- pyrogram/raw/types/peer_self_located.py +72 -0
- pyrogram/raw/types/peer_settings.py +147 -0
- pyrogram/raw/types/peer_user.py +81 -0
- pyrogram/raw/types/phone/__init__.py +31 -0
- pyrogram/raw/types/phone/exported_group_call_invite.py +81 -0
- pyrogram/raw/types/phone/group_call.py +113 -0
- pyrogram/raw/types/phone/group_call_stream_channels.py +81 -0
- pyrogram/raw/types/phone/group_call_stream_rtmp_url.py +89 -0
- pyrogram/raw/types/phone/group_participants.py +121 -0
- pyrogram/raw/types/phone/join_as_peers.py +97 -0
- pyrogram/raw/types/phone/phone_call.py +91 -0
- pyrogram/raw/types/phone_call.py +158 -0
- pyrogram/raw/types/phone_call_accepted.py +128 -0
- pyrogram/raw/types/phone_call_discard_reason_busy.py +67 -0
- pyrogram/raw/types/phone_call_discard_reason_disconnect.py +67 -0
- pyrogram/raw/types/phone_call_discard_reason_hangup.py +67 -0
- pyrogram/raw/types/phone_call_discard_reason_missed.py +67 -0
- pyrogram/raw/types/phone_call_discarded.py +111 -0
- pyrogram/raw/types/phone_call_empty.py +72 -0
- pyrogram/raw/types/phone_call_protocol.py +102 -0
- pyrogram/raw/types/phone_call_requested.py +128 -0
- pyrogram/raw/types/phone_call_waiting.py +129 -0
- pyrogram/raw/types/phone_connection.py +112 -0
- pyrogram/raw/types/phone_connection_webrtc.py +126 -0
- pyrogram/raw/types/photo.py +130 -0
- pyrogram/raw/types/photo_cached_size.py +96 -0
- pyrogram/raw/types/photo_empty.py +72 -0
- pyrogram/raw/types/photo_path_size.py +80 -0
- pyrogram/raw/types/photo_size.py +96 -0
- pyrogram/raw/types/photo_size_empty.py +72 -0
- pyrogram/raw/types/photo_size_progressive.py +96 -0
- pyrogram/raw/types/photo_stripped_size.py +80 -0
- pyrogram/raw/types/photos/__init__.py +27 -0
- pyrogram/raw/types/photos/photo.py +91 -0
- pyrogram/raw/types/photos/photos.py +89 -0
- pyrogram/raw/types/photos/photos_slice.py +97 -0
- pyrogram/raw/types/poll.py +132 -0
- pyrogram/raw/types/poll_answer.py +80 -0
- pyrogram/raw/types/poll_answer_voters.py +94 -0
- pyrogram/raw/types/poll_results.py +120 -0
- pyrogram/raw/types/pong.py +90 -0
- pyrogram/raw/types/popular_contact.py +80 -0
- pyrogram/raw/types/post_address.py +112 -0
- pyrogram/raw/types/pq_inner_data.py +112 -0
- pyrogram/raw/types/pq_inner_data_dc.py +120 -0
- pyrogram/raw/types/pq_inner_data_temp.py +120 -0
- pyrogram/raw/types/pq_inner_data_temp_dc.py +128 -0
- pyrogram/raw/types/premium_gift_option.py +107 -0
- pyrogram/raw/types/premium_subscription_option.py +128 -0
- pyrogram/raw/types/privacy_key_added_by_phone.py +67 -0
- pyrogram/raw/types/privacy_key_chat_invite.py +67 -0
- pyrogram/raw/types/privacy_key_forwards.py +67 -0
- pyrogram/raw/types/privacy_key_phone_call.py +67 -0
- pyrogram/raw/types/privacy_key_phone_number.py +67 -0
- pyrogram/raw/types/privacy_key_phone_p2_p.py +67 -0
- pyrogram/raw/types/privacy_key_profile_photo.py +67 -0
- pyrogram/raw/types/privacy_key_status_timestamp.py +67 -0
- pyrogram/raw/types/privacy_key_voice_messages.py +67 -0
- pyrogram/raw/types/privacy_value_allow_all.py +67 -0
- pyrogram/raw/types/privacy_value_allow_chat_participants.py +72 -0
- pyrogram/raw/types/privacy_value_allow_contacts.py +67 -0
- pyrogram/raw/types/privacy_value_allow_users.py +72 -0
- pyrogram/raw/types/privacy_value_disallow_all.py +67 -0
- pyrogram/raw/types/privacy_value_disallow_chat_participants.py +72 -0
- pyrogram/raw/types/privacy_value_disallow_contacts.py +67 -0
- pyrogram/raw/types/privacy_value_disallow_users.py +72 -0
- pyrogram/raw/types/reaction_count.py +91 -0
- pyrogram/raw/types/reaction_custom_emoji.py +72 -0
- pyrogram/raw/types/reaction_emoji.py +72 -0
- pyrogram/raw/types/reaction_empty.py +67 -0
- pyrogram/raw/types/read_participant_date.py +89 -0
- pyrogram/raw/types/received_notify_message.py +89 -0
- pyrogram/raw/types/recent_me_url_chat.py +80 -0
- pyrogram/raw/types/recent_me_url_chat_invite.py +80 -0
- pyrogram/raw/types/recent_me_url_sticker_set.py +80 -0
- pyrogram/raw/types/recent_me_url_unknown.py +72 -0
- pyrogram/raw/types/recent_me_url_user.py +80 -0
- pyrogram/raw/types/reply_inline_markup.py +72 -0
- pyrogram/raw/types/reply_keyboard_force_reply.py +87 -0
- pyrogram/raw/types/reply_keyboard_hide.py +72 -0
- pyrogram/raw/types/reply_keyboard_markup.py +107 -0
- pyrogram/raw/types/request_peer_type_broadcast.py +101 -0
- pyrogram/raw/types/request_peer_type_chat.py +116 -0
- pyrogram/raw/types/request_peer_type_user.py +84 -0
- pyrogram/raw/types/res_pq.py +106 -0
- pyrogram/raw/types/restriction_reason.py +88 -0
- pyrogram/raw/types/rpc_answer_dropped.py +97 -0
- pyrogram/raw/types/rpc_answer_dropped_running.py +76 -0
- pyrogram/raw/types/rpc_answer_unknown.py +76 -0
- pyrogram/raw/types/rpc_error.py +80 -0
- pyrogram/raw/types/rpc_result.py +80 -0
- pyrogram/raw/types/saved_phone_contact.py +105 -0
- pyrogram/raw/types/search_result_position.py +88 -0
- pyrogram/raw/types/search_results_calendar_period.py +96 -0
- pyrogram/raw/types/secure_credentials_encrypted.py +88 -0
- pyrogram/raw/types/secure_data.py +88 -0
- pyrogram/raw/types/secure_file.py +120 -0
- pyrogram/raw/types/secure_file_empty.py +67 -0
- pyrogram/raw/types/secure_password_kdf_algo_pbkdf2_hmacsha512iter100000.py +72 -0
- pyrogram/raw/types/secure_password_kdf_algo_sha512.py +72 -0
- pyrogram/raw/types/secure_password_kdf_algo_unknown.py +67 -0
- pyrogram/raw/types/secure_plain_email.py +72 -0
- pyrogram/raw/types/secure_plain_phone.py +72 -0
- pyrogram/raw/types/secure_required_type.py +92 -0
- pyrogram/raw/types/secure_required_type_one_of.py +72 -0
- pyrogram/raw/types/secure_secret_settings.py +88 -0
- pyrogram/raw/types/secure_value.py +163 -0
- pyrogram/raw/types/secure_value_error.py +88 -0
- pyrogram/raw/types/secure_value_error_data.py +96 -0
- pyrogram/raw/types/secure_value_error_file.py +88 -0
- pyrogram/raw/types/secure_value_error_files.py +88 -0
- pyrogram/raw/types/secure_value_error_front_side.py +88 -0
- pyrogram/raw/types/secure_value_error_reverse_side.py +88 -0
- pyrogram/raw/types/secure_value_error_selfie.py +88 -0
- pyrogram/raw/types/secure_value_error_translation_file.py +88 -0
- pyrogram/raw/types/secure_value_error_translation_files.py +88 -0
- pyrogram/raw/types/secure_value_hash.py +80 -0
- pyrogram/raw/types/secure_value_type_address.py +67 -0
- pyrogram/raw/types/secure_value_type_bank_statement.py +67 -0
- pyrogram/raw/types/secure_value_type_driver_license.py +67 -0
- pyrogram/raw/types/secure_value_type_email.py +67 -0
- pyrogram/raw/types/secure_value_type_identity_card.py +67 -0
- pyrogram/raw/types/secure_value_type_internal_passport.py +67 -0
- pyrogram/raw/types/secure_value_type_passport.py +67 -0
- pyrogram/raw/types/secure_value_type_passport_registration.py +67 -0
- pyrogram/raw/types/secure_value_type_personal_details.py +67 -0
- pyrogram/raw/types/secure_value_type_phone.py +67 -0
- pyrogram/raw/types/secure_value_type_rental_agreement.py +67 -0
- pyrogram/raw/types/secure_value_type_temporary_registration.py +67 -0
- pyrogram/raw/types/secure_value_type_utility_bill.py +67 -0
- pyrogram/raw/types/send_as_peer.py +80 -0
- pyrogram/raw/types/send_message_cancel_action.py +67 -0
- pyrogram/raw/types/send_message_choose_contact_action.py +67 -0
- pyrogram/raw/types/send_message_choose_sticker_action.py +67 -0
- pyrogram/raw/types/send_message_emoji_interaction.py +88 -0
- pyrogram/raw/types/send_message_emoji_interaction_seen.py +72 -0
- pyrogram/raw/types/send_message_game_play_action.py +67 -0
- pyrogram/raw/types/send_message_geo_location_action.py +67 -0
- pyrogram/raw/types/send_message_history_import_action.py +72 -0
- pyrogram/raw/types/send_message_record_audio_action.py +67 -0
- pyrogram/raw/types/send_message_record_round_action.py +67 -0
- pyrogram/raw/types/send_message_record_video_action.py +67 -0
- pyrogram/raw/types/send_message_typing_action.py +67 -0
- pyrogram/raw/types/send_message_upload_audio_action.py +72 -0
- pyrogram/raw/types/send_message_upload_document_action.py +72 -0
- pyrogram/raw/types/send_message_upload_photo_action.py +72 -0
- pyrogram/raw/types/send_message_upload_round_action.py +72 -0
- pyrogram/raw/types/send_message_upload_video_action.py +72 -0
- pyrogram/raw/types/server_dh_inner_data.py +112 -0
- pyrogram/raw/types/server_dh_params_fail.py +97 -0
- pyrogram/raw/types/server_dh_params_ok.py +97 -0
- pyrogram/raw/types/shipping_option.py +88 -0
- pyrogram/raw/types/simple_web_view_result_url.py +81 -0
- pyrogram/raw/types/speaking_in_group_call_action.py +67 -0
- pyrogram/raw/types/sponsored_message.py +169 -0
- pyrogram/raw/types/stats/__init__.py +27 -0
- pyrogram/raw/types/stats/broadcast_stats.py +193 -0
- pyrogram/raw/types/stats/megagroup_stats.py +209 -0
- pyrogram/raw/types/stats/message_stats.py +81 -0
- pyrogram/raw/types/stats_abs_value_and_prev.py +80 -0
- pyrogram/raw/types/stats_date_range_days.py +80 -0
- pyrogram/raw/types/stats_graph.py +92 -0
- pyrogram/raw/types/stats_graph_async.py +81 -0
- pyrogram/raw/types/stats_graph_error.py +81 -0
- pyrogram/raw/types/stats_group_top_admin.py +96 -0
- pyrogram/raw/types/stats_group_top_inviter.py +80 -0
- pyrogram/raw/types/stats_group_top_poster.py +88 -0
- pyrogram/raw/types/stats_percent_value.py +80 -0
- pyrogram/raw/types/stats_url.py +72 -0
- pyrogram/raw/types/sticker_keyword.py +80 -0
- pyrogram/raw/types/sticker_pack.py +80 -0
- pyrogram/raw/types/sticker_set.py +196 -0
- pyrogram/raw/types/sticker_set_covered.py +89 -0
- pyrogram/raw/types/sticker_set_full_covered.py +105 -0
- pyrogram/raw/types/sticker_set_multi_covered.py +89 -0
- pyrogram/raw/types/sticker_set_no_covered.py +81 -0
- pyrogram/raw/types/stickers/__init__.py +25 -0
- pyrogram/raw/types/stickers/suggested_short_name.py +81 -0
- pyrogram/raw/types/storage/__init__.py +34 -0
- pyrogram/raw/types/storage/file_gif.py +67 -0
- pyrogram/raw/types/storage/file_jpeg.py +67 -0
- pyrogram/raw/types/storage/file_mov.py +67 -0
- pyrogram/raw/types/storage/file_mp3.py +67 -0
- pyrogram/raw/types/storage/file_mp4.py +67 -0
- pyrogram/raw/types/storage/file_partial.py +67 -0
- pyrogram/raw/types/storage/file_pdf.py +67 -0
- pyrogram/raw/types/storage/file_png.py +67 -0
- pyrogram/raw/types/storage/file_unknown.py +67 -0
- pyrogram/raw/types/storage/file_webp.py +67 -0
- pyrogram/raw/types/text_anchor.py +80 -0
- pyrogram/raw/types/text_bold.py +72 -0
- pyrogram/raw/types/text_concat.py +72 -0
- pyrogram/raw/types/text_email.py +80 -0
- pyrogram/raw/types/text_empty.py +67 -0
- pyrogram/raw/types/text_fixed.py +72 -0
- pyrogram/raw/types/text_image.py +88 -0
- pyrogram/raw/types/text_italic.py +72 -0
- pyrogram/raw/types/text_marked.py +72 -0
- pyrogram/raw/types/text_phone.py +80 -0
- pyrogram/raw/types/text_plain.py +72 -0
- pyrogram/raw/types/text_strike.py +72 -0
- pyrogram/raw/types/text_subscript.py +72 -0
- pyrogram/raw/types/text_superscript.py +72 -0
- pyrogram/raw/types/text_underline.py +72 -0
- pyrogram/raw/types/text_url.py +88 -0
- pyrogram/raw/types/text_with_entities.py +80 -0
- pyrogram/raw/types/theme.py +165 -0
- pyrogram/raw/types/theme_settings.py +117 -0
- pyrogram/raw/types/top_peer.py +80 -0
- pyrogram/raw/types/top_peer_category_bots_inline.py +67 -0
- pyrogram/raw/types/top_peer_category_bots_pm.py +67 -0
- pyrogram/raw/types/top_peer_category_channels.py +67 -0
- pyrogram/raw/types/top_peer_category_correspondents.py +67 -0
- pyrogram/raw/types/top_peer_category_forward_chats.py +67 -0
- pyrogram/raw/types/top_peer_category_forward_users.py +67 -0
- pyrogram/raw/types/top_peer_category_groups.py +67 -0
- pyrogram/raw/types/top_peer_category_peers.py +88 -0
- pyrogram/raw/types/top_peer_category_phone_calls.py +67 -0
- pyrogram/raw/types/update_attach_menu_bots.py +67 -0
- pyrogram/raw/types/update_auto_save_settings.py +67 -0
- pyrogram/raw/types/update_bot_callback_query.py +124 -0
- pyrogram/raw/types/update_bot_chat_invite_requester.py +112 -0
- pyrogram/raw/types/update_bot_commands.py +88 -0
- pyrogram/raw/types/update_bot_inline_query.py +118 -0
- pyrogram/raw/types/update_bot_inline_send.py +110 -0
- pyrogram/raw/types/update_bot_menu_button.py +80 -0
- pyrogram/raw/types/update_bot_precheckout_query.py +125 -0
- pyrogram/raw/types/update_bot_shipping_query.py +96 -0
- pyrogram/raw/types/update_bot_stopped.py +96 -0
- pyrogram/raw/types/update_bot_webhook_json.py +72 -0
- pyrogram/raw/types/update_bot_webhook_json_query.py +88 -0
- pyrogram/raw/types/update_channel.py +72 -0
- pyrogram/raw/types/update_channel_available_messages.py +80 -0
- pyrogram/raw/types/update_channel_message_forwards.py +88 -0
- pyrogram/raw/types/update_channel_message_views.py +88 -0
- pyrogram/raw/types/update_channel_participant.py +142 -0
- pyrogram/raw/types/update_channel_pinned_topic.py +88 -0
- pyrogram/raw/types/update_channel_pinned_topics.py +84 -0
- pyrogram/raw/types/update_channel_read_messages_contents.py +91 -0
- pyrogram/raw/types/update_channel_too_long.py +83 -0
- pyrogram/raw/types/update_channel_user_typing.py +99 -0
- pyrogram/raw/types/update_channel_web_page.py +96 -0
- pyrogram/raw/types/update_chat.py +72 -0
- pyrogram/raw/types/update_chat_default_banned_rights.py +88 -0
- pyrogram/raw/types/update_chat_participant.py +136 -0
- pyrogram/raw/types/update_chat_participant_add.py +104 -0
- pyrogram/raw/types/update_chat_participant_admin.py +96 -0
- pyrogram/raw/types/update_chat_participant_delete.py +88 -0
- pyrogram/raw/types/update_chat_participants.py +72 -0
- pyrogram/raw/types/update_chat_user_typing.py +88 -0
- pyrogram/raw/types/update_config.py +67 -0
- pyrogram/raw/types/update_contacts_reset.py +67 -0
- pyrogram/raw/types/update_dc_options.py +72 -0
- pyrogram/raw/types/update_delete_channel_messages.py +96 -0
- pyrogram/raw/types/update_delete_messages.py +88 -0
- pyrogram/raw/types/update_delete_scheduled_messages.py +80 -0
- pyrogram/raw/types/update_dialog_filter.py +84 -0
- pyrogram/raw/types/update_dialog_filter_order.py +72 -0
- pyrogram/raw/types/update_dialog_filters.py +67 -0
- pyrogram/raw/types/update_dialog_pinned.py +89 -0
- pyrogram/raw/types/update_dialog_unread_mark.py +80 -0
- pyrogram/raw/types/update_draft_message.py +91 -0
- pyrogram/raw/types/update_edit_channel_message.py +88 -0
- pyrogram/raw/types/update_edit_message.py +88 -0
- pyrogram/raw/types/update_encrypted_chat_typing.py +72 -0
- pyrogram/raw/types/update_encrypted_messages_read.py +88 -0
- pyrogram/raw/types/update_encryption.py +80 -0
- pyrogram/raw/types/update_faved_stickers.py +67 -0
- pyrogram/raw/types/update_folder_peers.py +88 -0
- pyrogram/raw/types/update_geo_live_viewed.py +80 -0
- pyrogram/raw/types/update_group_call.py +80 -0
- pyrogram/raw/types/update_group_call_connection.py +80 -0
- pyrogram/raw/types/update_group_call_participants.py +88 -0
- pyrogram/raw/types/update_group_invite_privacy_forbidden.py +72 -0
- pyrogram/raw/types/update_inline_bot_callback_query.py +116 -0
- pyrogram/raw/types/update_lang_pack.py +72 -0
- pyrogram/raw/types/update_lang_pack_too_long.py +72 -0
- pyrogram/raw/types/update_login_token.py +67 -0
- pyrogram/raw/types/update_message_extended_media.py +88 -0
- pyrogram/raw/types/update_message_id.py +80 -0
- pyrogram/raw/types/update_message_poll.py +92 -0
- pyrogram/raw/types/update_message_poll_vote.py +96 -0
- pyrogram/raw/types/update_message_reactions.py +99 -0
- pyrogram/raw/types/update_move_sticker_set_to_top.py +86 -0
- pyrogram/raw/types/update_new_channel_message.py +88 -0
- pyrogram/raw/types/update_new_encrypted_message.py +80 -0
- pyrogram/raw/types/update_new_message.py +88 -0
- pyrogram/raw/types/update_new_scheduled_message.py +72 -0
- pyrogram/raw/types/update_new_sticker_set.py +72 -0
- pyrogram/raw/types/update_notify_settings.py +80 -0
- pyrogram/raw/types/update_peer_blocked.py +80 -0
- pyrogram/raw/types/update_peer_history_ttl.py +83 -0
- pyrogram/raw/types/update_peer_located.py +72 -0
- pyrogram/raw/types/update_peer_settings.py +80 -0
- pyrogram/raw/types/update_pending_join_requests.py +88 -0
- pyrogram/raw/types/update_phone_call.py +72 -0
- pyrogram/raw/types/update_phone_call_signaling_data.py +80 -0
- pyrogram/raw/types/update_pinned_channel_messages.py +104 -0
- pyrogram/raw/types/update_pinned_dialogs.py +85 -0
- pyrogram/raw/types/update_pinned_messages.py +104 -0
- pyrogram/raw/types/update_privacy.py +80 -0
- pyrogram/raw/types/update_pts_changed.py +67 -0
- pyrogram/raw/types/update_read_channel_discussion_inbox.py +108 -0
- pyrogram/raw/types/update_read_channel_discussion_outbox.py +88 -0
- pyrogram/raw/types/update_read_channel_inbox.py +107 -0
- pyrogram/raw/types/update_read_channel_outbox.py +80 -0
- pyrogram/raw/types/update_read_featured_emoji_stickers.py +67 -0
- pyrogram/raw/types/update_read_featured_stickers.py +67 -0
- pyrogram/raw/types/update_read_history_inbox.py +115 -0
- pyrogram/raw/types/update_read_history_outbox.py +96 -0
- pyrogram/raw/types/update_read_messages_contents.py +88 -0
- pyrogram/raw/types/update_recent_emoji_statuses.py +67 -0
- pyrogram/raw/types/update_recent_reactions.py +67 -0
- pyrogram/raw/types/update_recent_stickers.py +67 -0
- pyrogram/raw/types/update_saved_gifs.py +67 -0
- pyrogram/raw/types/update_saved_ringtones.py +67 -0
- pyrogram/raw/types/update_service_notification.py +113 -0
- pyrogram/raw/types/update_short.py +175 -0
- pyrogram/raw/types/update_short_chat_message.py +289 -0
- pyrogram/raw/types/update_short_message.py +281 -0
- pyrogram/raw/types/update_short_sent_message.py +228 -0
- pyrogram/raw/types/update_sticker_sets.py +78 -0
- pyrogram/raw/types/update_sticker_sets_order.py +86 -0
- pyrogram/raw/types/update_theme.py +72 -0
- pyrogram/raw/types/update_transcribed_audio.py +104 -0
- pyrogram/raw/types/update_user.py +72 -0
- pyrogram/raw/types/update_user_emoji_status.py +80 -0
- pyrogram/raw/types/update_user_name.py +96 -0
- pyrogram/raw/types/update_user_phone.py +80 -0
- pyrogram/raw/types/update_user_status.py +80 -0
- pyrogram/raw/types/update_user_typing.py +80 -0
- pyrogram/raw/types/update_web_page.py +88 -0
- pyrogram/raw/types/update_web_view_result_sent.py +72 -0
- pyrogram/raw/types/updates/__init__.py +32 -0
- pyrogram/raw/types/updates/channel_difference.py +130 -0
- pyrogram/raw/types/updates/channel_difference_empty.py +98 -0
- pyrogram/raw/types/updates/channel_difference_too_long.py +122 -0
- pyrogram/raw/types/updates/difference.py +121 -0
- pyrogram/raw/types/updates/difference_empty.py +89 -0
- pyrogram/raw/types/updates/difference_slice.py +121 -0
- pyrogram/raw/types/updates/difference_too_long.py +81 -0
- pyrogram/raw/types/updates/state.py +113 -0
- pyrogram/raw/types/updates_combined.py +207 -0
- pyrogram/raw/types/updates_t.py +199 -0
- pyrogram/raw/types/updates_too_long.py +162 -0
- pyrogram/raw/types/upload/__init__.py +29 -0
- pyrogram/raw/types/upload/cdn_file.py +81 -0
- pyrogram/raw/types/upload/cdn_file_reupload_needed.py +81 -0
- pyrogram/raw/types/upload/file.py +97 -0
- pyrogram/raw/types/upload/file_cdn_redirect.py +113 -0
- pyrogram/raw/types/upload/web_file.py +113 -0
- pyrogram/raw/types/url_auth_result_accepted.py +82 -0
- pyrogram/raw/types/url_auth_result_default.py +77 -0
- pyrogram/raw/types/url_auth_result_request.py +98 -0
- pyrogram/raw/types/user.py +327 -0
- pyrogram/raw/types/user_empty.py +85 -0
- pyrogram/raw/types/user_full.py +280 -0
- pyrogram/raw/types/user_profile_photo.py +103 -0
- pyrogram/raw/types/user_profile_photo_empty.py +67 -0
- pyrogram/raw/types/user_status_empty.py +67 -0
- pyrogram/raw/types/user_status_last_month.py +67 -0
- pyrogram/raw/types/user_status_last_week.py +67 -0
- pyrogram/raw/types/user_status_offline.py +72 -0
- pyrogram/raw/types/user_status_online.py +72 -0
- pyrogram/raw/types/user_status_recently.py +67 -0
- pyrogram/raw/types/username.py +86 -0
- pyrogram/raw/types/users/__init__.py +25 -0
- pyrogram/raw/types/users/user_full.py +97 -0
- pyrogram/raw/types/video_size.py +107 -0
- pyrogram/raw/types/video_size_emoji_markup.py +80 -0
- pyrogram/raw/types/video_size_sticker_markup.py +88 -0
- pyrogram/raw/types/wall_paper.py +143 -0
- pyrogram/raw/types/wall_paper_no_file.py +107 -0
- pyrogram/raw/types/wall_paper_settings.py +132 -0
- pyrogram/raw/types/web_authorization.py +136 -0
- pyrogram/raw/types/web_document.py +104 -0
- pyrogram/raw/types/web_document_no_proxy.py +96 -0
- pyrogram/raw/types/web_page.py +237 -0
- pyrogram/raw/types/web_page_attribute_theme.py +86 -0
- pyrogram/raw/types/web_page_empty.py +81 -0
- pyrogram/raw/types/web_page_not_modified.py +84 -0
- pyrogram/raw/types/web_page_pending.py +89 -0
- pyrogram/raw/types/web_view_message_sent.py +85 -0
- pyrogram/raw/types/web_view_result_url.py +89 -0
- pyrogram/session/__init__.py +20 -0
- pyrogram/session/auth.py +281 -0
- pyrogram/session/internals/__init__.py +21 -0
- pyrogram/session/internals/data_center.py +83 -0
- pyrogram/session/internals/msg_factory.py +38 -0
- pyrogram/session/internals/msg_id.py +35 -0
- pyrogram/session/internals/seq_no.py +30 -0
- pyrogram/session/session.py +412 -0
- pyrogram/storage/__init__.py +21 -0
- pyrogram/storage/file_storage.py +69 -0
- pyrogram/storage/memory_storage.py +73 -0
- pyrogram/storage/sqlite_storage.py +222 -0
- pyrogram/storage/storage.py +91 -0
- pyrogram/sync.py +113 -0
- pyrogram/types/__init__.py +28 -0
- pyrogram/types/authorization/__init__.py +22 -0
- pyrogram/types/authorization/sent_code.py +62 -0
- pyrogram/types/authorization/terms_of_service.py +56 -0
- pyrogram/types/bots_and_keyboards/__init__.py +71 -0
- pyrogram/types/bots_and_keyboards/bot_command.py +53 -0
- pyrogram/types/bots_and_keyboards/bot_command_scope.py +73 -0
- pyrogram/types/bots_and_keyboards/bot_command_scope_all_chat_administrators.py +32 -0
- pyrogram/types/bots_and_keyboards/bot_command_scope_all_group_chats.py +32 -0
- pyrogram/types/bots_and_keyboards/bot_command_scope_all_private_chats.py +32 -0
- pyrogram/types/bots_and_keyboards/bot_command_scope_chat.py +43 -0
- pyrogram/types/bots_and_keyboards/bot_command_scope_chat_administrators.py +43 -0
- pyrogram/types/bots_and_keyboards/bot_command_scope_chat_member.py +48 -0
- pyrogram/types/bots_and_keyboards/bot_command_scope_default.py +33 -0
- pyrogram/types/bots_and_keyboards/callback_game.py +29 -0
- pyrogram/types/bots_and_keyboards/callback_query.py +313 -0
- pyrogram/types/bots_and_keyboards/force_reply.py +66 -0
- pyrogram/types/bots_and_keyboards/game_high_score.py +70 -0
- pyrogram/types/bots_and_keyboards/inline_keyboard_button.py +208 -0
- pyrogram/types/bots_and_keyboards/inline_keyboard_markup.py +76 -0
- pyrogram/types/bots_and_keyboards/keyboard_button.py +95 -0
- pyrogram/types/bots_and_keyboards/login_url.py +90 -0
- pyrogram/types/bots_and_keyboards/menu_button.py +44 -0
- pyrogram/types/bots_and_keyboards/menu_button_commands.py +32 -0
- pyrogram/types/bots_and_keyboards/menu_button_default.py +32 -0
- pyrogram/types/bots_and_keyboards/menu_button_web_app.py +51 -0
- pyrogram/types/bots_and_keyboards/reply_keyboard_markup.py +112 -0
- pyrogram/types/bots_and_keyboards/reply_keyboard_remove.py +58 -0
- pyrogram/types/bots_and_keyboards/sent_web_app_message.py +42 -0
- pyrogram/types/bots_and_keyboards/web_app_info.py +37 -0
- pyrogram/types/inline_mode/__init__.py +47 -0
- pyrogram/types/inline_mode/chosen_inline_result.py +99 -0
- pyrogram/types/inline_mode/inline_query.py +181 -0
- pyrogram/types/inline_mode/inline_query_result.py +63 -0
- pyrogram/types/inline_mode/inline_query_result_animation.py +155 -0
- pyrogram/types/inline_mode/inline_query_result_article.py +99 -0
- pyrogram/types/inline_mode/inline_query_result_audio.py +120 -0
- pyrogram/types/inline_mode/inline_query_result_cached_animation.py +108 -0
- pyrogram/types/inline_mode/inline_query_result_cached_audio.py +101 -0
- pyrogram/types/inline_mode/inline_query_result_cached_document.py +113 -0
- pyrogram/types/inline_mode/inline_query_result_cached_photo.py +111 -0
- pyrogram/types/inline_mode/inline_query_result_cached_sticker.py +78 -0
- pyrogram/types/inline_mode/inline_query_result_cached_video.py +114 -0
- pyrogram/types/inline_mode/inline_query_result_cached_voice.py +108 -0
- pyrogram/types/inline_mode/inline_query_result_contact.py +114 -0
- pyrogram/types/inline_mode/inline_query_result_document.py +145 -0
- pyrogram/types/inline_mode/inline_query_result_location.py +122 -0
- pyrogram/types/inline_mode/inline_query_result_photo.py +147 -0
- pyrogram/types/inline_mode/inline_query_result_venue.py +131 -0
- pyrogram/types/inline_mode/inline_query_result_video.py +151 -0
- pyrogram/types/inline_mode/inline_query_result_voice.py +114 -0
- pyrogram/types/input_media/__init__.py +30 -0
- pyrogram/types/input_media/input_media.py +49 -0
- pyrogram/types/input_media/input_media_animation.py +85 -0
- pyrogram/types/input_media/input_media_audio.py +82 -0
- pyrogram/types/input_media/input_media_document.py +65 -0
- pyrogram/types/input_media/input_media_photo.py +63 -0
- pyrogram/types/input_media/input_media_video.py +91 -0
- pyrogram/types/input_media/input_phone_contact.py +51 -0
- pyrogram/types/input_message_content/__init__.py +24 -0
- pyrogram/types/input_message_content/input_message_content.py +40 -0
- pyrogram/types/input_message_content/input_text_message_content.py +68 -0
- pyrogram/types/list.py +30 -0
- pyrogram/types/messages_and_media/__init__.py +47 -0
- pyrogram/types/messages_and_media/animation.py +121 -0
- pyrogram/types/messages_and_media/audio.py +121 -0
- pyrogram/types/messages_and_media/contact.py +71 -0
- pyrogram/types/messages_and_media/dice.py +47 -0
- pyrogram/types/messages_and_media/document.py +98 -0
- pyrogram/types/messages_and_media/game.py +99 -0
- pyrogram/types/messages_and_media/location.py +55 -0
- pyrogram/types/messages_and_media/message.py +3590 -0
- pyrogram/types/messages_and_media/message_entity.py +124 -0
- pyrogram/types/messages_and_media/message_reactions.py +56 -0
- pyrogram/types/messages_and_media/photo.py +130 -0
- pyrogram/types/messages_and_media/poll.py +203 -0
- pyrogram/types/messages_and_media/poll_option.py +50 -0
- pyrogram/types/messages_and_media/reaction.py +86 -0
- pyrogram/types/messages_and_media/sticker.py +206 -0
- pyrogram/types/messages_and_media/stripped_thumbnail.py +47 -0
- pyrogram/types/messages_and_media/thumbnail.py +111 -0
- pyrogram/types/messages_and_media/venue.py +74 -0
- pyrogram/types/messages_and_media/video.py +134 -0
- pyrogram/types/messages_and_media/video_note.py +108 -0
- pyrogram/types/messages_and_media/voice.py +96 -0
- pyrogram/types/messages_and_media/web_app_data.py +51 -0
- pyrogram/types/messages_and_media/web_page.py +187 -0
- pyrogram/types/object.py +121 -0
- pyrogram/types/update.py +27 -0
- pyrogram/types/user_and_chats/__init__.py +67 -0
- pyrogram/types/user_and_chats/chat.py +963 -0
- pyrogram/types/user_and_chats/chat_admin_with_invite_links.py +63 -0
- pyrogram/types/user_and_chats/chat_event.py +489 -0
- pyrogram/types/user_and_chats/chat_event_filter.py +175 -0
- pyrogram/types/user_and_chats/chat_invite_link.py +130 -0
- pyrogram/types/user_and_chats/chat_join_request.py +139 -0
- pyrogram/types/user_and_chats/chat_joiner.py +82 -0
- pyrogram/types/user_and_chats/chat_member.py +227 -0
- pyrogram/types/user_and_chats/chat_member_updated.py +102 -0
- pyrogram/types/user_and_chats/chat_permissions.py +98 -0
- pyrogram/types/user_and_chats/chat_photo.py +107 -0
- pyrogram/types/user_and_chats/chat_preview.py +79 -0
- pyrogram/types/user_and_chats/chat_privileges.py +112 -0
- pyrogram/types/user_and_chats/chat_reactions.py +69 -0
- pyrogram/types/user_and_chats/dialog.py +79 -0
- pyrogram/types/user_and_chats/emoji_status.py +77 -0
- pyrogram/types/user_and_chats/invite_link_importer.py +61 -0
- pyrogram/types/user_and_chats/restriction.py +50 -0
- pyrogram/types/user_and_chats/user.py +399 -0
- pyrogram/types/user_and_chats/video_chat_ended.py +41 -0
- pyrogram/types/user_and_chats/video_chat_members_invited.py +50 -0
- pyrogram/types/user_and_chats/video_chat_scheduled.py +43 -0
- pyrogram/types/user_and_chats/video_chat_started.py +29 -0
- pyrogram/utils.py +371 -0
- stefano_pyrogram-2.0.107.dist-info/METADATA +128 -0
- stefano_pyrogram-2.0.107.dist-info/RECORD +2563 -0
- stefano_pyrogram-2.0.107.dist-info/WHEEL +5 -0
- stefano_pyrogram-2.0.107.dist-info/licenses/COPYING +674 -0
- stefano_pyrogram-2.0.107.dist-info/licenses/COPYING.lesser +165 -0
- stefano_pyrogram-2.0.107.dist-info/licenses/NOTICE +17 -0
- stefano_pyrogram-2.0.107.dist-info/top_level.txt +1 -0
pyrogram/client.py
ADDED
|
@@ -0,0 +1,1048 @@
|
|
|
1
|
+
# Pyrogram - Telegram MTProto API Client Library for Python
|
|
2
|
+
# Copyright (C) 2017-present Dan <https://github.com/delivrance>
|
|
3
|
+
#
|
|
4
|
+
# This file is part of Pyrogram.
|
|
5
|
+
#
|
|
6
|
+
# Pyrogram is free software: you can redistribute it and/or modify
|
|
7
|
+
# it under the terms of the GNU Lesser General Public License as published
|
|
8
|
+
# by the Free Software Foundation, either version 3 of the License, or
|
|
9
|
+
# (at your option) any later version.
|
|
10
|
+
#
|
|
11
|
+
# Pyrogram is distributed in the hope that it will be useful,
|
|
12
|
+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
13
|
+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
14
|
+
# GNU Lesser General Public License for more details.
|
|
15
|
+
#
|
|
16
|
+
# You should have received a copy of the GNU Lesser General Public License
|
|
17
|
+
# along with Pyrogram. If not, see <http://www.gnu.org/licenses/>.
|
|
18
|
+
|
|
19
|
+
import asyncio
|
|
20
|
+
import functools
|
|
21
|
+
import inspect
|
|
22
|
+
import logging
|
|
23
|
+
import os
|
|
24
|
+
import platform
|
|
25
|
+
import re
|
|
26
|
+
import shutil
|
|
27
|
+
import sys
|
|
28
|
+
from concurrent.futures.thread import ThreadPoolExecutor
|
|
29
|
+
from datetime import datetime, timedelta
|
|
30
|
+
from hashlib import sha256
|
|
31
|
+
from importlib import import_module
|
|
32
|
+
from io import StringIO, BytesIO
|
|
33
|
+
from mimetypes import MimeTypes
|
|
34
|
+
from pathlib import Path
|
|
35
|
+
from typing import Union, List, Optional, Callable, AsyncGenerator
|
|
36
|
+
|
|
37
|
+
import pyrogram
|
|
38
|
+
from pyrogram import __version__, __license__
|
|
39
|
+
from pyrogram import enums
|
|
40
|
+
from pyrogram import raw
|
|
41
|
+
from pyrogram import utils
|
|
42
|
+
from pyrogram.crypto import aes
|
|
43
|
+
from pyrogram.errors import CDNFileHashMismatch
|
|
44
|
+
from pyrogram.errors import (
|
|
45
|
+
SessionPasswordNeeded,
|
|
46
|
+
VolumeLocNotFound, ChannelPrivate,
|
|
47
|
+
BadRequest
|
|
48
|
+
)
|
|
49
|
+
from pyrogram.handlers.handler import Handler
|
|
50
|
+
from pyrogram.methods import Methods
|
|
51
|
+
from pyrogram.session import Auth, Session
|
|
52
|
+
from pyrogram.storage import FileStorage, MemoryStorage
|
|
53
|
+
from pyrogram.types import User, TermsOfService
|
|
54
|
+
from pyrogram.utils import ainput
|
|
55
|
+
from .dispatcher import Dispatcher
|
|
56
|
+
from .file_id import FileId, FileType, ThumbnailSource
|
|
57
|
+
from .mime_types import mime_types
|
|
58
|
+
from .parser import Parser
|
|
59
|
+
from .session.internals import MsgId
|
|
60
|
+
|
|
61
|
+
log = logging.getLogger(__name__)
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
class Client(Methods):
|
|
65
|
+
"""Pyrogram Client, the main means for interacting with Telegram.
|
|
66
|
+
|
|
67
|
+
Parameters:
|
|
68
|
+
name (``str``):
|
|
69
|
+
A name for the client, e.g.: "my_account".
|
|
70
|
+
|
|
71
|
+
api_id (``int`` | ``str``, *optional*):
|
|
72
|
+
The *api_id* part of the Telegram API key, as integer or string.
|
|
73
|
+
E.g.: 12345 or "12345".
|
|
74
|
+
|
|
75
|
+
api_hash (``str``, *optional*):
|
|
76
|
+
The *api_hash* part of the Telegram API key, as string.
|
|
77
|
+
E.g.: "0123456789abcdef0123456789abcdef".
|
|
78
|
+
|
|
79
|
+
app_version (``str``, *optional*):
|
|
80
|
+
Application version.
|
|
81
|
+
Defaults to "Pyrogram x.y.z".
|
|
82
|
+
|
|
83
|
+
device_model (``str``, *optional*):
|
|
84
|
+
Device model.
|
|
85
|
+
Defaults to *platform.python_implementation() + " " + platform.python_version()*.
|
|
86
|
+
|
|
87
|
+
system_version (``str``, *optional*):
|
|
88
|
+
Operating System version.
|
|
89
|
+
Defaults to *platform.system() + " " + platform.release()*.
|
|
90
|
+
|
|
91
|
+
lang_code (``str``, *optional*):
|
|
92
|
+
Code of the language used on the client, in ISO 639-1 standard.
|
|
93
|
+
Defaults to "en".
|
|
94
|
+
|
|
95
|
+
ipv6 (``bool``, *optional*):
|
|
96
|
+
Pass True to connect to Telegram using IPv6.
|
|
97
|
+
Defaults to False (IPv4).
|
|
98
|
+
|
|
99
|
+
proxy (``dict``, *optional*):
|
|
100
|
+
The Proxy settings as dict.
|
|
101
|
+
E.g.: *dict(scheme="socks5", hostname="11.22.33.44", port=1234, username="user", password="pass")*.
|
|
102
|
+
The *username* and *password* can be omitted if the proxy doesn't require authorization.
|
|
103
|
+
|
|
104
|
+
test_mode (``bool``, *optional*):
|
|
105
|
+
Enable or disable login to the test servers.
|
|
106
|
+
Only applicable for new sessions and will be ignored in case previously created sessions are loaded.
|
|
107
|
+
Defaults to False.
|
|
108
|
+
|
|
109
|
+
bot_token (``str``, *optional*):
|
|
110
|
+
Pass the Bot API token to create a bot session, e.g.: "123456:ABC-DEF1234ghIkl-zyx57W2v1u123ew11"
|
|
111
|
+
Only applicable for new sessions.
|
|
112
|
+
|
|
113
|
+
session_string (``str``, *optional*):
|
|
114
|
+
Pass a session string to load the session in-memory.
|
|
115
|
+
Implies ``in_memory=True``.
|
|
116
|
+
|
|
117
|
+
in_memory (``bool``, *optional*):
|
|
118
|
+
Pass True to start an in-memory session that will be discarded as soon as the client stops.
|
|
119
|
+
In order to reconnect again using an in-memory session without having to login again, you can use
|
|
120
|
+
:meth:`~pyrogram.Client.export_session_string` before stopping the client to get a session string you can
|
|
121
|
+
pass to the ``session_string`` parameter.
|
|
122
|
+
Defaults to False.
|
|
123
|
+
|
|
124
|
+
phone_number (``str``, *optional*):
|
|
125
|
+
Pass the phone number as string (with the Country Code prefix included) to avoid entering it manually.
|
|
126
|
+
Only applicable for new sessions.
|
|
127
|
+
|
|
128
|
+
phone_code (``str``, *optional*):
|
|
129
|
+
Pass the phone code as string (for test numbers only) to avoid entering it manually.
|
|
130
|
+
Only applicable for new sessions.
|
|
131
|
+
|
|
132
|
+
password (``str``, *optional*):
|
|
133
|
+
Pass the Two-Step Verification password as string (if required) to avoid entering it manually.
|
|
134
|
+
Only applicable for new sessions.
|
|
135
|
+
|
|
136
|
+
workers (``int``, *optional*):
|
|
137
|
+
Number of maximum concurrent workers for handling incoming updates.
|
|
138
|
+
Defaults to ``min(32, os.cpu_count() + 4)``.
|
|
139
|
+
|
|
140
|
+
workdir (``str``, *optional*):
|
|
141
|
+
Define a custom working directory.
|
|
142
|
+
The working directory is the location in the filesystem where Pyrogram will store the session files.
|
|
143
|
+
Defaults to the parent directory of the main script.
|
|
144
|
+
|
|
145
|
+
plugins (``dict``, *optional*):
|
|
146
|
+
Smart Plugins settings as dict, e.g.: *dict(root="plugins")*.
|
|
147
|
+
|
|
148
|
+
parse_mode (:obj:`~pyrogram.enums.ParseMode`, *optional*):
|
|
149
|
+
Set the global parse mode of the client. By default, texts are parsed using both Markdown and HTML styles.
|
|
150
|
+
You can combine both syntaxes together.
|
|
151
|
+
|
|
152
|
+
no_updates (``bool``, *optional*):
|
|
153
|
+
Pass True to disable incoming updates.
|
|
154
|
+
When updates are disabled the client can't receive messages or other updates.
|
|
155
|
+
Useful for batch programs that don't need to deal with updates.
|
|
156
|
+
Defaults to False (updates enabled and received).
|
|
157
|
+
|
|
158
|
+
takeout (``bool``, *optional*):
|
|
159
|
+
Pass True to let the client use a takeout session instead of a normal one, implies *no_updates=True*.
|
|
160
|
+
Useful for exporting Telegram data. Methods invoked inside a takeout session (such as get_chat_history,
|
|
161
|
+
download_media, ...) are less prone to throw FloodWait exceptions.
|
|
162
|
+
Only available for users, bots will ignore this parameter.
|
|
163
|
+
Defaults to False (normal session).
|
|
164
|
+
|
|
165
|
+
sleep_threshold (``int``, *optional*):
|
|
166
|
+
Set a sleep threshold for flood wait exceptions happening globally in this client instance, below which any
|
|
167
|
+
request that raises a flood wait will be automatically invoked again after sleeping for the required amount
|
|
168
|
+
of time. Flood wait exceptions requiring higher waiting times will be raised.
|
|
169
|
+
Defaults to 10 seconds.
|
|
170
|
+
|
|
171
|
+
hide_password (``bool``, *optional*):
|
|
172
|
+
Pass True to hide the password when typing it during the login.
|
|
173
|
+
Defaults to False, because ``getpass`` (the library used) is known to be problematic in some
|
|
174
|
+
terminal environments.
|
|
175
|
+
|
|
176
|
+
max_concurrent_transmissions (``bool``, *optional*):
|
|
177
|
+
Set the maximum amount of concurrent transmissions (uploads & downloads).
|
|
178
|
+
A value that is too high may result in network related issues.
|
|
179
|
+
Defaults to 1.
|
|
180
|
+
"""
|
|
181
|
+
|
|
182
|
+
APP_VERSION = f"Pyrogram {__version__}"
|
|
183
|
+
DEVICE_MODEL = f"{platform.python_implementation()} {platform.python_version()}"
|
|
184
|
+
SYSTEM_VERSION = f"{platform.system()} {platform.release()}"
|
|
185
|
+
|
|
186
|
+
LANG_CODE = "en"
|
|
187
|
+
|
|
188
|
+
PARENT_DIR = Path(sys.argv[0]).parent
|
|
189
|
+
|
|
190
|
+
INVITE_LINK_RE = re.compile(r"^(?:https?://)?(?:www\.)?(?:t(?:elegram)?\.(?:org|me|dog)/(?:joinchat/|\+))([\w-]+)$")
|
|
191
|
+
WORKERS = min(32, (os.cpu_count() or 0) + 4) # os.cpu_count() can be None
|
|
192
|
+
WORKDIR = PARENT_DIR
|
|
193
|
+
|
|
194
|
+
# Interval of seconds in which the updates watchdog will kick in
|
|
195
|
+
UPDATES_WATCHDOG_INTERVAL = 5 * 60
|
|
196
|
+
|
|
197
|
+
MAX_CONCURRENT_TRANSMISSIONS = 1
|
|
198
|
+
|
|
199
|
+
mimetypes = MimeTypes()
|
|
200
|
+
mimetypes.readfp(StringIO(mime_types))
|
|
201
|
+
|
|
202
|
+
def __init__(
|
|
203
|
+
self,
|
|
204
|
+
name: str,
|
|
205
|
+
api_id: Union[int, str] = None,
|
|
206
|
+
api_hash: str = None,
|
|
207
|
+
app_version: str = APP_VERSION,
|
|
208
|
+
device_model: str = DEVICE_MODEL,
|
|
209
|
+
system_version: str = SYSTEM_VERSION,
|
|
210
|
+
lang_code: str = LANG_CODE,
|
|
211
|
+
ipv6: bool = False,
|
|
212
|
+
proxy: dict = None,
|
|
213
|
+
test_mode: bool = False,
|
|
214
|
+
bot_token: str = None,
|
|
215
|
+
session_string: str = None,
|
|
216
|
+
in_memory: bool = None,
|
|
217
|
+
phone_number: str = None,
|
|
218
|
+
phone_code: str = None,
|
|
219
|
+
password: str = None,
|
|
220
|
+
workers: int = WORKERS,
|
|
221
|
+
workdir: str = WORKDIR,
|
|
222
|
+
plugins: dict = None,
|
|
223
|
+
parse_mode: "enums.ParseMode" = enums.ParseMode.DEFAULT,
|
|
224
|
+
no_updates: bool = None,
|
|
225
|
+
takeout: bool = None,
|
|
226
|
+
sleep_threshold: int = Session.SLEEP_THRESHOLD,
|
|
227
|
+
hide_password: bool = False,
|
|
228
|
+
max_concurrent_transmissions: int = MAX_CONCURRENT_TRANSMISSIONS
|
|
229
|
+
):
|
|
230
|
+
super().__init__()
|
|
231
|
+
|
|
232
|
+
self.name = name
|
|
233
|
+
self.api_id = int(api_id) if api_id else None
|
|
234
|
+
self.api_hash = api_hash
|
|
235
|
+
self.app_version = app_version
|
|
236
|
+
self.device_model = device_model
|
|
237
|
+
self.system_version = system_version
|
|
238
|
+
self.lang_code = lang_code.lower()
|
|
239
|
+
self.ipv6 = ipv6
|
|
240
|
+
self.proxy = proxy
|
|
241
|
+
self.test_mode = test_mode
|
|
242
|
+
self.bot_token = bot_token
|
|
243
|
+
self.session_string = session_string
|
|
244
|
+
self.in_memory = in_memory
|
|
245
|
+
self.phone_number = phone_number
|
|
246
|
+
self.phone_code = phone_code
|
|
247
|
+
self.password = password
|
|
248
|
+
self.workers = workers
|
|
249
|
+
self.workdir = Path(workdir)
|
|
250
|
+
self.plugins = plugins
|
|
251
|
+
self.parse_mode = parse_mode
|
|
252
|
+
self.no_updates = no_updates
|
|
253
|
+
self.takeout = takeout
|
|
254
|
+
self.sleep_threshold = sleep_threshold
|
|
255
|
+
self.hide_password = hide_password
|
|
256
|
+
self.max_concurrent_transmissions = max_concurrent_transmissions
|
|
257
|
+
|
|
258
|
+
self.executor = ThreadPoolExecutor(self.workers, thread_name_prefix="Handler")
|
|
259
|
+
|
|
260
|
+
if self.session_string:
|
|
261
|
+
self.storage = MemoryStorage(self.name, self.session_string)
|
|
262
|
+
elif self.in_memory:
|
|
263
|
+
self.storage = MemoryStorage(self.name)
|
|
264
|
+
else:
|
|
265
|
+
self.storage = FileStorage(self.name, self.workdir)
|
|
266
|
+
|
|
267
|
+
self.dispatcher = Dispatcher(self)
|
|
268
|
+
|
|
269
|
+
self.rnd_id = MsgId
|
|
270
|
+
|
|
271
|
+
self.parser = Parser(self)
|
|
272
|
+
|
|
273
|
+
self.session = None
|
|
274
|
+
|
|
275
|
+
self.media_sessions = {}
|
|
276
|
+
self.media_sessions_lock = asyncio.Lock()
|
|
277
|
+
|
|
278
|
+
self.save_file_semaphore = asyncio.Semaphore(self.max_concurrent_transmissions)
|
|
279
|
+
self.get_file_semaphore = asyncio.Semaphore(self.max_concurrent_transmissions)
|
|
280
|
+
|
|
281
|
+
self.is_connected = None
|
|
282
|
+
self.is_initialized = None
|
|
283
|
+
|
|
284
|
+
self.takeout_id = None
|
|
285
|
+
|
|
286
|
+
self.disconnect_handler = None
|
|
287
|
+
|
|
288
|
+
self.me: Optional[User] = None
|
|
289
|
+
|
|
290
|
+
self.message_cache = Cache(10000)
|
|
291
|
+
|
|
292
|
+
# Sometimes, for some reason, the server will stop sending updates and will only respond to pings.
|
|
293
|
+
# This watchdog will invoke updates.GetState in order to wake up the server and enable it sending updates again
|
|
294
|
+
# after some idle time has been detected.
|
|
295
|
+
self.updates_watchdog_task = None
|
|
296
|
+
self.updates_watchdog_event = asyncio.Event()
|
|
297
|
+
self.last_update_time = datetime.now()
|
|
298
|
+
|
|
299
|
+
self.loop = asyncio.get_event_loop()
|
|
300
|
+
|
|
301
|
+
def __enter__(self):
|
|
302
|
+
return self.start()
|
|
303
|
+
|
|
304
|
+
def __exit__(self, *args):
|
|
305
|
+
try:
|
|
306
|
+
self.stop()
|
|
307
|
+
except ConnectionError:
|
|
308
|
+
pass
|
|
309
|
+
|
|
310
|
+
async def __aenter__(self):
|
|
311
|
+
return await self.start()
|
|
312
|
+
|
|
313
|
+
async def __aexit__(self, *args):
|
|
314
|
+
try:
|
|
315
|
+
await self.stop()
|
|
316
|
+
except ConnectionError:
|
|
317
|
+
pass
|
|
318
|
+
|
|
319
|
+
async def updates_watchdog(self):
|
|
320
|
+
while True:
|
|
321
|
+
try:
|
|
322
|
+
await asyncio.wait_for(self.updates_watchdog_event.wait(), self.UPDATES_WATCHDOG_INTERVAL)
|
|
323
|
+
except asyncio.TimeoutError:
|
|
324
|
+
pass
|
|
325
|
+
else:
|
|
326
|
+
break
|
|
327
|
+
|
|
328
|
+
if datetime.now() - self.last_update_time > timedelta(seconds=self.UPDATES_WATCHDOG_INTERVAL):
|
|
329
|
+
await self.invoke(raw.functions.updates.GetState())
|
|
330
|
+
|
|
331
|
+
async def authorize(self) -> User:
|
|
332
|
+
if self.bot_token:
|
|
333
|
+
return await self.sign_in_bot(self.bot_token)
|
|
334
|
+
|
|
335
|
+
print(f"Welcome to Pyrogram (version {__version__})")
|
|
336
|
+
print(f"Pyrogram is free software and comes with ABSOLUTELY NO WARRANTY. Licensed\n"
|
|
337
|
+
f"under the terms of the {__license__}.\n")
|
|
338
|
+
|
|
339
|
+
while True:
|
|
340
|
+
try:
|
|
341
|
+
if not self.phone_number:
|
|
342
|
+
while True:
|
|
343
|
+
value = await ainput("Enter phone number or bot token: ")
|
|
344
|
+
|
|
345
|
+
if not value:
|
|
346
|
+
continue
|
|
347
|
+
|
|
348
|
+
confirm = (await ainput(f'Is "{value}" correct? (y/N): ')).lower()
|
|
349
|
+
|
|
350
|
+
if confirm == "y":
|
|
351
|
+
break
|
|
352
|
+
|
|
353
|
+
if ":" in value:
|
|
354
|
+
self.bot_token = value
|
|
355
|
+
return await self.sign_in_bot(value)
|
|
356
|
+
else:
|
|
357
|
+
self.phone_number = value
|
|
358
|
+
|
|
359
|
+
sent_code = await self.send_code(self.phone_number)
|
|
360
|
+
except BadRequest as e:
|
|
361
|
+
print(e.MESSAGE)
|
|
362
|
+
self.phone_number = None
|
|
363
|
+
self.bot_token = None
|
|
364
|
+
else:
|
|
365
|
+
break
|
|
366
|
+
|
|
367
|
+
sent_code_descriptions = {
|
|
368
|
+
enums.SentCodeType.APP: "Telegram app",
|
|
369
|
+
enums.SentCodeType.SMS: "SMS",
|
|
370
|
+
enums.SentCodeType.CALL: "phone call",
|
|
371
|
+
enums.SentCodeType.FLASH_CALL: "phone flash call",
|
|
372
|
+
enums.SentCodeType.FRAGMENT_SMS: "Fragment SMS",
|
|
373
|
+
enums.SentCodeType.EMAIL_CODE: "email code"
|
|
374
|
+
}
|
|
375
|
+
|
|
376
|
+
print(f"The confirmation code has been sent via {sent_code_descriptions[sent_code.type]}")
|
|
377
|
+
|
|
378
|
+
while True:
|
|
379
|
+
if not self.phone_code:
|
|
380
|
+
self.phone_code = await ainput("Enter confirmation code: ")
|
|
381
|
+
|
|
382
|
+
try:
|
|
383
|
+
signed_in = await self.sign_in(self.phone_number, sent_code.phone_code_hash, self.phone_code)
|
|
384
|
+
except BadRequest as e:
|
|
385
|
+
print(e.MESSAGE)
|
|
386
|
+
self.phone_code = None
|
|
387
|
+
except SessionPasswordNeeded as e:
|
|
388
|
+
print(e.MESSAGE)
|
|
389
|
+
|
|
390
|
+
while True:
|
|
391
|
+
print("Password hint: {}".format(await self.get_password_hint()))
|
|
392
|
+
|
|
393
|
+
if not self.password:
|
|
394
|
+
self.password = await ainput("Enter password (empty to recover): ", hide=self.hide_password)
|
|
395
|
+
|
|
396
|
+
try:
|
|
397
|
+
if not self.password:
|
|
398
|
+
confirm = await ainput("Confirm password recovery (y/n): ")
|
|
399
|
+
|
|
400
|
+
if confirm == "y":
|
|
401
|
+
email_pattern = await self.send_recovery_code()
|
|
402
|
+
print(f"The recovery code has been sent to {email_pattern}")
|
|
403
|
+
|
|
404
|
+
while True:
|
|
405
|
+
recovery_code = await ainput("Enter recovery code: ")
|
|
406
|
+
|
|
407
|
+
try:
|
|
408
|
+
return await self.recover_password(recovery_code)
|
|
409
|
+
except BadRequest as e:
|
|
410
|
+
print(e.MESSAGE)
|
|
411
|
+
except Exception as e:
|
|
412
|
+
log.exception(e)
|
|
413
|
+
raise
|
|
414
|
+
else:
|
|
415
|
+
self.password = None
|
|
416
|
+
else:
|
|
417
|
+
return await self.check_password(self.password)
|
|
418
|
+
except BadRequest as e:
|
|
419
|
+
print(e.MESSAGE)
|
|
420
|
+
self.password = None
|
|
421
|
+
else:
|
|
422
|
+
break
|
|
423
|
+
|
|
424
|
+
if isinstance(signed_in, User):
|
|
425
|
+
return signed_in
|
|
426
|
+
|
|
427
|
+
while True:
|
|
428
|
+
first_name = await ainput("Enter first name: ")
|
|
429
|
+
last_name = await ainput("Enter last name (empty to skip): ")
|
|
430
|
+
|
|
431
|
+
try:
|
|
432
|
+
signed_up = await self.sign_up(
|
|
433
|
+
self.phone_number,
|
|
434
|
+
sent_code.phone_code_hash,
|
|
435
|
+
first_name,
|
|
436
|
+
last_name
|
|
437
|
+
)
|
|
438
|
+
except BadRequest as e:
|
|
439
|
+
print(e.MESSAGE)
|
|
440
|
+
else:
|
|
441
|
+
break
|
|
442
|
+
|
|
443
|
+
if isinstance(signed_in, TermsOfService):
|
|
444
|
+
print("\n" + signed_in.text + "\n")
|
|
445
|
+
await self.accept_terms_of_service(signed_in.id)
|
|
446
|
+
|
|
447
|
+
return signed_up
|
|
448
|
+
|
|
449
|
+
def set_parse_mode(self, parse_mode: Optional["enums.ParseMode"]):
|
|
450
|
+
"""Set the parse mode to be used globally by the client.
|
|
451
|
+
|
|
452
|
+
When setting the parse mode with this method, all other methods having a *parse_mode* parameter will follow the
|
|
453
|
+
global value by default.
|
|
454
|
+
|
|
455
|
+
Parameters:
|
|
456
|
+
parse_mode (:obj:`~pyrogram.enums.ParseMode`):
|
|
457
|
+
By default, texts are parsed using both Markdown and HTML styles.
|
|
458
|
+
You can combine both syntaxes together.
|
|
459
|
+
|
|
460
|
+
Example:
|
|
461
|
+
.. code-block:: python
|
|
462
|
+
|
|
463
|
+
from pyrogram import enums
|
|
464
|
+
|
|
465
|
+
# Default combined mode: Markdown + HTML
|
|
466
|
+
await app.send_message("me", "1. **markdown** and <i>html</i>")
|
|
467
|
+
|
|
468
|
+
# Force Markdown-only, HTML is disabled
|
|
469
|
+
app.set_parse_mode(enums.ParseMode.MARKDOWN)
|
|
470
|
+
await app.send_message("me", "2. **markdown** and <i>html</i>")
|
|
471
|
+
|
|
472
|
+
# Force HTML-only, Markdown is disabled
|
|
473
|
+
app.set_parse_mode(enums.ParseMode.HTML)
|
|
474
|
+
await app.send_message("me", "3. **markdown** and <i>html</i>")
|
|
475
|
+
|
|
476
|
+
# Disable the parser completely
|
|
477
|
+
app.set_parse_mode(enums.ParseMode.DISABLED)
|
|
478
|
+
await app.send_message("me", "4. **markdown** and <i>html</i>")
|
|
479
|
+
|
|
480
|
+
# Bring back the default combined mode
|
|
481
|
+
app.set_parse_mode(enums.ParseMode.DEFAULT)
|
|
482
|
+
await app.send_message("me", "5. **markdown** and <i>html</i>")
|
|
483
|
+
"""
|
|
484
|
+
|
|
485
|
+
self.parse_mode = parse_mode
|
|
486
|
+
|
|
487
|
+
async def fetch_peers(self, peers: List[Union[raw.types.User, raw.types.Chat, raw.types.Channel]]) -> bool:
|
|
488
|
+
is_min = False
|
|
489
|
+
parsed_peers = []
|
|
490
|
+
|
|
491
|
+
for peer in peers:
|
|
492
|
+
if getattr(peer, "min", False):
|
|
493
|
+
is_min = True
|
|
494
|
+
continue
|
|
495
|
+
|
|
496
|
+
username = None
|
|
497
|
+
phone_number = None
|
|
498
|
+
|
|
499
|
+
if isinstance(peer, raw.types.User):
|
|
500
|
+
peer_id = peer.id
|
|
501
|
+
access_hash = peer.access_hash
|
|
502
|
+
username = (
|
|
503
|
+
peer.username.lower() if peer.username
|
|
504
|
+
else peer.usernames[0].username.lower() if peer.usernames
|
|
505
|
+
else None
|
|
506
|
+
)
|
|
507
|
+
phone_number = peer.phone
|
|
508
|
+
peer_type = "bot" if peer.bot else "user"
|
|
509
|
+
elif isinstance(peer, (raw.types.Chat, raw.types.ChatForbidden)):
|
|
510
|
+
peer_id = -peer.id
|
|
511
|
+
access_hash = 0
|
|
512
|
+
peer_type = "group"
|
|
513
|
+
elif isinstance(peer, raw.types.Channel):
|
|
514
|
+
peer_id = utils.get_channel_id(peer.id)
|
|
515
|
+
access_hash = peer.access_hash
|
|
516
|
+
username = (
|
|
517
|
+
peer.username.lower() if peer.username
|
|
518
|
+
else peer.usernames[0].username.lower() if peer.usernames
|
|
519
|
+
else None
|
|
520
|
+
)
|
|
521
|
+
peer_type = "channel" if peer.broadcast else "supergroup"
|
|
522
|
+
elif isinstance(peer, raw.types.ChannelForbidden):
|
|
523
|
+
peer_id = utils.get_channel_id(peer.id)
|
|
524
|
+
access_hash = peer.access_hash
|
|
525
|
+
peer_type = "channel" if peer.broadcast else "supergroup"
|
|
526
|
+
else:
|
|
527
|
+
continue
|
|
528
|
+
|
|
529
|
+
parsed_peers.append((peer_id, access_hash, peer_type, username, phone_number))
|
|
530
|
+
|
|
531
|
+
await self.storage.update_peers(parsed_peers)
|
|
532
|
+
|
|
533
|
+
return is_min
|
|
534
|
+
|
|
535
|
+
async def handle_updates(self, updates):
|
|
536
|
+
self.last_update_time = datetime.now()
|
|
537
|
+
|
|
538
|
+
if isinstance(updates, (raw.types.Updates, raw.types.UpdatesCombined)):
|
|
539
|
+
is_min = any((
|
|
540
|
+
await self.fetch_peers(updates.users),
|
|
541
|
+
await self.fetch_peers(updates.chats),
|
|
542
|
+
))
|
|
543
|
+
|
|
544
|
+
users = {u.id: u for u in updates.users}
|
|
545
|
+
chats = {c.id: c for c in updates.chats}
|
|
546
|
+
|
|
547
|
+
for update in updates.updates:
|
|
548
|
+
channel_id = getattr(
|
|
549
|
+
getattr(
|
|
550
|
+
getattr(
|
|
551
|
+
update, "message", None
|
|
552
|
+
), "peer_id", None
|
|
553
|
+
), "channel_id", None
|
|
554
|
+
) or getattr(update, "channel_id", None)
|
|
555
|
+
|
|
556
|
+
pts = getattr(update, "pts", None)
|
|
557
|
+
pts_count = getattr(update, "pts_count", None)
|
|
558
|
+
|
|
559
|
+
if isinstance(update, raw.types.UpdateChannelTooLong):
|
|
560
|
+
log.info(update)
|
|
561
|
+
|
|
562
|
+
if isinstance(update, raw.types.UpdateNewChannelMessage) and is_min:
|
|
563
|
+
message = update.message
|
|
564
|
+
|
|
565
|
+
if not isinstance(message, raw.types.MessageEmpty):
|
|
566
|
+
try:
|
|
567
|
+
diff = await self.invoke(
|
|
568
|
+
raw.functions.updates.GetChannelDifference(
|
|
569
|
+
channel=await self.resolve_peer(utils.get_channel_id(channel_id)),
|
|
570
|
+
filter=raw.types.ChannelMessagesFilter(
|
|
571
|
+
ranges=[raw.types.MessageRange(
|
|
572
|
+
min_id=update.message.id,
|
|
573
|
+
max_id=update.message.id
|
|
574
|
+
)]
|
|
575
|
+
),
|
|
576
|
+
pts=pts - pts_count,
|
|
577
|
+
limit=pts
|
|
578
|
+
)
|
|
579
|
+
)
|
|
580
|
+
except ChannelPrivate:
|
|
581
|
+
pass
|
|
582
|
+
else:
|
|
583
|
+
if not isinstance(diff, raw.types.updates.ChannelDifferenceEmpty):
|
|
584
|
+
users.update({u.id: u for u in diff.users})
|
|
585
|
+
chats.update({c.id: c for c in diff.chats})
|
|
586
|
+
|
|
587
|
+
self.dispatcher.updates_queue.put_nowait((update, users, chats))
|
|
588
|
+
elif isinstance(updates, (raw.types.UpdateShortMessage, raw.types.UpdateShortChatMessage)):
|
|
589
|
+
diff = await self.invoke(
|
|
590
|
+
raw.functions.updates.GetDifference(
|
|
591
|
+
pts=updates.pts - updates.pts_count,
|
|
592
|
+
date=updates.date,
|
|
593
|
+
qts=-1
|
|
594
|
+
)
|
|
595
|
+
)
|
|
596
|
+
|
|
597
|
+
if diff.new_messages:
|
|
598
|
+
self.dispatcher.updates_queue.put_nowait((
|
|
599
|
+
raw.types.UpdateNewMessage(
|
|
600
|
+
message=diff.new_messages[0],
|
|
601
|
+
pts=updates.pts,
|
|
602
|
+
pts_count=updates.pts_count
|
|
603
|
+
),
|
|
604
|
+
{u.id: u for u in diff.users},
|
|
605
|
+
{c.id: c for c in diff.chats}
|
|
606
|
+
))
|
|
607
|
+
else:
|
|
608
|
+
if diff.other_updates: # The other_updates list can be empty
|
|
609
|
+
self.dispatcher.updates_queue.put_nowait((diff.other_updates[0], {}, {}))
|
|
610
|
+
elif isinstance(updates, raw.types.UpdateShort):
|
|
611
|
+
self.dispatcher.updates_queue.put_nowait((updates.update, {}, {}))
|
|
612
|
+
elif isinstance(updates, raw.types.UpdatesTooLong):
|
|
613
|
+
log.info(updates)
|
|
614
|
+
|
|
615
|
+
async def load_session(self):
|
|
616
|
+
await self.storage.open()
|
|
617
|
+
|
|
618
|
+
session_empty = any([
|
|
619
|
+
await self.storage.test_mode() is None,
|
|
620
|
+
await self.storage.auth_key() is None,
|
|
621
|
+
await self.storage.user_id() is None,
|
|
622
|
+
await self.storage.is_bot() is None
|
|
623
|
+
])
|
|
624
|
+
|
|
625
|
+
if session_empty:
|
|
626
|
+
if not self.api_id or not self.api_hash:
|
|
627
|
+
raise AttributeError("The API key is required for new authorizations. "
|
|
628
|
+
"More info: https://docs.pyrogram.org/start/auth")
|
|
629
|
+
|
|
630
|
+
await self.storage.api_id(self.api_id)
|
|
631
|
+
|
|
632
|
+
await self.storage.dc_id(2)
|
|
633
|
+
await self.storage.date(0)
|
|
634
|
+
|
|
635
|
+
await self.storage.test_mode(self.test_mode)
|
|
636
|
+
await self.storage.auth_key(
|
|
637
|
+
await Auth(
|
|
638
|
+
self, await self.storage.dc_id(),
|
|
639
|
+
await self.storage.test_mode()
|
|
640
|
+
).create()
|
|
641
|
+
)
|
|
642
|
+
await self.storage.user_id(None)
|
|
643
|
+
await self.storage.is_bot(None)
|
|
644
|
+
else:
|
|
645
|
+
# Needed for migration from storage v2 to v3
|
|
646
|
+
if not await self.storage.api_id():
|
|
647
|
+
if self.api_id:
|
|
648
|
+
await self.storage.api_id(self.api_id)
|
|
649
|
+
else:
|
|
650
|
+
while True:
|
|
651
|
+
try:
|
|
652
|
+
value = int(await ainput("Enter the api_id part of the API key: "))
|
|
653
|
+
|
|
654
|
+
if value <= 0:
|
|
655
|
+
print("Invalid value")
|
|
656
|
+
continue
|
|
657
|
+
|
|
658
|
+
confirm = (await ainput(f'Is "{value}" correct? (y/N): ')).lower()
|
|
659
|
+
|
|
660
|
+
if confirm == "y":
|
|
661
|
+
await self.storage.api_id(value)
|
|
662
|
+
break
|
|
663
|
+
except Exception as e:
|
|
664
|
+
print(e)
|
|
665
|
+
|
|
666
|
+
def load_plugins(self):
|
|
667
|
+
if self.plugins:
|
|
668
|
+
plugins = self.plugins.copy()
|
|
669
|
+
|
|
670
|
+
for option in ["include", "exclude"]:
|
|
671
|
+
if plugins.get(option, []):
|
|
672
|
+
plugins[option] = [
|
|
673
|
+
(i.split()[0], i.split()[1:] or None)
|
|
674
|
+
for i in self.plugins[option]
|
|
675
|
+
]
|
|
676
|
+
else:
|
|
677
|
+
return
|
|
678
|
+
|
|
679
|
+
if plugins.get("enabled", True):
|
|
680
|
+
root = plugins["root"]
|
|
681
|
+
include = plugins.get("include", [])
|
|
682
|
+
exclude = plugins.get("exclude", [])
|
|
683
|
+
|
|
684
|
+
count = 0
|
|
685
|
+
|
|
686
|
+
if not include:
|
|
687
|
+
for path in sorted(Path(root.replace(".", "/")).rglob("*.py")):
|
|
688
|
+
module_path = '.'.join(path.parent.parts + (path.stem,))
|
|
689
|
+
module = import_module(module_path)
|
|
690
|
+
|
|
691
|
+
for name in vars(module).keys():
|
|
692
|
+
# noinspection PyBroadException
|
|
693
|
+
try:
|
|
694
|
+
for handler, group in getattr(module, name).handlers:
|
|
695
|
+
if isinstance(handler, Handler) and isinstance(group, int):
|
|
696
|
+
self.add_handler(handler, group)
|
|
697
|
+
|
|
698
|
+
log.info('[{}] [LOAD] {}("{}") in group {} from "{}"'.format(
|
|
699
|
+
self.name, type(handler).__name__, name, group, module_path))
|
|
700
|
+
|
|
701
|
+
count += 1
|
|
702
|
+
except Exception:
|
|
703
|
+
pass
|
|
704
|
+
else:
|
|
705
|
+
for path, handlers in include:
|
|
706
|
+
module_path = root + "." + path
|
|
707
|
+
warn_non_existent_functions = True
|
|
708
|
+
|
|
709
|
+
try:
|
|
710
|
+
module = import_module(module_path)
|
|
711
|
+
except ImportError:
|
|
712
|
+
log.warning('[%s] [LOAD] Ignoring non-existent module "%s"', self.name, module_path)
|
|
713
|
+
continue
|
|
714
|
+
|
|
715
|
+
if "__path__" in dir(module):
|
|
716
|
+
log.warning('[%s] [LOAD] Ignoring namespace "%s"', self.name, module_path)
|
|
717
|
+
continue
|
|
718
|
+
|
|
719
|
+
if handlers is None:
|
|
720
|
+
handlers = vars(module).keys()
|
|
721
|
+
warn_non_existent_functions = False
|
|
722
|
+
|
|
723
|
+
for name in handlers:
|
|
724
|
+
# noinspection PyBroadException
|
|
725
|
+
try:
|
|
726
|
+
for handler, group in getattr(module, name).handlers:
|
|
727
|
+
if isinstance(handler, Handler) and isinstance(group, int):
|
|
728
|
+
self.add_handler(handler, group)
|
|
729
|
+
|
|
730
|
+
log.info('[{}] [LOAD] {}("{}") in group {} from "{}"'.format(
|
|
731
|
+
self.name, type(handler).__name__, name, group, module_path))
|
|
732
|
+
|
|
733
|
+
count += 1
|
|
734
|
+
except Exception:
|
|
735
|
+
if warn_non_existent_functions:
|
|
736
|
+
log.warning('[{}] [LOAD] Ignoring non-existent function "{}" from "{}"'.format(
|
|
737
|
+
self.name, name, module_path))
|
|
738
|
+
|
|
739
|
+
if exclude:
|
|
740
|
+
for path, handlers in exclude:
|
|
741
|
+
module_path = root + "." + path
|
|
742
|
+
warn_non_existent_functions = True
|
|
743
|
+
|
|
744
|
+
try:
|
|
745
|
+
module = import_module(module_path)
|
|
746
|
+
except ImportError:
|
|
747
|
+
log.warning('[%s] [UNLOAD] Ignoring non-existent module "%s"', self.name, module_path)
|
|
748
|
+
continue
|
|
749
|
+
|
|
750
|
+
if "__path__" in dir(module):
|
|
751
|
+
log.warning('[%s] [UNLOAD] Ignoring namespace "%s"', self.name, module_path)
|
|
752
|
+
continue
|
|
753
|
+
|
|
754
|
+
if handlers is None:
|
|
755
|
+
handlers = vars(module).keys()
|
|
756
|
+
warn_non_existent_functions = False
|
|
757
|
+
|
|
758
|
+
for name in handlers:
|
|
759
|
+
# noinspection PyBroadException
|
|
760
|
+
try:
|
|
761
|
+
for handler, group in getattr(module, name).handlers:
|
|
762
|
+
if isinstance(handler, Handler) and isinstance(group, int):
|
|
763
|
+
self.remove_handler(handler, group)
|
|
764
|
+
|
|
765
|
+
log.info('[{}] [UNLOAD] {}("{}") from group {} in "{}"'.format(
|
|
766
|
+
self.name, type(handler).__name__, name, group, module_path))
|
|
767
|
+
|
|
768
|
+
count -= 1
|
|
769
|
+
except Exception:
|
|
770
|
+
if warn_non_existent_functions:
|
|
771
|
+
log.warning('[{}] [UNLOAD] Ignoring non-existent function "{}" from "{}"'.format(
|
|
772
|
+
self.name, name, module_path))
|
|
773
|
+
|
|
774
|
+
if count > 0:
|
|
775
|
+
log.info('[{}] Successfully loaded {} plugin{} from "{}"'.format(
|
|
776
|
+
self.name, count, "s" if count > 1 else "", root))
|
|
777
|
+
else:
|
|
778
|
+
log.warning('[%s] No plugin loaded from "%s"', self.name, root)
|
|
779
|
+
|
|
780
|
+
async def handle_download(self, packet):
|
|
781
|
+
file_id, directory, file_name, in_memory, file_size, progress, progress_args = packet
|
|
782
|
+
|
|
783
|
+
os.makedirs(directory, exist_ok=True) if not in_memory else None
|
|
784
|
+
temp_file_path = os.path.abspath(re.sub("\\\\", "/", os.path.join(directory, file_name))) + ".temp"
|
|
785
|
+
file = BytesIO() if in_memory else open(temp_file_path, "wb")
|
|
786
|
+
|
|
787
|
+
try:
|
|
788
|
+
async for chunk in self.get_file(file_id, file_size, 0, 0, progress, progress_args):
|
|
789
|
+
file.write(chunk)
|
|
790
|
+
except BaseException as e:
|
|
791
|
+
if not in_memory:
|
|
792
|
+
file.close()
|
|
793
|
+
os.remove(temp_file_path)
|
|
794
|
+
|
|
795
|
+
if isinstance(e, asyncio.CancelledError):
|
|
796
|
+
raise e
|
|
797
|
+
|
|
798
|
+
return None
|
|
799
|
+
else:
|
|
800
|
+
if in_memory:
|
|
801
|
+
file.name = file_name
|
|
802
|
+
return file
|
|
803
|
+
else:
|
|
804
|
+
file.close()
|
|
805
|
+
file_path = os.path.splitext(temp_file_path)[0]
|
|
806
|
+
shutil.move(temp_file_path, file_path)
|
|
807
|
+
return file_path
|
|
808
|
+
|
|
809
|
+
async def get_file(
|
|
810
|
+
self,
|
|
811
|
+
file_id: FileId,
|
|
812
|
+
file_size: int = 0,
|
|
813
|
+
limit: int = 0,
|
|
814
|
+
offset: int = 0,
|
|
815
|
+
progress: Callable = None,
|
|
816
|
+
progress_args: tuple = ()
|
|
817
|
+
) -> Optional[AsyncGenerator[bytes, None]]:
|
|
818
|
+
async with self.get_file_semaphore:
|
|
819
|
+
file_type = file_id.file_type
|
|
820
|
+
|
|
821
|
+
if file_type == FileType.CHAT_PHOTO:
|
|
822
|
+
if file_id.chat_id > 0:
|
|
823
|
+
peer = raw.types.InputPeerUser(
|
|
824
|
+
user_id=file_id.chat_id,
|
|
825
|
+
access_hash=file_id.chat_access_hash
|
|
826
|
+
)
|
|
827
|
+
else:
|
|
828
|
+
if file_id.chat_access_hash == 0:
|
|
829
|
+
peer = raw.types.InputPeerChat(
|
|
830
|
+
chat_id=-file_id.chat_id
|
|
831
|
+
)
|
|
832
|
+
else:
|
|
833
|
+
peer = raw.types.InputPeerChannel(
|
|
834
|
+
channel_id=utils.get_channel_id(file_id.chat_id),
|
|
835
|
+
access_hash=file_id.chat_access_hash
|
|
836
|
+
)
|
|
837
|
+
|
|
838
|
+
location = raw.types.InputPeerPhotoFileLocation(
|
|
839
|
+
peer=peer,
|
|
840
|
+
photo_id=file_id.media_id,
|
|
841
|
+
big=file_id.thumbnail_source == ThumbnailSource.CHAT_PHOTO_BIG
|
|
842
|
+
)
|
|
843
|
+
elif file_type == FileType.PHOTO:
|
|
844
|
+
location = raw.types.InputPhotoFileLocation(
|
|
845
|
+
id=file_id.media_id,
|
|
846
|
+
access_hash=file_id.access_hash,
|
|
847
|
+
file_reference=file_id.file_reference,
|
|
848
|
+
thumb_size=file_id.thumbnail_size
|
|
849
|
+
)
|
|
850
|
+
else:
|
|
851
|
+
location = raw.types.InputDocumentFileLocation(
|
|
852
|
+
id=file_id.media_id,
|
|
853
|
+
access_hash=file_id.access_hash,
|
|
854
|
+
file_reference=file_id.file_reference,
|
|
855
|
+
thumb_size=file_id.thumbnail_size
|
|
856
|
+
)
|
|
857
|
+
|
|
858
|
+
current = 0
|
|
859
|
+
total = abs(limit) or (1 << 31) - 1
|
|
860
|
+
chunk_size = 1024 * 1024
|
|
861
|
+
offset_bytes = abs(offset) * chunk_size
|
|
862
|
+
|
|
863
|
+
dc_id = file_id.dc_id
|
|
864
|
+
|
|
865
|
+
session = Session(
|
|
866
|
+
self, dc_id,
|
|
867
|
+
await Auth(self, dc_id, await self.storage.test_mode()).create()
|
|
868
|
+
if dc_id != await self.storage.dc_id()
|
|
869
|
+
else await self.storage.auth_key(),
|
|
870
|
+
await self.storage.test_mode(),
|
|
871
|
+
is_media=True
|
|
872
|
+
)
|
|
873
|
+
|
|
874
|
+
try:
|
|
875
|
+
await session.start()
|
|
876
|
+
|
|
877
|
+
if dc_id != await self.storage.dc_id():
|
|
878
|
+
exported_auth = await self.invoke(
|
|
879
|
+
raw.functions.auth.ExportAuthorization(
|
|
880
|
+
dc_id=dc_id
|
|
881
|
+
)
|
|
882
|
+
)
|
|
883
|
+
|
|
884
|
+
await session.invoke(
|
|
885
|
+
raw.functions.auth.ImportAuthorization(
|
|
886
|
+
id=exported_auth.id,
|
|
887
|
+
bytes=exported_auth.bytes
|
|
888
|
+
)
|
|
889
|
+
)
|
|
890
|
+
|
|
891
|
+
r = await session.invoke(
|
|
892
|
+
raw.functions.upload.GetFile(
|
|
893
|
+
location=location,
|
|
894
|
+
offset=offset_bytes,
|
|
895
|
+
limit=chunk_size
|
|
896
|
+
),
|
|
897
|
+
sleep_threshold=30
|
|
898
|
+
)
|
|
899
|
+
|
|
900
|
+
if isinstance(r, raw.types.upload.File):
|
|
901
|
+
while True:
|
|
902
|
+
chunk = r.bytes
|
|
903
|
+
|
|
904
|
+
yield chunk
|
|
905
|
+
|
|
906
|
+
current += 1
|
|
907
|
+
offset_bytes += chunk_size
|
|
908
|
+
|
|
909
|
+
if progress:
|
|
910
|
+
func = functools.partial(
|
|
911
|
+
progress,
|
|
912
|
+
min(offset_bytes, file_size)
|
|
913
|
+
if file_size != 0
|
|
914
|
+
else offset_bytes,
|
|
915
|
+
file_size,
|
|
916
|
+
*progress_args
|
|
917
|
+
)
|
|
918
|
+
|
|
919
|
+
if inspect.iscoroutinefunction(progress):
|
|
920
|
+
await func()
|
|
921
|
+
else:
|
|
922
|
+
await self.loop.run_in_executor(self.executor, func)
|
|
923
|
+
|
|
924
|
+
if len(chunk) < chunk_size or current >= total:
|
|
925
|
+
break
|
|
926
|
+
|
|
927
|
+
r = await session.invoke(
|
|
928
|
+
raw.functions.upload.GetFile(
|
|
929
|
+
location=location,
|
|
930
|
+
offset=offset_bytes,
|
|
931
|
+
limit=chunk_size
|
|
932
|
+
),
|
|
933
|
+
sleep_threshold=30
|
|
934
|
+
)
|
|
935
|
+
|
|
936
|
+
elif isinstance(r, raw.types.upload.FileCdnRedirect):
|
|
937
|
+
cdn_session = Session(
|
|
938
|
+
self, r.dc_id, await Auth(self, r.dc_id, await self.storage.test_mode()).create(),
|
|
939
|
+
await self.storage.test_mode(), is_media=True, is_cdn=True
|
|
940
|
+
)
|
|
941
|
+
|
|
942
|
+
try:
|
|
943
|
+
await cdn_session.start()
|
|
944
|
+
|
|
945
|
+
while True:
|
|
946
|
+
r2 = await cdn_session.invoke(
|
|
947
|
+
raw.functions.upload.GetCdnFile(
|
|
948
|
+
file_token=r.file_token,
|
|
949
|
+
offset=offset_bytes,
|
|
950
|
+
limit=chunk_size
|
|
951
|
+
)
|
|
952
|
+
)
|
|
953
|
+
|
|
954
|
+
if isinstance(r2, raw.types.upload.CdnFileReuploadNeeded):
|
|
955
|
+
try:
|
|
956
|
+
await session.invoke(
|
|
957
|
+
raw.functions.upload.ReuploadCdnFile(
|
|
958
|
+
file_token=r.file_token,
|
|
959
|
+
request_token=r2.request_token
|
|
960
|
+
)
|
|
961
|
+
)
|
|
962
|
+
except VolumeLocNotFound:
|
|
963
|
+
break
|
|
964
|
+
else:
|
|
965
|
+
continue
|
|
966
|
+
|
|
967
|
+
chunk = r2.bytes
|
|
968
|
+
|
|
969
|
+
# https://core.telegram.org/cdn#decrypting-files
|
|
970
|
+
decrypted_chunk = aes.ctr256_decrypt(
|
|
971
|
+
chunk,
|
|
972
|
+
r.encryption_key,
|
|
973
|
+
bytearray(
|
|
974
|
+
r.encryption_iv[:-4]
|
|
975
|
+
+ (offset_bytes // 16).to_bytes(4, "big")
|
|
976
|
+
)
|
|
977
|
+
)
|
|
978
|
+
|
|
979
|
+
hashes = await session.invoke(
|
|
980
|
+
raw.functions.upload.GetCdnFileHashes(
|
|
981
|
+
file_token=r.file_token,
|
|
982
|
+
offset=offset_bytes
|
|
983
|
+
)
|
|
984
|
+
)
|
|
985
|
+
|
|
986
|
+
# https://core.telegram.org/cdn#verifying-files
|
|
987
|
+
for i, h in enumerate(hashes):
|
|
988
|
+
cdn_chunk = decrypted_chunk[h.limit * i: h.limit * (i + 1)]
|
|
989
|
+
CDNFileHashMismatch.check(
|
|
990
|
+
h.hash == sha256(cdn_chunk).digest(),
|
|
991
|
+
"h.hash == sha256(cdn_chunk).digest()"
|
|
992
|
+
)
|
|
993
|
+
|
|
994
|
+
yield decrypted_chunk
|
|
995
|
+
|
|
996
|
+
current += 1
|
|
997
|
+
offset_bytes += chunk_size
|
|
998
|
+
|
|
999
|
+
if progress:
|
|
1000
|
+
func = functools.partial(
|
|
1001
|
+
progress,
|
|
1002
|
+
min(offset_bytes, file_size) if file_size != 0 else offset_bytes,
|
|
1003
|
+
file_size,
|
|
1004
|
+
*progress_args
|
|
1005
|
+
)
|
|
1006
|
+
|
|
1007
|
+
if inspect.iscoroutinefunction(progress):
|
|
1008
|
+
await func()
|
|
1009
|
+
else:
|
|
1010
|
+
await self.loop.run_in_executor(self.executor, func)
|
|
1011
|
+
|
|
1012
|
+
if len(chunk) < chunk_size or current >= total:
|
|
1013
|
+
break
|
|
1014
|
+
except Exception as e:
|
|
1015
|
+
raise e
|
|
1016
|
+
finally:
|
|
1017
|
+
await cdn_session.stop()
|
|
1018
|
+
except pyrogram.StopTransmission:
|
|
1019
|
+
raise
|
|
1020
|
+
except Exception as e:
|
|
1021
|
+
log.exception(e)
|
|
1022
|
+
finally:
|
|
1023
|
+
await session.stop()
|
|
1024
|
+
|
|
1025
|
+
def guess_mime_type(self, filename: str) -> Optional[str]:
|
|
1026
|
+
return self.mimetypes.guess_type(filename)[0]
|
|
1027
|
+
|
|
1028
|
+
def guess_extension(self, mime_type: str) -> Optional[str]:
|
|
1029
|
+
return self.mimetypes.guess_extension(mime_type)
|
|
1030
|
+
|
|
1031
|
+
|
|
1032
|
+
class Cache:
|
|
1033
|
+
def __init__(self, capacity: int):
|
|
1034
|
+
self.capacity = capacity
|
|
1035
|
+
self.store = {}
|
|
1036
|
+
|
|
1037
|
+
def __getitem__(self, key):
|
|
1038
|
+
return self.store.get(key, None)
|
|
1039
|
+
|
|
1040
|
+
def __setitem__(self, key, value):
|
|
1041
|
+
if key in self.store:
|
|
1042
|
+
del self.store[key]
|
|
1043
|
+
|
|
1044
|
+
self.store[key] = value
|
|
1045
|
+
|
|
1046
|
+
if len(self.store) > self.capacity:
|
|
1047
|
+
for _ in range(self.capacity // 2 + 1):
|
|
1048
|
+
del self.store[next(iter(self.store))]
|