# sumitsurwase06-code/homefix architecture

> Architecture diagram of the GitHub repository sumitsurwase06-code/homefix, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-17). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/sumitsurwase06-code/homefix
- Repository: https://github.com/sumitsurwase06-code/homefix

## Overview

HomeFix is a home-services marketplace connecting customers with technicians, with administrative oversight. The customer journey is service discovery and technician selection, booking, technician job handling, and—when needed—customer approval of a revised price. The frontend also exposes authentication and role-specific customer, technician, and admin areas. Backend excerpts show booking and price-change services, while the source index identifies supporting persistence, dashboard, and verification capabilities. Several subsystems are represented from the file tree or index; their internal links are omitted where no relationship was shown.

Main entry points: [`homefix-frontend/src/routes/AppRoutes.jsx`](https://github.com/sumitsurwase06-code/homefix/blob/main/homefix-frontend/src/routes/AppRoutes.jsx) (Role-based routes), [`backend/src/main/java/com/homefix/service/BookingService.java`](https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/service/BookingService.java) (Booking lifecycle), [`backend/src/main/java/com/homefix/service/PriceChangeService.java`](https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/service/PriceChangeService.java) (Price revisions), [`backend/src/main/java/com/homefix/repository`](https://github.com/sumitsurwase06-code/homefix/tree/main/backend/src/main/java/com/homefix/repository) (Persistence repositories)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_frontend["Web application"]
  node_routes["Role-based routes<br/>[AppRoutes.jsx]"]
  node_service_discovery["Service discovery<br/>[Services.jsx]"]
  node_service_catalog["Service catalog<br/>[services.js]"]
  node_booking_flow["Booking flow<br/>[BookService.jsx]"]
  node_auth_state["Authentication state<br/>[AuthContext.jsx]"]
  node_api_client["API client<br/>[api.js]"]
  node_customer_pages["Customer workspace"]
  node_technician_pages["Technician workspace"]
  node_admin_pages["Admin workspace"]
end

subgraph group_backend["Marketplace backend"]
  node_customer_controller["Customer endpoints"]
  node_technician_controller["Technician endpoints"]
  node_booking_service["Booking lifecycle"]
  node_price_service["Price revisions"]
  node_auth_service["Registration and login<br/>[AuthService.java]"]
  node_spring_api["Spring REST API"]
end

subgraph group_domain["Marketplace data"]
  node_domain_entities[("Marketplace entities")]
  node_repositories[("Persistence repositories")]
  node_booking_dto["Booking response DTO"]
  node_price_dto["Price response DTO"]
end

subgraph group_operations["Administration"]
  node_dashboard_service["Dashboard aggregation"]
  node_verification_service["Technician verification"]
end

node_customer(("Customer"))
node_technician(("Technician"))
node_admin(("Administrator"))

node_customer -.->|"opens app"| node_routes
node_technician -.->|"opens app"| node_routes
node_admin -.->|"opens app"| node_routes
node_routes -->|"routes to"| node_service_discovery
node_routes -->|"routes to"| node_customer_pages
node_routes -->|"routes to"| node_technician_pages
node_routes -->|"routes to"| node_admin_pages
node_service_discovery -->|"reads catalog"| node_service_catalog
node_booking_flow -->|"reads catalog"| node_service_catalog
node_booking_flow -->|"calls API"| node_api_client
node_auth_state -->|"calls auth API"| node_api_client
node_customer_controller -->|"calls"| node_booking_service
node_customer_controller -->|"calls"| node_price_service
node_technician_controller -->|"calls"| node_booking_service
node_technician_controller -->|"calls"| node_price_service
node_booking_service -->|"reads and writes"| node_repositories
node_price_service -->|"reads and writes"| node_repositories
node_booking_service -->|"creates booking"| node_domain_entities
node_price_service -->|"updates proposal"| node_domain_entities
node_booking_service -->|"builds response"| node_booking_dto
node_price_service -->|"builds response"| node_price_dto
node_auth_service -->|"persists accounts"| node_repositories
node_auth_service -->|"creates profiles"| node_domain_entities
node_dashboard_service -->|"aggregates data"| node_repositories
node_api_client -.->|"sends HTTP requests"| node_spring_api
node_admin_pages -.->|"requests dashboard"| node_dashboard_service
node_admin_pages -.->|"reviews technicians"| node_verification_service

click node_routes "https://github.com/sumitsurwase06-code/homefix/blob/main/homefix-frontend/src/routes/AppRoutes.jsx"
click node_service_discovery "https://github.com/sumitsurwase06-code/homefix/blob/main/homefix-frontend/src/pages/public/Services.jsx"
click node_service_catalog "https://github.com/sumitsurwase06-code/homefix/blob/main/homefix-frontend/src/data/services.js"
click node_booking_flow "https://github.com/sumitsurwase06-code/homefix/blob/main/homefix-frontend/src/pages/customer/BookService.jsx"
click node_auth_state "https://github.com/sumitsurwase06-code/homefix/blob/main/homefix-frontend/src/context/AuthContext.jsx"
click node_api_client "https://github.com/sumitsurwase06-code/homefix/blob/main/homefix-frontend/src/services/api.js"
click node_customer_pages "https://github.com/sumitsurwase06-code/homefix/tree/main/homefix-frontend/src/pages/customer"
click node_technician_pages "https://github.com/sumitsurwase06-code/homefix/tree/main/homefix-frontend/src/pages/technician"
click node_admin_pages "https://github.com/sumitsurwase06-code/homefix/tree/main/homefix-frontend/src/pages/admin"
click node_customer_controller "https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/controller/CustomerController.java"
click node_technician_controller "https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/controller/TechnicianController.java"
click node_booking_service "https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/service/BookingService.java"
click node_price_service "https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/service/PriceChangeService.java"
click node_auth_service "https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/service/AuthService.java"
click node_dashboard_service "https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/service/AdminDashboardService.java"
click node_verification_service "https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/service/TechnicianVerificationService.java"
click node_domain_entities "https://github.com/sumitsurwase06-code/homefix/tree/main/backend/src/main/java/com/homefix/entity"
click node_repositories "https://github.com/sumitsurwase06-code/homefix/tree/main/backend/src/main/java/com/homefix/repository"
click node_booking_dto "https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/dto/BookingResponse.java"
click node_price_dto "https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/dto/PriceChangeResponseDto.java"
click node_spring_api "https://github.com/sumitsurwase06-code/homefix/tree/main/backend/src/main/java/com/homefix/controller"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_routes,node_service_discovery,node_service_catalog,node_booking_flow,node_auth_state,node_api_client,node_customer_pages,node_technician_pages,node_admin_pages toneBlue
class node_customer_controller,node_technician_controller,node_booking_service,node_price_service,node_auth_service,node_spring_api toneAmber
class node_domain_entities,node_repositories,node_booking_dto,node_price_dto toneMint
class node_dashboard_service,node_verification_service toneRose
class node_customer,node_technician,node_admin toneIndigo
```

## Components

### Web application

- [Role-based routes](https://github.com/sumitsurwase06-code/homefix/blob/main/homefix-frontend/src/routes/AppRoutes.jsx): `homefix-frontend/src/routes/AppRoutes.jsx`
- [Service discovery](https://github.com/sumitsurwase06-code/homefix/blob/main/homefix-frontend/src/pages/public/Services.jsx): `homefix-frontend/src/pages/public/Services.jsx`
- [Service catalog](https://github.com/sumitsurwase06-code/homefix/blob/main/homefix-frontend/src/data/services.js): `homefix-frontend/src/data/services.js`
- [Booking flow](https://github.com/sumitsurwase06-code/homefix/blob/main/homefix-frontend/src/pages/customer/BookService.jsx): `homefix-frontend/src/pages/customer/BookService.jsx`
- [Authentication state](https://github.com/sumitsurwase06-code/homefix/blob/main/homefix-frontend/src/context/AuthContext.jsx): `homefix-frontend/src/context/AuthContext.jsx`
- [API client](https://github.com/sumitsurwase06-code/homefix/blob/main/homefix-frontend/src/services/api.js): `homefix-frontend/src/services/api.js`
- [Customer workspace](https://github.com/sumitsurwase06-code/homefix/tree/main/homefix-frontend/src/pages/customer): `homefix-frontend/src/pages/customer`
- [Technician workspace](https://github.com/sumitsurwase06-code/homefix/tree/main/homefix-frontend/src/pages/technician): `homefix-frontend/src/pages/technician`
- [Admin workspace](https://github.com/sumitsurwase06-code/homefix/tree/main/homefix-frontend/src/pages/admin): `homefix-frontend/src/pages/admin`

### Marketplace backend

- [Customer endpoints](https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/controller/CustomerController.java): `backend/src/main/java/com/homefix/controller/CustomerController.java`
- [Technician endpoints](https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/controller/TechnicianController.java): `backend/src/main/java/com/homefix/controller/TechnicianController.java`
- [Booking lifecycle](https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/service/BookingService.java): `backend/src/main/java/com/homefix/service/BookingService.java`
- [Price revisions](https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/service/PriceChangeService.java): `backend/src/main/java/com/homefix/service/PriceChangeService.java`
- [Registration and login](https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/service/AuthService.java): `backend/src/main/java/com/homefix/service/AuthService.java`
- [Spring REST API](https://github.com/sumitsurwase06-code/homefix/tree/main/backend/src/main/java/com/homefix/controller): `backend/src/main/java/com/homefix/controller`

### Marketplace data

- [Marketplace entities](https://github.com/sumitsurwase06-code/homefix/tree/main/backend/src/main/java/com/homefix/entity): `backend/src/main/java/com/homefix/entity`
- [Persistence repositories](https://github.com/sumitsurwase06-code/homefix/tree/main/backend/src/main/java/com/homefix/repository): `backend/src/main/java/com/homefix/repository`
- [Booking response DTO](https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/dto/BookingResponse.java): `backend/src/main/java/com/homefix/dto/BookingResponse.java`
- [Price response DTO](https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/dto/PriceChangeResponseDto.java): `backend/src/main/java/com/homefix/dto/PriceChangeResponseDto.java`

### Administration

- [Dashboard aggregation](https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/service/AdminDashboardService.java): `backend/src/main/java/com/homefix/service/AdminDashboardService.java`
- [Technician verification](https://github.com/sumitsurwase06-code/homefix/blob/main/backend/src/main/java/com/homefix/service/TechnicianVerificationService.java): `backend/src/main/java/com/homefix/service/TechnicianVerificationService.java`

### Other components

- **Customer**
- **Technician**
- **Administrator**

## Connections

- Customer → Role-based routes: opens app
- Technician → Role-based routes: opens app
- Administrator → Role-based routes: opens app
- Role-based routes → Service discovery: routes to (evidence: `homefix-frontend/src/routes/AppRoutes.jsx`)
- Role-based routes → Customer workspace: routes to (evidence: `homefix-frontend/src/routes/AppRoutes.jsx`)
- Role-based routes → Technician workspace: routes to (evidence: `homefix-frontend/src/routes/AppRoutes.jsx`)
- Role-based routes → Admin workspace: routes to (evidence: `homefix-frontend/src/routes/AppRoutes.jsx`)
- Service discovery → Service catalog: reads catalog (evidence: `homefix-frontend/src/pages/public/Services.jsx`)
- Booking flow → Service catalog: reads catalog (evidence: `homefix-frontend/src/pages/customer/BookService.jsx`)
- Booking flow → API client: calls API (evidence: `homefix-frontend/src/pages/customer/BookService.jsx`)
- Authentication state → API client: calls auth API (evidence: `homefix-frontend/src/context/AuthContext.jsx`)
- Customer endpoints → Booking lifecycle: calls (evidence: `backend/src/main/java/com/homefix/controller/CustomerController.java`)
- Customer endpoints → Price revisions: calls (evidence: `backend/src/main/java/com/homefix/controller/CustomerController.java`)
- Technician endpoints → Booking lifecycle: calls (evidence: `backend/src/main/java/com/homefix/controller/TechnicianController.java`)
- Technician endpoints → Price revisions: calls (evidence: `backend/src/main/java/com/homefix/controller/TechnicianController.java`)
- Booking lifecycle → Persistence repositories: reads and writes (evidence: `backend/src/main/java/com/homefix/service/BookingService.java`)
- Price revisions → Persistence repositories: reads and writes (evidence: `backend/src/main/java/com/homefix/service/PriceChangeService.java`)
- Booking lifecycle → Marketplace entities: creates booking (evidence: `backend/src/main/java/com/homefix/service/BookingService.java`)
- Price revisions → Marketplace entities: updates proposal (evidence: `backend/src/main/java/com/homefix/service/PriceChangeService.java`)
- Booking lifecycle → Booking response DTO: builds response (evidence: `backend/src/main/java/com/homefix/service/BookingService.java`)
- Price revisions → Price response DTO: builds response (evidence: `backend/src/main/java/com/homefix/service/PriceChangeService.java`)
- Registration and login → Persistence repositories: persists accounts (evidence: `backend/src/main/java/com/homefix/service/AuthService.java`)
- Registration and login → Marketplace entities: creates profiles (evidence: `backend/src/main/java/com/homefix/service/AuthService.java`)
- Dashboard aggregation → Persistence repositories: aggregates data (evidence: `backend/src/main/java/com/homefix/service/AdminDashboardService.java`)
- API client → Spring REST API: sends HTTP requests
- Admin workspace → Dashboard aggregation: requests dashboard
- Admin workspace → Technician verification: reviews technicians
