Seed

by get-convex6ca54f6e2e75No licenseListed Oct 8, 2026Updated Oct 8, 2026

Seed the Convex database with starter/fixture data or import an existing dataset (CSV/JSON). TRIGGER when the user wants sample/seed data or to import a dataset into Convex. Idempotent, schema-matching.

Instructions onlySoftware Development
AI-generated overview

Seeds a Convex database with fixture data or imports CSV/JSON datasets idempotently.

What it does
This skill guides populating Convex database tables with starter or fixture data, either by writing an internalMutation that inserts sample rows or by bulk importing an existing CSV/JSON dataset with npx convex import. It covers shaping data to match the schema validators, making seeding idempotent through clear-then-insert or upsert, and verifying row counts. It also warns against seeding secrets or PII into a shared deployment.
When to use it
Use it when a user wants sample or seed data in a Convex project, or wants to import an existing dataset into Convex. It fits setup and fixture-loading tasks where re-runnable, schema-matching inserts are needed.
Requirements
A Convex project with a defined schema and the Convex CLI (npx convex run, npx convex import). No scripts ship with the skill; it is instructions only.

Seed / import data

Populate tables via an internalMutation seed function (re-runnable) or npx convex import, matching the schema.

Steps

  1. For fixtures: write an internalMutation that inserts sample rows; run it with npx convex run.
  2. For bulk import: shape the data to the schema and use npx convex import.
  3. Make seeding idempotent (clear-then-insert or upsert) so re-running is safe.
  4. Verify row counts.

Rules

  • Seed via internalMutation or convex import, matching validators.
  • Make seeding idempotent.
  • Never seed secrets/PII into a shared deployment.

Source and attribution

Source:get-convex/convex-backend-skillinskills/seedat commit6ca54f6

License: No license

Content belongs to its original authors. SourceWeft indexes it from a public repository.

Report or request removal