Search documentation

Search documentation

Content

Content Entries

Create, review, version, localize, and publish content entries.

Create the records that a type describes#

A content entry is one website- and language-specific record made from a content type. If article is the model, “Hello, Contoprix” is one Article entry.

Entries are where editors write copy, select media, choose related records, review work, and publish it.

What an entry belongs to#

Every entry has:

PropertyMeaning
Content typeThe schema that validates its fields
WebsiteWhere it is managed and delivered
LanguageThe website language for this record
Current versionThe latest saved content snapshot
Published versionThe snapshot available to normal delivery, when published
StatusDraft, published, archived, scheduled, or a workflow state

For a Single content type, Contoprix allows one entry for each website and language. A Collection can have many.

Create an Article entry#

For an article type with title, slug, summary, and body, create this first record:

Example entry
Website: Marketing site
Language: English (en)
Title: Five ways to improve a content workflow
Slug: improve-content-workflow
Summary: A practical checklist for editorial teams.
Body: The full article copy goes here.

Choose media through the Media picker and relations through the Relation picker. Do not paste an image URL into an Image field or type a related entry's ID manually; the CMS stores the IDs that its validation and delivery layers expect.

Save, review, then publish#

Use this simple editorial loop:

  1. Create the entry in the correct website and language.
  2. Fill all required fields and select the correct media and relations.
  3. Save the draft.
  4. Open a protected preview if the entry appears on a page.
  5. Submit for review if a workflow is enabled.
  6. Publish after approval.
  7. Check the public route or SDK response.

Normal delivery requests return entries only when their status is Published and they have a published version. A draft is not public data.

Warning

In the current CMS workflow, saving a new draft changes the entry status to Draft. Normal delivery filters for Published status, so do not assume an older published version will continue to be delivered while a newer draft is being edited. Use preview to review edits and publish the new version promptly when the entry must remain public.

Understand the publishing guardrails#

Before publishing, Contoprix validates the current version against the current schema. It checks required values and structural rules, then verifies that referenced entries have a publishable version.

For example, publish an Author before publishing an Article that requires that Author relation. If a relation target later becomes unavailable, delivery handles it gracefully as an empty/null relation, so the frontend must still handle the missing state.

If approval workflows are configured, a user without workflow-bypass permission must publish an approved version. The approval becomes stale when an editor saves a different version, which prevents an old review from approving new content accidentally.

Versions: a safety net, not an automatic rollback#

Contoprix creates a content version when an entry is created and each time it is saved. Use version history to inspect previous work.

To restore a version:

  1. Open the entry's version history.
  2. Choose the version to restore.
  3. Treat the restored result as a new draft.
  4. Review it against the current model and preview it.
  5. Publish it deliberately.

The CMS revalidates restored data. A very old version can fail validation if a required field, relation target, or model rule has changed since it was first saved.

Unpublish, archive, and schedule#

ActionWhat it meansPublic delivery result
UnpublishRemove the published version and return to DraftNo longer returned
ArchivePreserve the record but remove it from active useNot returned; cannot publish while archived
Schedule publishRequest a future publication timeNot returned until the scheduled publish completes

Scheduling requires publish authority and a future time. It should be used only after the content is complete; it is not a replacement for editorial review.

Read the entry in the frontend#

The SDK returns entry metadata plus data. Put your model-specific cast and fallback logic in a mapper:

src/lib/contoprix/articles.ts
import { client } from "./client";

type ArticleData = {
  title?: string;
  summary?: string;
};

export async function getArticle(slug: string) {
  const entry = await client.content.getBySlug("article", slug, {
    languageCode: "en",
  });

  const data = entry.data as ArticleData;

  return {
    id: entry.id,
    title: data.title ?? "Untitled article",
    summary: data.summary ?? "",
    slug: entry.slug,
    publishedAt: entry.publishedAt,
  };
}

Avoid this incorrect pattern:

Incorrect
entry.title

title is a model field, so it belongs at entry.data.title.

A publish checklist#

  • The entry is in the intended website and language.
  • Every required field has a meaningful value.
  • The slug is correct and unique for that website, type, and language.
  • Media is selected from the library and has appropriate alt text where your model supports it.
  • Related entries exist and have been published if required for this publish.
  • Optional fields have been checked in the frontend's empty state.
  • A preview or delivery request shows the expected result.
  • Application caches are revalidated if your deployment needs it.

Common editor problems#

ProblemExplanationFix
“Slug already exists”Another active entry has the same normalized slug in the same website/type/language scope.Choose a unique slug or edit the existing record.
Cannot publishRequired content, a relation, workflow approval, or permissions are missing.Read the validation message, complete the record, then retry.
Public page does not show an editThe entry is draft, the route uses another language, or the app caches delivery.Publish the correct entry/language and revalidate the app if applicable.
Image renders strangelyA picker value was not stored as a media reference or the UI assumes a URL string.Re-select the media item and map the delivered media object.

Continue with Relations to reuse Authors and Products, or Localization to create language-specific entries.