# Удалить пользователя из чата

В чатах бывают свои правила, и вы можете применить блок "Удалить пользователя из чата", чтобы исключать нарушителей.

<figure><img src="/files/0Ke9iwaZoGWd08JWGw8s" alt=""><figcaption></figcaption></figure>

Нужно указать Канал (телеграм-бота или группу ВК), далее "Удалить текущего пользователя", который написал запретное слово, и, если необходимо, удалить последнее сообщение либо оставить его.

<figure><img src="/files/3l7tno4R6Lzi4mirzg8w" alt=""><figcaption></figcaption></figure>

Пользователь написал "Запретное слово", наш бот среагировал, удалил пользователя и его последнее сообщение из чата:<br>

<figure><img src="/files/pJf3eQXX9xaTzls2SKcU" alt=""><figcaption></figcaption></figure>

Если ваш бот в Telegram, тогда можно удалить пользователя не только из чата, но и из канала, когда пользователь пишет комментарий. Также можно удалить пользователя навсегда или на определенное время (доступно для супер-групп Telegram)

<figure><img src="/files/iL9xJubgeByiC4OBe5je" alt=""><figcaption><p> </p></figcaption></figure>

Вот так просто можно удалять нежелательных пользователей :)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.smartbotpro.ru/scenarii/deistviya/udalit-polzovatelya-iz-chata.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
