Move duplicates to trash
trash_duplicatesMove duplicate copies within a folder to a restorable trash while keeping the oldest marked copy, after listing duplicate groups. Run a dry-run plan first to preview which files will be moved.
Instructions
Keep the copy marked keep=true (the oldest) of each duplicate group inside path and move the others to the axross trash; copies outside path do not count. Use when: after list_duplicate_groups; run dry_run=true first. Instead: list_duplicate_groups to look; delete_path to delete for good. Requires: --mcp-tools duplicates. Behavior: destructive but restorable; dry_run=true (default) only plans. Trashed copies leave the index. Copies are re-checked first; changed ones go to refused. Moves done before a cancel or timeout stay: rerun to finish. The trash is .axross-trash in the MCP root (remote: home); restore in the axross app. Time limit: 30 min. Returns: {path, dry_run, groups, undated_groups (survivor chosen by path), keep, trash (planned), removed (done; [] on dry_run), refused, failed, trash_root}.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "trash_duplicates"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | The folder (absolute, or relative to the MCP root). Default on the local backend: the MCP root; other backends need it. | |
| backend | No | Backend id from list_backends; omit for the default. | |
| dry_run | No | true: only return the plan; false: move the planned copies to the trash. | |
| scan_id | No | Only groups with at least one copy from this scan (a scan_id from list_duplicate_scans); 0 = rows from before scans were recorded. Omit for all scans. | |
| path_b64 | No | path as base64 of its raw bytes, for non-UTF-8 names; replaces path. | |
| algorithm | No | Only groups hashed with this algorithm; omit for every algorithm. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| keep | Yes | ||
| path | Yes | ||
| trash | Yes | ||
| failed | Yes | ||
| groups | Yes | ||
| dry_run | Yes | ||
| refused | Yes | ||
| removed | Yes | ||
| trash_root | Yes | ||
| undated_groups | Yes |