postmd_update_document
Update a document. Password-protected documents require the password or the owner's API key; documents without a password can be updated by anyone. Include markdown to replace the stored content; any metadata field replaces that field. clearPassword removes the password. Replacing the content requires notesOnReplace.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| title | No | ||
| docCode | Yes | ||
| fileName | No | Upload filename when replacing content. Default document.md. | |
| markdown | No | Full new Markdown body as one UTF-8 string. Omit if only metadata changes. Adding or revising a graph means sending the whole body with the graph comment in it; the format is at /docs/graph. | |
| password | No | Readers must supply this password to see the content. | |
| viewerStyle | No | Viewer theme: readable (default), github, minimal, report, pamphlet or dark. Unknown values fall back to readable. | |
| clearPassword | No | true removes the password. | |
| notesOnReplace | No | Required when replacing the content. Notes are located by the text they quote, so replacing the body moves or loses where they point: a note whose quote is gone loses its place in the body, and one whose quote now appears elsewhere points there. keep replaces anyway and leaves the notes. abort refuses when the document has notes anchored to its text, and the answer says how many. | |
| currentPassword | No | Current password to authenticate if the document is password-protected. |