JSON Schema

State Machine

Represents a state machine with a collection of states.

type

object

properties

  • name

State Machine Name

The name of the state machine

type

string

minLength

1

default

State Machine

  • states

default

#/$defs/States

  • global_timers

default

#/$defs/GlobalTimers

  • global_counters

default

#/$defs/GlobalCounters

  • conditions

default

#/$defs/Conditions

$defs

  • Actions

Actions

A collection of actions.

type

object

additionalProperties

The integer value of the output action

type

integer

maximum

255

minimum

0

  • Condition

Condition

A condition in the state machine.

type

object

properties

  • channel

Channel

The channel or global timer attached to the condition

type

string

minLength

1

  • value

Value

The value of the condition channel if the condition is met

type

boolean

  • Conditions

Conditions

A collection of conditions.

type

object

patternProperties

  • ^\d+$

#/$defs/Condition

  • GlobalCounter

Global Counter

A global counter in the state machine.

type

object

properties

  • event

Event

A state machine event

type

string

minLength

1

  • threshold

Threshold

The count threshold to generate an event

type

integer

maximum

4294967295

minimum

0

  • GlobalCounters

Global Counters

A collection of global counters.

type

object

patternProperties

  • ^\d+$

#/$defs/GlobalCounter

  • GlobalTimer

Global Timer

A global timer in the state machine.

type

object

properties

  • duration

Global Timer Duration

The duration of the global timer in seconds

type

number

minimum

0.0

  • onset_delay

Onset Delay

The onset delay of the global timer in seconds

type

number

minimum

0.0

default

0.0

  • channel

Channel

default

null

anyOf

type

string

type

null

  • value_on

Channel Value

The value a channel is set to

type

integer

maximum

255

minimum

0

default

0

  • value_off

Channel Value

The value a channel is set to

type

integer

maximum

255

minimum

0

default

0

  • send_events

Send Events

Whether the global timer is sending events

type

boolean

default

True

  • loop

Loop Mode

Whether the global timer is looping or not

type

integer

maximum

255

minimum

0

default

0

  • loop_interval

Loop Interval

The interval in seconds that the global timer is looping

type

number

minimum

0.0

default

0.0

  • onset_trigger

Onset Trigger

An integer whose bits indicate other global timers to trigger

type

integer

minimum

0

default

0

  • GlobalTimers

Global Timers

A collection of global timers.

type

object

patternProperties

  • ^\d+$

#/$defs/GlobalTimer

  • State

State

A state in the state machine.

type

object

properties

  • timer

State Timer

The state’s timer in seconds

type

number

minimum

0.0

default

0.0

  • transitions

default

#/$defs/Transitions

  • actions

default

#/$defs/Actions

  • comment

Comment

default

null

anyOf

Comment

A comment describing the state.

type

string

type

null

  • States

States

A collection of states.

type

object

patternProperties

  • ^(?!>)(?!exit$).+$

#/$defs/State

  • Transitions

State Transitions

A collection of state transitions.

type

object

additionalProperties

anyOf

State Name

The name of the state

type

string

minLength

1

pattern

^(?!>)(?!exit$).+$

Operator

A state machine operator

type

string

pattern

^(exit)|(>.+)$