List Blocks
A list is an ordered collection of values that you can build, modify, search, and iterate over inside a single automation run. Lists created with these blocks are ephemeral — they last only for the duration of the run. For persistence across runs, see Database.Creating and Modifying Lists
erlc_list_empty
Produces a new, empty list with no items. Use it as the starting point before pushing values with
erlc_list_add.erlc_list_create
Creates a list with up to three pre-set items. Connect value blocks to the
ITEM0, ITEM1, and ITEM2 inputs.erlc_list_add
Appends the value in the
VALUE input to the list variable named in the VARIABLE field. This is a statement block — it mutates the variable in place.erlc_list_remove
Removes the first occurrence of the value in the
VALUE input from the list variable named in the VARIABLE field.Querying Lists
erlc_list_contains
Returns
true if the LIST input contains the VALUE input. Returns false otherwise.erlc_list_length
Returns the number of items in the
LIST input.erlc_list_item
Returns the item at position
INDEX in the LIST input. Indices are 1-based.erlc_list_first
Returns the first item in the
LIST input.erlc_list_last
Returns the last item in the
LIST input.erlc_list_random
Returns a randomly selected item from the
LIST input.erlc_list_index_of
Returns the 1-based position of
VALUE within LIST, or 0 if the value is not found.Transforming Lists
erlc_list_join
Joins all items in the
LIST input into a single string, separated by the SEPARATOR input.erlc_list_sort
Returns a new sorted copy of the
LIST input.erlc_list_reverse
Returns a new reversed copy of the
LIST input.erlc_list_unique
Returns a new copy of the
LIST input with duplicate values removed.erlc_list_slice
Returns a sub-list from the
LIST input beginning at position START and ending at position END (inclusive, 1-based).erlc_for_each
Iterates over every item in the
LIST input. Each item is stored in the variable named by the VARIABLE field, and the DO body runs once per item.Saved List Blocks
Saved lists are persistent named lists stored on the server. Unlike in-run lists, saved lists survive between automation runs and are shared across all your automations. They are read-only from these blocks — use the Database blocks to write saved list data.erlc_saved_list_contains
Returns
true if the saved list named in the LIST field contains the value provided in the VALUE input.erlc_saved_list_item
Returns the item at the 1-based position provided in the
INDEX input from the saved list named in the LIST field.Saved lists use the same underlying named-set storage as the Database blocks. The
LIST field value corresponds to a set name. Read Persistent Database Storage to understand how sets and positions work.Text Blocks
Text blocks let you produce, combine, inspect, and transform string values throughout your automations.Producing Text
Combining Text
erlc_join_values
Concatenates the
LEFT and RIGHT inputs into a single string. Chain multiple blocks to join more than two values.erlc_text_split
Splits the
TEXT input into a list using the SEPARATOR input as the delimiter. Returns a list of strings.JSON Example — Joining Two Text Values
JSON Example — Splitting a String by a Separator
Inspecting Text
Transforming Text
Custom Reusable Blocks
Custom block definitions let you encapsulate a sequence of blocks and call it by name from anywhere in your workspace — similar to a function or subroutine.erlc_custom_block_definition
Defines a reusable block. Connect a text value to
TITLE to name it, and build the body in the BODY statement input. Use the EDIT field to manage the definition.erlc_custom_block_call
Calls the custom block whose name matches the value connected to the
TITLE input. Execution jumps into the definition body and returns when it finishes.erlc_custom_block_argument
Reads an argument passed to the currently executing custom block. Connect a text value to the
NAME input specifying which argument to retrieve.Custom block definitions are evaluated at the time they are called, not when they are defined. This means you can define a block anywhere on your canvas and call it from any other automation stack.