generate_migration
Generate dialect-correct ALTER TABLE migration SQL + rollback from a plain-English intent. Output uses the connection's exact dialect (ALTER TABLE for all three, plus pg-specific USING casts / mssql-specific sp_rename / mysql-specific MODIFY COLUMN). Never executes. Check response dialect field before manually editing — don't hand-translate across dialects. [BUILD tier]
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| intent | Yes | Plain English: 'add soft delete to drivers', 'add index on trips.driver_id' | |
| connection | No | Target connection name from this tenant's inventory. Call `list_connections` to see every name + dialect, then match semantically to the user's intent (e.g. 'analytics' → a connection named `*-analytics-*`; 'prod' → a connection with `prod-` prefix). If the user didn't specify, use the tenant's default (first added). Do not invent names — resolve from `list_connections` output. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| data | No | ||
| meta | No | ||
| display | No | ||
| summary | No | ||
| insights | No |