Skip to content

Instantly share code, notes, and snippets.

@barrowsys
Created February 12, 2020 17:40
Show Gist options
  • Save barrowsys/91d5f5087fc96041cbd2390c6ffbd480 to your computer and use it in GitHub Desktop.
Save barrowsys/91d5f5087fc96041cbd2390c6ffbd480 to your computer and use it in GitHub Desktop.
async def delete(
self, channel: Union[chat1.ChatChannel, chat1.ConvIDStr], message_id: int
) -> chat1.SendRes:
await self.bot.ensure_initialized()
ch_key, ch_val = self._channel_or_conv_id(channel)
res = await self.execute(
{
"method": "delete",
"params": {"options": {ch_key: ch_val, "message_id": message_id}},
}
)
return chat1.SendRes.from_dict(res)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment