Message

class pyrogram.raw.types.Message

A message

Constructor of Message.

Details:
  • Layer: 194

  • ID: 94345242

Parameters:
  • id (int 32-bit) – ID of the message

  • peer_id (Peer) – Peer ID, the chat where this message was sent

  • date (int 32-bit) – Date of the message

  • message (str) – The message

  • out (bool, optional) – Is this an outgoing message

  • mentioned (bool, optional) – Whether we were mentioned in this message

  • media_unread (bool, optional) – Whether there are unread media attachments in this message

  • silent (bool, optional) – Whether this is a silent message (no notification triggered)

  • post (bool, optional) – Whether this is a channel post

  • from_scheduled (bool, optional) – Whether this is a scheduled message

  • legacy (bool, optional) – This is a legacy message: it has to be refetched with the new layer

  • edit_hide (bool, optional) – Whether the message should be shown as not modified to the user, even if an edit date is present

  • pinned (bool, optional) – Whether this message is pinned

  • noforwards (bool, optional) – Whether this message is protected and thus cannot be forwarded; clients should also prevent users from saving attached media (i.e. videos should only be streamed, photos should be kept in RAM, et cetera).

  • invert_media (bool, optional) – If set, any eventual webpage preview will be shown on top of the message instead of at the bottom.

  • offline (bool, optional)

  • video_processing_pending (bool, optional) – N/A

  • from_id (Peer, optional) – ID of the sender of the message

  • from_boosts_applied (int 32-bit, optional)

  • saved_peer_id (Peer, optional) – Messages fetched from a saved messages dialog » will have peer=inputPeerSelf and the saved_peer_id flag set to the ID of the saved dialog.

  • fwd_from (MessageFwdHeader, optional) – Info about forwarded messages

  • via_bot_id (int 64-bit, optional) – ID of the inline bot that generated the message

  • via_business_bot_id (int 64-bit, optional)

  • reply_to (MessageReplyHeader, optional) – Reply information

  • media (MessageMedia, optional) – Media attachment

  • reply_markup (ReplyMarkup, optional) – Reply markup (bot/inline keyboards)

  • entities (List of MessageEntity, optional) – Message entities for styled text

  • views (int 32-bit, optional) – View count for channel posts

  • forwards (int 32-bit, optional) – Forward counter

  • replies (MessageReplies, optional) – Info about post comments (for channels) or message replies (for groups)

  • edit_date (int 32-bit, optional) – Last edit date of this message

  • post_author (str, optional) – Name of the author of this message for channel posts (with signatures enabled)

  • grouped_id (int 64-bit, optional) – Multiple media messages sent using messages.sendMultiMedia with the same grouped ID indicate an album or media group

  • reactions (MessageReactions, optional) – Reactions to this message

  • restriction_reason (List of RestrictionReason, optional) – Contains the reason why access to this message must be restricted.

  • ttl_period (int 32-bit, optional) – Time To Live of the message, once message.date+message.ttl_period === time(), the message will be deleted on the server, and must be deleted locally as well.

  • quick_reply_shortcut_id (int 32-bit, optional)

  • effect (int 64-bit, optional)

  • factcheck (FactCheck, optional)