Delete a doc, file or folder
delete_entityDelete a file or folder, including all folder contents, from an Overleaf project by project-relative path; recover deleted items later from project history in the web editor.
Instructions
Deletes the entity at path (a folder with all its contents). Overleaf keeps deleted files in the project history, from where they can be restored in the web editor.
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": {
"path": "<path>"
},
"name": "delete_entity"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | Project-relative path of the doc, file or folder to delete. Folders are deleted with their contents. | |
| project_id | No | Overleaf project id from list_projects or open_project. Opens the project if it is not already active. Pass it on every call when MCP sessions may change between calls. Writes without it only go to the project last confirmed by open_project or by a write naming it. |