Read a page
get_pageRead what is on the site's DRAFT. view 'content' (default) lists every editable node id with its text, plus form fields, FAQ items, image nodes and collection items — call it when you come back to a site and before patch_nodes. view 'structure' gives the container nesting with ids (for moving, inserting or removing containers, and the only way to see how header/footer nodes nest). view 'copy' lists all rewriteable copy on the whole site for a full rewrite. To check what visitors see, use read_rendered_page; for pages, theme and publish state, get_site. Read-only.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| view | No | 'content' (default): every patchable node id with its current text, each form's full field list, copy kept in node data (FAQ items, banner links, form messages), image nodes, slots, and each collection's items read live — the view to build a patch_nodes call from. 'structure': the container nesting with ids, types and short labels and no props — for moving, inserting into or removing a container; pass page_slug 'header' / 'footer' / 'pageLayout' / 'shell' for the shared chrome, or 'collection:<contentType>' for a collection's detail template. 'copy': every rewriteable text field on the WHOLE site, chrome and collection items included, for a full copy pass. | |
| site_id | Yes | ||
| max_items | No | With view 'copy': cap on returned items (default 200). When `truncated` is true, or content_items_returned is below content_items_total, call again with a higher cap before reporting the pass done. | |
| page_slug | No | Which page, e.g. '/', '/about'. 'content': omit for the whole site (large — scope it when editing one page; the header, footer and collections are always included, in site_elements, so 'header' or 'footer' returns the home page with them). 'structure': defaults to the home page. Ignored by 'copy'. | |
| instructions | No | With view 'copy': the rewrite intent ('more formal', 'shorter'), echoed back. Nothing is rewritten for you — compose the new copy and apply it with patch_nodes / edit_content_item. |