Edit note
bm_editEdit existing Basic Memory notes by appending, prepending, replacing text or sections, and merging frontmatter metadata; use checksums to avoid overwriting a newer revision.
Instructions
Change part of an existing Basic Memory note. command: append or prepend content; find_replace find_text with content (exact text, which must occur expected_replacements times, default 1); replace_section, insert_before_section or insert_after_section for a section heading ('Decisions', 'Auth/Decisions', 'Decisions[1]', as bm_read takes it); set_metadata to merge metadata into the frontmatter without touching the body. metadata also merges with any other command. Pass expected_checksum (from bm_read) to edit only the revision you read. A missing note is an error; create notes with bm_write.
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": {
"identifier": "<identifier>",
"command": "<command>",
"project": "<project>"
},
"name": "bm_edit"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| command | Yes | The edit. | |
| content | No | The text to add or the replacement. Not used by set_metadata. | |
| project | Yes | Required project name, 'workspace/project', or project external id. Discover projects with bm_project(command='list'). Paths are relative to this project; a qualified path must agree with it. | |
| section | No | The heading for section commands: "Decisions", "Auth/Decisions" for one under "Auth", or "Decisions[1]" for the second of two. | |
| metadata | No | Frontmatter fields to set; other fields are kept. | |
| find_text | No | For find_replace: the exact, case-sensitive text to replace. | |
| identifier | Yes | The note or file: a file path ('notes/plan.md'), permalink, memory:// URL, exact title, external id, or '<project>/path'. | |
| output_format | No | text | |
| expected_checksum | No | Edit only while the note is still this revision (from bm_read). | |
| replace_subsections | No | For replace_section: true replaces the section's subsections too; false stops at the first subsection heading. | |
| expected_replacements | No | For find_replace: how many times find_text must occur. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |