# ChapterPage

One page in a chapter stack, up to 40 pages and 150000 JSON characters after normalisation. Every field except id and type is optional; empty pages are valid and skipped for buyers. Strings are trimmed; empty strings and arrays disappear. Unused fields are dropped on save. Missing and changed-kind refs, self Contents refs and removed photos are dropped silently; ids belonging to another guide are refused.

Group: Chapters.

## Fields

- `id` (string, required): Stable client-made identity: 8 to 16 letters, digits, underscores or hyphens, unique within the stack. Trimmed on save. Keep ids when editing or reordering; make a new id when duplicating.
- `type` (string, required): cover: opening with title, photo and optional byline (kicker/title/lead/byline/author/authorMediaId/photos). text: paragraphs (kicker/title/lead/body). photoText: a photo beside paragraphs (kicker/title/lead/body/photos). photo: a big image (title/lead/photos). gallery: image grid (kicker/title/lead/photos with captions). quote: quotation (body/author/authorMediaId/photos). tips: numbered cards (kicker/title/lead/items title and text). checklist: lines (kicker/title/lead/items title only). facts: label/value table (kicker/title/lead/items title and text). chapters: Contents rows (kicker/title/lead/refs collectionId/title/line/color/hidden). collections: collection cards (kicker/title/lead/refs collectionId/title/mediaId/hidden). itineraries: trip tiles (kicker/title/lead/refs itineraryId/hidden). spots: chosen spot cards (kicker/title/lead/refs spotKey). creator: About me (kicker/title/body/photos), with socials from the creator profile. Other fields are dropped. One of `cover`, `text`, `photoText`, `photo`, `gallery`, `quote`, `tips`, `checklist`, `facts`, `chapters`, `collections`, `itineraries`, `spots`, `creator`.
- `variant` (string, optional): cover: split (default), full, simple; photoText: left (default), right; photo: overlay (default), below; quote: plain (default), photo; spots: reader (default), grid; creator: profile (default), portrait. An invalid variant for these types is refused. Other types have no variants and drop this field.
- `kicker` (string, optional): Small heading line, at most 120 characters. Used by cover, text, photoText, gallery, tips, checklist, facts, chapters, collections, itineraries, spots and creator.
- `title` (string, optional): Heading, at most 160 characters. Used by every type except quote. Empty cover title uses the chapter name; creator title overrides the profile name.
- `lead` (string, optional): Short introduction, at most 500 characters. Used by every type except quote and creator. Spots shows a heading only when kicker, title or lead has text.
- `body` (array of strings, optional): text/photoText paragraphs, quote text or creator bio override: up to 30 strings of 10000 characters. Lines beginning with "- " render as dotted lists. Other types drop body.
- `byline` (boolean, optional): Cover only: true shows the author and round photo. false is dropped. Empty author and authorMediaId use the current creator name and avatar.
- `author` (string, optional): Cover byline or quote attribution, at most 120 characters. Other types drop it.
- `authorMediaId` (string, optional): Cover or quote author photo: a media row id owned by this chapter or a spot/collection of this guide. Removed photos are dropped; other-guide ids are refused. Other page types drop it.
- `photos` (array of ChapterPagePhoto, optional): cover/photoText/photo/quote/creator accept at most one photo; gallery accepts up to 6. Other types drop photos. Only gallery keeps captions. Upload with ownerType collection and ownerId collectionId, or reuse a spot photo mediaId from list_media. Photos retain the media row's credit; its display follows guide settings and licence requirements.
  Fields of ChapterPagePhoto: https://developers.sceniq.earth/fields/chapter-page-photo.md
- `items` (array of ChapterPageItem, optional): tips: up to 8 title/text cards; checklist: up to 20 title-only lines; facts: up to 12 title (label)/text (value) rows. Empty items are dropped; other types drop items.
  Fields of ChapterPageItem: https://developers.sceniq.earth/fields/chapter-page-item.md
- `refs` (array of ChapterPageRef, optional): chapters/collections/itineraries accept up to 60/60/60 per-item overrides. They list the guide's eligible rows by themselves, not just refs. spots accepts zero to 12 spotKeys in display order. Each ref must carry exactly the target its type accepts; unsupported dressing is refused. Duplicate targets keep the first. Missing targets are dropped; archived spots stay stored and buyers hide them. Other types drop refs.
  Fields of ChapterPageRef: https://developers.sceniq.earth/fields/chapter-page-ref.md

## Used by

- [set_chapter_pages](https://developers.sceniq.earth/reference/set_chapter_pages.md)
