Back to Skills

db-migrate

Run database migrations in Medusa

192stars22forksUpdated 7/1/2026

Security Assessment

Safe(100/100)
Security Score100/100

About db-migrate

Runs pending database migrations for a Medusa project. It is a focused operational helper that executes the Medusa migration command and reports the outcome, intended for use when a Medusa application has schema changes waiting to be applied to its database.

Operationally, it uses the Bash tool to run npx medusa db:migrate, which applies any pending migrations. The skill is scoped with an allowed-tools restriction of Bash(npx medusa db:migrate:*), keeping its execution narrowly limited to that migration command family.

After running, it reports the migration results back to the user, including the number of migrations applied, any errors that occurred, and a success confirmation. Because the doc is minimal, it does not describe additional flags, rollback behavior, or configuration beyond invoking the single migrate command; use it whenever you need to bring a Medusa database up to date with the latest schema and get a concise report of what happened.

FAQ

What command does this skill run?

It uses the Bash tool to execute npx medusa db:migrate, which applies pending migrations.

What does it report after running?

It reports the number of migrations applied, any errors that occurred, and a success confirmation.

When should I use it?

Use it to apply pending database migrations in a Medusa project so the database schema is brought up to date.

Which tools is it allowed to use?

It is restricted to Bash(npx medusa db:migrate:*), limiting it to the Medusa migrate command.

Does it support rolling back migrations?

The documentation only describes applying pending migrations with db:migrate and does not mention rollback behavior.

Install db-migrate

Download and extract the skill files to your .claude/skills/ directory.

Quick Setup:

  1. Copy the skill folder to .claude/skills/
  2. Claude will automatically detect and use the skill