---
url: /docs/api/core/variables/toleranceViolationSchema.md
---
[**@kaiord/core**](../README.md)

***

[@kaiord/core](../README.md) / toleranceViolationSchema

# Variable: toleranceViolationSchema

> `const` **toleranceViolationSchema**: `ZodObject`<{ `actual`: `ZodNumber`; `actualValue`: `ZodOptional`<`ZodString`>; `deviation`: `ZodNumber`; `expected`: `ZodNumber`; `expectedValue`: `ZodOptional`<`ZodString`>; `field`: `ZodString`; `tolerance`: `ZodNumber`; }, `$strip`>

Defined in: [packages/core/src/domain/validation/tolerance-checker.ts:31](https://github.com/pablo-albaladejo/kaiord/blob/3eacbe62ef72342d970523967cc5155b5935bb85/packages/core/src/domain/validation/tolerance-checker.ts#L31)

A round-trip drift. `tolerance` 0 marks a value that must match exactly
(a count, a zone). A categorical mismatch (a duration type, a target unit)
carries `expectedValue`/`actualValue`; its numeric fields are then the
fixed sentinel `expected 0, actual 1, deviation 1, tolerance 0`.
