Create snapshot
create_snapshotCreate a manual checkpoint of the current document to roll back after risky edits. Optionally label the snapshot for identification.
Instructions
Snapshot the current working copy of a document and index it.
When to use: checkpointing before a risky edit so you can roll back. To browse checkpoints use
list_snapshots; to roll back use restore_snapshot. (Mutating tools auto-snapshot; this is an
explicit, manual checkpoint.)
Key params: optional label tags the snapshot (length-bounded; over the cap is rejected).
Return shape: SnapshotInfo — the new snapshot_id plus its metadata.
Example: create_snapshot(doc_id, label="before cleanup")
Risk class: low (write-new snapshot; original untouched).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| label | No | ||
| doc_id | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| seq | Yes | ||
| file | Yes | ||
| label | No | ||
| created_at | Yes | ||
| size_bytes | Yes | ||
| snapshot_id | Yes | ||
| operation_id | No |