Join and Leave notifications

Join and Leave notifications

Telegram Bot Support

Telegram Bot API has been supporting join and leave notifications in groups and supergroups for quite a while. Those notifications should arrive to your bot as an Update within the chat_member or my_chat_member field.

In the ChatMemberUpdated object, you can receive two different fields to inform your bot about those notifications:

  • old_chat_member: This field will contain the previous information about the user status in relation to the group. Keep in mind that your own bot can be among them first time the bot is added to the chat.
  • new_chat_member: This field will contain the new information about the user status in relation to the group. Keep in mind that your own bot can be among them first time the bot is added to the chat.

Notifications don't work the same way in all kinds of chats, kindly see more details below.

Groups

In normal groups, your bot will receive a notifications every time an user join the chat or leave it (including a notification when the bot itself is kicked from the group).

Supergroups

  • During first minutes after supergroup creation, no join/left notifications are sent.
  • In supergroups with a big amount of members, left notifications won't be sent if there have been no new messages in this group during the last hours.

Report Page