Delete a strategy file
delete_fileDeletes a file in a new immutable revision for any strategy owned by the authenticated user. Requires editHandle from get_file/list_files to prevent stale edits. main.py cannot be deleted. For the current attached/open strategy, omit strategyId and revisionId; pass explicit ids only for another owned strategy.
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>",
"editHandle": "<editHandle>"
},
"name": "delete_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | ||
| editHandle | Yes | Opaque edit handle returned by list_files or get_file. It replaces raw hash copying while preserving stale-write protection. | |
| revisionId | No | Base revision ID to snapshot from. Omit with strategyId for the current attached/open strategy. | |
| strategyId | No | Base strategy id. Omit with revisionId for the current attached/open strategy. | |
| description | No | Shown to the customer as "How your strategy works". One or two plain sentences on what the strategy now does, e.g. "Buys Apple after a 5% drop in a day and sells at a 10% gain." Write for the customer, not an internal change note. |