Understanding Variables in Workflows

What Are Variables?

Variables are how you pass data between nodes in a Trigify workflow. Every trigger and action node produces outputs, and variables let you reference that data in later steps.

Think of it this way: when a New Post trigger fires, it captures the post text, author URL, like count, and more. Variables let you plug any of that data into the next node, whether that is an enrichment step, an AI agent, or a CRM integration.

Key concept: Variables are the glue that connects your workflow nodes together. Without them, each node would operate in isolation.


The Variable Syntax

All variables in Trigify follow this format:

{{ !ref($.trigger.outputs.variableName) }}

Here is how it breaks down:

PatternWhat It References
$.trigger.outputsData from the workflow's trigger node
$.steps.actionId.resultData from a specific action step
$.steps.loopId.result[N].propertyNameData from loop items

Three Types of Variable References

1. Trigger Data

Data from whatever kicked off the workflow.

{{ !ref($.trigger.outputs.text) }}{{ !ref($.trigger.outputs.authorUrl) }}{{ !ref($.trigger.outputs.likes) }}

2. Step Data

Data produced by any action node. Each node has a unique ID you can reference.

{{ !ref($.steps.personEnrichment1.result.firstName) }}{{ !ref($.steps.sentimentAgent1.result) }}

3. Loop Item Data

When inside a Loop node, you get special variables for the current item.

{{ !ref($.steps.loop1.result.item) }}{{ !ref($.steps.loop1.result.index) }}{{ !ref($.steps.loop1.result.isFirst) }}{{ !ref($.steps.loop1.result.isLast) }}

Variable Cheat Sheet

What You WantVariable PathExample Use
Post text from trigger$.trigger.outputs.textThe full post content
Author LinkedIn URL$.trigger.outputs.authorUrlInput for Person Enrichment
Like count$.trigger.outputs.likesFilter with If Condition (likes > 100)
Comment count$.trigger.outputs.commentsFilter viral posts
Post URL$.trigger.outputs.postUrlPass to Get Post Likes node
Date posted$.trigger.outputs.datePostedFilter by recency
Source platform$.trigger.outputs.sourcelinkedin, twitter, youtube, reddit, podcast
Enriched first name$.steps.{nodeId}.result.firstNamePersonalize outreach
Enriched email$.steps.{nodeId}.result.emailAdd to email campaign
AI agent output$.steps.{nodeId}.resultSentiment score, generated copy
Current loop item$.steps.{loopId}.result.itemThe current item being processed
Loop index$.steps.{loopId}.result.indexPosition in the loop (starts at 0)
Loop total$.steps.{loopId}.result.totalTotal items in the collection

Pro Tips

Pro tip: Use the variable picker! You do not have to type these by hand. Click the variable icon in any input field and Trigify shows you all available variables from previous steps.

Watch out: Person Enrichment uses jobTitle, not title. This trips people up.