Skip to main content

Numbers schema example

This schema example shows how to define integer and number properties and apply validation using the minimum, maximum, and multipleOf keywords to constrain user input. It also demonstrates the use of UI components, including a slider and a dropdown with labels, along with example component parameters.

Note

In Dynamic Content, integers must be whole numbers. For example, 1.0 is not a valid integer.

The exclusiveMaximum and exclusiveMinimum validation keywords are not currently supported.

Pre-requisites
Link copied!

This is a self contained schema that uses standard JSON Schema property types and validations.

How to use
Link copied!

You can change the validation of each property to meet your own requirements.

Integer and number example
Link copied!

Interactive

This example is best viewed on a desktop browser where the schema editor is fully interactive.

    Validation keywords

    Input field component reference