prisma-next db schema
Inspect a live database schema.
prisma-next db schema reads the live database schema and prints it. The command is read-only.
Use it when you need to inspect what Prisma Next sees in the database before inferring, signing, updating, or debugging drift.
Usage
prisma-next db schema --db "$DATABASE_URL"Options
| Option | What it does |
|---|---|
--db <url> | Connects to the database. |
--config <path> | Reads a specific prisma-next.config.ts file. |
--json | Prints machine-readable schema output. |
Examples
prisma-next db schema --db "$DATABASE_URL"
prisma-next db schema --db "$DATABASE_URL" --json > schema.jsonRelated commands
Use prisma-next contract infer when you want to turn a live schema into a starter PSL contract. Use prisma-next db verify when you want to compare the live schema with the emitted contract.