docs_delete
Soft-delete a document. The row is marked deleted (deleted_at set) and removed from listings/search/embeddings, but stays in the database and can be restored by an admin via the workspace UI. The WHOLE SUBTREE goes with it — children (and their children) are soft-deleted as a unit. Works on UI folders too: pass the folder's UUID from docs_tree as docId (folders have no alias); deleting a folder soft-deletes everything inside it — to keep the children, first move them out via docs_update parentId/parentAlias. This is NOT a hard delete — for permanent removal, use the workspace admin tools. Requires delete permission (internal tokens only).
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": {
"docId": "<docId>"
},
"name": "docs_delete"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| docId | Yes | Document UUID, short_id, or alias (folders: UUID only — they have no alias) | |
| workspaceId | No | Workspace UUID (optional, auto-selected if user has only one workspace) | |
| workspaceAlias | No | Workspace alias (optional, auto-selected if user has only one workspace) |