Skip to main content

Module map

Module map 

Source
Expand description

§Map Function Module

This module provides data transformation capabilities using JSONLogic expressions. The map function allows copying, transforming, and reorganizing data within messages by evaluating JSONLogic expressions and assigning results to specified paths.

§Features

  • Transform data using JSONLogic expressions
  • Support for nested path access and creation
  • Automatic merging for root fields (data, metadata, temp_data)
  • Null value handling (null results skip assignment)
  • Change tracking for audit trails

§Example Usage

{
    "name": "map",
    "input": {
        "mappings": [
            {
                "path": "data.full_name",
                "logic": {"cat": [{"var": "data.first_name"}, " ", {"var": "data.last_name"}]}
            },
            {
                "path": "metadata.processed",
                "logic": true
            }
        ]
    }
}

Structs§

MapConfig
Configuration for the map function containing a list of mappings.
MapMapping
A single mapping that transforms and assigns data.