restore
Preview recovering a single backed-up path at a chosen backup version, including destination, conflicts, and exact P5 GUI steps; confirmation creates only the destination folder.
Instructions
Restore plan for ONE path at a chosen BACKUP version (at = a version start from restore_options). P5's CLI and REST cannot select a single path of a backup version (RestoreSelection addentry takes only archive handles; addfromvolume restores a whole volume), so this tool never starts a P5 job: it returns the full preview (source version, volume(s) with barcode and location, destination, bytes, free space, bounded tree, existing destination files, conflict policy, planId) and the exact P5 GUI steps (Restore > Backup > client > path > backup date > restore to the destination folder). confirm:true with the planId only creates the destination folder. Data comes from the catalogue copy of the backup index when the client is indexed, else P5's SQLite index. For archive entries use restore_archive; a whole volume is restore_volume.
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": {
"at": "<at>",
"path": "<path>"
},
"name": "restore"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| at | Yes | Version chosen from restore_options (its `start`, YYYY-MM-DD HH:MM) | |
| to | No | Absolute directory in the P5 container; the original path is placed below it. Default: <restoreRoot>/<YYYYMMDD-HHMMSS> | |
| path | Yes | Original absolute path (file or folder) as backed up | |
| client | No | P5 client (default localhost) | |
| planId | No | planId printed by the preview; required with confirm:true. A changed destination or new conflicts make the call refuse and show the new plan | |
| confirm | No | With planId: prepare the destination folder | |
| forceSync | No | Allow to:'original' inside a configured syncRoot | |
| onConflict | No | What to do when a destination file exists: refuse (default), rename (<name>.restored-YYYYMMDD; not for P5 volume restores) or overwrite |