A powerful and easy-to-use application to manage and distribute tasks to agents using CSV uploads. Built with ❤️ using Next.js, Tailwind CSS, MongoDB, Node.js, and Express.js.
🌐 Live Demo: Click here to try it!
email : uq0803@gmail.com
password : uq0803
Replace these image paths with your actual file paths.
- ✅ Admin login & dashboard
- 📁 Upload CSVs with agent entries
- 📊 Automatically distribute tasks among agents
- 🧠 Smart round-robin logic for fair distribution
- 🛡️ Validates uploaded CSV format
Your CSV file must contain these headers:
✅ Valid Example:
| FirstName | Phone | Notes |
|---|---|---|
| John | 1234567890 | Follow-up Monday |
| Alice | 9876543210 | Confirmed lead |
❌ Invalid headers or extra columns will be rejected!
- 🌐 Frontend: Next.js, Tailwind CSS
- 🔙 Backend: Node.js, Express.js
- 🛢️ Database: MongoDB
- 📦 CSV Parsing:
csv-parser/fast-csv(whichever you're using)
git clone https://github.com/08Uzair/agentDistribution
cd agent-distribution-app- Install Dependencies
bash
# For backend
cd backend
npm install
# For frontend
cd ../frontend
npm install
- Environment Setup Create a .env file in both backend and frontend directories with the following variables:
Backend .env:
env
PORT=5000
MONGO_URI=your_mongodb_connection_string
Frontend .env.local:
env
NEXT_PUBLIC_API_URL=http://localhost:5000
- Run the App Start Backend
bash
cd backend
npm run dev
Start Frontend
bash
cd ../frontend
npm run dev
🎉 Visit http://localhost:3000 to start using the app!
💡 How It Works 🟢 Admin logs in to the dashboard.
🟢 Only CSV file is Accepted
🟢 Upload a valid CSV file (with columns FirstName, Phone, Notes).
🟢 The app parses the CSV and distributes entries evenly among available agents.
🟢 Distribution is smart — for example:
If there are 6 entries and 4 agents:
Agent 1 gets 2 entries
Agent 2 gets 2 entries
Agent 3 & 4 get 1 entry each
Each agent can then view their assigned entries on their dashboard.
Q: What if the CSV has extra columns or wrong headers?
A: The upload will be rejected with an error message. Only FirstName, Phone, and Notes are allowed.
Q: Can I upload Excel files (.xlsx)?
A: Currently, only CSV format is supported.
Q: How many agents can I create?
A: There's no hard limit. You can create as many agents as needed.
🤝 Contributing Contributions are welcome! Please fork the repo and submit a pull request. Let’s make it better together. 🙌
Made with ❤️ by Mohammad Uzer Qureshi
📧 Contact: uzerqureshi26@gmail.com
🌐 Portfolio: https://uzerqureshi-portfolio.netlify.app/





