prisma-upgrade-v7

Migrates Prisma ORM projects from v6 to v7 across schema, adapters, and configuration.

2|Updated Aug 11, 2026
One-click install
npx skills add https://github.com/MahdiaMayati/spotlight --skill prisma-upgrade-v7-mahdiamayati
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: prisma-upgrade-v7
Source: https://github.com/MahdiaMayati/spotlight/tree/main/spotlight-backend/.windsurf/skills/prisma-upgrade-v7
Command: npx skills add https://github.com/MahdiaMayati/spotlight --skill prisma-upgrade-v7-mahdiamayati

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 you through each migration step without missing critical changes. ## Core Features & Use Cases - Schema and Generator Migration: Switch from prisma-client-js to the prisma-client generator with required output paths, module format options, and new client/browser/models/enums entrypoints. - Driver Adapter Setup: Install and configure required adapters for PostgreSQL, MySQL, SQLite, Neon, SQL Server, and Prisma Postgres, including pool and SSL settings. - Configuration Modernization: Create prisma.config.ts, load environment variables explicitly with dotenv, and replace removed features like middleware, metrics, and Prisma.validator. - Use Case: You upgrade a Node.js API to Prisma 7 and hit "Cannot find module" errors; follow the reference guides to fix the generator output path, add the PrismaPg adapter, and regenerate the client. ## Quick Start Ask the assistant to upgrade your project to Prisma 7 and walk through the schema, 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 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 instantiate PrismaPg with your connection string and pass it to PrismaClient via the adapter option. Prisma Postgres in standard Node.js apps uses the same adapter.

Does Prisma 7 support MongoDB?▼

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

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

Prisma v7 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 model type.

Can I use Prisma Accelerate with driver adapters in v7?▼

No, driver adapters expect direct database connection strings and fail with prisma:// or prisma+postgres:// URLs. Instead, pass the Accelerate URL via accelerateUrl on PrismaClient and apply the withAccelerate extension.