Skip to content

Documentation / @facturometro/einvoice / Verdict

Type Alias: Verdict ​

Verdict = boolean | { at?: ModelPath; data?: Readonly<Record<string, string>>; }

Defined in: packages/validator/src/engine/rule.ts:33

What a rule's test returns: true passes, false fails at the context node, and an object fails with a refinement - at is a model path relative to the context node that points at the offending element, data carries the values that explain the failure.

Example ​

ts
import type { Verdict } from '@facturometro/validator';

const verdict: Verdict = { at: ['payableAmount'], data: { actual: '99.00', expected: '100.00' } };

MIT licensed. Specification artefacts belong to OpenPEPPOL, CEN and OASIS.