How infogudkart-maker/goodkart-new works
Goodkart is a multi-sided marketplace: shoppers discover products, authenticate, check out and track orders; sellers onboard and manage products and orders; administrators manage the platform. The backend exposes these capabilities through Express routes and controllers, with Firebase-backed state and payment, invoicing, email and shipping integrations. The graph preserves the major marketplace, seller and admin domains visible in the repository tree. Several frontend page-to-page transitions and unsampled controller behavior are not evidenced in the excerpts, so those links are omitted.
Main entry points: firebase.js Firebase data and auth · paymentController.js Payment processing · api.js Frontend API client · orderController.js Order lifecycle
Components 30
Shopper marketplace
- Product discovery
frontend/src/modules/marketplace/pages/ProductListing.jsx - Product details
frontend/src/modules/marketplace/pages/ProductDetail.jsx - Checkout
frontend/src/modules/marketplace/pages/Checkout.jsx - Customer account
frontend/src/modules/consumer/pages/Dashboard.jsx - Frontend API client
frontend/src/modules/shared/utils/api.js
Identity and sellers
- Sign-in UI
frontend/src/modules/auth/components/PhoneOtpForm.jsx - Seller portal
frontend/src/modules/seller/pages/Dashboard.jsx - Auth routes
backend/src/modules/auth/routes/authRoutes.js - Identity and onboarding
backend/src/modules/auth/controllers/authController.js - Access control
backend/src/middleware/auth.js - Seller operations
backend/src/modules/seller/controllers/sellerController.js
Commerce backend
- HTTP application
backend/src/server.js - Product catalog
backend/src/modules/products/controllers/productController.js - Order lifecycle
backend/src/modules/orders/controllers/orderController.js - Payment processing
backend/src/modules/payment/controllers/paymentController.js - Product reviews
backend/src/modules/reviews/controllers/reviewController.js - Shipping estimates
backend/src/modules/shipping/controllers/shippingEstimateController.js - Firebase data and auth
backend/src/config/firebase.js - Pricing calculations
backend/src/utils/pricing.js - Stock updates
backend/src/utils/stockUtils.js - In-memory cache
backend/src/utils/cache.js
Platform operations
- Admin dashboard
frontend/src/modules/admin/pages/Dashboard.jsx - Admin routes
backend/src/modules/admin/routes/adminRoutes.js - Seller administration
backend/src/modules/admin/controllers/sellerManagementController.js - Review administration
backend/src/modules/admin/controllers/reviewManagementController.js - Invoice generation
backend/src/shared/services/invoiceService.js - Email notifications
backend/src/shared/services/emailService.js - Shiprocket integration
backend/src/shared/services/shiprocketService.js
Other components
- Shopper
- Razorpay
Connections 37
- Shopper → Sign-in UI: signs in
- Shopper → Product discovery: browses
- Shopper → Checkout: checks out
- Shopper → Customer account: manages account
- Sign-in UI → Frontend API client: requests auth
- Product discovery → Frontend API client: requests products
- Checkout → Frontend API client: submits purchase
- Seller portal → Frontend API client: manages selling
- Admin dashboard → Frontend API client: manages platform
- Frontend API client → HTTP application: calls API
- HTTP application → Auth routes: mounts routes
backend/src/server.js - HTTP application → Admin routes: mounts routes
backend/src/server.js - Auth routes → Identity and onboarding: dispatches
backend/src/modules/auth/routes/authRoutes.js - Auth routes → Access control: guards routes
backend/src/modules/auth/routes/authRoutes.js - Identity and onboarding → Firebase data and auth: reads identity
backend/src/modules/auth/controllers/authController.js - Access control → Firebase data and auth: verifies tokens
backend/src/middleware/auth.js - Admin routes → Seller administration: dispatches
backend/src/modules/admin/routes/adminRoutes.js - Admin routes → Review administration: dispatches
backend/src/modules/admin/routes/adminRoutes.js - Product catalog → Firebase data and auth: reads catalog
backend/src/modules/products/controllers/productController.js - Seller operations → Firebase data and auth: reads seller data
backend/src/modules/seller/controllers/sellerController.js - Seller operations → Pricing calculations: calculates revenue
backend/src/modules/seller/controllers/sellerController.js - Seller operations → In-memory cache: invalidates cache
backend/src/modules/seller/controllers/sellerController.js - Order lifecycle → Firebase data and auth: reads orders
backend/src/modules/orders/controllers/orderController.js - Order lifecycle → In-memory cache: reads order cache
backend/src/modules/orders/controllers/orderController.js - Order lifecycle → Invoice generation: generates invoice
backend/src/modules/orders/controllers/orderController.js - Order lifecycle → Shiprocket integration: cancels shipment
backend/src/modules/orders/controllers/orderController.js - Payment processing → Razorpay: creates payment
backend/src/modules/payment/controllers/paymentController.js - Payment processing → Firebase data and auth: stores order
backend/src/modules/payment/controllers/paymentController.js - Payment processing → Stock updates: reduces stock
backend/src/modules/payment/controllers/paymentController.js - Payment processing → Invoice generation: generates invoice
backend/src/modules/payment/controllers/paymentController.js - Payment processing → Email notifications: notifies sellers
backend/src/modules/payment/controllers/paymentController.js - Payment processing → Shiprocket integration: creates shipment
backend/src/modules/payment/controllers/paymentController.js - Product reviews → Firebase data and auth: updates reviews
backend/src/modules/reviews/controllers/reviewController.js - Product reviews → In-memory cache: caches results
backend/src/modules/reviews/controllers/reviewController.js - Shipping estimates → Shiprocket integration: estimates shipping
- Seller administration → Firebase data and auth: reads seller records
backend/src/modules/admin/controllers/sellerManagementController.js - Review administration → Firebase data and auth: manages reviews
backend/src/modules/admin/controllers/reviewManagementController.js