Skip to main content
This page lists the configuration fields for each Workflow block as they appear in a Workflow definition. Use it when you create or update Workflows with the Workflows API or manage them as YAML with Workflows as code. The API and YAML use the same structure, so every example on this page works in both. In JSON, use the same keys. For instructions on configuring blocks in the Workflow editor, see Adding blocks to a Workflow.
The fastest way to get a correct definition is to build the Workflow in the UI first, then click Export Workflow YAML (see Workflows as code). The export shows the exact values Cortex expects, including IDs that are specific to your workspace.

How a block appears in a Workflow definition

In a definition, blocks are listed under actions. Each entry has the same outer fields, and the block-specific configuration sits under schema. The schema.type value sets which other fields the block takes.

Referencing run data in block fields

Blocks can read the Workflow run state through three top-level keys: context, actions, and variables. Each block writes its result to actions.<slug>.outputs. How you reference a value depends on the field:
  • Text fields (URLs, headers, payloads, messages, descriptions) - Use Mustache templates, such as {{variables.app-name}} or {{actions.get-user-email.outputs.result}}. Use three curly braces to avoid HTML escaping.
  • JQ expressions - Start with a dot, such as .variables.app-name.
  • CEL expressions, JavaScript, and path fields - Use dot paths without a leading dot, such as variables.app-name.
  • Slugs that contain a hyphen - In CEL, JavaScript, and JQ, quote them: actions["get-user-email"] (or .actions["get-user-email"] in JQ).
For the full state object, see Referencing a Workflow state in a block.

Core blocks

Branch (CONDITIONAL_BRANCH)

Cortex evaluates the paths in order and takes the first one whose expression returns true. If none do, it takes the fallback path. See Branch for how paths work. Each path in branches takes the following fields. fallbackBranch takes the same fields except expression, and its type is FALLBACK. Outputs: actions.<slug>.outputs.conditions.<path-slug>.result

Data transformation (JQ)

Outputs: actions.<slug>.outputs.result

HTTP request (HTTP_REQUEST)

Outputs: actions.<slug>.outputs.status, actions.<slug>.outputs.headers, actions.<slug>.outputs.body

Asynchronous HTTP request (HTTP_REQUEST_ASYNC)

This block takes all of the HTTP request fields, plus a timeout. The Workflow pauses until the external system calls the callback URL (available as {{callbackUrl}}) or the timeout expires. See Asynchronous HTTP request for the callback format.

JavaScript (JAVASCRIPT)

Outputs: actions.<slug>.outputs.result, plus any top-level keys of the returned object.

Manual approval (MANUAL_APPROVAL)

Run Workflow (RUN_WORKFLOW)

Outputs: actions.<slug>.outputs.runId. With waitForCompletion: true, also status, runResponse, and variables. See Run Workflow.

Scaffolder (SCAFFOLDER)

Set variable(s) (SET_VARIABLES)

The variables must be declared in the Workflow’s variables list (see Configuring Workflow settings).

User input (USER_INPUT)

Outputs: actions.<slug>.outputs.<key> for each field.

User input field types

Every field takes these common keys: Each type also takes the keys below. Keys in bold are required. Notes on these keys:
  • If you leave out a required boolean (disabled, allowMultiple, allowAdditionalOptions, limitEntitiesToRunnerUserScope, or shouldDisplayOptionsAsHierarchy), Cortex uses false. If you leave out format, Cortex uses DECIMAL for numbers and DATE for dates.
  • optionsLabels sets display labels in the same order as options. If you leave it out, Cortex shows the option values.
  • entityFilter accepts typeFilter ({types: [service, team]}), groupTags, excludedGroupTags, teamIds, domainIds, and emailOwners. Use {} to allow all entities.
  • For CORTEX_USER_FIELD, filter accepts teamCids and userEmails. Use {} to allow all users.

Nested form fields

A NESTED_FORM_FIELD lets the user enter a list of items. It takes the common keys, plus: Outputs: an array of objects for OBJECT (for example, [{"name": "db-1", "size": 100}]), or a flat array for single values (for example, [8080, 8443]).
For a single-value example, see Workflows as code.

Input overrides

inputOverrides on User input and Scaffolder blocks fill a field from a value earlier in the run.

Integration blocks

Most prebuilt integration blocks use the ADVANCED_HTTP_REQUEST type and identify the action with actionIdentifier. Each action has its own set of inputs, so the easiest way to get the identifier and input keys is to add the block in the UI and export the Workflow YAML.

Validating a definition

Before you save, you can check a definition with the Validates YAML descriptor endpoint. It reports missing required fields, slugs that aren’t unique, and broken references between blocks.
Last modified on October 15, 2026