Skip to content

Set validation rules for a property

Validation rules aren’t a separate screen in Prolibu: they’re declared inside the field’s own JSON Schema, in the Custom fields box — see Custom fields for how that box is opened and edited.

The available constraints are the ones JSON Schema supports, and they’re written alongside the field’s definition:

ConstraintWhat it’s for
patternRequire the value to match a regular expression.
formatValidate known types, such as email or date.
minLength / maxLengthLimit the length of the text.
minimum / maximumLimit the range of a number.
enumRestrict the field to a closed list of values.

This applies only to the fields you add inside customFields: Prolibu’s default properties ship with their own built-in validation and aren’t adjusted through this route.

Frequently asked questions

Was this article helpful?