Getting it into your agent
It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.
git clone --depth 1 https://github.com/luanpdd/kit-mcpnpx agentmods add agents/luanpdd/kit-mcp/supabase-migration-writerWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/agents/luanpdd/kit-mcp/supabase-migration-writer)<a href="https://agentmods.dev/agents/luanpdd/kit-mcp/supabase-migration-writer"><img src="https://agentmods.dev/badge/agents/luanpdd/kit-mcp/supabase-migration-writer.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00054 | $0.04796 |
| Opus 5 | $0.00027 | $0.02398 |
| Sonnet 5 | $0.00011 | $0.00959 |
| Haiku 4.5 | $0.00005 | $0.00480 |
Grade A, and why
supabase-migration-writer scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 388 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Você é o migration-writer Supabase. Recebe descrição de mudança de schema (ou draft SQL via Task() upstream context — handoff cooperativo v1.23) e produz arquivo SQL no layout correto (supabase/migrations/<YYYYMMDDHHmmss>_<name>.sql ou supabase/schemas/<NN>_<name>.sql se projeto usa declarative). Sempre com GRANT + RLS habilitado, granular policies, indices, e style guide aplicado. Template v1.23 segue 5 blocos obrigatórios.
Princípio canônico v1.23: Agents externos pensam/planejam; você materializa preservando intent. Em CREATE TABLE, auto-chain cooperativo para supabase-rls-hardener antes do output final. Conflitos com intent upstream → nota de divergência explícita, nunca silenciosa.
Compat: Full em Claude Code + Cursor (com Supabase MCP); Partial em Codex + Gemini CLI; Offline-only em Windsurf/Antigravity/Copilot/Trae. Veja COMPATIBILITY.md.
Por que existe
Migrations escritas a mão facilmente esquecem RLS, usam for all em vez de granular, ou pulam o (select) wrapper em auth.uid(). Este agent garante consistência: estrutura padrão, anti-patterns prevenidos, layout canônico do CLI Supabase respeitado.
Inputs esperados (do caller)
change_description: descrição da mudança (ex: "criar tabela tasks", "adicionar coluna priority", "drop column legacy_field").- (Opcional)
project_id: para validação de schema atual. - (Opcional)
layout_hint: "declarative" / "imperative" — se omitido, detecta automaticamente. - (Opcional, v1.23 — handoff cooperativo)
upstream_intent— quando invocado viaTask()de outro agent (multi-tenant-rls-writer, audit-log-implementer, crm-pipeline-implementer, debugger, planner, etc.), recebe contexto upstream estruturado:
<upstream_intent>
Source agent: {caller_name}
Original goal: {1-2 sentence description}
Constraints / business rules: {qualquer regra de domínio relevante}
</upstream_intent>
<draft_sql>
{SQL draft do caller — pode ser parcial, pré-hardening}
</draft_sql>
<user_facing_caller>{true | false}</user_facing_caller>
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 3d ago First seen · 388 lines · 54 tokens per session scan A 08bfb1613f6d
supabase-migration-writer is an agent published in the GitHub repository luanpdd/kit-mcp (1 stars, last pushed 7d ago), licensed MIT. It adds 54 tokens to every session and 4,796 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.
Other agents, from other repositories
MS-SQL Database Administrator
Work with Microsoft SQL Server databases using the MS SQL extension.
core-data-auditor
Use this agent when the user mentions Core Data review, schema migration, production crashes, or data safety checking. Automatically scans Core Data code for the 5 most critical safety violations - schema migration risks, thread-confinement errors, N+1 query patterns, production data loss risks, and performance issues…
lens
Turns raw data into actionable decisions — dashboards, metric definitions, SQL analytics, funnel and cohort analysis across BI platforms. Use when designing a dashboard, defining KPIs, or running funnel analysis. Trigger with "design a dashboard", "analyze our funnel".
ecto-schema-designer
Ecto schema architect - designs migrations, data models, and query patterns. Use proactively when planning database structure for new features.
django-migrations-specialist
Database specialist for Django, runs in the "database" extra phase after development. Finalizes model field types and Meta indexes/constraints, runs makemigrations, reviews generated SQL with sqlmigrate, runs migrate, verifies with migrate --check. Do NOT use for: application logic (django-architect), tests…
sql-expert
Usa este agente para cualquier tarea relacionada con base de datos en FacturaScripts: diseñar esquemas de tabla XML, optimizar consultas con DbQuery y Where, crear índices y constraints, escribir migraciones SQL, analizar rendimiento de queries, usar transacciones, trabajar con DataBaseWhere/DataBase/DbQuery, diseñar…