prisma-cli

Reference Prisma ORM CLI commands for migrations, client generation, and database workflows.

1|Updated Jun 5, 2026
One-click install
npx skills add https://github.com/sristigupta04/Airbnb-app --skill prisma-cli-sristigupta04
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: prisma-cli
Source: https://github.com/sristigupta04/Airbnb-app/tree/main/Full-stack/.agents/skills/prisma-cli
Command: npx skills add https://github.com/sristigupta04/Airbnb-app --skill prisma-cli-sristigupta04

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Developers working with Prisma ORM need accurate, current guidance on CLI commands like init, generate, migrate, db push, and studio, including correct flags, configuration via prisma.config.ts, and safe handling of destructive operations. ## Core Features & Use Cases - Command Reference: Covers the full Prisma ORM CLI surface including init, generate, migrate dev/deploy/reset/status/diff/resolve, db pull/push/seed/execute, dev, studio, validate, format, debug, complete, and mcp. - AI Safety Checkpoint: Documents the consent workflow required before destructive commands like migrate reset or db push --force-reset when an AI agent is detected. - Use Case: When setting up a new project, follow the init reference to scaffold prisma/schema.prisma and prisma.config.ts, then run migrate dev and generate to produce a typed Prisma Client. ## Quick Start Ask the assistant to show how to create and apply a named Prisma migration for your current schema changes.

Frequently Asked Questions about prisma-cli

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

FAQPage Schema
How do I create and apply a Prisma migration in development?

Run prisma migrate dev --name your_migration_name to generate and apply a migration from schema changes. It uses a shadow database for drift detection, and you should run prisma generate afterward to refresh the client.

What is the difference between prisma db push and prisma migrate dev?

db push syncs the schema directly without creating migration files or history, making it suited for prototyping and MongoDB. migrate dev creates tracked migration files with rollback capability, making it the right choice for team development and production-bound changes.

How do I apply Prisma migrations in production or CI/CD?

Use prisma migrate deploy, which applies pending migrations without prompts or a shadow database, making it safe for CI/CD pipelines. Run prisma migrate status first to verify the database state before deploying.

Why is prisma migrate reset blocked when run by an AI agent?

Prisma detects AI agent environments and blocks destructive commands like migrate reset and db push --force-reset until the user gives explicit consent. The agent must explain the data-loss impact and pass the exact consent text via PRISMA_USER_CONSENT_FOR_DANGEROUS_AI_ACTION.

Does Prisma CLI work with Bun runtime?

Yes, but you must add the --bun flag, for example bunx --bun prisma generate. Without it, the CLI falls back to Node.js because of the CLI shebang.

When should I not use prisma db push?

Avoid db push in production, in team environments needing trackable changes, and whenever you need rollback capability. Use migrate dev and migrate deploy instead, since db push creates no migration history.