Pill References
Pill references pass data between steps — the output of one step becomes the input to another.
Syntax
Section titled “Syntax”$<source>.<field>$<source>.<field>.<subfield>Sources
Section titled “Sources”Trigger
Section titled “Trigger”Access fields from the triggering record:
$trigger.current.number$trigger.current.short_description$trigger.current.caller_id # Reference field (sys_id)$trigger.current.caller_id.email # Dot-walk through referenceAccess subflow input parameters:
$input.my_param$input.recipient.email # Dot-walk on reference inputsVariable
Section titled “Variable”Access scratch variables:
$variable.counter$variable.temp_recordStep Output
Section titled “Step Output”Reference outputs from earlier steps using the step’s id:
steps: - action: lookup_record id: find_user inputs: table: sys_user conditions: "sys_id=$trigger.current.caller_id"
- action: send_email inputs: to: $find_user.record.email subject: "Hello $find_user.record.name"Step IDs
Section titled “Step IDs”Give a step an id to reference its outputs:
- action: lookup_record id: my_lookup inputs: table: incidentThen reference it as $my_lookup.<output>.
Common action outputs:
| Action | Outputs |
|---|---|
lookup_record | record, record_count |
create_record | record, record_sys_id |
run_script | Script-defined outputs |
Embedding in Strings
Section titled “Embedding in Strings”Pill references work inline in text:
inputs: subject: "Incident $trigger.current.number needs attention" body: "Assigned to $find_user.record.name ($find_user.record.email)"Validation
Section titled “Validation”flowctl --validate checks that:
$<step_id>references point to a step with thatid- Referenced steps appear before the referencing step (no forward references)
$trigger,$input, and$variableare reserved and not checked against step IDs
If a pill reference points to an undefined step ID:
pill reference $find_user (in input "to") refers to undefined step id