Convert to Array Transformer

Table of contents

  • General description
  • The different parts of the Convert to Array Transformer

General description

The Convert to Array Transformer takes the input data and transforms JSON objects to arrays. The given patterns work on the keys of the objects (key-1 in the example). The groups within the found key will be wrapped in an array element.

{ "key-1": { "item-1":"item-1", "item-2":"item-2" } }

Will become

{ "key-1": [ { "item-1": "item-1", "item-2": "item-2" } ] }

The different parts of the Convert to Array Transformer

  • Base pattern (required)
    This is a pattern that is used to filter keys. More details can be found on the pattern reference page.

Note: The base pattern impacts the recursive pattern, and it is only applied to elements that are found with the base pattern expression.

  • Recursive (optional)
    By default, only objects of the first level that match the given pattern will be converted to arrays. When this option is activated, the conversion will continue in the underlying parts of the found data.

  • Recursive pattern (conditionally required)
    This field is only required when “recursive” is activated. More details can be found on the pattern reference page.