page_upsert
Create or update a journal page in Foundry VTT with HTML content, category, indentation level, and public visibility settings. Supports reordering pages by specifying a 0-based index within the category.
Instructions
Create or update a journal page. Idempotent.
content is HTML. level controls sidebar indentation (1=top, 2=indented under the preceding level-1 page). category must already exist — call category_upsert first. public=True sets OBSERVER ownership so players can see this page.
index: 0-based position within the category. When set, all pages in the category are reindexed with clean sort values so the page lands at that position. Omit to leave sort order unchanged.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| index | No | ||
| level | No | ||
| title | Yes | ||
| public | No | ||
| content | Yes | ||
| journal | Yes | ||
| category | No |