MongoDB provider for zod-dbs, a tool that generates Zod schemas from database schemas. Version 1.0.5 requires `mongodb` (>=5) peer dependency. It introspects a MongoDB database (sampling documents) to infer schema types and generate type-safe Zod validation schemas. Key differentiator: works with existing MongoDB databases to produce TypeScript-first schemas without manual definition. Release cadence is low; the package is in early stages. Enum types are not yet supported.
npm install zod-dbs-mongodbNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Generates Zod schemas from a MongoDB database using environment variables for credentials.
Add enum fields to schemas manually after generation or use hooks.
Increase sample size via --sample-size or config.sampleSize.
Manually install mongodb with npm install mongodb.
Use import statement or configure ESM (type: module in package.json).
Run npm install mongodb.