Prisma ORM 8 is here.Read the docs

contract emit

Emit Prisma ORM contract artifacts.

contract emit reads your contract source (TypeScript or Prisma schema) and writes the generated artifacts used by the runtime, verification, and migration tooling.

The command is offline. It does not need a database connection.

Usage

bunx prisma@latest contract emit

Options

OptionWhat it does
--output-path <dir>Writes contract.json and contract.d.ts into a specific directory.
--config <path>Read this config file instead of ./prisma.config.ts.
--jsonPrints a machine-readable result.

What it creates

The command emits:

  • contract.json, the canonical machine-readable contract
  • contract.d.ts, the generated TypeScript contract declarations

Do not edit these files by hand. Re-run contract emit after changing the contract source or extension pack list.

Examples

bunx prisma@latest contract emit
bunx prisma@latest contract emit --output-path ./generated
bunx prisma@latest contract emit --json

Next steps

After emitting, choose the database workflow:

On this page