restore
Revert a note to a past Git revision by vault, path, and rev; recreates deleted notes and snapshots dirty worktree state first. Rejects stale content when expected_sha256 is supplied.
Instructions
Restore a note's content from a past revision (git rev, e.g. a history sha); the response echoes the revision as restored_from. Snapshots dirty worktree state first; recreates deleted notes. Honors expected_sha256 against current content.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"vault": "<vault>",
"path": "<path>",
"rev": "<rev>"
},
"name": "restore"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| rev | Yes | Git revision (e.g. a history sha) | |
| path | Yes | Vault-root-relative note path | |
| vault | Yes | Vault name | |
| expected_sha256 | No | SHA-256 of current content; rejects stale restores |