# Ban/unban command

## Ban a user

To ban a user, you just need to run the command `/ban` and indicating, as in the example below, the user, the duration, the reason and a proof.

<figure><img src="https://3326436899-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0q7dNYj3sqpFKv3PRoew%2Fuploads%2F8w95U88YIMQMewYqjNcr%2Fimage.png?alt=media&#x26;token=4f344e9a-b383-43c1-b166-8830332e3cd1" alt=""><figcaption><p>Example of the command <code>/ban</code></p></figcaption></figure>

{% hint style="warning" %}
The **duration**, the **reason** and the **proof** are not **obligatory** ! If you **don't specify** a reason or you **don't give** a proof, they will be **filled** as `none`. If you **don't specify** a duration, the ban will be **definitive**.
{% endhint %}

Once the command is run, the robot will do all the necessary checks to find out if the user can be banned from the server. If this is the case, this message will be resend to you.

<figure><img src="https://3326436899-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0q7dNYj3sqpFKv3PRoew%2Fuploads%2Fwtl9vs8zCFZggus1QW5y%2Fimage.png?alt=media&#x26;token=c5b875d2-8b90-43a6-8546-5a96dcc2054a" alt=""><figcaption><p>Example of the command <code>/ban</code> response</p></figcaption></figure>

{% hint style="success" %}
**Congratulations**, you have just banned a user with **ProtectList** ! The **ban informations** will be **saved** by the bot and you will be able to **get** it.
{% endhint %}

## Unban a user

### With the button

You can unban a user with the button below the command response. You just have to click on the button and indicate the reason for the unban in the modal appearing, as below.

<figure><img src="https://3326436899-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0q7dNYj3sqpFKv3PRoew%2Fuploads%2FgFl8ahxEacCdPZo6LIW1%2Fimage.png?alt=media&#x26;token=f8bdae61-e2f5-43b4-8e43-3da754dc8e48" alt=""><figcaption><p>Example of the modal for deban a user from the button of the command <code>/ban</code></p></figcaption></figure>

When you click on the button `Submit`, the bot will send this message.

<figure><img src="https://3326436899-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0q7dNYj3sqpFKv3PRoew%2Fuploads%2FM55y6VgDQwJyQnblxDST%2Fimage.png?alt=media&#x26;token=278b2ef8-46d9-49ec-9545-d642334c3ef3" alt=""><figcaption><p>Example of the response for a deban of a user from the button of the command <code>/ban</code></p></figcaption></figure>

### With the command

The command is the same thing than the button. You have just to run the command `/unban` and indicating, as in the example below, the user ID and the reason.

<figure><img src="https://3326436899-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0q7dNYj3sqpFKv3PRoew%2Fuploads%2FIuOUnWbFtzjsS2ghWE3j%2Fimage.png?alt=media&#x26;token=47fc8a66-8017-4fe3-9111-6323a5f94ab2" alt=""><figcaption><p>Exemple of the command <code>/unban</code></p></figcaption></figure>

When you execute this command, the bot will send this message :

<figure><img src="https://3326436899-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0q7dNYj3sqpFKv3PRoew%2Fuploads%2FUYp5y1Fyz15JnHoI9ZpF%2Fimage.png?alt=media&#x26;token=63fe9db2-496d-44a3-95bf-e3982f578a92" alt=""><figcaption><p>Exemple of the response for a deban of a user from the command <code>/unban</code></p></figcaption></figure>

{% hint style="success" %}
**Congratulations**, you have just unbanned a user with **ProtectList** ! The **unban informations** will be **saved** by the bot and you will be able to **get** it.
{% endhint %}
