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

# tai db

> Apply and inspect the database schema.

Apply and inspect the database schema.

```console theme={null}
$ tai db [OPTIONS] COMMAND [ARGS]...
```

## `tai db apply`

Apply the bundled DDL to Postgres. Idempotent; loud on a connection failure.

```console theme={null}
$ tai db apply [OPTIONS]
```

| Option                 | Description                            |
| ---------------------- | -------------------------------------- |
| `--json` / `--no-json` | Emit raw JSON instead of human tables. |

## `tai db check`

Verify DB connectivity and that every expected framework table exists.

```console theme={null}
$ tai db check [OPTIONS]
```

| Option                 | Description                            |
| ---------------------- | -------------------------------------- |
| `--json` / `--no-json` | Emit raw JSON instead of human tables. |
