init_project
Creates a new backend project directory with Express.js, TypeScript strict mode, and your choice of ORM. Optionally use a preset to generate a full domain with pre-built resources and JWT auth.
Instructions
Creates a new backend project directory with Express.js + TypeScript strict mode, ORM data layer (Prisma/Drizzle/Mongoose), Zod env validation, Swagger docs, Docker, ESLint, Vitest, and a .backgenrc.json manifest. Run add_plugin afterwards to add auth, payments, storage, rate-limiting, or CI/CD. Run generate_resource to add CRUD modules. Use --preset to generate a full domain (healthcare/saas/ecommerce/crm/lms) with pre-built resources and auto-installed JWT auth in one command. Call list_presets first to see what each domain preset includes. Typical generation takes 10–30 seconds with npm install being the longest step.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Project name — used as the directory name and npm package name. Must start with a letter or number. Hyphens and underscores allowed. Examples: 'my-api', 'saas-backend', 'healthcare-api'. | |
| orm | No | Database ORM. prisma (PostgreSQL/MySQL/SQLite, recommended for relational), drizzle (lightweight SQL, closer-to-SQL control), mongoose (MongoDB, document-oriented). Defaults to prisma if not specified. | prisma |
| preset | No | Domain preset that generates multiple pre-wired resources in one command. Auto-installs JWT auth. Call list_presets first to see what each preset includes. Examples: 'saas-core' for multi-tenant orgs, 'healthcare' for patient/doctor/appointment. | |
| defaults | No | Use default options (non-interactive). Recommended for AI use and automation. Set to false only if you want to prompt the user for each choice interactively. | |
| skipInstall | No | Skip npm install. Use true for CI pipelines, quick scaffolding demos, or when you want to install dependencies later manually. When true, remind the user to run 'npm install' before 'npm run dev'. | |
| dir | No | Absolute or relative path to the parent directory where the project folder will be created. Defaults to the current working directory. Example: '/home/user/projects' or 'C:\Users\me\projects'. |