DocsCLI

seedkit new

Generate data and provision a fresh ephemeral Postgres in one command.


Generates synthetic data and provisions a new ephemeral Postgres on Neon, returning a connection string. This is the "magic moment" command — most flows start here.

Synopsis

seedkit new [options]

Examples

Generate from a Prisma file:

seedkit new --schema schema.prisma

Generate from raw SQL DDL:

seedkit new --schema schema.sql

Generate from natural language:

seedkit new --prompt "a small SaaS CRM with orgs, users, deals, activities"

Generate, lock the seed name, and write DATABASE_URL to .env.local:

seedkit new --schema schema.prisma --seed my-fixture --env

Options

FlagTypeDefaultDescription
--schema <path>pathPrisma file, raw SQL DDL, or live:<connection-url> to introspect a running DB.
--prompt <text>stringNatural-language description. Used alone or as a hint alongside --schema.
--rows <n>numberautoTarget row count. Auto-scales by table importance when omitted.
--seed <name>stringrandomLock a name for the cache. Re-runs with the same name + schema replay byte-identically.
--scope <domain>enumnoneBias the LLM: b2b-saas, e-commerce, fintech-eu, fintech-us, healthcare-us, social, dev-tools.
--ttl <duration>durationtier-defaultDatabase lifespan. Free: 1h max. Pro: 24h. Team: 7d. Format: 60m, 12h, 3d.
--envflagoffWrite DATABASE_URL to .env.local (creates the file if needed).
--region <code>stringeu-central-1Neon region. EU-hosted by default.
--previewflagoffPrint sample rows; don't provision a DB or insert anything.
--resetflagoffIf the seed name already has a cached entry, force regeneration.

Cache behavior

Without --seed, every run is unique — fresh data, fresh cache key. With --seed, the cache key is sha256(schema + seed_name + generator_versions). Hits replay the cached SQL in seconds; misses regenerate and store under that key.

See Seed cache for the full hashing model.

Exit codes

  • 0 — success.
  • 2 — invalid arguments (e.g. --schema and --prompt both omitted).
  • 3 — schema parse failed.
  • 4 — generation failed (LLM upstream error; retryable).
  • 5 — provisioning failed (Neon upstream error; retryable).

See also