channels.DeleteHistory

class pyrogram.raw.functions.channels.DeleteHistory

Delete the history of a supergroup

Details:
  • Layer: 223

  • ID: 9BAA9647

Parameters:
  • channel (InputChannel) – Supergroup whose history must be deleted

  • max_id (int 32-bit) – ID of message up to which the history must be deleted

  • for_everyone (bool, optional) – Whether the history should be deleted for everyone

Returns:

Updates

TL Schema

channels.deleteHistory#9baa9647
flags:#
for_everyone:flags.0?true
channel:InputChannel
max_id:int

= Updates

Parameter Tree

DeleteHistory
├── for_everyonetrue (optional)
├── channelInputChannel
│ ├── InputChannelEmpty
│ ├── InputChannel
│ │ ├── channel_idlong
│ │ └── access_hashlong
│ ├── peerInputPeer
│ │ ├── InputPeerEmpty
│ │ ├── InputPeerSelf
│ │ ├── InputPeerChat
│ │ ├── InputPeerUser
│ │ ├── InputPeerChannel
│ │ ├── InputPeerUserFromMessage
│ │ └── InputPeerChannelFromMessage
│ ├── msg_idint
│ └── channel_idlong
└── max_idint

Example

await app.invoke(
    DeleteHistory(
        for_everyone=None,
        channel=await app.resolve_channel(chat_id),
        max_id=0,
    )
)