Something Else

cms-edit · HopSkipDrive

← All playbooks · Raw API

task-create-page

# Capability: Create a page

## Intent phrases

- create a new page
- add a landing page
- new marketing page

## Requires capabilities

`pages`

## Prerequisites

- Read `cms-edit://customer/components-index` and `cms-edit://customer/routing`
- `cms_edit ["index", "sync"]` for template lookup

## Steps

1. `cms_edit ["schema", "component"]` and `cms_edit ["schema", "types", "component"]` — this space’s fields/enums
2. `cms_edit_help` topic `create-from-json` (or `cms_edit ["help", "create-from-json"]`)
3. Draft JSON with `"components"` and nested `"type"`. Filesystem: `--json-base64`. Desktop: `--json`.
4. `cms_edit ["create", "from-json", "--json", "{…}", "--dry-run", "--strict"]` then without `--dry-run`
5. To edit later: `open` → `export from-json` → `apply from-json`

`add` / `set` / `rtf` only for tiny patches after the tree exists.

After each `add`, set `heading` then `cmsLabel` (not left as `New Generic`).

Test/agent pages: `indexed: false`, omit `hidden` (visible on production when published).

## Confirmation gates

1. Confirm slug, title, and template with user
2. `create from-json --dry-run --strict` before create when using JSON
3. `diff` before `save`

## Out of scope

- Publish

## Related resources

- `cms-edit://customer/components-index`
- `task-create-from-document` for doc-driven pages