{"id":24429729,"url":"https://github.com/hasanali112/prime-bazaar-server","last_synced_at":"2026-04-21T21:31:03.083Z","repository":{"id":267320318,"uuid":"900885489","full_name":"hasanali112/Prime-Bazaar-server","owner":"hasanali112","description":"This project aims to develop a Multi-Vendor E-Commerce Dashboard that allows multiple vendors to sell their products on a unified platform. The system will include robust features for product management, order handling, and vendor-specific analytics.","archived":false,"fork":false,"pushed_at":"2025-05-02T12:08:47.000Z","size":248,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-01-02T00:14:24.456Z","etag":null,"topics":["graphql","jwt","prisma","psotgresql","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hasanali112.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-12-09T16:44:54.000Z","updated_at":"2025-05-02T12:08:51.000Z","dependencies_parsed_at":"2025-01-13T17:26:45.402Z","dependency_job_id":"5f016818-fe86-4a97-817f-fc8bfabca1ed","html_url":"https://github.com/hasanali112/Prime-Bazaar-server","commit_stats":null,"previous_names":["hasanali112/library-manage-system","hasanali112/multi-vendor-e-commerse","hasanali112/prime-bazaar-server"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/hasanali112/Prime-Bazaar-server","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hasanali112%2FPrime-Bazaar-server","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hasanali112%2FPrime-Bazaar-server/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hasanali112%2FPrime-Bazaar-server/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hasanali112%2FPrime-Bazaar-server/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hasanali112","download_url":"https://codeload.github.com/hasanali112/Prime-Bazaar-server/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hasanali112%2FPrime-Bazaar-server/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32110770,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-21T11:25:29.218Z","status":"ssl_error","status_checked_at":"2026-04-21T11:25:28.499Z","response_time":128,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["graphql","jwt","prisma","psotgresql","typescript"],"created_at":"2025-01-20T13:47:18.357Z","updated_at":"2026-04-21T21:31:03.062Z","avatar_url":"https://github.com/hasanali112.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Project Requirements for Multi-Vendor E-Commerce Dashboard\n\n## Overview\nThis project aims to develop a Multi-Vendor E-Commerce Dashboard that allows multiple vendors to sell their products on a unified platform. The system will include robust features for product management, order handling, and vendor-specific analytics.\n\nThe system will be developed using the following tech stack:\n\n- **Frontend**: Next.js, Tailwind CSS\n- **Backend**: Graphql Apollo Server\n- **Database**: PostgreSQL\n- **ORM**: Prisma\n\n---\n\n## Functional Requirements\n\n### User Roles and Authentication\n1. **User Roles**:\n   - Define roles such as Admin, Vendor, and Customer.\n   - Role-based access control for different features.\n\n2. **Authentication**:\n   - Secure registration and login for all user roles.\n   - Password reset functionality.\n   - Vendors and customers have separate login portals.\n\n### Vendor Management\n1. **Vendor Dashboard**:\n   - Vendors can manage their profile, store details, and products.\n   - View sales reports, earnings, and order statuses.\n\n2. **Product Management**:\n   - Vendors can add, update, and delete their products.\n   - Products have attributes such as title, description, category, price, stock, and images.\n\n3. **Order Management**:\n   - Vendors can view and update order statuses.\n   - Integration with delivery tracking systems (optional).\n\n### Product and Inventory Management\n1. **Product Categories**:\n   - Admins can create and manage product categories.\n   - Vendors can assign categories to their products.\n\n2. **Inventory Tracking**:\n   - Automatic stock updates based on orders.\n   - Alerts for low-stock products.\n\n### Customer Features\n1. **Product Browsing**:\n   - Customers can search and filter products by category, price, and ratings.\n   - View detailed product descriptions and reviews.\n\n2. **Shopping Cart**:\n   - Add, update, and remove items from the cart.\n   - Calculate totals, discounts, and shipping costs.\n\n3. **Order Placement**:\n   - Checkout process with shipping details and payment options.\n   - Order history accessible to customers.\n\n### Admin Features\n1. **Vendor and Customer Management**:\n   - View, approve, or reject vendor registrations.\n   - Manage customer accounts.\n\n2. **Platform Analytics**:\n   - Generate reports on overall sales, vendor performance, and customer activities.\n\n3. **Content Management**:\n   - Manage banners, promotional campaigns, and featured products.\n\n---\n\n## Non-Functional Requirements\n\n1. **Scalability**:\n   - Handle a growing number of vendors, products, and customers.\n\n2. **Security**:\n   - Use JWT for secure authentication.\n   - Encrypt sensitive data such as passwords and payment details.\n\n3. **Performance**:\n   - Optimize API responses and database queries for high performance.\n\n4. **Accessibility**:\n   - Ensure the UI is accessible and responsive.\n\n5. **Reliability**:\n   - Implement error handling, logging, and failover mechanisms.\n\n---\n\n## Technical Requirements\n\n### Frontend\n1. Use **Next.js** for server-side rendering and routing.\n2. Build a responsive UI using **Tailwind CSS**.\n3. Implement reusable components for products, orders, and dashboards.\n\n### Backend\n1. Use **Express.js** for building RESTful APIs.\n2. Set up secure routes for authentication and resource management.\n3. Implement role-based access control (RBAC).\n\n### Database\n1. Use **PostgreSQL** for data storage.\n2. Define models for users, products, orders, and vendors using **Prisma**.\n3. Implement database migrations for schema changes.\n\n### Deployment\n1. Host the application on platforms like Vercel (Frontend) and Heroku or AWS (Backend).\n2. Use environment variables to manage secrets like database credentials and JWT keys.\n\n---\n\n## API Endpoints\n\n### Authentication\n- `POST /auth/register` - Register a new user (Admin, Vendor, or Customer).\n- `POST /auth/login` - Authenticate user and return JWT.\n- `POST /auth/forgot-password` - Send a password reset link.\n- `POST /auth/reset-password` - Reset user password.\n\n### Vendor Management\n- `GET /vendors` - Fetch all registered vendors (Admin-only).\n- `GET /vendors/:id` - Fetch details of a specific vendor.\n- `PUT /vendors/:id` - Update vendor details.\n- `DELETE /vendors/:id` - Delete a vendor (Soft delete).\n\n### Product Management\n- `GET /products` - Fetch all products (Paginated).\n- `GET /products/:id` - Fetch details of a specific product.\n- `POST /products` - Add a new product (Vendor-only).\n- `PUT /products/:id` - Update a product (Vendor-only).\n- `DELETE /products/:id` - Delete a product (Vendor-only).\n\n### Order Management\n- `GET /orders` - Fetch all orders (Admin-only).\n- `GET /orders/vendor` - Fetch orders for the logged-in vendor.\n- `POST /orders` - Place a new order (Customer-only).\n- `PUT /orders/:id` - Update order status (Vendor-only).\n\n### Analytics\n- `GET /analytics/sales` - Fetch overall sales analytics (Admin-only).\n- `GET /analytics/vendor` - Fetch vendor-specific analytics (Vendor-only).\n\n---\n\n## Database Models\n\n### User\n```prisma\nmodel User {\n  id              Int       @id @default(autoincrement())\n  email           String    @unique\n  password        String\n  role            String\n  createdAt       DateTime  @default(now())\n  updatedAt       DateTime  @updatedAt\n  Vendor          Vendor?\n  Customer        Customer?\n}\n```\n\n### Vendor\n```prisma\nmodel Vendor {\n  id              Int       @id @default(autoincrement())\n  name            String\n  contactInfo     String\n  products        Product[]\n  orders          Order[]\n  userId          Int       @unique\n  User            User      @relation(fields: [userId], references: [id])\n}\n```\n\n### Customer\n```prisma\nmodel Customer {\n  id              Int       @id @default(autoincrement())\n  name            String\n  orders          Order[]\n  userId          Int       @unique\n  User            User      @relation(fields: [userId], references: [id])\n}\n```\n\n### Product\n```prisma\nmodel Product {\n  id              Int       @id @default(autoincrement())\n  title           String\n  description     String\n  category        String\n  price           Float\n  stock           Int\n  images          String[]\n  vendorId        Int\n  Vendor          Vendor    @relation(fields: [vendorId], references: [id])\n}\n```\n\n### Order\n```prisma\nmodel Order {\n  id              Int       @id @default(autoincrement())\n  status          String\n  totalAmount     Float\n  createdAt       DateTime  @default(now())\n  customerId      Int\n  vendorId        Int\n  Customer        Customer  @relation(fields: [customerId], references: [id])\n  Vendor          Vendor    @relation(fields: [vendorId], references: [id])\n}\n```\n\n---\n\n## Project Milestones\n\n### Phase 1: Planning and Design\n- Define project requirements and technical stack.\n- Create wireframes and database schema.\n\n### Phase 2: Backend Development\n- Set up Express.js server and Prisma ORM.\n- Implement authentication and role management.\n- Develop APIs for product and order management.\n\n### Phase 3: Frontend Development\n- Build reusable UI components with Next.js and Tailwind CSS.\n- Integrate APIs for dynamic content.\n- Implement responsive design.\n\n### Phase 4: Testing and Optimization\n- Write unit and integration tests.\n- Optimize API performance and database queries.\n\n### Phase 5: Deployment and Maintenance\n- Deploy the application to production.\n- Monitor for bugs and implement updates as needed.\n\n---\n\n## Future Enhancements\n1. Introduce advanced analytics dashboards for vendors and admin.\n2. Add support for promotional codes and discounts.\n3. Integrate multiple payment gateways.\n4. Develop a mobile app for customers and vendors.\n5. Implement AI-based recommendations for customers.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhasanali112%2Fprime-bazaar-server","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhasanali112%2Fprime-bazaar-server","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhasanali112%2Fprime-bazaar-server/lists"}