A complete eCommerce Backend API built with Node.js, Express.js, and MongoDB.
This project provides a secure and scalable RESTful API for managing products, users, carts, wishlists, invoices, and more.
- Node.js with Express.js for backend framework
- MongoDB with Mongoose for database
- JWT Authentication for secure login
- Nodemailer for email/OTP verification
- Helmet, CORS, XSS Sanitizer, HPP, Rate Limiting for security
- Product Brand List
- Product Category List
- Product Slider List
- Product List by Brand, Category, Remark, Keyword
- Product Details
- Review List
- OTP based login system
- Verify Login
- Create, Update, Read Profile
- User Logout
- Add product to wishlist
- Remove product from wishlist
- View wishlist
- Add product to cart with color, size, quantity
- Update cart item
- Remove cart item
- View cart list
- Create Invoice
- View Invoice List
- View Invoice Product List
- JWT Authentication
- Helmet for HTTP headers security
- XSS Sanitizer & xss-clean
- Rate Limiting (express-rate-limit)
- HPP (HTTP Parameter Pollution protection)
- Features List endpoint
- Legal Details endpoint
GET /ProductBrandListGET /ProductCategoryListGET /ProductSliderListGET /ProductListByBrand/:idGET /ProductListByCategory/:idGET /ProductListBySmiler/:idGET /ProductListByRemark/:remarkGET /ProductListByKeyword/:keywordGET /ProductDetails/:idGET /ReviewList/:id
GET /UserOTP/:emailGET /VerifyLogin/:email/:otpGET /UserLogOutPOST /CreateProfilePOST /UpdateProfileGET /ReadProfile
GET /WishListGET /SaveWishListGET /RemoveWishList
GET /CartListGET /SaveCartListGET /UpdateCartList/:idGET /RevoveCartList
GET /CreateInvoiceGET /InvoiceListGET /InvoiceProductList/:id
GET /FeaturesListGET /LegalDetails/:type
| Dependency | Purpose |
|---|---|
| express | Web framework |
| mongoose | MongoDB ODM |
| jsonwebtoken | Authentication |
| helmet | Security headers |
| cors | Cross-origin requests |
| cookie-parser | Cookie handling |
| express-rate-limit | Prevent brute force |
| xss-clean | Prevent XSS attacks |
| hpp | Prevent parameter pollution |
| nodemailer | Email sending |
| dotenv | Environment variables |
| axios | HTTP requests |
- Clone the repository:
git clone https://github.com/your-username/ecommerce-backend.git cd ecommerce-backend