Natours is a CRUD (Create, Read, Update, Delete) application built with Node.js, Express and MongoDB.
- User authentication and authorization
- Sign up and login functionality
- JWT tokens for authentication
- Different access rights for users, guides and admins
- Tours
- Browse available tours
- View tour details
- Book tours
- Review and rate tours
- User profiles
- View profile information
- Update profile data
- Credit card payments
- Integrate payments using Stripe API
- Admin dashboard
- Manage tours, users, reviews etc.
- View analytics and statistics
The app can be run locally or deployed to a server.
- Install Node.js and MongoDB
- Clone the repository
- git clone https://github.com/natours.git
- Install dependencies
- npm install
- Set up environment variables in
.env
file - MongoDB connection string
- JWT secret
- Stripe API keys
- Start the app
- npm run dev
The app will be served at http://localhost:3000
The app can be deployed to any hosting platform that supports Node.js like Heroku, AWS, Azure etc.
Make sure to set up environment variables on the platform.
- Node.js - Runtime environment
- Express - Web application framework
- MongoDB - Database
- Mongoose - MongoDB ODM
- JWT - Authentication
- Bcryptjs - Password hashing
- Stripe - Payments
- Pug - Templating engine
- Environment variables and configuration are documented in
.env.example
- For detailed code documentation, check inline comments and JSDoc annotations in source code