Portal Community

Properties

PropertyTypeRequiredDefaultDescription
sub_workflow_idstring (GUID)YesThe unique identifier of the child workflow to invoke. Obtain this from the workflow designer URL or the workflow catalogue API.
sub_workflow_version_idintegerNo1The specific version of the child workflow to execute. Defaults to version 1. Pin to a specific version to protect the parent from unexpected changes when the child workflow is updated.
input_dataobject | expressionNo{}Data to pass to the child workflow as its input. The child accesses this via $input.current.*. Can be a literal object or a BizFirst expression: {@ { customerId: var.customerId, orderTotal: var.orderTotal } }.

Data Passing: Parent to Child

Parent Context in Child Workflows

Inside the child workflow, the following references are available in addition to the child's own input:

This means you do not always need to explicitly pass data via input_data — the child can reference parent data directly using the parent.* prefix.

Data Passing: Child to Parent

When the child workflow completes, BizFirst automatically collects all of the child's output values and variables and makes them available in the parent under the subworkflow.* namespace:

Child producesParent accesses as
Variable invoiceId{@ subworkflow.invoiceId } or {@ output.RunInvoiceSubflow.subworkflow.invoiceId }
Node output output.GeneratePDF.url{@ subworkflow.result } (via child's StopWorkflow message)

Version Pinning Guidance

StrategyWhen to Use
Pin to version 1 (default)Initial development; the child workflow is stable and not expected to change.
Pin to a specific version numberProduction workflows that require stability. Update the pin deliberately after testing the new child version.
Always use latest (not currently supported)Development/testing environments where you always want the newest version of the child.

JSON Configuration Example

{
  "node_type": "SubWorkflow",
  "name": "RunApprovalProcess",
  "config": {
    "sub_workflow_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "sub_workflow_version_id": 3,
    "input_data": {
      "requestId": "{@ var.purchaseRequestId }",
      "amount":    "{@ var.requestedAmount }",
      "requestor": "{@ var.employeeName }"
    }
  }
}