Skip to main content

Overview

Data processing nodes transform, format, and prepare data as it flows through workflows.

Template Node

Transform and format data using Pongo2 template expressions

Template Node

Purpose: Transform and format data using template expressions Template nodes process text templates with dynamic variable substitution, allowing you to format data from previous nodes.
Template node visual representation
Template node visual representation
Node Handles:
Left Side - Template TriggerReceives trigger to process the template.Accepts:
  • Workflow execution flow
  • Template variables from variable mappings
  • Previous node outputs (accessed via template syntax)

Template Engine (Pongo2)

Splox uses Pongo2, a Django-syntax inspired template engine, for powerful text processing.
Variable Substitution
{{ variable_name }}                    <!-- Insert variable value -->
{{ node_output.field }}                <!-- Access object fields -->
{{ data.nested.deep }}                 <!-- Access nested fields -->
{{ array.0 }}                          <!-- Access array elements -->
Example:
Hello {{ user.name }}, you have {{ messages|length }} new messages.

Variable Mappings

Template nodes access data through variable mappings that reference previous nodes:
{
  "variable_mappings": [
    {
      "mapping_name": "user_data",
      "node_json_schema_id": "abc-123-..."
    },
    {
      "mapping_name": "api_response",
      "node_json_schema_id": "def-456-..."
    }
  ],
  "template": {
    "text": "User: {{ user_data.name }}\nStatus: {{ api_response.status }}",
    "language": {"label": "Text", "value": "text"}
  }
}

Output Format

Template nodes return a structured object:
{
  "template": "Processed template text with all variables substituted"
}

Use Cases

API Response Formatting

Format API responses for display or LLM consumption

Dynamic Messages

Generate personalized messages with user data

Email Content

Build email/notification content from data

Data Combination

Combine data from multiple nodes into formatted output
Template nodes are perfect for preparing data before sending it to LLMs or external APIs. Use filters like |json to properly format complex objects.

What’s Next?