Delete a file or folder
delete_fileDeletes a file or folder and its contents from an Overleaf project for every collaborator; use it to remove unwanted project items, knowing Overleaf keeps deleted content in project history.
Instructions
Deletes a file or folder (with its contents) from a project, for every collaborator. These tools cannot undo it, but Overleaf keeps the deleted content in the project history. To rename or reorganise, use move_file instead.
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_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | Path of the file or folder to delete, e.g. "figures/old-plot.png" | |
| project | No | Project name, id or Overleaf URL. May be omitted when exactly one project is pinned. |