> ## Documentation Index
> Fetch the complete documentation index at: https://repost.sh/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# repost schema validate

> Parse and validate the schema without writing anything. Errors fail; warnings don't.

`repost schema validate` checks that your schema parses and satisfies every rule, and writes nothing. Errors render to stderr and exit `1`; warnings render to stderr and still exit `0`, so the command works as a CI check without failing on advisories.

## Usage

```bash theme={"languages":{"custom":["/languages/repost.json"]}}
repost schema validate [options]
```

## Options

| Option            | Description                                                                                             |
| ----------------- | ------------------------------------------------------------------------------------------------------- |
| `--schema <path>` | A `.repost` file or a directory of them. Defaults to `./repost/schema.repost`, else `./repost/schema/`. |

## Examples

```bash theme={"languages":{"custom":["/languages/repost.json"]}}
repost schema validate
```

```text theme={"languages":{"custom":["/languages/repost.json"]}}
The schema at repost/schema.repost is valid.
```

With warnings, the count is appended (`is valid (1 warning).`) and the warnings themselves print to stderr. On an error, the diagnostic names the file and the offending field, and the command exits `1`.

## Continue

<Columns cols={3} className="gap-y-4">
  <Card title="fmt" icon="align-left" href="/docs/cli/schema/fmt" cta="Format" arrow="true">
    The companion formatter, with its own CI mode.
  </Card>

  <Card title="generate" icon="cog" href="/docs/cli/schema/generate" cta="Generate" arrow="true">
    Validation runs as its first step.
  </Card>

  <Card title="Defining events" icon="braces" href="/docs/send/schema" cta="Schema" arrow="true">
    The rules this command enforces.
  </Card>
</Columns>
