skip to Main Content

Looking at the Telegram API documentation I can’t find any hook that allow me to call a method when an user enter in a group.

Note that forma ‘enter’ I mean when the user open the chat, and not a join to the group.

I’m using TelegrafJS framework.

Kind regards.

2

Answers


  1. As far as I know it’s a security feature that you have no access to what people ‘open’, there is a reason that the join button is there, so that people share their info with the group when they are comfortable sharing it.

    If there was, you’d have to use the same solution with a different result (I.E: new_browsed_users)
    Since the Update object doesn’t return it, then we can assume there isn’t a way.

    Telegram Bot Event When Users Join To Channel

    Login or Signup to reply.
  2. I’m not in TelegrafJS, but should be like this:

    bot.on('new_chat_members', (ctx) => ctx.reply('👍'))
    

    See “new_chat_members” here.

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