the key to check.
true if the type is known, false otherwise.
Get the type of the given key from the type checker. Nested keys can be accessed using dot notation (e.g., "user.name").
the key to look up in the type checker.
the type associated with the key, or undefined if the type is not known.
Perform type checking on the given target, which can be a rule, expression, or any other component that requires type validation.
the target to check types for, which must implement the HasValidity interface.
the result of the type check, indicating whether the target is valid and any errors if it is not.
Perform type checking on the given data, which can be any json object or array. Can be used to validate input to a context (e.g. from an HTTP request body).
the target to check types for.
the result of the type check, indicating whether the target is valid and any errors if it is not.
Coerce input data into types acceptable to the known types (as far as possible). Input data can only be a json object but can contain arrays. Can be used to coerce input to a context (e.g. from an HTTP request body). N.B. Unknown keys (i.e. wihout registyered type definitions) will be passed on without coercion. N.B. Recommended to use ONLY after validating input.
the input data to coerce.
a deep clone of the input data, with values mutated as necessary to suite declared types.
Indicates whether the type checker should enforce strict syntax validation. When true, the type checker will validate that all rules and expressions conform to expected syntax, potentially throwing errors if syntax is invalid. This can be used to catch issues early in development.
Indicates whether the type checker should enforce strict input validation. When true, the type checker will validate that all required input data for rules and expressions are defined and conform to expected types, potentially throwing errors if inputs are missing or incorrectly typed.
Indicates whether the type checker should enforce strict output validation. When true, the type checker will validate that all output data for rules and expressions are defined and conform to expected types, potentially throwing errors if outputs are missing or incorrectly typed.
Check if the type checker knows the type of the given key. Nested keys can be checked using dot notation (e.g., "user.name").