FixMate — Smart Device & Appliance Repair Platform
A full-stack device and home appliance repair platform built around a Pay-After-Service model, where customers track repairs live and pay via Stripe only after job completion. Features 3 role-based dashboards, server-enforced job pipelines, verified reviews, PDF invoices, and JWT-secured REST APIs.
Key Highlights & Features
Core architecture capabilities & functional highlights
3-Role RBAC Workbenches
Separate Customer, Technician, and Admin dashboards with JWT protection and Recharts analytics.
Pay-After-Service Checkout
Stripe payment unlocks only after job completion, settled safely via webhooks.
Server-Enforced Job Timeline
Strict repair stages (requested to completed) with live timestamp progress tracking.
Verified Reviews & PDF Invoices
Reviews locked to paid jobs, paired with instant jsPDF receipt downloads.
Paginated Catalog & Moderation
Server-side search, filters, and pagination with ImgBB uploads and admin approval.
System Overview & Workflow
In-depth technical architecture, engineering choices, and business impact
Project Overview & Mission
FixMate is a full-stack smart device and home appliance repair marketplace built around a strict Pay-After-Service trust model. Instead of paying upfront, customers request a repair, track every handoff in real time, and only unlock online Stripe payment after the technician completes the repair and logs the final verified cost.
Architecture & Engineering
user, services, bookings, payments)jose) API tokens with expiration enforcement and zero-retry guards on mutationsCore System Workflow
requested → accepted → in-progress → completed), appending timestamped entries to statusHistory for the live visual Job Timeline Tracker.completed status and finalAmount entry. Payments settle idempotently across redirect verification and webhook events, unlocking instant one-click PDF invoices via jsPDF.completed and paid, automatically recalculating service ratings.Key Engineering Challenges & Solutions
express.raw({ type: "application/json" }) strictly before express.json() so cryptographic signature verification never breaks, paired with idempotent database writes to prevent duplicate payment records.authFetch) that mints short-lived HS256 JWTs per request and validates user roles against MongoDB on every protected Express route.Repositories & Live Evaluation
4242 4242 4242 4242 (any future expiry date & any 3-digit CVC)Challenges & Engineered Solutions
Key engineering bottlenecks paired with the architecture decisions that solved them
Stripe Webhook Body Mutation & Duplicate Payments
Global JSON middleware alters the raw request stream and breaks Stripe signature verification, while redirect and webhook callbacks risk recording duplicate payments.
Raw-Buffer Route Ordering & Idempotency
Mounted the Stripe webhook endpoint with express.raw() strictly before express.json(), paired with idempotent session checks so every payment settles exactly once.
Cross-Origin Auth & Cold-Start Session Drops
Bridging a Next.js Better-Auth frontend with a standalone Express API can cause token sync issues and unintended sign-in redirects during database latency.
Reload-Safe JWT Bridge & Session Retries
Built an authFetch layer that mints short-lived HS256 JWTs per request, retries Better-Auth session reads on cold starts, and enforces Express RBAC ownership checks.
Booking Stage Skips & Unverified Reviews
Without server-side guards, repair stages could be skipped, customers could trigger checkout before completion, or users could submit duplicate reviews.
State-Machine Pipeline & Atomic Review Gates
Enforced sequential transitions (requested → accepted → in-progress → completed), locked Stripe checkout until completion, and gated reviews to paid jobs with atomic isReviewed flags.
Listing Quota Bypasses & Unsafe Mutation Retries
Client-only limits can be bypassed via direct API calls, and automatic HTTP retries on POST/PATCH mutations risk creating duplicate bookings.
Server Quota Enforcement & Zero-Retry Mutations
Validated the 3-service free tier limit in MongoDB before insertion (returning 403 with a Stripe Pro upgrade path) and disabled retries on all non-idempotent mutations.
Interface & Key Screens
Switch between screens below or expand any view in fullscreen
Potential Improvements & Future Plans
Planned architectural enhancements, upcoming feature modules, and engineering milestones
Real-Time WebSocket Integration
Implement bi-directional event streaming for instant collaborative updates, live notifications, and real-time activity indicators.
Progressive Web App (PWA) & Offline Sync
Add service worker caching and IndexedDB background sync for complete offline reliability across mobile and desktop devices.
Automated E2E Testing & CI/CD Pipeline
Deploy Playwright end-to-end testing alongside automated GitHub Actions workflows for continuous regression testing and preview deployments.
AI-Powered Analytics & Smart Recommendations
Incorporate intelligent personalization and usage telemetry to deliver tailored content recommendations and proactive anomaly alerts.

