{"id":20484028,"url":"https://github.com/nuxy/nodejs-restful-jsonapi-seed","last_synced_at":"2026-05-14T01:03:38.707Z","repository":{"id":57311955,"uuid":"127812326","full_name":"nuxy/nodejs-restful-jsonapi-seed","owner":"nuxy","description":":seedling: Everything you need to start building a scalable web application.","archived":false,"fork":false,"pushed_at":"2024-10-12T00:38:06.000Z","size":3070,"stargazers_count":12,"open_issues_count":0,"forks_count":4,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-27T05:34:59.789Z","etag":null,"topics":["docker","es6","expressjs","jsonapi","nodejs","restful","servers"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nuxy.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2018-04-02T21:04:48.000Z","updated_at":"2025-01-19T21:13:49.000Z","dependencies_parsed_at":"2024-01-25T02:50:21.699Z","dependency_job_id":"ed167d60-3983-4ab4-92e6-66474f1b85b0","html_url":"https://github.com/nuxy/nodejs-restful-jsonapi-seed","commit_stats":{"total_commits":277,"total_committers":2,"mean_commits":138.5,"dds":"0.0036101083032491488","last_synced_commit":"97085a45aae16a8654ce431e41b221dfeba22c4c"},"previous_names":[],"tags_count":66,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuxy%2Fnodejs-restful-jsonapi-seed","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuxy%2Fnodejs-restful-jsonapi-seed/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuxy%2Fnodejs-restful-jsonapi-seed/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuxy%2Fnodejs-restful-jsonapi-seed/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nuxy","download_url":"https://codeload.github.com/nuxy/nodejs-restful-jsonapi-seed/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248729368,"owners_count":21152408,"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":["docker","es6","expressjs","jsonapi","nodejs","restful","servers"],"created_at":"2024-11-15T16:19:37.454Z","updated_at":"2026-05-14T01:03:38.700Z","avatar_url":"https://github.com/nuxy.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Node.js Express restful JSON API seed\n\n[![npm version](https://badge.fury.io/js/nodejs-restful-jsonapi-seed.svg)](https://badge.fury.io/js/nodejs-restful-jsonapi-seed) [![](https://img.shields.io/npm/dm/nodejs-restful-jsonapi-seed.svg)](https://www.npmjs.com/package/nodejs-restful-jsonapi-seed) [![Build Status](https://img.shields.io/github/actions/workflow/status/nuxy/nodejs-restful-jsonapi-seed/.github%2Fworkflows%2Fci.yml)](https://app.travis-ci.com/github/nuxy/nodejs-restful-jsonapi-seed) [![Install size](https://packagephobia.com/badge?p=nodejs-restful-jsonapi-seed)](https://packagephobia.com/result?p=nodejs-restful-jsonapi-seed) [![](https://img.shields.io/github/v/release/nuxy/nodejs-restful-jsonapi-seed)](https://github.com/nuxy/nodejs-restful-jsonapi-seed/releases) [![NO AI](https://raw.githubusercontent.com/nuxy/no-ai-badge/master/badge.svg)](https://github.com/nuxy/no-ai-badge)\n\nEverything you need to start building a scalable web application.\n\n![the \"seed\" app](https://raw.githubusercontent.com/nuxy/nodejs-restful-jsonapi-seed/master/package.png)\n\n## Features\n\n- ECMAScript 2022 (ES6) compatible.\n- RESTful application interface.\n- JSON API standard request/responses.\n- ABAC (Attribute-Based Access Control)\n- HTTP/1/2 and SSL support.\n- Database driver support.\n- Session handling using cookies.\n- Schema-based validation.\n- Stream-based logging and file rotation.\n- Production process manager.\n- JSDoc App/Swagger API documentation.\n- Deployable as a Docker service.\n\n## Dependencies\n\n- [Node.js](https://nodejs.org)\n- [Docker](https://docker.com) (optional)\n\n## Installation\n\n### seed-cli\n\nInstall the command-line utility using [NPM](https://npmjs.com).\n\n    $ npm install -g nodejs-restful-jsonapi-seed\n    $ seed-cli --help\n\n    Usage: seed-cli [options]\n\n    Options:\n      --create \u003cproject-name\u003e  Create a new seed example project\n      --start                  Launch a single server instance\n      --deploy                 Launch a server cluster\n      --watch                  Launch the server (development mode)\n      --lint                   Run ESLint on project sources\n      --test                   Run Mocha integration tests\n      --docker                 Deploy your application as a Docker service\n      --genapi                 Generate Swagger definitions\n      --gendoc                 Generate documentation using JSDoc\n      --env \u003cenvironment\u003e      Set the NODE_ENV (default: development)\n      -h, --help               output usage information\n\n### Manual\n\nClone the repository, or download the latest [release](https://github.com/nuxy/nodejs-restful-jsonapi-seed/releases).\n\n    $ git clone https://github.com/nuxy/nodejs-restful-jsonapi-seed.git\n\nInstall package dependencies using [NPM](https://npmjs.com).\n\n    $ npm install\n\n## Developers\n\nWhile `seed-cli` provided with this package can execute NPM scripts, it's not a requirement. You can also achieve this using [npm-run-script](https://docs.npmjs.com/cli/run-script).\n\n### CLI options\n\nSet your environment. If `NODE_ENV` is not defined, the default config `development` is used.\n\n    $ export NODE_ENV=\u003cproduction|staging|qa\u003e\n\nLaunch a _single server instance_:\n\n    $ npm run start\n\nLaunch a _server cluster_:\n\n    $ npm run deploy\n\nLaunch the server (development mode) with [nodemon](https://nodemon.io):\n\n    $ npm run watch\n\nRun [ESLint](https://eslint.org) on project sources:\n\n    $ npm run lint\n\nRun [Mocha](https://mochajs.org) integration tests:\n\n    $ npm run test\n\nDeploy your application as a [Docker](https://docker.com) service:\n\n    $ npm run docker\n\nGenerate [Swagger](https://swagger.io) definitions:\n\n    $ npm run genapi\n\nGenerate documentation using [JSDoc](https://jsdoc.app):\n\n    $ npm run gendoc\n\n## API Examples\n\nThe following [routes](src/routes/examples) have been enabled in the application.  When the server is running in _development_ mode [Swagger](https://swagger.io) generated documentation can be accessed at: [http://localhost:3000/api-doc](http://localhost:3000/api-doc)\n\n## Documentation\n\nWhen the server is running in _development_ mode [JSDoc](https://jsdoc.app) generated documentation can be accessed at: [http://localhost:3000/app-doc](http://localhost:3000/app-doc)\n\n## Enabling HTTP/2\n\nThe [http2](https://nodejs.org/api/http2.html) module is an experimental API which relies on the [Latest Current Version](https://nodejs.org/en/download/current) of Node.js to work.  Furthermore, since there are no browsers known that support unencrypted HTTP/2, the use of [X.509 certificates](https://en.wikipedia.org/wiki/X.509) is necessary when communicating with browser clients.\n\nTo set-up the server, first you must generate the certificate and key files:\n\n    $ openssl req -x509 -newkey rsa:2048 -nodes -sha256 -keyout localhost-key.pem -out localhost-cert.pem\n\nSee the [Node.js documentation](https://nodejs.org/api/http2.html#http2_client_side_example) for information regarding client-side set-up.\n\n## SSL configuration\n\nDepending on your application requirements there are multiple ways to set-up the [server config](https://github.com/nuxy/nodejs-restful-jsonapi-seed/blob/master/config/default.json#L49):\n\n### Absolute path\n\nIf your certificates are installed in a location outside of the application scope (e.g. `/etc/ssl/certs`), and your application has the permissions to access these files, you can add the _absolute path_ to the respective configuration values.\n\n### String output\n\nIf, for whatever reason, you cannot host the certificates locally (shared environment), you can output each file as a newline-delimited string using the following command and add the _string output_ to the respective configuration values.\n\n    $ cat localhost-\u003ckey|cert\u003e.pem | perl -pe 's/\\n/\\\\n/g'\n\n## Common questions\n\n\u003e What was your motivation for creating this package?\n\nI wanted a package that was lightweight and provided all of the Production features needed to create a scalable API server.  While there are many packages available, most are lacking or require you to sacrifice simplicity or features for little gain.\n\nThis package provides _everything_ you need to quickly build your application using a consistent and secure set of standards.\n\n\u003e How do you set-up this package to use a custom database?\n\nYou can update the [database wrapper](https://github.com/nuxy/nodejs-restful-jsonapi-seed/blob/master/src/lib/Database.js) example to use any [DBMS](https://www.npmjs.com/search?q=dbms) package available while  extending the application [SessionStore](https://github.com/nuxy/nodejs-restful-jsonapi-seed/blob/master/src/lib/SessionStore.js) to use a compatible [Connection Session Store](https://github.com/expressjs/session#compatible-session-stores) module.\n\n## Windows support\n\nThis package has limited support for Windows due to cross-platform compatibility issues, most notably `SHELL` environment differences. Due to this, you can either run this package in [Docker](https://docker.com) or switch to a UNIX-like operating system.\n\n## Contributions\n\nIf you fix a bug, or have a code you want to contribute, please send a pull-request with your changes. (Note: Before committing your code please ensure that you are following the [Node.js style guide](https://github.com/felixge/node-style-guide))\n\n## Versioning\n\nThis package is maintained under the [Semantic Versioning](https://semver.org) guidelines.\n\n## License and Warranty\n\nThis package is distributed in the hope that it will be useful, but without any warranty; without even the implied warranty of merchantability or fitness for a particular purpose.\n\n_nodejs-restful-jsonapi-seed_ is provided under the terms of the [MIT license](http://www.opensource.org/licenses/mit-license.php)\n\n## Author\n\n[Marc S. Brooks](https://github.com/nuxy)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnuxy%2Fnodejs-restful-jsonapi-seed","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnuxy%2Fnodejs-restful-jsonapi-seed","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnuxy%2Fnodejs-restful-jsonapi-seed/lists"}