---
title: "Audit Log"
description: "Track every change in your organization with a tamper-evident activity history — and undo mistakes with a single click."
updated: 2026-06-09
---

# Audit Log

## What is the Audit Log?

Every organization needs a paper trail. The Audit Log records every meaningful action taken within your Toolbelt organization — who did what, when, and to which resource. Whether you're debugging an unexpected change, conducting a security review, or simply curious about recent activity, the Audit Log gives you full visibility.

The system also supports **undo** for reversible actions, so a mis-click on a delete or update isn't necessarily permanent.

---
## How it works

When any user in your organization creates, modifies, or deletes a resource, Toolbelt automatically writes an audit entry containing:

- **Who** performed the action (user ID)
- **What** was affected (entity type + entity ID + name)
- **When** it happened (timestamp)
- **What changed** (a snapshot of the previous state, where applicable)
- **Whether it can be undone**

No configuration is required — auditing is always on for your organization.

---
## Tracked entity types

| Entity type | Description | Undoable? |
|---|---|---|
| `workspace` | Assistants | ✅ create, update, delete |
| `scheduled_task` | Scheduled tasks | ✅ create, update, delete |
| `quick_chat` | Quick chat prompts | ✅ create, update, delete |
| `service_connection` | Connected services | ✅ create, update, delete |
| `wrench` | Reusable code snippets | ✅ create, update, delete |
| `storage_file` | Files in organization storage | ✅ create, update, delete |
| `organization` | Organization settings | ✅ update |
| `organization_member` | User membership | ✅ create, update, delete |
| `workspace_chat` | Organization chats | ✅ create, update, delete |
| `board_task` | Kanban board tasks | ✅ create, update, delete |
| `wrench_execution` | Wrench runs | ❌ action only |
| `chat` | Conversations | ❌ action only |
| `task_execution` | Scheduled task runs | ❌ action only |

> **Note:** Executions and conversation history are logged for observability but cannot be undone — they represent things that happened in the real world.



---
## Action types

| Action | Description |
|---|---|
| `create` | A new entity was created |
| `update` | An existing entity was modified |
| `delete` | An entity was removed |
| `action` | An activity was logged but is not reversible (e.g., a chat, an execution) |

---
## Viewing the Audit Log

Navigate to **Organization Settings → Audit Log** in the Toolbelt dashboard. You can filter entries by:

- **Entity type** — show only changes to assistants, tasks, etc.
- **Action type** — show only deletes, or only creates
- **Date range** — focus on a specific window of time
- **User** — see what a specific team member has done

---
## Undoing a change

When an entry is marked as undoable, an **Undo** button appears next to it in the dashboard. What happens when you undo depends on the original action:

| Original action | Undo behavior |
|---|---|
| `create` | The entity is soft-deleted |
| `update` | The entity is restored to its `previousState` |
| `delete` | The entity is recreated from its `previousState` |

> **Warning:** Undo restores the entity to exactly the state it was in before the action. Any changes made between the original action and the undo are **not** automatically preserved.



---
## API reference

### List audit entries


```http
GET /api/audit
```


Returns a paginated list of audit entries for your organization. Supports the following query parameters:

| Parameter | Type | Description |
|---|---|---|
| `entityType` | string | Filter by entity type (e.g., `workspace`, `wrench`) |
| `actionType` | string | Filter by action type (`create`, `update`, `delete`, `action`) |
| `limit` | number | Maximum number of entries to return (default: 50) |
| `offset` | number | Pagination offset |

**Example response**


```json
{
  "entries": [
    {
      "id": "audit_abc123",
      "userId": "user_xyz",
      "entityType": "wrench",
      "entityId": "wrench_456",
      "entityName": "fetch-github-pr",
      "actionType": "delete",
      "description": "Deleted wrench 'fetch-github-pr'",
      "isUndoable": true,
      "createdAt": "2026-03-22T14:30:00Z"
    }
  ],
  "total": 142,
  "offset": 0
}
```

### Undo an action


```http
POST /api/audit/:id/undo
```


Reverses the specified audit entry. Returns the restored entity or an error if the action is not undoable.

> **Note:** Requires authentication. Only organization admins can undo other users' actions.
