@bot.message_handler(content_types=['new_chat_members'])
def get_text(message):
count = bot.get_chat_members_count(
message.chat.id)
if count == 999:
bot.send_message(
message.chat.id, "Еще один участник и нас будет 1000!!! ")
elif count == 1000:
bot.send_message(
message.chat.id, "Воу Воу Воу! Нас уже 1000 человек! Спасибо всем участникам нашего чата!")
for user in message.new_chat_members:
bot.send_message(
message.chat.id, "Привет, рады видеть тебя в нашем сообществе!")