---
title: "Require"
---

{/* Auto-generated by scripts/generate_core_action_docs.py; do not edit by hand. */}

## `core.require`

Evaluate a conditional expression and returns the boolean result.

### Inputs

<ParamField path="conditions" type="boolean | array[boolean]" required>

Conditional expression(s) to evaluate. All must be true for the result to be true.

</ParamField>

<ParamField path="raise_error" type="boolean">

If `True`, the function will raise an error if the condition is false. If `False`, the function will return `False` instead.

Default: `true`.

</ParamField>

<ParamField path="require_all" type="boolean">

If `True`, all conditions must be true for the result to be true. If `False`, only one condition must be true.

Default: `true`.

</ParamField>

### Examples

**Stop when prerequisites are not met**

```yaml
- ref: require_inputs
  action: core.require
  args:
    conditions:
      - ${{ TRIGGER.case_id != None }}
      - ${{ TRIGGER.severity in ["high", "critical"] }}
    require_all: true
    raise_error: true
```
