Graph history
Every non-empty save copies the previous on-disk graph into
~/.config/threadle/graphs/versions/<id>/. Cap is 30 snapshots per graph
(oldest pruned). Empty graphs are never written to disk and do not create
versions.
Undo vs history
Section titled “Undo vs history”| In-session undo | Version history | |
|---|---|---|
| Lifetime | Current editor tab | On disk under config dir |
| Trigger | Structural edits (debounced) | Each successful save of a non-empty graph |
| Restore | Cmd+Z / redo stack | Topbar versions menu → pick a stamp |
Restore writes through the normal save path, so the state you leave behind is itself snapshotted first.
In the workflow editor topbar, open versions (⟲). The list shows timestamp, name, and node count. Click a row to restore.
| Method | Path | Body / notes |
|---|---|---|
GET | /api/graphs/:id/versions | Summary list (ts, updatedAt, name, nodeCount) |
GET | /api/graphs/:id/versions/:ts | Full graph JSON for that stamp |
POST | /api/graphs/:id/restore | { "ts": "<stamp>" } → restored graph |
Related
Section titled “Related”- Graph & wires
- Files & config
- Backup. Full machine archive (includes current graphs, not every version file by default)