How devbingacodes/fast-store works
FastStore is a commerce application with a shopper storefront, an administrative console, and an API backend. Shoppers browse products, manage a cart and address, check out, and follow orders, deliveries, wallet activity, and refunds; administrators manage catalog, orders, fulfillment, and financial operations. The backend includes payment settlement, refund processing, and account services. The excerpts establish frontend routing and webhook handling, but do not show most API-to-controller wiring, so those relationships are omitted.
Main entry points: refunds.js Refund processing · webhook.js Webhook handling · src/App.jsx Storefront routes · src/App.jsx Admin routes
Components 30
Shopper storefront
- Storefront routes
frontend/src/App.jsx - Store state
frontend/src/store/StoreProvider.jsx - Store context
frontend/src/store/context.js - Store API client
frontend/src/api.js - Checkout
frontend/src/pages/Checkout.jsx - Refunds
frontend/src/pages/Refunds.jsx
Admin console
- Admin routes
administrator/src/App.jsx - Admin API client
administrator/src/api.js - Admin context
administrator/src/store/AdminContext.js - Admin forms
administrator/src/components/FormControls.jsx - Admin UI
administrator/src/components/UI.jsx - Order management
administrator/src/pages/OrderDetails.jsx - Product management
administrator/src/pages/Products.jsx
Backend API
- HTTP API server
backend/index.js - Payment webhook routes
backend/routes/webhook.js - Webhook handling
backend/controllers/webhook.js - HTTP utilities
backend/utils/http.js
Commerce services
- Checkout and orders
backend/services/orders.js - Order records
backend/models/orders.js - Payment records
backend/models/paymentTransaction.js - Refund processing
backend/services/refunds.js - Refund records
backend/models/refund.js - Stripe integration
backend/services/stripe.js - PayPal integration
backend/services/paypal.js - Wallet operations
backend/services/wallet.js
Accounts and messaging
- User records
backend/models/users.js - Account email flows
backend/controllers/emailService.js - Email delivery
backend/services/email.js
Other components
- Shopper
- Administrator
Connections 33
- Shopper → Storefront routes: uses
frontend/src/App.jsx - Storefront routes → Store state: wraps
frontend/src/App.jsx - Storefront routes → Checkout: routes to
frontend/src/App.jsx - Storefront routes → Refunds: routes to
frontend/src/App.jsx - Store state → Store API client: requests through
frontend/src/store/StoreProvider.jsx - Store state → Store context: provides state
frontend/src/store/StoreProvider.jsx - Administrator → Admin routes: uses
administrator/src/App.jsx - Admin routes → Admin context: checks session
administrator/src/App.jsx - Admin routes → Order management: routes to
administrator/src/App.jsx - Admin routes → Product management: routes to
administrator/src/App.jsx - Order management → Admin API client: requests through
administrator/src/pages/OrderDetails.jsx - Order management → Admin forms: uses
administrator/src/pages/OrderDetails.jsx - Order management → Admin UI: uses
administrator/src/pages/OrderDetails.jsx - Product management → Admin API client: requests through
administrator/src/pages/Products.jsx - Product management → Admin forms: uses
administrator/src/pages/Products.jsx - Product management → Admin UI: uses
administrator/src/pages/Products.jsx - HTTP API server → Payment webhook routes: mounts routes
backend/index.js - Payment webhook routes → Webhook handling: dispatches to
backend/routes/webhook.js - Webhook handling → Checkout and orders: settles orders
backend/controllers/webhook.js - Webhook handling → Refund processing: syncs refunds
backend/controllers/webhook.js - Webhook handling → Stripe integration: verifies events
backend/controllers/webhook.js - Webhook handling → PayPal integration: verifies events
backend/controllers/webhook.js - Webhook handling → Wallet operations: settles wallet
backend/controllers/webhook.js - Checkout and orders → Order records: reads and writes
backend/services/orders.js - Checkout and orders → Payment records: records payment
backend/services/orders.js - Refund processing → Refund records: reads and writes
backend/services/refunds.js - Refund processing → Order records: updates order
backend/services/refunds.js - Refund processing → Payment records: records refund
backend/services/refunds.js - Refund processing → Stripe integration: requests refund
backend/services/refunds.js - Refund processing → PayPal integration: requests refund
backend/services/refunds.js - Refund processing → Wallet operations: credits wallet
backend/services/refunds.js - Account email flows → User records: updates account
backend/controllers/emailService.js - Account email flows → Email delivery: sends messages
backend/controllers/emailService.js