Built-in operators - AWS Verified Access

Built-in operators

When creating the context of an AWS Verified Access policy using various conditions, as discussed in Policy statement structure, you can use the && operator to add additional conditions. There are also many other built-in operators that you can use to add additional expressive power to your policy conditions. The following table contains all the built-in operators for reference.

Operator Types and overloads Description


bool → bool

Logical not.


any → any

Equality. Works on arguments of any type, even if the types don't match. Values of different types are never equal to each other.

!= any → any

Inequality; the exact inverse of equality (see above).


(long, long) → bool

Long integer less-than.


(long, long) → bool

Long integer less-than-or-equal-to.


(long, long) → bool

Long integer greater-than.


(long, long) → bool

Long integer greater-than-or-equal-to.

in (entity, entity) → bool Hierarchy membership (reflexive: A in A is always true).
(entity, set(entity)) → bool Hierarchy membership: A in [B, C, ...] is true if (A and B) || (A in C) || … error if the set contains a non-entity.
&& (bool, bool) → bool

Logical and (short-circuiting).

|| (bool, bool) → bool

Logical or (short-circuiting).

.exists() entity → bool Entity existence.
has (entity, attribute) → bool Infix operator. e has f tests if the record or entity e has a binding for the attribute f. Returns false if e does not exist or if e does exist but doesn't have the attribute f. Attributes can be expressed as identifiers or string literals.
like (string, string) → bool Infix operator. t like p checks if the text t matches the pattern p, which may include wildcard characters * that match 0 or more of any character. In order to match a literal star character in t, you can use the special escaped character sequence \* in p.
.contains() (set, any) → bool Set membership (is B an element of A).
.containsAll() (set, set) → bool Tests if set A contains all of the elements in set B.
.containsAny() (set, set) → bool Tests if set A contains any of the elements in set B.