write_file
Writes content to a file and creates missing parent directories, with an option to overwrite existing files or skip directory creation.
Instructions
Write content to a file with automatic directory creation
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": {
"file_path": "<file_path>",
"content": "<content>"
},
"name": "write_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| content | Yes | Content to write | |
| file_path | Yes | Target file path | |
| overwrite | No | Allow overwriting existing files | |
| create_dirs | No | Auto-create parent directories |