equals

Validates that a function argument equals a given value.

Configuration

This rule type accepts the following parameters:

KeyTypeDefaultDescription
arg *stringThe name of the argument
value *stringThe value the argument must equal

Example

This validates that an argument called message is defined:

{
"type": "equals",
"arg": "status",
"value": "subscribed"
}

You can also validate nested arguments, using dots to denote the path:

{
"type": "equals",
"arg": "fields.status",
"value": "subscribed"
}