# Backups

URL: https://zerodev.ca/docs/medusa/modules/backups

> Save a snapshot of your server's roles and channels and rebuild that layout later.



Backups saves the layout of your server so you can keep a record of it or rebuild it after something goes wrong. A snapshot holds roles and channels. It does not hold messages or members.

## What a Snapshot Holds

| Part     | Saved                                                                                      |
| -------- | ------------------------------------------------------------------------------------------ |
| Roles    | Name, color, permissions and position.                                                     |
| Channels | Name, type, category, position, topic, NSFW flag, voice bitrate and permission overwrites. |

## Restoring

`/backup restore <id>` applies a snapshot to the live server. Medusa matches existing roles and channels by ID first and then by name, so only the missing ones are created. Running it twice is safe.

<Callout type="warn">
  A restore changes the server right away. Medusa needs **Manage Roles** and **Manage Channels**, and its own role has to sit above every role it restores.
</Callout>

## Saving a Single Message

Right-click a message and pick **Apps > Archive Message** to get a JSON file with its author, content, attachments and embeds.

## Settings

| Setting                  | Default | What it does                                                                                        |
| ------------------------ | ------- | --------------------------------------------------------------------------------------------------- |
| Maximum Stored Snapshots | 10      | How many snapshots a server can keep. Delete one before making a new one once the limit is reached. |

## Commands

| Command                  | What it does                                       |
| ------------------------ | -------------------------------------------------- |
| `/backup create [notes]` | Save a snapshot of the current roles and channels. |
| `/backup list`           | List saved snapshots.                              |
| `/backup info <id>`      | Show what a snapshot holds.                        |
| `/backup delete <id>`    | Delete a snapshot.                                 |
| `/backup restore <id>`   | Apply a snapshot to the server.                    |
| Archive Message          | Download a message as JSON.                        |

These commands belong to the Admin rank by default. Snapshots are also listed on the **Backups** dashboard page.
