> ## Documentation Index
> Fetch the complete documentation index at: https://slackhive.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Version History

> Every save auto-snapshots the agent. Browse GitHub-style file diffs and restore any version.

Every save to an agent - system prompt, skills, tools, permissions, channel restrictions - automatically creates a snapshot. The **History** tab lets you browse the full timeline, see exactly what changed, and restore any previous version.

This gives you a safety net: experiment freely, and roll back cleanly if something breaks.

## What gets snapshotted

| Captured                                           | Not captured                                              |
| -------------------------------------------------- | --------------------------------------------------------- |
| System prompt                                      | Name                                                      |
| All skill files                                    | Slug                                                      |
| Tool allowlist and denylist                        | Description                                               |
| MCP server assignments                             | Slack credentials (stored separately)                     |
| Capability toggles (Internet Access, Shell Access) | Memory (has its own storage)                              |
| Channel restrictions                               | Knowledge Library wiki folders (shared, separate storage) |

## Skip when nothing changed

If you save without changing anything, **no snapshot is created**. The history only shows real state changes. This keeps the list clean.

## GitHub-style file diffs

Open a snapshot and you see a file-level diff in GitHub's familiar layout:

* **Left pane** - file tree of what changed (added / modified / removed badges)
* **Right pane** - the unified diff for the selected file
* Green additions, red deletions, gray context
* Each changed file is collapsible

Works for every captured piece - skills, system prompt, MCP assignments, permission lists, and channel restrictions all render as unified diffs.

## Restore preview

Before you restore, you can preview what will happen:

1. Open a snapshot
2. Click **Preview Restore**
3. A new pane shows the file-level diff between **now** and the snapshot
4. Every file that would change is listed with its diff
5. Click **Restore** to apply, or close the preview to cancel

This means no surprises - you see the exact impact before committing.

## How to restore

1. Open an agent → **History** tab
2. Click the snapshot you want
3. **Preview Restore** (optional - see above)
4. Click **Restore this version**
5. Confirm

The runner hot-reloads the agent within seconds. The restored state becomes current and is itself snapshotted as a new entry - so restoring is always reversible.

## Retention

SlackHive keeps up to **10 snapshots per agent**. When a new snapshot would exceed the cap, the oldest is dropped automatically.

To preserve a specific version permanently, export the agent config (see [Import / Export](/features/import-export)) before it ages out.

## Conversation history

Separate from version history - each Slack thread has its own persistent agent session.

* Sessions identified by `userId + channelId + threadTs`
* Session context survives runner restarts
* Same thread next week? Same session - full context preserved, including tool results and prior exchanges
* Sessions expire after **30 minutes of inactivity**
* The runner runs a cleanup job every 10 minutes to prune stale sessions

After expiry, the next message in the thread starts a fresh session. The agent still has all memories from previous conversations - those live separately in the agent-level memory store.
