Create line items in Zaps

Available on plans:

Free

Pro

Team

Enterprise

 

Line items are collections of separate data gathered into a single field. A single line item can consist of multiple fields and values. This contrasts with other field types that have one value per field. In programming terms, they are arrays of objects. Line item fields are usually found in commerce apps.

Many apps require information formatted as line items to work properly. If the step where the data comes from does not support line items, you can use Formatter to reformat your data into line items.

For computers, line items must be represented as a type of JSON data structure, composed of a key and a comma-separated list inside of square brackets that looks like this:

{ fruit:
    [ “apples”, “oranges”, “bananas” ]}

1. Add a Formatter Utilities step to your Zap

  • In the Zap outline, click the Action step or the plus sign + to add a new action. A dialog box will open.
  • In the search box, search for and select Formatter. The right sidebar will open to the Setup tab.
  • Click the Action event dropdown menu and select Utilities.
  • Click Continue.

2. Set up your transform

You can create line items with two different Formatter transforms: Text to Line-item, to create one set of line items, and Line Itemizer, to create multiple sets of line items.

Text to Line-item Line Itemizer

Text to Line-item

If you have a single set of line items you want to create, use the Text to Line-item transform:

  • Click the Transform dropdown menu and select Text to Line-item.
  • Click the Input field and map data from another step that's formatted as comma-separated values (e.g., “apples,bananas,oranges”).
  • Click Continue.

3. Test your line item transformation

  • Click Test step. If the transformation is successful, the information from the trigger will be converted into line items.

Once you create line items with Formatter, you can use these line items in other actions in your Zap.

Was this article helpful?
6 out of 27 found this helpful