convex-migrate
What it does
This skill updates the database structure of a Convex app that already has real data. It is for builders who need to change a table without breaking the live app.
When to use it
- ✓When you want to add a required field to a table that already has records.
- ✓When you need to rename, change or split a field in a live app.
- ✓When you need to fill in missing values for old records before tightening a rule.
Skill link
https://github.com/openclaw/clawhub/blob/main/.agents/skills/convex-migrate/SKILL.mdCopy it and paste it into your AI (Claude, ChatGPT or Cursor), asking it to follow the instructions.
How to use
The easiest way: copy the message and paste it into your AI. It reads the skill and follows the instructions.
Ready-to-paste message
For Claude Code, Codex or Cursor: run it in your project folder and the skill gets installed.
Download the SKILL.md and drop it into your agent’s skills folder.
Example of what to ask your AI
“Add a required email field to my users table without breaking the users I already have.”
5 new skills a week. 1 minute to read.
How it works
The agent first makes the new field optional, installs the migration library, writes a step that fills in old records, runs it, checks the counts, and only then makes the field required.
Technical content (original SKILL.md)
Original text by the author, straight from GitHub.
Migrate the schema / data on a live app
Change a deployed schema without breaking existing data: stage the schema change, install @convex-dev/migrations, write a backfill that makes old rows valid, run it, and verify before tightening the validator.
Workflow
- Make the new field optional first (so deploy doesn't reject existing rows).
- Install @convex-dev/migrations; write a migration that backfills/transforms existing rows.
- Run the migration; verify all rows are valid.
- Tighten the validator (make the field required) once the backfill is complete.
Rules
- Never tighten a validator before the backfill completes — it rejects existing rows and breaks the live app.
- Add new fields as optional first, migrate, then require.
- Verify row counts before and after.
FAQ
Why not make the field required right away?
Existing records would fail the new rule and break the live app.
How does the agent know the migration worked?
It compares row counts before and after, and checks that all rows are valid before tightening the rule.
Which library does it use?
It uses the Convex migrations library, which runs changes in batches while the app keeps working.
Details
Original description by the author
Migrate schema + backfill data on a deployed Convex app using @convex-dev/migrations.
repo: openclaw/clawhub
Popularity
- GitHub stars
- 9.5k
- Ranking position
- #12249
- License
- MIT
- Updated
- 11/2/2026
Comments
- …
More skills from this repository
axiom-alerting
9.5kHelps your agent create and manage Axiom monitors and notification routes through the Axiom API, and check that alerts behave as expected.
axiom-sre
9.5kHelps your agent investigate production incidents and bugs step by step, testing each guess against Axiom logs before drawing a conclusion.
building-dashboards
9.5kHelps your agent design Axiom dashboards with fitting charts, queries and filters, starting from the decisions the dashboard must support.
controlling-costs
9.5kHelps your agent find unused data in Axiom and build dashboards and monitors that track and cut logging costs.
Similar skills
api-connector-builder
280kHas your agent build new API connections following the existing pattern. Use when you need to add one more integration without creating a new way of doing things.
api-design
280kHelps your agent design REST APIs following best practices. It's useful for defining how APIs communicate, how errors are shown, and how to organize data.
backend-patterns
280kHelps your agent with server-side architecture patterns and database optimization. It's useful for building or reviewing code that runs on the server.