Workflow

Modify specific fields on multiple contentlets

Changed on

Assigns values to the specified fields across multiple contentlets simultaneously.

Can use a Lucene query in its body to select all resulting content items.

Returns a list of resultant contentlet maps, each with an additional AUTO_ASSIGN_WORKFLOW property, which can be referenced by delegate services that handle automatically assigning workflow schemes to content with none.

LOCK and UNLOCK are not supported by this endpoint and are rejected with a 400. Locking is per-user state on the contentlet's version info rather than a content change, so there is nothing for a merge to apply — accepting the call would lock the contentlet and silently discard the submitted field values. Use POST or PUT /v1/workflow/actions/default/fire/{systemAction} for those two.

patch/api/v1/workflow/actions/default/fire/{systemAction}

Request

Path parameters

systemAction'NEW' | 'EDIT' | 'PUBLISH' | 'UNPUBLISH' | 'ARCHIVE' | 'UNARCHIVE' | 'DELETE' | 'DESTROY' required

Default system action.

Query parameters

inodestring

Inode of the target content.

identifierstring

Identifier of target content.

languagestring

Language version of target content.

offsetinteger

Numeric offset for query results; useful for paginating.

Request body

commentsstring

Optional comment recorded on the workflow task history.

assignstring

User or role ID to assign the task to (used by actions that reassign).

publishDatestring

Publish date for the 'Publish' step, in the content type's configured date format.

publishTimestring

Publish time for the 'Publish' step, in the content type's configured time format.

expireDatestring

Expiration date, in the content type's configured date format.

expireTimestring

Expiration time, in the content type's configured time format.

neverExpirestring

Set to 'true' to mark the content as never expiring.

whereToSendstring

Push-publishing target environment(s) for a 'Push Publish' action.

filterKeystring

Push-publishing filter key for a 'Push Publish' action.

querystring

Lucene query selecting the content to act on, as an alternative to 'contentlet'.

pathToMovestring

Target folder path for a 'Move' action.

timezoneIdstring

Timezone ID (e.g. 'America/New_York') used to interpret the publish/expire date-times.

individualPermissionsobject

Per-content individual permissions to apply, keyed by permission type (READ, WRITE, PUBLISH, etc.) to a list of user/role IDs.

iwantTostring
contentletobject

The contentlet to create or edit, as a flat map of field-variable names to values. Polymorphic: the allowed fields depend on the content type.

System fields (all content):

  • contentType (string) — the content type's variable name (e.g. 'webPageContent'). Required when creating.
  • languageId (number) — language ID; defaults to the system default language when omitted.
  • contentHost (string) — host (site) identifier the content belongs to, or hostFolder (string) — a folder identifier. Supply one of these.
  • inode / identifier (string) — include the existing identifier (and optionally inode) to edit existing content; omit both to create new.

⚠️ Do not set host — use contentHost (host id) or hostFolder (folder id) instead.

Host defaulting (common wrong-host trap): if you omit contentHost/hostFolder when creating, the content does NOT go to the current/default site — it inherits the content type's own host, which is SYSTEM_HOST unless the type was explicitly created on a site. So content of a SYSTEM_HOST content type silently lands on SYSTEM_HOST, where it is invisible to another site's URL-maps and to host-scoped searches (+conHost:<siteId>). Always pass contentHost:<siteId> (the site identifier UUID, not the hostname) to place content on a specific site.

Constant fields are content-type configuration, not contentlet data. Fields whose clazz is ImmutableConstantField are shared by the content type. Keys for them in this contentlet map are silently ignored even when the workflow response is HTTP 200/live. For example, a WIDGET's widgetCode must be written to the field's values property via the content-type field API, not included in a widget contentlet.

Pages (contentType: 'htmlpageasset') additionally use:

  • title (string) — the page title.
  • url (string) — the page name (the last URL segment) within hostFolder.
  • template (string) — identifier of the template to render the page.
  • cachettl (number) — page cache time-to-live in seconds.
  • sortOrder (number) — sort order within the folder.

Note: there is no dedicated page-create endpoint — pages are created by firing an action with an htmlpageasset contentlet.

Example request

{
  "contentlet": {
    "contentType": "htmlpageasset",
    "languageId": 1,
    "hostFolder": "48190c8c-42c4-46af-8d1a-0cd5db894797",
    "title": "My Page",
    "url": "my-page",
    "template": "8e63a9c0-...",
    "cachettl": 15,
    "sortOrder": 0
  }
}

Response

Contentlet(s) modified successfully

entityobject
i18nMessagesMapobject
permissionsstring[]

Changes

    • breaking

      removed the media type application/octet-stream for the response with the status

    • info

      added the media type application/json for the response with the status