{"id":19081068,"url":"https://github.com/backendexpert/automate-backend-fullstack","last_synced_at":"2026-01-27T12:01:56.621Z","repository":{"id":260188463,"uuid":"880311227","full_name":"BackendExpert/automate-backend-fullstack","owner":"BackendExpert","description":"automate backend fullstack with MVC (NPM Package)","archived":false,"fork":false,"pushed_at":"2024-11-07T09:19:28.000Z","size":1586,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-28T03:45:48.703Z","etag":null,"topics":["fullstack-development","javascript","mern-stack","npm","npm-package"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/automate-backend-fullstack","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/BackendExpert.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-10-29T13:54:33.000Z","updated_at":"2024-11-07T09:19:31.000Z","dependencies_parsed_at":null,"dependency_job_id":"3580c789-2e16-42ea-a64f-e80a7348b45d","html_url":"https://github.com/BackendExpert/automate-backend-fullstack","commit_stats":null,"previous_names":["backendexpert/automate-backend-fullstack"],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BackendExpert%2Fautomate-backend-fullstack","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BackendExpert%2Fautomate-backend-fullstack/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BackendExpert%2Fautomate-backend-fullstack/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BackendExpert%2Fautomate-backend-fullstack/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/BackendExpert","download_url":"https://codeload.github.com/BackendExpert/automate-backend-fullstack/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251660145,"owners_count":21623196,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["fullstack-development","javascript","mern-stack","npm","npm-package"],"created_at":"2024-11-09T02:32:53.031Z","updated_at":"2026-01-27T12:01:51.602Z","avatar_url":"https://github.com/BackendExpert.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Automate Backend MVC for FullStack Projects\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://skillicons.dev\"\u003e\n    \u003cimg src=\"https://skillicons.dev/icons?i=mongodb,npm,nodejs,express,js\" /\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n- `automate-backend-fullstack` is an npm package that helps you quickly set up a MongoDB model, Controller and Route in a Node.js MVC backend using the Mongoose ORM. This CLI tool allows you to specify model details, including field types, uniqueness, requirements, and default values, creating a ready-to-use Mongoose schema.\n\n## Features\n\n- \u003cb\u003eInteractive CLI:\u003c/b\u003e Prompts for model name, number of fields, and details for each field.\n- \u003cb\u003eFlexible Field Options:\u003c/b\u003e Supports field configurations including type, unique, required, and default value.\n- \u003cb\u003eAutomatic Model Generation:\u003c/b\u003e  Creates a Mongoose model file in a structured format. Avoids Redundant Model Creation:\n- \u003cb\u003eAvoids Redundant Model Creation:\u003c/b\u003e  Checks if a model with the specified name already exists and prompts to confirm overwriting, saving you from recreating existing models.\n\n\n- \u003cb\u003e About Controller : \u003c/b\u003e This npm package helps to create Controllers after create models. According to this Controller created using given name for model\n\n- \u003cb\u003e About Route : \u003c/b\u003e This npm package helps to create Routes after create models and Controllers. According to this Route created using given name for model\n\n## Installation\n\n- To use this package as a global CLI tool, install it using:\n\n```bash\n\n    npm install -g automate-backend-fullstack \n\n```\n\n## Usage\n\n- To create a new model, simply run:\n\n\n```bash\n\n    npx create-mvc-fullstack \n\n```\n\n## Step-by-Step Process\n\n- \u003cb\u003eRun the Command: \u003c/b\u003e After running `npx create-mvc-fullstack`  you’ll be prompted for the model details.\n- \u003cb\u003eSpecify the Model Name:\u003c/b\u003e Enter the name for your model (e.g., User, Product). If a model with this name already exists, you’ll be prompted to overwrite it or skip creation.\n- \u003cb\u003eDefine Field Count: \u003c/b\u003e Specify the number of fields the model will have.\n- \u003cb\u003eEnter Field Details:\u003c/b\u003e For each field, you’ll be prompted for:\n- - Field Name: Name of the field (e.g., email, username).\n- - Field Type: Data type of the field (e.g., String, Number).\n- - Unique: Whether the field should be unique (true or false).\n- - Required: Whether the field is required (true or false).\n- - Default Value: Optional default value for the field (leave blank if not required).\n\n- After Model Create then you can create Controller\n- - after creating of model it automatically ask to create Controller and Route using given name for model\n\n## Example\n\n- If you specify a model name as `User` with two fields (email and username), the generated schema file will look like this:\n\n\n```js\n\nconst mongoose = require(\"mongoose\");\n\nconst UserSchema = new mongoose.Schema({\n    email: {\n        type: String,\n        unique: true,\n        required: true\n    },\n    username: {\n        type: String,\n        required: true\n    }\n});\n\nmodule.exports = mongoose.model(\"User\", UserSchema);\n\n```\n\n- Example Controller\n\n\n```js\n\n// this user model can be changed\nconst user = require(\"../models/user\");\n\n// Controller name can be changed\nconst userController = {\n    // body of controller goese here\n    // create methods in here that you need to create\n};\n\nmodule.exports = userController;\n\n\n```\n\n- Example Route\n\n\n```js\n\n\n// impoert express\nconst express = require('express');\n\n// import Controller\nconst userController = require('../controllers/userController');\n\nconst router = express.Router();\n\n// All routes goes here\n\nmodule.exports = router;\n\n    \n\n\n```\n\n\n## Notes\n\n- The default property is only added if specified; otherwise, it’s omitted.\n- Avoids redundant model, controller and route creation by confirming overwrites for existing.\n- Ensure `mongoose` is installed in your project to use the generated models.\n- More fuctions will be add in Future Releases.\n\n## Releases\n\n### v1.0.0 30 October 2024\n\n- inital release\n- Adding only Model\n\n### v2.0.0 04 November 2024\n\n- Adding Controllers\n- fixing bugs on model\n\n### v3.0.0 07 November 2024\n\n- Adding Routes\n- fixing bugs on model and Controllers\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbackendexpert%2Fautomate-backend-fullstack","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbackendexpert%2Fautomate-backend-fullstack","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbackendexpert%2Fautomate-backend-fullstack/lists"}