CLI Overview
Open Mercato bundles CLI commands for project setup, tenant administration, and module scaffolding. Top-level helpers are exposed as Yarn scripts (yarn init, yarn db:generate, …) while module-specific utilities live under the umbrella command:
yarn mercato <module> <command> [options]
Run yarn mercato --help to list modules and yarn mercato <module> --help to drill in.
Workflow Cheat Sheet
- Bootstrap & Database
yarn init– full app bootstrap with optional reinstall mode.yarn db:generate– per-module migration diffing.yarn db:migrate– apply migrations and refresh generated metadata.yarn db:greenfield– destructive reset that regenerates a clean schema.
- Auth module
- Security
mercato api_keys add– mint scoped API keys for automations.
- Example module
- Entities
Each linked page provides usage syntax, option breakdowns, sample output, and troubleshooting notes so you can copy commands directly into your terminal.