Skip to content

Latest commit

 

History

History
144 lines (105 loc) · 5.76 KB

File metadata and controls

144 lines (105 loc) · 5.76 KB

PyrogramMod v2.4.0

Layer 228, Communities, Ephemeral Messages, Rich Messages, Guard Bot and more

Layer Updates

Updated API schema through layers 221 -> 228.

Communities

New communities.* namespace with 10 methods:

Monoforum / Direct Messages

New methods for channels with Direct Messages (monoforum) enabled:

Ephemeral Messages

New ephemeral.* namespace — bot-private messages visible only to the receiver:

Rich Messages (Bot API 10.1)

New types: :obj:`~pyrogram.types.RichMessage`, :obj:`~pyrogram.types.RichText`, :obj:`~pyrogram.types.RichBlock`, :obj:`~pyrogram.types.InputRichMessage`, :obj:`~pyrogram.types.PollLink`.

New enums: :obj:`~pyrogram.enums.RichTextType` (26 variants), :obj:`~pyrogram.enums.RichBlockType` (30 variants).

New methods:

Incoming :obj:`~pyrogram.types.Message` objects expose the new rich_message field.

Guard Bot & Join Request Queries

New handler :meth:`~pyrogram.Client.on_guard_bot_query`, new type :obj:`~pyrogram.types.GuardBotQuery`, new field ChatJoinRequest.query_id.

Streaming Text

Bot & Browser Settings

User & Chat

New :obj:`~pyrogram.types.User` fields: color, profile_color, bot_active_users, bot_has_main_app.

New :obj:`~pyrogram.types.Chat` fields: guard_bot_id, send_paid_messages_stars, monoforum, autotranslation.

New type :obj:`~pyrogram.types.PeerColor`.

:obj:`~pyrogram.types.ChatPrivileges` gains: can_manage_direct_messages, can_manage_ranks, can_manage_linked_peers.

New update :obj:`~pyrogram.raw.types.UpdateBotStarsSubscription` — fires when a bot Stars subscription is created, canceled, or restored.

New method :meth:`~pyrogram.Client.get_poll_stats`.

New field linked_community_id on :obj:`~pyrogram.types.User` and :obj:`~pyrogram.types.Chat`.

Styled Keyboards

:obj:`~pyrogram.types.InlineKeyboardButton` and :obj:`~pyrogram.types.KeyboardButton` now accept a style parameter. New type :obj:`~pyrogram.enums.KeyboardButtonStyle`.

Bug Fixes

  • Session reconnect deadlock fixed.
  • account.* namespace corrected for web browser methods and confirm_bot_connection (were incorrectly using messages.*).
  • Fixed message_thread_id, EmojiStatusUntil AttributeError, PeerID invalid.
  • Fixed messages.chatInviteJoinResultWebView TL ID and replaced webview field with query_id.
  • Fixed messages.composedRichMessageWithAI TL ID and schema (now returns RichMessage).
  • Fixed TypeError on :meth:`~pyrogram.Client.send_message` caused by missing ephemeral_receiver_bot_id in messages.SendMessage.

Build

  • Migrated scrape-errors CI to uv.
  • docs.json regenerated for layers 225, 227, 228 (Unicode preserved, ensure_ascii=False).
  • :meth:`~pyrogram.Client.invoke` now has a generic return type.
  • Fixed async/asyncio compatibility for Python 3.13 & 3.14. CI matrix: 3.10, 3.11, 3.12, 3.13.