SocialluxSociallux
Toggle navigation menu
Docs navigationv

Primitive

logic.assert

BETA

Short name: assert

Version: 1.0.0

Throw a typed error when condition is not strictly true.

Back to primitive library

Inputs

KeyTypeRequiredDescription
codestringfalseOptional machine-readable error code. Defaults to ASSERTION_FAILED.
conditionbooleantrueMust be strictly true to pass.
messagestringtrueError message surfaced when condition is false.
statusCodenumberfalseOptional HTTP-style status code. Defaults to 422 for assertion failures.

Outputs

KeyTypeRequiredDescription
okbooleanfalseAlways true when the step returns; false path throws instead.