database-migration skill (wshobson) for Claude: safe schema changes
Gives your agent migration patterns for Sequelize, TypeORM and Prisma, with rollbacks and zero-downtime steps. For developers changing a live database.
- Installs
- 17.8K
- on skills.sh
- Stars
- 42.1K
- on GitHub
- Files
- 1
- besides SKILL.md
- Updated
- Oct 2026
- last repo commit
database-migration makes your agent write database migrations with worked examples for Sequelize, TypeORM and Prisma. It covers adding, renaming and retyping columns without downtime, moving data, and two rollback styles: a transaction and a backup-table checkpoint. A second file adds a five-phase blue-green style column swap and a Sequelize example that branches on the database dialect (MySQL JSON versus PostgreSQL JSONB).
It loads when you ask to migrate a database, change a schema or plan a zero-downtime release. It needs a project with one of those ORMs and a database to run migrations against. The examples include steps that drop columns and tables, so run them on a copy first.
Good for
- Developers writing schema migrations in Node.js ORMs
- Teams planning a zero-downtime column rename or type change
- Anyone adding rollback steps to risky data changes
Install database-migration
Claude Code
- 1
Copy this prompt.
Install the database-migration skill in Claude Code. Run this command: npx skills add https://github.com/wshobson/agents --skill database-migration Then check that it loaded and tell me how to use it.
- 2
Paste it into Claude Code. It shows the change and asks before running it.
Requires Node.js.
From its listing on skills.sh. Source.
What's in the skill
When it loads
Execute database migrations across ORMs and platforms with zero-downtime strategies, data transformation, and rollback procedures. Use when migrating databases, changing schemas, performing data transformations, or implementing zero-downtime deployment strategies.
Sections in SKILL.md
- When to Use This Skill
- ORM Migrations
- Sequelize Migrations
- TypeORM Migrations
- Prisma Migrations
- Schema Transformations
- Adding Columns with Defaults
- Renaming Columns (Zero Downtime)
- Changing Column Types
- Data Transformations
- Complex Data Migration
- Rollback Strategies
- Transaction-Based Migrations
- Checkpoint-Based Rollback
- Additional patterns and templates
Key facts
- Author
- wshobson
- License
- MIT
- Installs on skills.sh
- 17,806 (Nov 2, 2026)
- GitHub stars
- 42,081 for the whole repo (Nov 2, 2026)
- Last commit
- Oct 30, 2026
What it includes
Create-table examples with run and rollback commands
Shows a Sequelize, a TypeORM and a Prisma migration and the commands to apply or undo them.
Try: “Write a Prisma migration that adds a status column to users.”
Runs code ·
ORM migrationsSafe add with a default value and a down step
A migration that adds a required column with a default and removes it on rollback.
Write ·
Add a column with a defaultThree steps: add, switch the app, drop
Adds the new column and copies data, then the app switches over, then a later migration removes the old column.
Delete ·
Rename a column without downtimeAdd, copy and cast, drop, rename
A multi-step approach for large tables that avoids altering the column in place.
Delete ·
Change a column typeSplit an address string into columns
Reads rows, updates each one with the parsed parts, then drops the old column.
Delete ·
Transform dataWrap the change in a transaction
Commits on success and rolls back if anything fails.
Write ·
Transaction rollbackCopy the table first, restore on failure
Creates a backup table, runs the change, checks it, and drops the backup. On failure it drops the table and restores the copy.
Delete ·
Checkpoint rollbackExtra patterns in references/details.md
A five-phase zero-downtime column swap (add, dual-write, backfill, read from new, drop old) and a Sequelize example that picks MySQL JSON or PostgreSQL JSONB by dialect. It is not a full database-to-database migration guide.
Read ·
Blue-green and dialect example
From the official docs
Permissions
Medium risk
What it can do
- Read your data
- Create and change things
- Delete things
- Read-only mode
Watch out for
Migrations here can drop columns and tables
Several examples remove columns, and the checkpoint rollback drops and recreates the users table. Run them on a copy and back up first. github.com
The agent may run migration commands
Approve a migrate or rollback command only after checking which database the connection string points to. github.com
Technical details
| Sign-in and keys | Uses whatever database connection your project already has. |
|---|---|
| Scopes |
|
Questions
What does the database-migration skill do?
It gives your agent patterns for writing schema and data migrations in Sequelize, TypeORM and Prisma, with ways to avoid downtime and to roll back safely.
How do I install it in Claude Code, the Claude app or Codex?
Use the install box above. The wshobson/agents README documents installing a single skill with npx skills add or gh skill, and lists Claude Code and Codex plugin routes. It does not document a Claude app upload.
Does it need an API key?
No key is listed in the SKILL.md. The agent works with your project's ORM and database connection.
Is it safe to install?
The skill is instructions and examples, with no scripts. The migrations it helps write can drop columns and tables, so run them on a copy of your data first and keep a backup.
Does it run migrations for me?
The examples include run commands such as npx sequelize-cli db:migrate, npx prisma migrate deploy and npm run typeorm migration:run. Your agent may run them if you approve, so check which database your connection string points to.
Which ORMs does it cover?
Sequelize, TypeORM and Prisma, though most worked examples are Sequelize. The extra reference file has one Sequelize example that handles MySQL and PostgreSQL JSON column types.
Information
updated Nov 2, 2026
- Repository
- wshobson/agents
- Folder
plugins/framework-migration/skills/database-migration
Sources
Docs, issue trackers and discussions this page is built from.
Show all 3Hide
- database-migration SKILL.md · github.com
- database-migration details.md · github.com
- wshobson/agents README · github.com