Display
Learn how to display workflow results in a structured way.
Display
When building workflows, you have two main properties for displaying results:
display
: The primary property for showing the results UI everywhere including workflow, rules, and record contextsworkflow_display
: The property for showing the results UI only in the workflow context
How to Return Display Properties
Display properties are typically returned in a code step, usually the last step of your workflow. And the UI will be rendered in this code step’s output section.
Display Formats
All display properties support two main formats:
Markdown
Use markdown for rich text formatting:
Structured Display
For more complex layouts, use arrays and objects that Cortex will render as beautiful, readable UI content:
Tables in Structured Display
Tables can be created in two ways:
- Single Row Table: Add an object directly to the display array:
- Multi-Row Table: Wrap multiple row objects in an array:
Display Configuration
In structured displays, any nested array can include a configuration object as its first element:
Mermaid Diagrams
Cortex supports Mermaid diagrams to output visualizations in the result UI:
You can create diagrams dynamically with workflow data:
Available Colors
The following colors can be used to style display variants:
info
- Informational bluesuccess
- Positive greendanger
- Critical redwarning
- Cautionary yelloworange
- Orange highlightyellow
- Yellow highlightgreen
- Green highlightred
- Red highlightblue
- Blue highlight
Displaying in Rules and Records Contexts
This section is only relevant if you’re working with rules and records. If you’re just building standalone workflows, you can skip this section.
When workflows run as part of rules and records, you can use additional display properties:
Rule & Record Display Properties
These context-specific properties determine where results appear on the record page:
rule_display
: Shows within the specific rule section on a record pagerecord_display
: Shows at the top level of the record page
Record and rule properties serve different purposes:
- Record properties appear at the top level of the record page, showing overall results
- Rule properties appear within their specific rule section, showing results specific to that rule
Use record properties to elevate important results for better visibility at the top of the record page.
Metric Blocks for Rules and Records
Blocks display key metrics with optional formatting and styling. All properties except label
and value
are optional.
Record Blocks
Rule Blocks
Block Properties
-
Required Properties:
label
: Identifies the metricvalue
: The actual value to display
-
Optional Properties:
description
: Tooltip text explaining the metricvalue_color
: Color styling for the valueformat
: How to format the valueorder
: Display order (numeric)
Available Formats
date
: Formats timestamps as datesdatetime
: Formats timestamps with date and timenumber
: Formats numerical valuescurrency
: Formats monetary valuespercent
: Formats percentage values
Special Status Color
In rules and records contexts, the status
color is dynamic and changes based on the workflow or rule status: