Open-Source Wikis

/

Prisma

/

Packages

/

Other packages

prisma/prisma

Other packages

Smaller or thinner workspace packages, grouped here rather than each getting a dedicated page. The bigger ones already have their own pages — see Packages.

Driver adapter foundation

driver-adapter-utils

packages/driver-adapter-utils defines every type a driver adapter implements: SqlQuery, SqlQueryable, SqlDriverAdapter, SqlDriverAdapterFactory, SqlMigrationAwareDriverAdapterFactory, Transaction, MappedError, ConnectionInfo, and the Provider union ('mysql' | 'postgres' | 'sqlite' | 'sqlserver'). It also provides shared helpers used across adapters (e.g., parameter coercion). See Driver adapters for how it ties everything together.

bundled-js-drivers

packages/bundled-js-drivers re-exports specific bundled versions of underlying drivers (pg, mysql2, mssql, etc.) so that Prisma's own bundles can pin against known-good driver versions. Consumed by the build pipeline; not user-facing.

Client foundation

client-common

packages/client-common holds shared utilities that both the client runtime and the generators use. From AGENTS.md:

@prisma/client-common provides shared client utilities used by both generators and runtime.

client-runtime-utils

packages/client-runtime-utils provides utility types and singletons used inside generated clients, e.g., the Decimal re-export and other small helpers. Per AGENTS.md: "utility types and singletons for Prisma Client".

client-generator-registry

packages/client-generator-registry is the lookup table for client generators. When the CLI invokes prisma generate, it asks this package which generator backs the provider declared in the schema. Both prisma-client (TS generator) and prisma-client-js (JS generator) register here.

ts-builders

packages/ts-builders is a fluent API for building TypeScript syntax — interfaces, types, properties (with doc comments), function signatures. Both client generators rely on it. Cleaner than templating strings and gives generators a single point to control output formatting.

Schema and DMMF

dmmf

packages/dmmf defines the DMMF (Datamodel Meta Format) types — the JSON AST representation of a Prisma schema. Documented as internal: no stability guarantees across minor versions. Consumed by the generators.

get-dmmf

packages/get-dmmf is a small wrapper that calls into @prisma/prisma-schema-wasm to compute a DMMF AST from a schema. Most callers go through @prisma/internals.getDMMF instead, which delegates here.

schema-files-loader

packages/schema-files-loader handles multi-file Prisma schemas (split across multiple .prisma files in a directory). It assembles the schema into a single textual representation for the parser, deduplicating imports and respecting include rules.

Generators

generator-helper

packages/generator-helper defines the IPC contract that external (third-party) generators speak. They run as subprocesses and exchange JSON-RPC over stdio with the CLI. Use this if you're shipping a generator outside of prisma/prisma.

generator

packages/generator is a higher-level scaffold for writing generators. It builds on generator-helper with conveniences for the common cases.

Engine plumbing

fetch-engine

packages/fetch-engine does the actual download/cache logic for engine binaries, including the enginesOverride mechanism for development. See Engines for the override flow. Also home to the branch / folder override fields that pnpm install consumes.

get-platform

packages/get-platform detects the host platform (Linux, macOS, Windows, plus libc variants and CPU architectures) so the right engine binary can be picked.

Observability

debug

packages/debug is a thin wrapper around the upstream debug package, providing a Debug(namespace) constructor used across the codebase. Enabled at runtime with DEBUG=prisma:* etc.

instrumentation

packages/instrumentation is the OpenTelemetry instrumentation for Prisma Client. Users register it as @prisma/instrumentation to get auto-instrumented spans around PrismaClient operations.

instrumentation-contract

packages/instrumentation-contract defines the contract between the client runtime and the OTel instrumentation. Decoupling lets the client emit spans without taking a hard dependency on @opentelemetry/api.

json-protocol

packages/json-protocol defines JSON wire format types used by the client and server-side execution. Its content overlaps with @prisma/client-engine-runtime/src/json-protocol.ts and the two are kept in sync; this package is the public-facing entry.

Internals

credentials-store

packages/credentials-store provides a small abstraction over Prisma's local credential storage (used for cloud-related features like Prisma Accelerate sign-in). Tests live in this package; usage is in packages/cli/src/platform/.

param-graph and param-graph-builder

packages/param-graph and packages/param-graph-builder model parameter dependency graphs (used by query planning to track placeholder reuse). Internal to the Wasm execution stack.

nextjs-monorepo-workaround-plugin

packages/nextjs-monorepo-workaround-plugin is a Webpack plugin that fixes Next.js's tendency to mis-resolve Prisma engine binaries in monorepo setups. Single-file workaround that ships as its own package because Next.js users want to install only this plugin.

bundle-size

packages/bundle-size is the test infrastructure that the bundle-size GitHub Action consumes. It contains worker projects for several driver adapters that are bundled into output artifacts whose size is tracked.

type-benchmark-tests

packages/type-benchmark-tests measures TypeScript type-check time for generated clients against representative schemas. Has a special turbo task config (@prisma/type-benchmark-tests#dev outputs **/generated).

integration-tests

packages/integration-tests is the home of cross-provider integration coverage — the SQL scenarios that don't fit naturally inside the client package. See Testing for how it's run.

CI workflow inputs that map to per-package tests

.github/workflows/test-template.yml partitions packages into test jobs:

Job Packages
others (Linux) debug, generator-helper, get-platform, fetch-engine, engines, instrumentation, instrumentation-contract, schema-files-loader, config, dmmf, generator, credentials-store, sqlcommenter-*
client-packages client-common, client-engine-runtime, ts-builders, client-generator-js, client-generator-ts, client-generator-registry
driver-adapter-unit-tests adapter-libsql, adapter-mariadb, adapter-d1, adapter-pg, adapter-planetscale, adapter-mssql, adapter-neon
no-docker (Windows/macOS) mirrors others and client-packages

When you add a new package with tests, edit test-template.yml to assign it to the right job.

See also

Built by Factory AutoWiki from public repository content. It is a generated preview for codebase exploration, not source-maintained documentation.

Other packages – Prisma wiki | Factory