Merge duplicate books
calibre_merge_booksMerge duplicate Calibre book records by moving formats into a target book, merging metadata, and trashing sources, with safe/formats-only modes and dry-run preview.
Instructions
Merge duplicate book records: moves formats from the sourceIds books into targetId (the target's copy wins conflicts), merges metadata per Calibre's rules, then trashes the sources. mode=safe keeps sources; mode=formatsOnly moves formats only. Dry-run unless confirm=true. Previews work without writes; applying needs CALIBRE_MCP_ENABLE_WRITE.
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": {
"targetId": "<targetId>",
"sourceIds": "<sourceIds>"
},
"name": "calibre_merge_books"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mode | No | merge | |
| confirm | No | ||
| library | No | ||
| targetId | Yes | ||
| sourceIds | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mode | No | ||
| steps | No | ||
| status | No | ||
| targetId | No | ||
| warnings | No | ||
| indexNote | No | ||
| sourceIds | No | ||
| formatMoves | No | ||
| writeEnabled | No | false on a preview in a session with writes disabled: applying it will be refused (write_disabled) | |
| metadataChanges | No |