Content Item Expressions
When a content item is stored as a process or case variable, its properties can be accessed through backend expressions.
For example, if a content item is stored in a variable named document, its MIME type can be accessed via ${document.mimeType}.
The metadata, renditions, and definition properties support lazy loading:
if the content item was queried without including that related data, it is fetched automatically when the expression is evaluated.
All content item properties are read-only.
Content Item Properties
The following properties are available on a content item:
| Property | Description |
|---|---|
| id | The unique technical identifier of the content item. |
| name | The name of the content item. |
| mimeType | The MIME type of the content item. |
| created | The time (as a java.util.Date) the content item was created. |
| createdBy | The id of the user that created the content item. |
| lastModified | The time (as a java.util.Date) the content item was last modified. |
| lastModifiedBy | The id of the user that last modified the content item. |
| contentSize | The size in bytes of the stored content. |
| contentAvailable | Whether the content is currently available in the content store. |
| contentStoreId | The identifier used within the content store to reference the stored content. |
| contentStoreName | The name of the content store where the content is stored. |
| taskId | The id of the task this content item is associated with, if any. |
| processInstanceId | The id of the process instance this content item is associated with, if any. |
| scopeId | The scope identifier of the content item, if any. |
| scopeType | The scope type of the content item, if any. |
| tenantId | The tenant identifier of the content item. |
| version | The version number of the content item. |
| versionInfo | Additional version information, if set. |
| versionParentId | The id of the parent version, if the content item is versioned. |
| definitionId | The id of the document definition associated with this content item, if set. |
| definitionName | The name of the document definition associated with this content item, if set. |
| state | The state of the content item, if set. |
| subState | The sub-state of the content item, if set. |
| type | The type of the content item, if set. |
| subType | The sub-type of the content item, if set. |
| lockInfo | Lock information for the content item, if it is currently locked. |
| parentFolderId | The id of the parent folder, if the content item is stored in a folder. |
| baseFolderId | The id of the base folder, if set. |
| metadata | A Map<String, Object> of all metadata key-value pairs. Loaded lazily if not pre-fetched. |
| renditions | A list of renditions associated with the content item. Loaded lazily if not pre-fetched. See Rendition Properties. |
| definition | The document definition associated with the content item, or null if no definitionId is set. Loaded from the deployment cache. See Definition Properties. |
In addition, the following shorthand properties give direct access to a rendition of a specific type (or its data), without iterating over the renditions list:
| Property | Description |
|---|---|
| thumbnailRendition | The thumbnail RenditionItem of the content item, or null if none exists. See Rendition Properties. |
| pdfRendition | The PDF RenditionItem of the content item, or null if none exists. |
| structuredRendition | The structured RenditionItem of the content item, or null if none exists. |
| thumbnailRenditionData | The binary content of the thumbnail rendition as an InputStream, or null if none exists. |
| pdfRenditionData | The binary content of the PDF rendition as an InputStream, or null if none exists. |
| structuredRenditionData | The structured rendition content parsed as a JSON object (JsonNode), or null if none exists. |
Metadata
Metadata can be accessed via the metadata property, which resolves to an object of all metadata key-value pairs.
Example: ${document.metadata.author}
If the metadata was not included in the original content item query, it is fetched automatically on first access.
Rendition Properties
The renditions property resolves to a list of RenditionItem objects associated with the content item.
If renditions were not included in the original query, they are fetched automatically on first access.
Example: ${document.renditions}
To access a rendition of a specific type directly, use the shorthand properties instead of iterating the list.
Example: ${document.thumbnailRendition} (the RenditionItem), ${document.pdfRenditionData} (the binary content), or ${document.structuredRenditionData.someField} (a field of the parsed JSON).
Each rendition in the list exposes the following properties:
| Property | Description |
|---|---|
| id | The unique technical identifier of the rendition. |
| contentItemId | The id of the content item this rendition belongs to. |
| contentItemName | The name of the content item this rendition belongs to. |
| name | The name of the rendition. |
| mimeType | The MIME type of the rendition. |
| renditionType | The type of the rendition (thumbnail, pdf, or structured). |
| contentStoreId | The identifier used within the content store to reference the rendition content. |
| contentStoreName | The name of the content store where the rendition is stored. |
| contentSize | The size in bytes of the rendition content. |
| contentAvailable | Whether the rendition content is currently available. |
| created | The time (as a java.util.Date) the rendition was created. |
| lastModified | The time (as a java.util.Date) the rendition was last modified. |
| taskId | The id of the task this rendition is associated with, if any. |
| processInstanceId | The id of the process instance this rendition is associated with, if any. |
| scopeId | The scope identifier of the rendition, if any. |
| scopeType | The scope type of the rendition, if any. |
| tenantId | The tenant identifier of the rendition. |
| provisional | Whether the rendition is provisional (not yet finalized). |
Structured Renditions
A structured rendition holds a JSON representation of the content item (MIME type application/json).
Unlike the thumbnail and pdf renditions, a structured rendition is not generated for every uploaded file.
It is created for specific content sources, most notably for content items that originate from an inbound email channel.
For an ordinary uploaded document, ${document.structuredRendition} and ${document.structuredRenditionData} therefore resolve to null unless a structured rendition was explicitly produced.
When accessed through the structuredRenditionData shorthand, the JSON is parsed automatically and returned as a JsonNode, so individual fields can be addressed directly, for example ${document.structuredRenditionData.subject}.
Email Structured Rendition
When a content item is created from a received email, the structured rendition contains the parsed email as JSON.
Only fields that are present on the email are included, plus the attachments array, which is always added.
| Field | Type | Description |
|---|---|---|
| from | String | The sender's email address. |
| to | Array of String | The recipient addresses. |
| cc | Array of String | The CC'd addresses. |
| bcc | Array of String | The BCC'd addresses. |
| subject | String | The email subject line. |
| subjectCorrelation | String | The correlation value extracted from the subject, if a correlation pattern is configured. |
| sentDate | String | The time the email was sent, as an ISO 8601 instant. |
| receivedDate | String | The time the email was received, as an ISO 8601 instant. |
| content | String | The plain text body of the email. |
| contentHtml | String | The HTML body of the email. |
| customHeaders | Object | Any non-standard email headers, as a key-value object. |
| attachments | Array of Object | The email attachments, each as an object with id (the content item id of the stored attachment) and name (the file name). |
The raw MIME message and the binary attachment data are not part of the structured rendition.
Each attachment is stored as its own content item and referenced from the attachments array by its id.
Example: ${document.structuredRenditionData.from} returns the sender address, and
${document.structuredRenditionData.attachments} returns the list of attachment references.
Definition Properties
If a content item is associated with a document definition, the definition can be accessed via the definition property.
If the content item has no definitionId set, the property resolves to null.
The definition is backed by the deployment cache, so repeated access does not trigger additional database queries.
Example: ${document.definition.key}
| Property | Description |
|---|---|
| id | The unique technical identifier of the document definition. |
| key | The key of the document definition, unique per tenant. |
| name | The name of the document definition. |
| version | The version of the definition. Each time a document model is published, a new version for the same key is created. |
| category | The category of the document definition, if set. |
| deploymentId | A reference to the deployment that contains this definition. |
| resourceName | The name of the resource file that defines this document definition. |
| tenantId | The tenant identifier of the document definition. |
| creationTime | The time (as a java.util.Date) the definition was deployed. |
| updateTime | The time (as a java.util.Date) the definition was last updated. |