Gathering detailed insights and metrics for @bodheesh/create-bodhi-node-app
Gathering detailed insights and metrics for @bodheesh/create-bodhi-node-app
Gathering detailed insights and metrics for @bodheesh/create-bodhi-node-app
Gathering detailed insights and metrics for @bodheesh/create-bodhi-node-app
npm install @bodheesh/create-bodhi-node-app
Typescript
Module System
Min. Node Version
Node Version
NPM Version
Verify real, reachable, and deliverable emails with instant MX records, SMTP checks, and disposable email detection.
Total Downloads
14
Last Day
1
Last Week
1
Last Month
14
Last Year
14
Latest Version
1.0.0
Package Id
@bodheesh/create-bodhi-node-app@1.0.0
Unpacked Size
370.91 kB
Size
93.54 kB
File Count
38
NPM Version
10.9.0
Node Version
18.17.1
Published on
Feb 03, 2025
Cumulative downloads
Total Downloads
Last Day
0%
1
Compared to previous day
Last Week
-92.3%
1
Compared to previous week
Last Month
0%
14
Compared to previous month
Last Year
0%
14
Compared to previous year
1
A powerful CLI tool that generates Express.js REST APIs or GraphQL endpoints from a simple JSON schema.
1npm install -g @bodhi/crud-api-generator
schema.json
):1{ 2 "name": "User", 3 "fields": { 4 "name": { 5 "type": "String", 6 "required": true 7 }, 8 "email": { 9 "type": "String", 10 "required": true, 11 "unique": true 12 }, 13 "age": { 14 "type": "Number" 15 } 16 } 17}
1bodhi-crud generate -s schema.json -d mongodb -t rest
Options:
-s, --schema
: Path to JSON schema file (required)-d, --database
: Database type (mongodb, postgres, firebase) (default: mongodb)-t, --type
: API type (rest, graphql) (default: rest)-o, --output
: Output directory (default: ./generated)The tool will generate the following files:
generated/
├── models/
│ └── user.model.js
├── controllers/
│ └── user.controller.js
├── routes/
│ └── user.routes.js
└── swagger.json
Contributions are welcome! Please feel free to submit a Pull Request.
MIT
📦 rest-api ┣ 📂 src ┃ ┣ 📂 config ┃ ┃ ┣ 📄 index.js # Central configuration ┃ ┃ ┗ 📄 swagger.js # Swagger/OpenAPI configuration ┃ ┣ 📂 controllers ┃ ┃ ┣ 📂 auth ┃ ┃ ┃ ┗ 📄 auth.controller.js # Authentication controller ┃ ┃ ┗ 📂 user ┃ ┃ ┗ 📄 user.controller.js # User management controller ┃ ┣ 📂 middleware ┃ ┃ ┣ 📄 error.middleware.js # Global error handler ┃ ┃ ┗ 📂 validation ┃ ┃ ┣ 📄 auth.middleware.js # JWT authentication ┃ ┃ ┣ 📄 auth.validation.js # Auth input validation ┃ ┃ ┣ 📄 role.middleware.js # Role-based access control ┃ ┃ ┗ 📄 user.validation.js # User input validation ┃ ┣ 📂 models ┃ ┃ ┗ 📄 user.model.js # User model schema ┃ ┣ 📂 routes ┃ ┃ ┣ 📂 auth ┃ ┃ ┃ ┗ 📄 auth.routes.js # Auth routes ┃ ┃ ┗ 📂 user ┃ ┃ ┗ 📄 user.routes.js # User routes ┃ ┣ 📂 utils ┃ ┃ ┣ 📄 db.util.js # Database utilities ┃ ┃ ┣ 📄 error.util.js # Error classes ┃ ┃ ┣ 📄 logger.util.js # Logging utility ┃ ┃ ┗ 📄 response.util.js # Response formatter ┃ ┗ 📄 index.js # Application entry point ┣ 📂 logs # Log files directory ┣ 📄 .env.example # Environment variables example ┣ 📄 .gitignore # Git ignore file ┣ 📄 package.json # Project dependencies ┗ 📄 README.md # Project documentation
No vulnerabilities found.
No security vulnerabilities found.