Replace the content of a page
replace-journal-pageReplace a journal page's entire content in one write, optionally renaming it. Handles HTML or plain text, rejects empty content, and verifies the change.
Instructions
Replace the whole content of one text page, and optionally rename it, in one write. Content with HTML tags is stored exactly as sent. Plain text becomes paragraphs: a blank line starts a new paragraph, a single line break stays a break, and nothing is removed; Markdown is not converted, and the result says when the text looks like Markdown. Empty content is refused. The page is read back and compared; the result carries its length, not the content. To append instead, use journal-append-page. Needs the journal permission "create and change".
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| pageId | Yes | Id of the text page, from list-journals. | |
| journalId | Yes | Id of the journal, from list-journals. | |
| newContent | Yes | The new content: HTML, or plain text that becomes paragraphs. | |
| newPageName | No | New name of the page. Leave out to keep the name. |