Node.js Starter with Swagger Generation, Security, Database( CouchDB) and a CORS Filter
Nodejs
/
July 06, 2018
This Project has been created to facilitate Node.js API Development. I added all the bits and pieces that you need to get a solid Node.js project running.
What’s in the project
Promises
Database Integration for CouchDB using nano( Supports all major operations including insert, update, delete, find one, find all, Database Views etc.).
REST calls made using request
CORS Middleware for handling requests made from Browser based Clients in another Origin
A Code Snippet showing how the API can be protected using an API Key.
An example configuration fetched from the evvironment to support Production Deployments.
Promises
A Commented Code Snippet from hello_world.js
Database Integration
A few Lines of Code from couchdb_database_service.js
REST Calls
A few Code Snippet from w3school_api_service.js
CORS Middleware
The CORS Filter in middleware Directory
API Security
A Code Snippet from app.js.
Environment Variables
A Commented Code Snippet from application_config.js.