> For the complete documentation index, see [llms.txt](https://docs.datasentinel.io/manual/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.datasentinel.io/manual/implementation/platform-usage/configuration/audit.md).

# Audit

You can thus know the Datasentinel modules as well as the selected instances with their date of use.

Convenient if you want to delete inactive accounts for example

## Configure

{% hint style="info" %}
On a new installation, the audit is **enabled** with a retention of **60** days.
{% endhint %}

{% stepper %}
{% step %}

### Open tools menu

> <img src="/files/vTlfxOUujU3ED19qYJfj" alt="" data-size="original">

{% endstep %}

{% step %}

### Global settings

> <img src="/files/9wXHX0cMClM0zSBv4tDG" alt="" data-size="original">

{% endstep %}

{% step %}

### Audit settings

<figure><img src="/files/HhpWHQkmfB8tjV0c9o7B" alt=""><figcaption><p>Audit settings</p></figcaption></figure>

Enable or disable audit logging and configure the retention period (in days) for audit records.

When audit logging is enabled, Datasentinel records all user actions, including the module used and the selected PostgreSQL instance.
{% endstep %}
{% endstepper %}

## View

From the **Tools** menu, click **Users**.

The **Last Use** field shows the date of the most recent action performed by each user.

<figure><img src="/files/eoXkkYDzR1oPnOhkLlb8" alt=""><figcaption><p>Audit last use</p></figcaption></figure>

All user actions can be viewed in the **Usage** tab.

<div data-with-frame="true"><figure><img src="/files/Ydq1zxSIrn8kl0uiV3Hx" alt=""><figcaption><p>Usage</p></figcaption></figure></div>

Actions are grouped by user and PostgreSQL instance. For more detailed analysis, results can also be grouped by day and/or module.

The **Number of Uses** column shows how many times each action was performed.

{% hint style="info" %}
Actions can also be viewed at the individual user level.
{% endhint %}

<div data-with-frame="true"><figure><img src="/files/GK0DXKMKLhOA83dKOjNu" alt=""><figcaption><p>User audit actions</p></figcaption></figure></div>


---

# 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://docs.datasentinel.io/manual/implementation/platform-usage/configuration/audit.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.
