1

I wrote a userbot by Pyrogram to send_message, click bot keyboard with my telegram account.

There's a bot , its menu button is a web app. Can I click its menu button by Pyrogram?

I wrote some code, but it didn't work out.

    raw_bot_peer = await user_bot.resolve_peer('xxx_bot')
    ret = await user_bot.invoke(
        functions.messages.RequestWebView(peer=raw_bot_peer, bot=raw_bot_peer,
                                          platform='android',
                                          from_bot_menu=True,
                                          ))

This code return errors: pyrogram.errors.exceptions.bad_request_400.BotInvalid: Telegram says: [400 BOT_INVALID] - This is not a valid bot (caused by "messages.RequestWebView")

Is there any way to click bot's menu button by Pyrogram code?

zhongwang
  • 11
  • 1

0 Answers0