> For the complete documentation index, see [llms.txt](https://docs.botdistrikt.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.botdistrikt.com/features/settings/audit-logs.md).

# Audit Logs

**Audit log** in BotDistrikt records or logs all the interactions and activities that occur within the chatbot system. It serves as a chronological history of events, actions, and data related to your chatbots’ operations.&#x20;

Audit logs are essential for monitoring system usage, debugging issues, ensuring security compliance, and tracking changes made to chatbot configurations.

### Key Information Captured

Each audit log entry contains the following fields:

* **ID**: Unique identifier for each log entry
* **User**: The user or system that performed the action
* **Action**: The type of action performed (e.g. LOGIN, CREATED, UPDATED, DELETED)
* **Entity Name**: The type of object affected (e.g. card, access, tag, text\_prompt)
* **Entity ID**: Unique identifier of the affected entity
* **Timestamp**: Date and time when the action occurred

### Types of Activities Logged

The audit log captures a wide range of events, including:

* **User interactions** (e.g. logins, access events)
* **System events** (e.g. automated processes)
* **Configuration changes** (e.g. updates to chatbot content or settings)
* **Security-related actions** (e.g. access control changes)
* **CRUD operations**:
  * **CREATED**
  * **UPDATED**
  * **DELETED**

### Entity Names

The queryable entity names in the platform are tabulated below

<table><thead><tr><th width="185.6484375">Entity Name</th><th>Description</th></tr></thead><tbody><tr><td>access</td><td>Team member user access record</td></tr><tr><td>action_prompt</td><td>LLM Agent that outputs a value or JSON schema into a user attribute </td></tr><tr><td>action</td><td>Context change response modifying memory and variables</td></tr><tr><td>alibaba_cloud_app</td><td>Alibaba Cloud integration settings</td></tr><tr><td>assistant_app</td><td>Google Assistant integration settings</td></tr><tr><td>audio</td><td>Audio response from chatbot</td></tr><tr><td>azure_openai_app</td><td>Microsoft Azure OpenAI integration settings</td></tr><tr><td>broadcast</td><td>Bulk notification to multiple users</td></tr><tr><td>button</td><td>Clickable button attached to responses</td></tr><tr><td>card</td><td>Rich element with image, title, subtitle, buttons</td></tr><tr><td>chatbase_app</td><td>Chatbase integration settings</td></tr><tr><td>condition</td><td>Evaluates incoming message against context property and value</td></tr><tr><td>csv_export</td><td>CSV Export record</td></tr><tr><td>deepseek_app</td><td>DeepSeek integration settings</td></tr><tr><td>dialogflow_app</td><td>Dialogflow integration settings</td></tr><tr><td>docs_app</td><td>Google Docs integration settings</td></tr><tr><td>document</td><td>Document response from chatbot</td></tr><tr><td>facebook_app</td><td>Facebook App integration settings</td></tr><tr><td>facebook_page</td><td>Facebook Page integration settings</td></tr><tr><td>form_question</td><td>Form question inside a form</td></tr><tr><td>form</td><td>Fillable form in a linear flow</td></tr><tr><td>function</td><td>JavaScript function to modify or evaluate message context</td></tr><tr><td>group</td><td>Set of rules organizing bot topics and functionalities</td></tr><tr><td>image</td><td>Image response from chatbot</td></tr><tr><td>instagram_page</td><td>Instagram Page integration settings</td></tr><tr><td>integration_step</td><td>Integration step response</td></tr><tr><td>langfuse_app</td><td>Langfuse integration settings</td></tr><tr><td>llm_source</td><td>Source for LLM chunks, in the form of Website, Document, Google Docs or Google Sheets</td></tr><tr><td>openai_app</td><td>OpenAI integration settings</td></tr><tr><td>persisted_menu</td><td>Always-on clickable buttons at chat screen bottom</td></tr><tr><td>quick_reply</td><td>Transient button for user to respond to story</td></tr><tr><td>response_group</td><td>Text response from chatbot with random variant selection</td></tr><tr><td>response</td><td>Text response variant for random selection</td></tr><tr><td>rule</td><td>Conditions to evaluate message and select story response</td></tr><tr><td>salesforce_app</td><td>Salesforce integration settings</td></tr><tr><td>sheets_app</td><td>Google Sheets integration settings</td></tr><tr><td>skype_app</td><td>Skype integration settings</td></tr><tr><td>sms_app</td><td>SMS integration settings</td></tr><tr><td>step</td><td>One response in a story with position order</td></tr><tr><td>sticker</td><td>Sticker response from chatbot with emoji or set</td></tr><tr><td>story</td><td>Bot response with multiple response types and steps</td></tr><tr><td>tag</td><td>Label applied to users and models for filtering</td></tr><tr><td>teams_app</td><td>Microsoft Teams integration settings</td></tr><tr><td>telegram_app</td><td>Telegram integration settings</td></tr><tr><td>template</td><td>Bot Template to create a new bot from</td></tr><tr><td>text_prompt</td><td>LLM Agent that performs RAG and outputs a response</td></tr><tr><td>thread_comment</td><td>Comments in threads</td></tr><tr><td>thread</td><td>A group of comments for an entity</td></tr><tr><td>twitter_app</td><td>Twitter integration settings</td></tr><tr><td>vertexai_app</td><td>Google Vertex AI integration settings</td></tr><tr><td>video</td><td>Video response from chatbot</td></tr><tr><td>webchat_app_placement</td><td>Website Chat Widget variant settings</td></tr><tr><td>webchat_app</td><td>Website Chat Widget settings</td></tr><tr><td>webhook_app</td><td>Webhook to notify other applications on user message</td></tr><tr><td>webhook</td><td>API call response from chatbot to external systems</td></tr><tr><td>wechat_app</td><td>WeChat integration settings</td></tr><tr><td>whatsapp_app</td><td>WhatsApp integration settings</td></tr><tr><td>wit_app</td><td>Wit.ai integration settings</td></tr><tr><td>wrong_response</td><td>Tracked issue based on a message-response pair</td></tr><tr><td>zendesk_app</td><td>Zendesk integration settings</td></tr></tbody></table>

### How to Access Audit Logs

To access the audit log, navigate to the side panel **Settings → Audit Log**

<figure><img src="/files/HQy5fuLQ9pFjdSSuTVm4" alt=""><figcaption><p>Audit Log Dashboard</p></figcaption></figure>

### Viewing Changes

* Hover over **Entity Name** to view the code block of changes made.

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

* This allows you to inspect exactly what was modified during an update.

#### Action Types and JSON Data Deltas

#### 1. Action: CREATED

The **CREATED** action indicates that a new record has been added to the database.

* **Visual Cue:** Fields are highlighted in **Green**.&#x20;
* **Behavior:** Because there is no "previous state" for a new entity, the system displays the entire initial data set as an addition.
* **Example:** When a user creates a new `Text` responses under "Responses", all defined attributes like `name` and `is_active` will appear in green to show they are now part of the system.

<figure><img src="/files/7T2KY6FgAnrKCRsh0NwE" alt=""><figcaption></figcaption></figure>

#### 2. Action: UPDATED

The **UPDATED** action records modifications made to an existing record.

* **Visual Cue:** **Red Strikethrough** (Old) and **Green Highlight** (New).
* **Behavior:** The system performs a "delta" comparison. It shows you exactly what the value was before the change and what it became after the save.
* **Example:** If a `name` is changed from `"Hello World!"` to `"Good Morning 🌞"`, the log will display:&#x20;

<figure><img src="/files/7vTQqrJknrsIcsaal0n3" alt=""><figcaption></figcaption></figure>

#### 3. Action: DELETED

The **DELETED** action tracks the removal of a record from the system.

* **Visual Cue:** All fields are highlighted in **Red with a Strikethrough**.&#x20;
* **Behavior:** The JSON snapshot represents the "final state" of the data immediately before it was removed. The red formatting indicates that this specific data set is no longer active or reachable.
* **Example:** Deleting a `Text` will show the entire object struck through in red, serving as a historical record of what was removed.

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

### Filtering Logs

You can use the **filter function** to refine and search for specific logs based on:

* User
* Action type
* Entity
* Date/time range

This helps quickly locate relevant events for troubleshooting or audits.

**Add filter(s)** to search through specific logs.

### Example

An example log entry may show:

* A user login event
* A deleted card entity
* The exact timestamp of when the action occurred

### How to Apply Filters

1. Click the **+ add filter** button.

<div align="left"><figure><img src="/files/84nMixPOi9AyD9A17CX9" alt=""><figcaption></figcaption></figure></div>

2. Select category from the first dropdown.

<figure><img src="/files/5LrXUC216ONvLUI9XIc6" alt=""><figcaption></figcaption></figure>

3. Choose your **Operator** (e.g., `contains`, `equals`).
4. Input the **Value** or select it from the provided list/calendar.
5. To remove a filter, click the **trash icon** 🗑️ next to the filter row.

#### 1. Filter by ID

Filter records based on their unique identifier.

* **Operators:** `equals`, `not equals`, `greater than`, `less than`.
* **Use Case:** Best for locating a specific log entry if you have the direct ID number.

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

#### 2. Filter by User

Filter logs based on the person who performed the action.

* **Operators:** `equals`, `not equals`.
* **Use Case:** Auditing the activity of a specific team member or administrator.

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

#### 3. Filter by Action

Filter by the type of action that occurred.

* **Available Values:** `CREATED`, `UPDATED`, `DELETED`, `INVITED`, `ACCEPTED`, `LOGIN`, `LOGOUT`.

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

#### Actions on Entities / Objects

Track changes to specific objects within the platform (such as story changes or user access activities).

**Use Case:** Finding all instances of a specific behavior, such as seeing who has logged in recently or identifying all deleted entities.

* **CREATED**: Logged when a new entity is initially added to the system. The associated JSON will show all initial values in green.
* **UPDATED**: Logged whenever an existing entity is modified. The JSON delta will highlight exactly which values were changed.
* **DELETED**: Logged when an entity is removed. This provides a final snapshot of the data before deletion.

#### 4. Filter by Entity Name

Filter based on the name of the object being modified (e.g., a specific response group name).

* **Operators:** `equals`, `not equals`, `contains`, `not contains`.
* **Use Case:** Searching for all changes related to access management, or if want to search actions done to a specific story (even if you only remember a part of the story name, use "contains").

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

#### 5. Filter by Entity ID

Filter based on the unique ID of the entity itself.

* **Operators:** `equals`, `not equals`, `greater than`, `less than`.
* **Use Case:** Tracking the entire lifecycle (creation, updates, deletion) of one specific entity e.g. tag, card, story across different points in time.

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

#### 6. Filter by Timestamp

Narrow down logs by a specific date and time.

* **Modes:**
  * **Normal:** Select a specific date from the calendar and a specific time.
  * **Relative:** (e.g., "Last 1 hour", "Last 7 days").
* **Operators:** `greater than` (after), `less than` (before).
* **Use Case:** Investigating incidents that occurred within a specific timeframe.

<figure><img src="/files/6cFJaVTeCdnVdJm4cb2l" alt=""><figcaption></figcaption></figure>

#### Notes

* Logs are displayed in descending chronological order (most recent first).
* All actions are recorded automatically and cannot be modified.
