Edit
editPerform targeted edits on markdown notes using AST operations (append/prepend/replace) or freeform text replacements. Supports batch mode and dry run preview.
Instructions
Edit notes. Single mode: provide path, operation, content. Batch mode: provide operations array (max 50, sequential, stops on first error). AST ops (append/prepend/replace) target headings or block IDs with fuzzy matching. Freeform ops (line_replace/string_replace) for line range or literal string. frontmatter_set merges YAML. dryRun=true previews as unified diff without writing.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | Note path (required for single edit). | |
| operation | No | Edit operation (required for single edit). | |
| content | No | Content to apply (required for single edit). | |
| heading | No | ||
| headingDepth | No | ||
| blockId | No | ||
| startLine | No | ||
| endLine | No | ||
| searchText | No | ||
| replaceAll | No | ||
| dryRun | No | If true, returns a preview of changes as a unified diff without saving to disk. | |
| operations | No | For batch mode: array of edit operations (max 50). Executed sequentially, stops on first error. |