> For the complete documentation index, see [llms.txt](https://dfend.gitbook.io/documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://dfend.gitbook.io/documentation/developer-api/bans.md).

# Bans

Events may include [Recommendations](/documentation/developer-api/types/event/recommendation.md) of type BAN\_IP, BAN\_ACTION, or BAN\_DEVICE. In these cases, you should enforce the ban according to your best judgment and using the tools you have available.

## Expiration

[Ban](/documentation/developer-api/types/event/recommendation/ban.md) objects on [Recommendations](/documentation/developer-api/types/event/recommendation.md) may contain an expiration time on the `until` property. This gives you a recommended time limit on the ban.

## Configure

{% hint style="info" %}
Coming soon.
{% endhint %}

You can set your preferences on how bans are handled and what type of ban recommendations you receive in your **Dashboard.**

## Handling false positives

Rarely, a user undergoing normal activity might be operating on an IP that was previously identified as a threat. We are expanding our API to support IP whitelisting, and this functionality is coming soon.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://dfend.gitbook.io/documentation/developer-api/bans.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
