Skip to main content
Start with installation, authentication, and a verified project context. Replace PAGE_ID below with an ID returned by your project.

Find and read a page

Replace PAGE_ID with an ID from the list. These commands use your active profile and saved project context. Search examines titles and blocks. Full get returns a page object whose content is in top-level blocks, with metadata such as id, title, and updatedAt. For a large inventory, add --limit and --offset to pages list; those options slice the fetched list locally. Continue offsets until a slice is empty, and account for concurrent changes when collecting a full inventory. Use --fields id,title,parentPageId,updatedAt to select a compact view, or --summary with pages get for a compact page summary.
--fields selects a compact view; --limit and --offset slice the fetched list locally.
Export the project pages before editing:
Exports fetch page documents. JSONL is one JSON record per line; Markdown is text. Treat an interrupted export as incomplete and check the exit status before using the file as a backup.

Create a small document

The Home commands provide convenient text authoring for the same Canvas pages. Preview the request, then run the same create command without --dry-run when the destination and content are correct:
A preview returns ok, dry_run, method, path, params, and body; it does not create a page. The actual create returns the backend page result. Copy its page ID, then verify the stored document:

Append and verify

--append-content preserves existing blocks and adds a text block. --content and --blocks replace the page blocks; choose them only when you intend replacement. The Home update command reads the current page and sends its updatedAt as expectedUpdatedAt. An update preview can therefore perform a read even though it does not write. On a conflict, fetch the page again, reconcile your change, and preview again. Do not bypass conflict protection with --force or blindly repeat an append: a timeout may occur after the server accepted it. Read the page first to see whether your text is already present. Compare the final blocks and title with your intended result. See the command reference for structured Canvas editing.