Skip to content

CMS Page — Create

Creates a new CMS page.

Top-level fields vs. update locale-nested

Create takes the translated fields (page_title, html_content, meta_*, url_key) at the top level — they are broadcast to every locale by the core PageRepository. The Update endpoint, in contrast, requires a locale-nested payload ({ "en": { "page_title": "...", ... } }).

Endpoint

EndpointMethod
/api/admin/cms/pagesPOST

Request body

FieldTypeRequiredNotes
url_keystringyesMust be unique on cms_page_translations and pass slug regex.
page_titlestringyes
html_contentstringyes
channelsint[]yesNon-empty array of existing channel IDs.
meta_titlestringno
meta_keywordsstringno
meta_descriptionstringno

Response

201 Created returning the same shape as GET /api/admin/cms/pages/{id}.

Errors

HTTPCause
422 Unprocessable EntityValidation failure (missing required field, duplicate url_key, empty channels).

Released under the MIT License.