write_file
Write content to any file, automatically escalating to sudo for protected paths to avoid permission errors.
Instructions
Write content to a file, escalating to sudo if the path is protected.
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": {
"filename": "<filename>"
},
"name": "write_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| content | No | File content. | |
| filename | Yes | Destination path. |