public boolean expectBooleanValue() {
        if (value instanceof Boolean) {
            return (Boolean) value;
        }

        throw new JmespathException("Expected a boolean literal, but found " + value.getClass());
    }
Gets the value as a boolean.

@return Returns the boolean value.
@throws JmespathException if the value is not a boolean.
smithy-jmespath/src/main/java/software/amazon/smithy/jmespath/ast/LiteralExpression.java