Models
Document Validation
Properties
| Name | Type | Required | Description |
|---|---|---|---|
result | valid | invalid | not_supported | error | Yes | valid: the document passed every rule that applies to it. invalid: at least one rule was violated; see errors. not_supported: no ruleset is available for this document type, so nothing was checked. error: the validation service could not be reached or its answer could not be read. Example: "valid". Values: valid, invalid, not_supported, error |
errors | object[] | Yes | The findings the validation produced. Empty when the document is valid, and also when the result is not_supported or error |
errors properties
| Name | Type | Required | Description |
|---|---|---|---|
ruleCode | string | null | No | The identifier of the rule that was violated, for example an EN 16931 or Peppol BIS business rule code. Null for findings that come from something other than a coded rule, such as a schema error. Example: "PEPPOL-EN16931-R010" |
errorMessage | string | Yes | What the rule expected, in the words of the ruleset that raised it |
errorLevel | string | Yes | How serious the finding is. Only findings the ruleset treats as errors make a document invalid. Example: "ERROR" |
fieldName | string | null | No | Where in the document the finding applies, usually as an XPath. Null when the finding is not tied to one place |
source | string | No | Which ruleset produced the finding, for example the syntax schema or a Peppol business rule set |