edit_note_section_tool
Edit specific sections in Obsidian notes by markdown heading to add, update, or replace content without rewriting entire files.
Instructions
Edit a specific section of a note identified by a markdown heading.
When to use:
Adding content to a specific section without rewriting the whole note
Updating a particular section (like status updates, task lists)
Inserting content at precise locations in structured notes
Building up notes incrementally by section
When NOT to use:
Simple append to end of note (use update_note with merge_strategy='append')
Replacing entire note content (use update_note)
Creating a new note (use create_note)
Section identification:
Sections are identified by markdown headings (# ## ### etc.)
Match is case-insensitive
First matching heading is used if duplicates exist
Section includes content until next heading of same/higher level
Operations:
insert_after: Add content immediately after the section heading
insert_before: Add content immediately before the section heading
replace: Replace entire section including the heading
append_to_section: Add content at the end of the section
Returns: Edit status including whether section was found or created
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | Path to the note to edit | |
| section_identifier | Yes | Markdown heading that identifies the section (e.g., '## Tasks', '### Status') | |
| content | Yes | Content to insert, replace, or append to the section | |
| operation | No | How to edit the section. 'insert_after' = add content after heading, 'insert_before' = add before heading, 'replace' = replace entire section, 'append_to_section' = add to end of section | insert_after |
| create_if_missing | No | Create the section at the end of the note if it doesn't exist | |
| ctx | No |