Samridhi Enterprises is a professional full-stack MERN e-commerce platform designed for managing and selling vehicle spare parts. The project provides a seamless experience for buyers to find parts and for admins and sellers to manage inventory.
- Features
- Tech Stack
- Folder Structure
- Documentation
- Local Development Setup
- Environment Variables
- MongoDB Atlas Setup
- Cloudinary Setup
- Brevo Email Setup
- Deployment Guide
- Screenshots
- Future Roadmap
- ELUSOC 2026 Contribution Guide
- Developer Info
- Authentication: Secure login and registration using JWT.
- Product Browsing: Search and filter vehicle parts by brand and model.
- Cart Management: Add/remove items and manage quantities.
- Reviews & Ratings: Share feedback on purchased products.
- Profile Management: Update personal information and view order history.
- Inventory Management: Add and update stock levels for parts.
- Product Listings: Manage detailed listings including images and specifications.
- Dashboard: Comprehensive overview of site activity and sales.
- User Management: Manage user roles and permissions.
- Product Moderation: Review and approve product listings.
- Brand/Model Management: Manage the database of vehicle brands and models.
| Layer | Technology |
|---|---|
| Frontend | React.js, Vite, Redux Toolkit, Tailwind CSS, Framer Motion, Axios |
| Backend | Node.js, Express.js |
| Database | MongoDB, Mongoose |
| Image Storage | Cloudinary |
| Email Service | Brevo (formerly Sendinblue) |
| Deployment | Vercel (Frontend + Backend) |
samridhi-enterprises/
├── client/ # Frontend React application
│ ├── public/ # Static assets
│ └── src/
│ ├── api/ # Axios instance and API calls
│ ├── components/ # Reusable UI components
│ ├── pages/ # Page-level components
│ └── store/ # Redux state management
└── server/ # Backend Node.js application
├── config/ # Database and service configurations
├── controllers/ # API request handlers
├── middleware/ # Custom Express middleware
├── models/ # Mongoose schemas
├── route/ # API route definitions
└── template/ # Email templates
In-depth technical documentation lives in the docs/ directory:
- Architecture Overview — system design, backend layers, request lifecycle, and the authentication & authorization flow.
- API Reference — every REST endpoint across all 10 routers, with method, path, access level, and request fields.
- Database Schema — all 10 Mongoose models with fields, types, enums, and relationships.
- Admin Workflows — admin/manager operations: users, catalogue, order & payment verification, coupons, support, and analytics.
- Workflow Guide — in-depth breakdown of order processing, concurrency, atomic inventory reservation, stock restoration, payment verification, and status transition guards.
- Environment Variables — a developer reference for every backend/frontend variable and where it is used.
New contributors can start with docs/README.md for an index.
Make sure the following are installed before you begin:
| Tool | Version | Download |
|---|---|---|
| Node.js | v18 or higher | https://nodejs.org |
| Git | Any recent version | https://git-scm.com |
| MongoDB | Local or Atlas | https://mongodb.com |
git clone https://github.com/SRV30/samridhi-enterprises.git
cd samridhi-enterprises# Navigate to the server directory
cd server
# Install dependencies
npm install
# Copy the environment variables template
cp .env.example .envOpen server/.env and fill in all required values.
See Environment Variables below for what each variable means and where to get it.
# Start the backend development server (runs on http://localhost:5000)
npm run devOpen a new terminal window, then:
# Navigate to the client directory (from the repo root)
cd client
# Install dependencies
npm install
# Copy the environment variables template
cp .env.example .envOpen client/.env and set VITE_BACKEND_URL to your running backend URL:
VITE_BACKEND_URL="http://localhost:5000"# Start the frontend development server (runs on http://localhost:5173)
npm run devThe application will be available at http://localhost:5173.
| Variable | Description | Example |
|---|---|---|
VITE_BACKEND_URL |
Full URL of the running backend server | http://localhost:5000 |
| Variable | Description | Where to get it |
|---|---|---|
PORT |
Port the Express server listens on | Any free port, default 5000 |
MONGODB_URL |
MongoDB connection string | MongoDB Atlas → Connect → Drivers |
FRONTEND_URL |
Production URL of your frontend | Your Vercel frontend URL |
FRONTEND_WWW_URL |
www. variant of the frontend URL (for CORS) |
Same as above with www. prefix |
JWT_SECRET |
Secret key used to sign JWT tokens | Any long random string (min 32 chars) |
JWT_EXPIRE |
JWT token expiry duration | 5d (5 days) |
COOKIE_EXPIRE |
Cookie expiry in days | 7 |
BREVO_API_KEY |
API key for Brevo email service | Brevo dashboard → API Keys |
CLOUDINARY_NAME |
Your Cloudinary cloud name | Cloudinary dashboard → Settings |
CLOUDINARY_API_KEY |
Cloudinary API key | Cloudinary dashboard → API Keys |
CLOUDINARY_API_SECRET |
Cloudinary API secret | Cloudinary dashboard → API Keys |
⚠️ Never commit your.envfile. It is already listed in.gitignore. Only commit.env.examplewith placeholder values.
- Go to https://cloud.mongodb.com and sign in or create a free account.
- Click New Project, give it a name (e.g.
samridhi), and click Create Project. - Click Build a Database → choose M0 Free Tier → select your nearest region → click Create.
- Set a database username and password — save these, you will need them in the connection string.
- Under Network Access, click Add IP Address → choose Allow Access from Anywhere (
0.0.0.0/0) for development, or add your specific IP for production. - Once the cluster is created, click Connect → Connect your application → choose Driver: Node.js and copy the connection string.
- Replace
<password>in the string with your database password and add your database name before?:
MONGODB_URL=mongodb+srv://<username>:<password>@cluster0.xxxxx.mongodb.net/samridhi?retryWrites=true&w=majority- Paste the full string into
server/.envasMONGODB_URL.
Cloudinary stores product images uploaded through the admin panel.
- Go to https://cloudinary.com and sign in or create a free account.
- From your Dashboard, copy your Cloud Name, API Key, and API Secret.
- Add them to
server/.env:
CLOUDINARY_NAME=your_cloud_name
CLOUDINARY_API_KEY=your_api_key
CLOUDINARY_API_SECRET=your_api_secretThe free tier provides 25 GB storage and 25 GB bandwidth per month — more than enough for development.
Brevo (formerly Sendinblue) handles transactional emails such as order confirmations and password resets.
- Go to https://app.brevo.com and sign in or create a free account.
- In the top-right menu, click your name → SMTP & API.
- Click the API Keys tab → Generate a new API key → give it a name and click Generate.
- Copy the generated key and add it to
server/.env:
BREVO_API_KEY=xkeysib-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx- Under Senders & Domains, verify the email address you want to send from. Brevo requires sender verification before emails are delivered.
The free tier allows up to 300 emails per day.
The server already includes a vercel.json configuration file. No additional setup is needed for routing.
- Push your code to GitHub.
- Go to https://vercel.com → New Project → import your repository.
- Set the Root Directory to
server. - Under Environment Variables, add all variables from
server/.env. - Click Deploy.
- Copy the deployed backend URL (e.g.
https://se-xxx.vercel.app) — you will need it for the frontend.
- Go to https://vercel.com → New Project → import the same repository.
- Set the Root Directory to
client. - Under Environment Variables, add:
VITE_BACKEND_URL = https://your-backend-url.vercel.app
- Click Deploy.
- Copy the frontend URL, then go back to your backend Vercel project → Settings → Environment Variables → update
FRONTEND_URLandFRONTEND_WWW_URLwith the new frontend URL, then Redeploy the backend.
⚠️ Important: After deploying the frontend, always redeploy the backend with the updatedFRONTEND_URLandFRONTEND_WWW_URLvalues. These are used for CORS — requests will be blocked without them.
📷 Screenshots are being captured and will render here automatically once the image files are added to
docs/screenshots/. Contributors: see the capture guide for the exact pages, filenames, and viewport sizes to grab.
![]() Home Page |
![]() Product Listing |
![]() Product Details |
![]() Cart |
![]() Checkout Flow |
|
![]() Admin Dashboard |
![]() Sales Analytics |
![]() Product Management |
![]() Order Management |
- Integration of Razorpay/Stripe for payments.
- Advanced inventory tracking and compatibility matching.
- Real-time order tracking.
- Multi-language support.
Target Branch: elusoc
- Find an issue: Browse open issues or create a new one.
- Get assigned: Comment on the issue and wait for a Project Admin to assign it.
- Branch: Create a new branch from
elusoc(e.g.feature/your-feature-name). - Develop: Make your changes and commit them.
- PR: Submit a Pull Request targeting the
elusocbranch. - Review: Address any review comments.
- Merge: PR merged into
elusoc.
- No work without assignment.
- No duplicate issues — check existing ones first.
- All PRs must target
elusoc, notmain. - Resolve merge conflicts before submitting PRs.
SRV30 — Full-Stack Developer GitHub: @SRV30












