Using List Mapping Step
  • 07 Dec 2020
  • 1 Minute to read
  • Dark
    Light
  This documentation version is deprecated, please click here for the latest version.

Using List Mapping Step

  • Dark
    Light

Article summary

Overview

The List Mapping Step allows users to change a list from one type of structure, into a different type of structure. This helps in the context of API calls because it can change the XML, JSON, or other list types into a different data structure. There are 3 main properties of the list mapping step:

Properties
INPUTSTakes in a list of user defined types or primitive types
Output TypeThe type of INPUTS will be changed to
Show Item Mapping EditorThe mapping editor to map the desired data fields from the INPUTS type to the Output Type

To prepare for this example, create a database structure with the following fields.

DisplayValue
DisplayString
ValueString

Example

To utilize a List Mapping Step in an example,  create a flow, and give it a name. Once you are in the flow designer drag a fetch Entities Step and a List Mapping Step onto the flow canvas. On the fetch entities step, select the 'Account' type under 'Type Name'


On the List Mapping Step, set the output type to 'DisplayValue', then map the 'Entity Results' from to the input of the list mapping step, and click on the Show Item Mapping Editor.


In the Show Item Mapping Editor, the variable that is mapped into the List Mapping Step will be called the __INPUTS. It will be located in the bottom left of the mapping editor. Expand the __INPUTS variable and map the 'Email Address' field and the 'AccountID' field to 'Display' and 'Value' fields of the DisplayValue Data structure.


When this flow runs, what the List Mapping Step will do is take the values 'AccountID' and 'EmailAddress' from the decisions account table. It will then pass those values to the fields in the 'DisplayValue' data structure. 



Was this article helpful?