prisma-upgrade-v7

Migrates Prisma ORM projects from v6 to v7 across all breaking changes.

Updated Aug 21, 2026
One-click install
npx skills add https://github.com/Rithika135/watchtower-360 --skill prisma-upgrade-v7-rithika135
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: prisma-upgrade-v7
Source: https://github.com/Rithika135/watchtower-360/tree/main/watchtower360-backend/.windsurf/skills/prisma-upgrade-v7
Command: npx skills add https://github.com/Rithika135/watchtower-360 --skill prisma-upgrade-v7-rithika135

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Upgrading from Prisma ORM v6 to v7 introduces breaking changes around the new prisma-client generator, mandatory driver adapters, prisma.config.ts, explicit environment loading, and new generated client entrypoints, and this Skill guides the full migration without missing any step. ## Core Features & Use Cases - Step-by-step migration path: Covers package updates, ESM or CommonJS module format selection, tsconfig changes, schema generator block updates, and prisma.config.ts creation. - Driver adapter setup: Provides installation and configuration for PostgreSQL, MySQL, SQLite, SQL Server, Neon, PlanetScale, Turso, D1, and Prisma Postgres adapters, including pool and SSL settings. - Removed feature replacements: Shows how to replace $use middleware with Client Extensions, Prisma.validator with TypeScript satisfies, and removed CLI flags with explicit commands. - Use Case: A backend project on Prisma 6 fails after upgrading packages with "Cannot find module" errors; follow the schema-changes and driver-adapters references to fix the generator output path, install @prisma/adapter-pg, and update client instantiation. ## Quick Start Ask the AI to upgrade your project to Prisma 7 and walk through the generator, driver adapter, and prisma.config.ts changes step by step.

Frequently Asked Questions about prisma-upgrade-v7

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I upgrade Prisma from v6 to v7?

Update @prisma/client and prisma to version 7, switch the generator provider to prisma-client with an explicit output path, create prisma.config.ts, install a driver adapter for your SQL database, update PrismaClient imports and instantiation, then run prisma generate.

What driver adapter should I use with Prisma 7?

Prisma 7 requires a driver adapter matching your database: @prisma/adapter-pg for PostgreSQL, @prisma/adapter-mariadb for MySQL, @prisma/adapter-better-sqlite3 for SQLite, and dedicated adapters for Neon, PlanetScale, Turso, D1, and SQL Server.

Does Prisma 7 support MongoDB?

No, Prisma 7 has no MongoDB connector and no MongoDB driver adapter. MongoDB projects should stay on the latest Prisma 6.x release or migrate to Prisma Next instead of following the v7 SQL migration path.

Can I use Prisma 7 with CommonJS instead of ESM?

Yes, Prisma 7 is ESM-first but supports CommonJS by setting moduleFormat = "cjs" in the generator block. Keep your app as CommonJS and regenerate the client instead of forcing an ESM conversion.

Why does Prisma 7 not load my .env file automatically?

Prisma 7 removed automatic environment variable loading, so you must install dotenv and add import 'dotenv/config' as the first line of prisma.config.ts. Bun users are exempt because Bun loads .env files automatically.

How do I replace Prisma.validator in Prisma 7?

The prisma-client generator no longer exposes Prisma.validator, so use TypeScript's satisfies operator instead. Write your select or include object literal followed by satisfies Prisma.UserSelect or the equivalent generated type.