Skip to content

addChatMember

Sahri Riza Umami edited this page Dec 8, 2016 · 3 revisions

Adds new member to chat.

addChatMember(chat_id, user_id, forward_limit)

Members can't be added to private or secret chats.
Member will not be added until chat state will be synchronized with the server.
Member will not be added if application is killed before it can send request to the server.

Option Description
chat_id Chat identifier.
user_id Identifier of the user to add.
forward_limit Number of previous messages from chat to forward to new member, ignored for channel chats.

Example

Add user 1234567890 into 133780085 group and forward 20 previous messages to this new member.

addChatMember(1234567890, 133780085, 20)

Test script
Frequently Asked Questions
The Functions

Clone this wiki locally