Skip to main content

OutputData


🎯 Purpose​

OutputData is the finalization node. It collects the data produced by your workflow, formats it using a template engine, and exposes the result as the workflow’s final payload for display, export, or handoff to downstream systems.

πŸ“€ Outputs​

  • Formatted Payload: A string (HTML/Markdown/plain text/JSON-like) produced by the selected template engine.
  • Raw Context (optional): Whatever your template renders from the upstream {{ Out }} (or selected fields).

βš™οΈ Parameters​

NameTypeRequiredDefaultDescription
dataRich Text / TemplateNo{{Out}}The output template. Use variables from the workflow context (e.g., {{ order.id }}, {{ items }}).
String CompilerDropdownNoSynthreo String CompilerTemplate engine: Synthreo String Compiler (simple vars)
Suppress Skipped ExecutionBooleanNofalseIf true, run even when prior nodes were skipped, ensuring an output is always produced.
Allow OverrideBooleanNofalseIf true, permits later nodes/steps to modify this node’s output.

πŸ’‘ Example Usage​

  • πŸ“‘ Human-Readable Summary (Markdown)
    • Compiler: Synthreo String Compiler
    • data:
      # Order Summary β€” {{ order.id }}
      Customer: {{ customer.name }} ({{ customer.email }})
      Items ({{ items.length }}):
      {{#each items}}
      - {{ name }} Γ— {{ qty }} β€” ${{ price }}
      {{/each}}
      Total: ${{ totals.grand }}

Tip: Start with {{Out}} during prototyping to see the full payload, then narrow the template to only the fields you need.

πŸ“˜ Best Practices​

  • Begin Broad, Then Narrow: Use {{Out}} first, inspect the shape, and then reference only required fields.

  • Choose the Right Engine:

    • Synthreo String Compiler β€” simple variable replacement, fastest.
  • Defensive Templates: Add defaults/guards for optional fields (e.g., {{ customer.email || 'N/A' }} if supported).

  • Deterministic Shapes: For machine consumption, render stable keys and types (avoid mixing human text with JSON).

  • Flow Control: Enable Suppress Skipped Execution when you must always emit a summary (e.g., errors, partial results).

πŸ§ͺ Test Cases​

  • Default Pass-Through
    • Given: data="{{Out}}", compiler=Synthreo String Compiler
    • Expected: Entire upstream payload rendered as string.

πŸ”§ Troubleshooting​

  • Blank Output: Check variable names; they’re case-sensitive. Confirm upstream data reaches {{Out}}.
  • Malformed JSON: When exporting JSON, avoid trailing commas and ensure values are already JSON-encoded if you inject arrays/objects.
  • Slow Rendering: Prefer Synthreo String Compiler for simple outputs; minimize heavy loops/partials in large payloads.