Course/Chapter 3/3. Data Flow & Mapping
    beginner
    Chapter 3: Understanding Workflows

    3. Data Flow & Mapping

    Master how data moves through a workflow.

    20m Lesson 3 of 6

    Data flows through your workflow as items — arrays of JSON objects. Understanding how to reference, transform, and route this data is essential.

    Expression Editor

    The expression editor lets you dynamically reference data from any previous node. Access it by clicking the "fx" icon on any field.

    Common Patterns

    • - Direct reference: `{{ $json.email }}` — access a field from the previous node
    • - Cross-node reference: `{{ $node["Node Name"].json.field }}`
    • - JavaScript: `{{ $json.name.split(" ")[0] }}` — use JS functions inline

    Code Examples

    Expression Examples
    javascript
    // Simple field access
    {{ $json.customer.email }}
    
    // Array operations
    {{ $json.items.map(i => i.name).join(", ") }}
    
    // Conditional values
    {{ $json.status === "active" ? "✅" : "❌" }}
    
    // Date formatting
    {{ DateTime.fromISO($json.created_at).toFormat("MMM dd, yyyy") }}
    
    // Math
    {{ ($json.price * $json.quantity * 1.1).toFixed(2) }}

    Pro Tips

    • 💡Use the expression editor's autocomplete — press Ctrl+Space to see available fields

    Comprehension Quiz

    Answer 2 of 2 correctly to unlock lesson completion.

    1. What does {{ $json.email }} reference?

    2. How do you access output from a specific node by name?

    Pass the quiz above to unlock lesson completion