Get started
This page takes you from nothing to a validated file. You’ll install docmeta (or skip install entirely), validate one document, and learn to read both a passing and a failing result — including the summary line that CI watches.
Before you start
Section titled “Before you start”docmeta runs on Node.js 20 or newer. Check your version:
node --versionIf that prints v20 or higher, you’re ready.
Install and validate
Section titled “Install and validate”-
Get docmeta.
You have two options. For a quick try or a one-off CI step,
npxruns the latest version without installing anything. For day-to-day local use, install it globally.Terminal window npx docmeta validate path/to/your-doc.mdTerminal window npm install -g docmetadocmeta validate path/to/your-doc.md -
Validate a file.
Point docmeta at any Markdown file. With no schema configured, it validates the file’s YAML frontmatter against the built-in OKF schema, which requires a
typefield and recommends a handful of others.Terminal window docmeta validate path/to/your-doc.md
Read a passing result
Section titled “Read a passing result”A file whose frontmatter satisfies the schema passes. Given a document like this:
---type: concepttitle: A Valid Documentdescription: A single-sentence summary of this concept.timestamp: 2026-06-25T10:00:00Z---
# A Valid Document
Body content goes here.docmeta prints a green check and a summary:
✓ path/to/your-doc.md
1 file checked, 1 passed, 0 failed, 0 errorsThe ✓ marks each file that passed. docmeta exits with code 0, which CI reads
as success.
Read a failing result
Section titled “Read a failing result”Now remove the type field. docmeta marks the file with a red ✗ and lists
every problem it found:
✗ path/to/your-doc.md (root) must have required property 'type' [google:okf:0.1]
1 file checked, 0 passed, 1 failed, 1 errorEach error line names the field, what’s wrong, the line (when docmeta
can locate it), and the schema that flagged it, in brackets. Here (root)
means the problem is with the document as a whole rather than one field — the
required type is missing entirely, so there’s no line to point at. When the
fix isn’t obvious, the Fix a failing check page decodes every part of
this line.
Read the summary line
Section titled “Read the summary line”Every run ends with one summary line. CI and humans both read it at a glance:
N files checked, M passed, K failed, E errors| Field | Meaning |
|---|---|
N files checked |
How many files docmeta resolved and validated. |
M passed |
Files with no errors. |
K failed |
Files with at least one error. |
E errors |
Total errors across all files — a single file can contribute several. |
A run is green only when K failed is 0. The exit code follows: 0 when
nothing failed, 1 when one or more files failed validation. (A third code,
2, signals an operational problem such as a missing schema or no files to
check — see Fix a failing check for those.)
What docmeta is — and isn’t
Section titled “What docmeta is — and isn’t”docmeta is a metadata gate. It confirms that the structured data attached to
your documents is present and correctly formatted, according to a schema you
control. It is not a linter for your writing, a link checker, or a renderer. If
your schema requires a type and a valid timestamp, that’s what docmeta
enforces — no more, no less.
Next steps
Section titled “Next steps”You’ve validated one file by hand. To make this a standing guarantee for your whole repo, add a config file and a schema, then wire it into CI.