md-log-mcp
v1.3.1md-log MCP: save/update/fetch markdown by path (stdio + remote HTTP, PAT auth).
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
save_markdown Save Markdown
Save (create or overwrite) a .md file in md-log by path; missing folders are auto-created. Optionally upload embedded images as assets first and rewrite their refs to asset:// links. This is a force-write (last-writer-wins) — the headline agent tool. Before choosing a path, PREFER an existing folder that already holds related documents and reuse its exact spelling — do not invent a new casing or separator (e.g. don't save to 'MdLog/…' when 'md-log/…' already exists). Call list_folders / list_files first if unsure. (The server also auto-reuses a unique near-duplicate folder, but consist…
| Parameter | Type | Description |
|---|---|---|
content * | string | Full markdown content of the file. |
path * | string | POSIX path to the .md file, e.g. 'reports/2026/error-report.md'. Folders auto-created. |
assets | array | Embedded images to upload before saving. Each is uploaded, then its `placeholder` in `content` is replaced with the resulting asset:// reference. |
commit_message | string | A concise 1-2 line summary of WHAT changed in this version and WHY, written for a human reviewer scanning the version history (it is stored on the version and shown next to it on web & mobile). ALWAYS… |
upload_asset Upload Asset
Upload a single image as an asset (reserve -> presigned PUT -> complete) and return an 'asset://<key>' reference you can embed in markdown image syntax: . Provide the image as EITHER `data_base64` (inline base64) OR `file_path` (a local file to read) — exactly one.
| Parameter | Type | Description |
|---|---|---|
path * | string | The .md document path this asset is associated with (used for quota/scoping). |
content_type | string | MIME type, e.g. 'image/png'. Optional with `file_path` when the extension is recognized (png/jpg/jpeg/gif/webp/avif). |
data_base64 | string | Base64-encoded raw image bytes. Provide EITHER this OR `file_path`, not both. |
file_path | string | Absolute or relative local filesystem path to the image file to read and upload. Provide EITHER this OR `data_base64`, not both. |
filename | string | Original file name. Optional with `file_path` (defaults to its basename). |
append_to_markdown Append to Markdown
Append content to the end of an existing .md file using optimistic concurrency (GET current -> concat -> PUT with base_version_no). Auto-retries once on conflict, then surfaces CONFLICT.
| Parameter | Type | Description |
|---|---|---|
content * | string | Markdown to append. A newline separator is inserted if needed. |
path * | string | POSIX path to the .md file, e.g. 'reports/2026/error-report.md'. Folders auto-created. |
commit_message | string | A concise 1-2 line summary of WHAT you appended and WHY, written for a human reviewer scanning the version history (stored on the new version, shown next to it on web & mobile). ALWAYS provide this   |
edit_markdown Edit Markdown
Change PART of an existing .md file by replacing exact literal strings. USE THIS, NOT update_markdown, for any partial change — a fixed line, a corrected table row, a reworded paragraph, an added section under a heading. update_markdown requires the ENTIRE new document, so using it for a small change means regenerating text you never meant to touch and risks silently rewriting the rest of the report. Read the file with get_markdown first and copy each `old_string` VERBATIM out of it, including indentation, punctuation and any blank lines. SEVERAL CHANGES TO ONE FILE? Send them together in ON…
| Parameter | Type | Description |
|---|---|---|
path * | string | POSIX path to the .md file, e.g. 'reports/2026/error-report.md'. Folders auto-created. |
commit_message | string | A concise 1-2 line summary of WHAT you changed and WHY, written for a human reviewer scanning the version history (stored on the new version, shown next to it on web & mobile). ALWAYS provide this —… |
edits | array | Ordered list of literal edits applied in ONE write (one version, one notification), all-or-nothing. Prefer this whenever you change a file in more than one place. At most 50 edits. Do not combine with… |
new_string | string | Single-edit shorthand. The literal text to put in its place, inserted as-is (no escaping, no '$' substitution). Pass an empty string to DELETE the matched text. Omit when using `edits`. |
old_string | string | Single-edit shorthand. The EXACT, non-empty literal text to find in the current document — not a regex, not a pattern, no wildcards. Copy it verbatim from get_markdown output; whitespace and line br… |
replace_all | boolean | Single-edit shorthand. Opt in to replacing EVERY occurrence of `old_string` (e.g. renaming a term throughout the document). Default false = exactly one occurrence is required, otherwise the edit is re… |
update_markdown Update Markdown
Replace the ENTIRE content of an existing .md file. For a PARTIAL change — a line, a row, a paragraph — use edit_markdown instead: it replaces one exact string in place, so you never regenerate (and never accidentally rewrite) the rest of the document. Reach for this tool only when you are genuinely rewriting the whole file. Pass expected_version for optimistic concurrency (mismatch -> CONFLICT); omit it to force last-writer-wins. If you pass expected_version for a path that does not exist you get CONFLICT (detail.server_version_no is 0), not a new file — use save_markdown to create.
| Parameter | Type | Description |
|---|---|---|
content * | string | New full markdown content. |
path * | string | POSIX path to the .md file, e.g. 'reports/2026/error-report.md'. Folders auto-created. |
commit_message | string | A concise 1-2 line summary of WHAT changed in this version and WHY, written for a human reviewer scanning the version history (stored on the version, shown next to it on web & mobile). ALWAYS provide… |
expected_version | integer | Version you based your edit on. Omit to force-overwrite (LWW). |
get_markdown Get Markdown
Read a .md file's content by path. Pass `version` (a version_no from list_versions) to read an OLD immutable version instead of the current one.
| Parameter | Type | Description |
|---|---|---|
path * | string | POSIX path to the .md file, e.g. 'reports/2026/error-report.md'. Folders auto-created. |
version | integer | Version number to read (see list_versions). Omit for the current version. |
list_versions List Versions
List a .md file's immutable version history, newest first (version_no, commit_message, author, registered_at, size). Read an old version's content with get_markdown + `version`.
| Parameter | Type | Description |
|---|---|---|
path * | string | POSIX path to the .md file, e.g. 'reports/2026/error-report.md'. Folders auto-created. |
restore_version Restore Version
Roll a .md file back to an earlier version: version N's exact stored content becomes a NEW current version. History is immutable — nothing is deleted or rewound, the rollback is just another version on top, so it is itself undoable by restoring again. Use this after a bad write instead of retyping the old text through save_markdown, which would guess at the content and lose fidelity. Get version numbers from list_versions (and read one first with get_markdown + `version` if you want to check before rolling back). Restoring the version the file is already on is accepted and does nothing.
| Parameter | Type | Description |
|---|---|---|
path * | string | POSIX path to the .md file, e.g. 'reports/2026/error-report.md'. Folders auto-created. |
version * | integer | The version_no to restore, from list_versions. Its content becomes the new current version. |
commit_message | string | A concise 1-2 line summary of WHY you are rolling back, written for a human reviewer scanning the version history (stored on the new version, shown next to it on web & mobile). ALWAYS provide this (e.… |
delete_markdown Delete Markdown
Soft-delete a .md file. Requires confirm:true (otherwise VALIDATION). Resolves the path to a document key, then DELETE /documents/{key}.
| Parameter | Type | Description |
|---|---|---|
confirm * | boolean | Must be true to actually delete. A safety guard against accidental deletes. |
path * | string | POSIX path to the .md file, e.g. 'reports/2026/error-report.md'. Folders auto-created. |
create_folder Create Folder
Create a folder path, creating every missing parent segment (mkdir -p). Already-existing folders are treated as success.
| Parameter | Type | Description |
|---|---|---|
path * | string | POSIX folder path, e.g. 'reports/2026'. No '.md' suffix. |
move_markdown Move Markdown
Move and/or rename a .md file: from_path -> to_path. Destination folders are auto-created (mkdir -p). The document KEEPS its identity (same document key), so its whole version history and reviewers' annotations survive the move — never re-save + delete to relocate a file. Fails if a different file already occupies to_path.
| Parameter | Type | Description |
|---|---|---|
from_path * | string | Current POSIX path of the .md file. |
to_path * | string | Target POSIX path (must end in .md). Same folder + new name = rename; new folder + same name = move; both may change at once. |
move_folder Move Folder
Move a folder (with its whole subtree: documents, versions, annotations) under a new parent. new_parent_path '' or omitted = move to the root. Parent folders are auto-created. Moving a folder into its own subtree is rejected by the server.
| Parameter | Type | Description |
|---|---|---|
path * | string | Current POSIX path of the folder to move. |
new_parent_path | string | POSIX path of the destination PARENT folder. Empty/omitted = root. |
rename_folder Rename Folder
Rename a folder in place (descendant paths are rewritten automatically; documents, versions and annotations are untouched).
| Parameter | Type | Description |
|---|---|---|
new_name * | string | New folder NAME (a single path segment, not a path). |
path * | string | Current POSIX path of the folder. |
delete_folder Delete Folder
Delete a folder. Requires confirm:true (otherwise VALIDATION). By default only an EMPTY folder is deleted (a non-empty one is refused); pass cascade:true to soft-delete the whole subtree — every subfolder and document under it (like `rm -r`). Documents are soft-deleted (recoverable), but prefer move_folder/move_markdown when reorganizing.
| Parameter | Type | Description |
|---|---|---|
confirm * | boolean | Must be true to actually delete. A safety guard against accidental deletes. |
path * | string | POSIX path of the folder to delete. |
cascade | boolean | true = delete the folder AND everything under it. Default false = refuse unless empty. |
list_folders List Folders
Return the full folder tree.
list_files List Files
List the documents (and immediate subfolders) inside a folder path. Omit path (or pass '' / '/') to list the ROOT folder.
| Parameter | Type | Description |
|---|---|---|
path | string | POSIX folder path, e.g. 'reports/2026'. Omit or pass '' / '/' to list the ROOT folder. |
search_markdown Search Markdown
Search documents by TITLE (substring) and BODY (full-text over current versions; whole-word match, ranked, body hits carry a **bolded** snippet). Use it to find a prior report by its content or name.
| Parameter | Type | Description |
|---|---|---|
query * | string | Search query; matched against document titles (substring) and body text (words). |