Skip to main content
Glama

ohmyho.st

Apply the saved migration files to a database

database_migrate
Idempotent

Apply the migration files at commit_sha to the project's selected Dev or Prod database, provisioning it if needed. Dev requires active Paid access. Prod and Dev with shared data require publication permission. Shared Dev and Prod use the same database. The job skips applied files, rejects edits to applied files and changes the database without building, deploying or publishing. Missing migrations, noncanonical filenames and missing database configuration are rejected before queuing. Returns an operation that starts within about a minute. A failed file is identified in error.migration. A job ending in database_migrate_unavailable leaves no partially applied file. Requires confirm: true.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "project_id": "<project_id>",
      "idempotency_key": "<idempotency_key>",
      "environment": "<environment>",
      "commit_sha": "<commit_sha>",
      "confirm": "<confirm>"
    },
    "name": "database_migrate"
  }
}

Input Schema

NameRequiredDescriptionDefault
confirmYes
commit_shaYesThe saved version whose migration files are applied.
project_idYesProject identifier.
environmentYes
idempotency_keyYesIdentifies one mutation and its canonical request payload.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the annotations (idempotentHint=true, destructiveHint=false), the description discloses that applied files are skipped, edits to applied files are rejected, missing/noncanonical migrations are rejected before queuing, no build/deploy/publish occurs, and a database_migrate_unavailable outcome leaves no partially applied file. It also gives latency expectation (~1 minute) and the error.migration field for failed files — behavior an agent cannot get from the annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Purpose is front-loaded, then prerequisites, then behavioral consequences, with essentially no filler sentences. The cost is a dense unbroken block of short clauses that is harder to scan than it needs to be, but every sentence conveys operative information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

There is no output schema and this is a mutation tool, yet the description still covers return semantics (a job starting within about a minute), failure identification (error.migration), and the no-partial-application guarantee for database_migrate_unavailable. Nothing material is missing for an agent to call this correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 60%, and the description compensates for the undocumented parameters: the explicit 'Requires confirm: true' covers the const-constrained confirm, and 'project's selected Dev or Prod database ... Shared Dev and Prod use the same database' explains the environment enum and its shared-database implication. commit_sha and idempotency_key meaning still comes mostly from the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The first sentence states a specific verb and resource ('Apply the migration files at commit_sha') plus scope ('the project's selected Dev or Prod database, provisioning it if needed'). An agent can distinguish this from sibling tools like database_query or database_write without opening any schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Prerequisites are spelled out concretely: Dev requires active Paid access, Prod and Dev-with-shared-data require publication permission, and confirm must be true. What's absent is explicit routing to alternatives (e.g., what to use instead when migrations are missing or when only a query is wanted), so it lands just short of a 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.