Skip to content

lb_delete_node

Permanently removes a node from your knowledge graph. Deletion cascades to link rows (both outgoing and incoming) and PARA tag junctions in a single D1 batch, and issues a best-effort cleanup against Vectorize.

This action cannot be undone. The HTTP DELETE /nodes/:id route wraps the same service method.

ParameterTypeRequiredDescription
idstringYesThe ID of the node to delete
{ "deleted": true, "id": "..." }
CodeWhen
NOT_FOUNDThe node does not exist in the current tenant (or never did)
  • Deletion is atomic at the D1 layer: node row, node_para_tags junctions, and links rows are deleted in one transaction. Vectorize cleanup runs outside the transaction and is best-effort — a transient Vectorize failure will not roll back the D1 delete.
  • Prefer archiving via PARA item workflows when the user might want to restore context later. There is no restore path for deleted nodes today.
  • Idempotency: calling this tool twice for the same ID returns NOT_FOUND on the second call.