A boilerplate/starter project for quickly building RESTful APIs using Node.js, Express, and Mongoose. By running a single command, you will get a production-ready Node.js app installed and fully configured on your machine. The app comes with many built-in features, such as authentication using JWT, request validation, unit and integration tests, continuous integration, docker support, API documentation, pagination, etc. The app has a utility ApiError class to which you can attach a response code and a message, and then throw it from anywhere (catchAsync will catch it). Request data is validated using Joi. Check the documentation for more details on how to write Joi validation schemas. In production mode, only info, warn, and error logs will be printed to the console. It is up to the server (or process manager) to actually read them from the console and store them in log files.

Features

  • NoSQL database: MongoDB object data modeling using Mongoose
  • Authentication and authorization: using passport
  • Validation: request data validation using Joi
  • Logging: using winston and morgan
  • Testing: unit and integration tests using Jest
  • Error handling: centralized error handling mechanism

Project Samples

Project Activity

See All Activity >

License

MIT License

Follow RESTful API Node Server Boilerplate

RESTful API Node Server Boilerplate Web Site

You Might Also Like
Red Hat Enterprise Linux on Microsoft Azure Icon
Red Hat Enterprise Linux on Microsoft Azure

Deploy Red Hat Enterprise Linux on Microsoft Azure for a secure, reliable, and scalable cloud environment, fully integrated with Microsoft services.

Red Hat Enterprise Linux (RHEL) on Microsoft Azure provides a secure, reliable, and flexible foundation for your cloud infrastructure. Red Hat Enterprise Linux on Microsoft Azure is ideal for enterprises seeking to enhance their cloud environment with seamless integration, consistent performance, and comprehensive support.
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of RESTful API Node Server Boilerplate!

Additional Project Details

Programming Language

JavaScript

Related Categories

JavaScript Frameworks, JavaScript Web Development Software

Registered

2022-10-31