vault_write
Create or replace UTF-8 text files in an Obsidian vault, with guarded version checks for existing notes and automatic parent creation.
Instructions
Create or replace UTF-8 text. Existing files require ifMatch or ifMatchGuard (copy versionGuard). Creates parents. Binary/NUL refused; no automatic retry.
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>",
"content": "<content>"
},
"name": "vault_write"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | ||
| content | Yes | ||
| ifMatch | No | ||
| ifMatchGuard | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | ||
| created | Yes | ||
| message | Yes | ||
| version | Yes | ||
| warnings | No | ||
| sizeBytes | Yes | ||
| versionGuard | Yes | ||
| beforeSizeBytes | Yes |