Skip to main content

List: random item

Node function to extract a random item from a list. The item is picked uniformly at random; an empty input list fails the step.

Parameters​

Item typerequired

The type of the list item. One of Bool, String or Number.

Example
["a", "b", "c"] // item type -> String
[1, 2, 3] // item type -> Number

Input​

Array

required

A list of items. Only the Array type is accepted. The list must not be empty, otherwise the step fails.

Output​

Item value

The value extracted randomly from the list. The output connector is labeled with the configured Item type (Bool, String or Number).