How mridulgandhi874/localiq works
LocaliQ is a hyperlocal marketplace for independent neighbourhood shops, with customer takeaway or delivery by LocaliQ riders. Customers discover nearby stock, obtain a server-recomputed quote, place and pay for an order, then follow its separate order and dispatch lifecycles. Merchants manage listings and fulfil orders; riders handle offers and delivery; admins oversee operations and catalog review. The source excerpts show search and quote/order behavior, while other capabilities and app roles are documented in the README; unsampled subsystem links are cited there rather than inferred from imports.
Main entry points: customer Customer app · mongo.ts MongoDB access · route.ts Order creation · orders.ts Order lifecycle
Components 24
Customer shopping
- Customer app
apps/customer - Product discovery
web/app/api/search/route.ts - Nearby shops
web/app/api/shops/nearby - Cart quote
web/app/api/orders/quote/route.ts - Order creation
web/app/api/orders/route.ts
Shop and delivery
- Merchant app
apps/merchant - Shop operations
web/app/api/shop - Rider app
apps/rider - Rider dispatch
web/lib/dispatch.ts - Rider workflow
web/app/api/rider
Platform operations
- Catalog review
web/app/api/admin/catalog-requests - Contributor app
apps/contributor - Admin console
web/app/admin - Admin operations
web/app/api/admin
API and services
- Payment handling
web/app/api/payments/webhook/route.ts - Payment provider
web/lib/payments/provider.ts - Order lifecycle
web/lib/orders.ts
Persistence and identity
- MongoDB access
web/lib/mongo.ts - Request authentication
web/lib/auth.ts - Firebase identity
web/lib/firebase-admin.ts
Other components
- Customer
- Merchant
- Rider
- Administrator
Connections 28
- Customer → Customer app: shops with
- Customer app → Product discovery: searches
- Customer app → Nearby shops: finds shops
- Product discovery → MongoDB access: reads products
web/app/api/search/route.ts - Product discovery → Nearby shops: resolves sellers
web/app/api/search/route.ts - Customer app → Cart quote: requests quote
- Cart quote → MongoDB access: recomputes cart
web/app/api/orders/quote/route.ts - Customer app → Order creation: submits token
web/app/api/orders/route.ts - Cart quote → Order creation: signs quote for
- Order creation → Order lifecycle: transitions status
web/app/api/orders/route.ts - Order creation → Payment handling: starts payment
- Payment handling → Payment provider: verifies event
- Payment handling → Order lifecycle: marks paid
- Merchant → Merchant app: manages shop
- Merchant app → Shop operations: manages listings
- Shop operations → MongoDB access: updates shop data
web/app/api/shop/listings/route.ts - Contributor app → Catalog review: submits scans
- Administrator → Admin console: operates platform
- Admin console → Admin operations: manages operations
- Admin operations → Rider dispatch: assigns riders
web/app/api/admin/dispatch/route.ts - Admin operations → MongoDB access: reviews catalog
- Rider → Rider app: handles deliveries
- Rider app → Rider workflow: accepts offers
- Rider workflow → Rider dispatch: updates dispatch
- Rider dispatch → Order lifecycle: tracks separate state
- Order lifecycle → MongoDB access: persists orders
- Customer app → Request authentication: authenticates
- Request authentication → Firebase identity: verifies token
web/lib/auth.ts