prisma-upgrade-v7

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

Updated Jul 9, 2026
One-click install
npx skills add https://github.com/DimonikRV/ghost-pilot-project --skill prisma-upgrade-v7-dimonikrv
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: prisma-upgrade-v7
Source: https://github.com/DimonikRV/ghost-pilot-project/tree/main/.agents/skills/prisma-upgrade-v7
Command: npx skills add https://github.com/DimonikRV/ghost-pilot-project --skill prisma-upgrade-v7-dimonikrv

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. This Skill provides a complete, step-by-step migration path so you avoid import errors, connection failures, and removed-feature regressions. ## Core Features & Use Cases - Schema and Generator Migration: Switch from prisma-client-js to the prisma-client generator with required output paths, ESM or CommonJS module formats, and new client/browser/models/enums entrypoints. - Driver Adapter Setup: Configure required adapters for PostgreSQL, MySQL, SQLite, Neon, SQL Server, and Prisma Postgres, including pool and SSL settings. - Config and Environment Migration: Create prisma.config.ts, load .env files explicitly with dotenv, and replace removed features like $use middleware, metrics, and Prisma.validator. - Use Case: Your Next.js app fails after running npm install prisma@7 with "Cannot find module" errors. Follow the skill to update the generator block, install @prisma/adapter-pg, create prisma.config.ts, and fix client imports. ## Quick Start Ask the AI to upgrade my project from Prisma 6 to Prisma 7 and fix all resulting errors.

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 such as @prisma/adapter-pg, update client imports, and run prisma generate.

What driver adapter do I need for Prisma 7 with PostgreSQL?▼

Install @prisma/adapter-pg along with the pg package, then pass a PrismaPg adapter instance with your connection string to the PrismaClient constructor. Driver adapters are required for all SQL providers in v7.

Does Prisma 7 support CommonJS projects?▼

Yes. Prisma 7 is ESM-first, but you can keep a CommonJS app by setting moduleFormat = "cjs" in the generator block and regenerating the client. This avoids forcing your whole project to ESM.

Can I use Prisma 7 with MongoDB?▼

No. There is no MongoDB driver adapter in Prisma 7.6.0, and MongoDB projects should remain on the latest Prisma 6.x release instead of following the v7 SQL migration path.

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

Prisma v7 removed automatic environment loading. Install dotenv and add import 'dotenv/config' as the first line of prisma.config.ts, or load variables explicitly in your application entry point.

How do I replace Prisma.validator in Prisma 7?▼

The prisma-client generator no longer exposes Prisma.validator. Use TypeScript's satisfies operator instead, for example defining a select object with satisfies Prisma.UserSelect for type-safe query fragments.