# Manage Prisma ORM Workflows

Prisma CLI workflows can be difficult to apply safely across development and production. This skill provides command guidance, options, examples, and environment-specific practices.

## Install

```bash
npx skillstore add prisma/prisma-cli
```

## Metadata

- Status: approved
- Slug: prisma-prisma-cli
- Version: 7.6.0
- Author version: 7.6.0
- Skillstore revision: r2
- Version status: valid
- Tree hash: 3d38f5fcc056c2fda76c85bc2486cf11a9d39c8e99eb950e14061f48a52c0165
- Author: prisma
- GitHub username: prisma
- License: MIT
- Repository: https://github.com/prisma/skills/tree/1a9f427e9fe2137298abbcc1a6f372db92e8c40d/prisma-cli
- Ref: ebdfe608f5de2b66ff37ab4af12af8ac4f5e8006
- Supported tools: Claude, Codex, Claude Code
- Audit status: complete
- Agent install advisory: allowed
- Manual install advisory: allowed
- Artifact signature: available
- Audit attestation: unavailable
- Human verification: not\_verified
- Risk factors: env\_access, external\_commands, filesystem
- Quality score: 70
- Public page: https://skillstore.pages.dev/skills/prisma-prisma-cli
- Manifest: https://skillstore.pages.dev/api/skills/prisma-prisma-cli/manifest

## Capabilities

- Guides project initialization and datasource provider selection with Prisma init.
- Explains Prisma Client generation, custom outputs, generators, and watch mode.
- Covers schema introspection, direct schema synchronization, seeding, and raw SQL execution.
- Documents development migrations, production deployment, drift checks, diffs, resets, and migration recovery.
- Provides guidance for local databases, Studio, validation, formatting, debugging, and MCP.

## Use Cases

- Start a Prisma project: Developers can select a datasource, initialize project files, configure environment loading, and generate Prisma Client.
- Prepare database changes: Database engineers can compare schemas, create migrations, inspect drift, and plan controlled deployment steps.
- Automate delivery checks: Platform engineers can validate schemas, inspect migration status, and apply reviewed migrations in CI environments.

## Prompt Templates

### Initialize a project

```
Set up Prisma for [database] in [runtime]. Explain generated files, environment configuration, and the first client generation step.
```

### Plan a schema change

```
Review this Prisma schema change: [change]. Propose a development migration workflow and identify possible data-loss risks before any command runs.
```

### Diagnose migration drift

```
Analyze this migration status and error: [details]. Explain likely drift causes, non-destructive checks, and recovery options.
```

### Design a production migration runbook

```
Create a production runbook for [deployment]. Include staging validation, backups, status checks, approval gates, deployment, rollback planning, and post-deployment verification.
```

## Limitations

- It covers Prisma ORM CLI workflows, not Prisma Compute deployments.
- Examples require project-specific paths, credentials, schemas, and runtime tools.
- It does not replace database backups, access controls, migration review, or recovery testing.
- Destructive commands can remove data and require explicit environment checks.

## Best Practices

- Confirm the active datasource and environment before any command that changes data.
- Review generated SQL and maintain a tested backup before production migrations.
- Use migrations for shared environments and reserve direct schema pushes for controlled development workflows.

## Anti Patterns

- Do not run reset, force-reset, or data-loss options against production databases.
- Do not place database connection strings directly in commands, logs, prompts, or source control.
- Do not mark failed migrations as resolved before reconciling the actual database state.

## Security Audit

- Audited at: 2026-07-23T17:24:13.784\+00:00
- Summary: The static alerts are false positives caused by Markdown backticks, standard Prisma environment configuration, relative project paths, and schema examples. No prompt injection, credential exfiltration, or hidden executable payload was found. A medium operational risk remains because quick references include destructive database commands without mandatory confirmation or target checks.

## Stats

- Views: 0
- Downloads: 5
- Favorites: 0
- Popularity score: 0
