How vrindanarang/unithrift works
Campus Exchange is a campus-restricted student marketplace. Students authenticate, browse or manage listings, and can create wanted requests; listings may trigger matching-request email notifications. The map includes documented marketplace, account, dashboard, and upload capabilities, plus repository-backed chat, AI, wishlist, and administration branches. Several frontend and backend subsystems are represented by their exact tree directories because their implementation files were not sampled; their internal links are omitted where evidence does not establish call ownership.
Main entry points: app.js Express API · listing.controller.js Listing handlers · App.jsx Web application · auth.service.js Account and verification
Components 22
Student experience
- Web application
frontend/src/App.jsx - Account experience
frontend/src/context/AuthContext.jsx - Marketplace and dashboard
frontend/src/pages - HTTP client
frontend/src/api/axios.js
API and domain
- Express API
backend/src/app.js - Authentication routes
backend/src/routes/auth.routes.js - Authentication handlers
backend/src/controllers/auth.controller.js - Account and verification
backend/src/services/auth.service.js - Listing routes
backend/src/routes/listing.routes.js - Listing handlers
backend/src/controllers/listing.controller.js - Listing search and management
backend/src/services/listing.service.js - Wanted requests
backend/src/services/wantedRequest.service.js - User, wishlist, admin, AI
backend/src/routes - Domain services
backend/src/services - Chat API and service
backend/src/routes/chat.routes.js
Data and integrations
- MySQL via Prisma
backend/src/config/db.js - Cloudinary images
backend/src/utils/uploadImage.js - Email delivery
backend/src/services/email.service.js
Realtime and discovery
- Socket.IO
backend/src/socket/index.js - Semantic embeddings
backend/src/services/embedding.service.js - Gemini service
backend/src/config/gemini.js
Other components
- Student
Connections 24
- Student → Web application: uses
README.md - Web application → Account experience: hosts
frontend/src/main.jsx - Web application → Marketplace and dashboard: renders
- Account experience → HTTP client: requests through
frontend/src/context/AuthContext.jsx - HTTP client → Express API: calls
- Express API → Authentication routes: routes to
backend/src/app.js - Express API → Listing routes: routes to
backend/src/app.js - Express API → User, wishlist, admin, AI: routes to
backend/src/app.js - Express API → Chat API and service: routes to
backend/src/app.js - Authentication routes → Authentication handlers: dispatches to
backend/src/routes/auth.routes.js - Authentication handlers → Account and verification: calls
backend/src/controllers/auth.controller.js - Account and verification → MySQL via Prisma: reads and writes
backend/src/services/auth.service.js - Account and verification → Email delivery: sends verification
backend/src/services/auth.service.js - Listing routes → Listing handlers: dispatches to
backend/src/routes/listing.routes.js - Listing handlers → Listing search and management: calls
backend/src/controllers/listing.controller.js - Listing handlers → Cloudinary images: uploads images
backend/src/controllers/listing.controller.js - Listing handlers → Wanted requests: notifies matches
backend/src/controllers/listing.controller.js - Listing search and management → MySQL via Prisma: persists listings
- Wanted requests → Email delivery: emails matches
README.md - User, wishlist, admin, AI → Domain services: dispatches to
- User, wishlist, admin, AI → Chat API and service: includes chat endpoints
backend/src/app.js - Domain services → MySQL via Prisma: uses data store
backend/src/services/auth.service.js - Chat API and service → Socket.IO: supports realtime messaging
- Semantic embeddings → Gemini service: requests vectors
backend/src/services/embedding.service.js