Документация пока доступна только на английском языке. Остальная часть сайта соответствует вашему языку.
Content
Posts, pages, and custom types: create, edit, publish, translate, keep working revisions, and recover from the trash.
8 минута чтения
Admin → Content lists entries by type. Create from New, edit metadata on /admin/content/:id, and open the visual builder at /admin/content/:id/builder. Dashboard tiles also jump to a new post or page.
Types
`post` and `page` ship as built-in types and cannot be deleted. Admin → Content types (/api/content-types) persists additional slugs and field definitions per site. Field kinds: text, textarea, richtext, number, boolean, media, date, select. Reserved keys seoTitle, seoDescription, seoCanonical, and seoImage belong to built-in SEO — do not reuse them on a custom type.
POST /api/content accepts any registered type slug. Custom fields are stored on the row as JSON and shown in the editor. You cannot delete a built-in type, or a custom type that still has entries.
Each content type has a Cache-Control setting in Admin → Content Types: inherit the site default, never cache, or a validated custom header. A single post or page can override it under Advanced. See Caching.
Content type settings
Content → Content Types lists every type in a table. Opening one shows a two-column editor for its labels, description, cache policy, system fields, and custom fields. Field settings expand in place, fields can be reordered, and you are warned before leaving with unsaved changes. Existing types keep their previous behaviour until you save an override.
| Setting | What it does |
|---|---|
| Label / plural label | The plural label names the type in the overview. |
| Content editor | Automatic (the type or plugin default), the block builder, or custom fields. Existing blocks and fields are kept. Plugins can still choose through content.editor. |
| Dashboard shortcut | Adds a New shortcut to the dashboard. On for posts and pages; other types opt in. |
| Revision history | Captures new restore points. Turning it off keeps old history, working drafts, autosave, version checks, and scheduling. |
| Draft previews | Allows staff previews and shareable preview links, including links already sent. |
| Public search | Inherit the site setting, or always include or exclude the type from site search. Admin search always includes it. |
| SEO metadata and sitemap | Shows the SEO panel, renders its tags, and lists published entries in the sitemap. Turning it off is not noindex and does not restrict access. |
| Comments | Inherit the site default, on by default, or off for the whole type. Off wins over an entry's own setting. |
| Cache-Control | Inherit the site policy or set one for the type. Account and sign-in types never cache. |
Account and sign-in types cannot turn on public search, SEO, or comments. The content-type endpoints accept and return a settings object, stored per site by migration 0050_content_type_settings.
Statuses
The admin API accepts draft, published, archived, and scheduled. Publishing is available to administrators, editors, and authors. Authors can edit their own items; administrators and editors can delete any.
Scheduled publish
scheduled is accepted on PATCH. A job name content.publish-scheduled exists on the jobs package; the CE server does not yet register a cron publisher. Treat scheduled as a status you set, not an automatic go-live clock.
Translations
POST /api/content/:id/translate with { locale } clones the item into a translation group (translation_group_id, per-row locale from migration 0002). List filters: type, status, slug, locale, translationGroupId, limit, cursor.
Admin API
| Method | Path | Purpose |
|---|---|---|
GET | /api/content | List (session, content roles). |
POST | /api/content | Create (type must be a registered slug). |
GET | /api/content/:id | One item. |
PATCH | /api/content/:id | Update metadata, status, blocks, fields. |
DELETE | /api/content/:id | Delete. |
POST | /api/content/:id/translate | Clone into another locale. |
GET / POST / PATCH / DELETE | /api/content-types | List and manage type definitions (write: administrator). |
Saves invalidate the content: cache prefix. Hooks: content.beforeCreate / beforeUpdate / beforeDelete / beforePublish (gates), then content.created / updated / deleted / published / unpublished (actions). Filters content.input, content.output, and content.render sit on the way in, out, and onto the public HTML.
Revisions and taxonomies
Every content type keeps working revisions. Saving a published item writes a draft without touching the live version — visitors keep seeing what is published until you explicitly publish, which copies the working revision across atomically. The Revisions panel lists the last five published versions and can restore one as a draft; you can preview, compare, and discard drafts. The content list shows “Published — draft changes” while a draft is waiting. Categories, tags, and custom taxonomies are managed under Content → Categories & Tags and assigned in the editor sidebar; see Categories, tags, and taxonomies.
Note
Deleting content moves it to the Trash, where it can be restored with its revisions intact until the retention job purges it.