skip to Main Content

I created a new Telegram Bot which maintains a simple list. When I chat with the Bot directly (in PMs) the Bot works as intended.

Working as intended

I created this bot for a group of friends, so I added the bot to the group, and now, whenever I execute a command, the bot responds, but also repeats my command. Is there any way to avoid this behavior?

Bot in Group

I am using the python-telegram-bot API and sending messages using update.message.reply_text('My message')

Is this just intended behavior or is there any way to avoid the bot repeating the sent command?

2

Answers


  1. Chosen as BEST ANSWER

    I found the solution. Telegram API understands this as quoting, and is enabled in groups by default, disabled in private chats. It can be disabled by using:

    update.message.reply_text("message", quote=False)
    

  2. The bot only is replying message, not creating 2 messages.

    You should use send_message.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search