db-migrate

Execute Medusa CLI database migrations and report applied changes.

2|Updated Mar 29, 2026
One-click install
npx skills add https://github.com/NagyVikt/codex-plugins --skill db-migrate-nagyvikt
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: db-migrate
Source: https://github.com/NagyVikt/codex-plugins/tree/main/plugins/medusa/skills/db-migrate
Command: npx skills add https://github.com/NagyVikt/codex-plugins --skill db-migrate-nagyvikt

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill resolves the friction of manually managing database schema updates in Medusa projects, ensuring your local or development environment stays synchronized with the latest code changes.

Core Features & Use Cases

  • Automated Migration Execution: Triggers the Medusa CLI to apply pending database migrations safely.
  • Status Reporting: Provides immediate feedback on the number of migrations applied and surfaces any potential errors.
  • Use Case: After pulling the latest code from a repository that includes new entity definitions, use this skill to update your database schema without leaving your development environment.

Quick Start

Run the db-migrate skill to apply all pending database migrations to your current Medusa project.

Frequently Asked Questions about db-migrate

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

FAQPage Schema
How do I apply pending database migrations in a Medusa project?

Running database migrations in Medusa requires the Medusa CLI tool and a configured database connection to execute schema updates. The process targets development and staging workflows requiring automated schema synchronization and error reporting.

Do I need the Medusa CLI tool to run database migrations?

Yes, applying Medusa database migrations requires the Medusa CLI tool and a configured database connection to function correctly. These prerequisites allow the system to execute schema updates and report any potential errors during the process.

When do I need to run database migrations for my Medusa backend?

You need to run database migrations when your Medusa project has pending schema updates, typically after pulling repository code with new entity definitions. This synchronizes your development or staging database schema with the latest application requirements.

What is the best way to automate database schema updates for Medusa?

Automating Medusa database schema updates involves triggering the Medusa CLI to safely apply pending migrations and provide immediate status reporting. This approach targets development and staging workflows requiring automated schema synchronization and error reporting.

Why are my Medusa database migrations not working?

Medusa database migrations fail when the Medusa CLI tool is missing or the database connection is improperly configured. The skill surfaces potential errors during execution, requiring both elements to function correctly for successful schema synchronization.