Synopsis
Description
dms validate checks DMS JSON records against the official schema using the JSON Schema Draft 2020-12 validator. It reports:
- Errors — schema violations that make the record invalid (missing required fields, wrong types, disallowed enum values, etc.).
- Warnings — recommended fields that are absent (
creator,date,subject,location,rights,source,format). Warnings do not affect the exit code.
FILE to validate one record, or use --dir to validate every .json file found in a directory.
Options
Path to a single
.json file to validate. Optional when --dir is used.Directory containing
.json files. All files are validated and a batch summary is printed at the end.Exit codes
| Code | Meaning |
|---|---|
0 | All validated records are valid. |
1 | One or more records are invalid, or neither FILE nor --dir was provided. |
The non-zero exit code on failure makes
dms validate safe to use in CI pipelines. Any invalid record will fail the pipeline step.