Soft-delete a node
delete_nodeDeletes a node while preventing accidental cascades: refuses if it has active descendants, unless transplanting mode allows a hard delete.
Instructions
Sets removed_at on the node. By policy this tool rejects deletion if the node has any active descendant — delete children explicitly first to avoid accidental cascades. (The underlying REST API would cascade; the MCP layer guards against silent loss.) EXCEPTION — while the ground is transplanting (project.transplanting=true), the active-descendant guard is lifted (subtree cascade allowed) and you may pass hard=true to permanently remove import mistakes, including grown (past-season) nodes. Once the human roots the ground, normal guards return.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Node id. | |
| hard | No | Permanently delete (incl. descendants via FK cascade) instead of soft-delete. Only honored while the ground is transplanting; irreversible — use for import cleanup. | |
| slug | Yes | Ground slug. |