Edit on Github

Script

A schema that is used to validate a part of Laboperator workflow templates.

Schema

Defines a field of type script. A script field can be used to do simple calculations of boolean or numerical expressions and save the result to a field.

typerequired
string
One of: script result
scriptrequired
reference
#/definitions/script

The script will be evaluated to determine the value of the field whenever it is accessed.

readOnly
any

Script fields are always read-only as their value is calculated.

resultrequired
reference or object

You can provide a schema for the result of the expression to have the value validated.

Where is this used?

Other schemas that have a reference ($ref) to this schema.