# gopivemuri-tech/hirehub-smart-recruitment-platform architecture

> Architecture diagram of the GitHub repository gopivemuri-tech/hirehub-smart-recruitment-platform, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-25). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/gopivemuri-tech/hirehub-smart-recruitment-platform
- Repository: https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform

## Overview

HireHub supports jobseekers discovering and matching opportunities, applying to native jobs or tracking external applications, and recruiters managing candidates through hiring stages; administrators oversee users, jobs, and platform activity. The React client presents role-specific workflows and calls an Express REST API. The API connects matching, recruitment, external discovery, and tracking services to MySQL-backed models. README capabilities are represented where route or service excerpts were not sampled; those internal links are therefore limited to documented or clearly named subsystem boundaries.

Main entry points: [`server/src/server.js`](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/server.js) (Express app), [`client/src/App.jsx`](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/client/src/App.jsx) (Role dashboards), [`server/src/services/matchingEngine.js`](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/services/matchingEngine.js) (Weighted matching), [`server/src/routes/applications.js`](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/applications.js) (Applications)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_client["Web client"]
  node_webapp["Role dashboards<br/>[App.jsx]"]
  node_authstate["Session state<br/>[AuthContext.jsx]"]
  node_apiclient["API client<br/>[api.js]"]
end

subgraph group_api["REST API"]
  node_server["Express app<br/>[server.js]"]
  node_authroutes["Accounts<br/>[auth.js]"]
  node_jobroutes["Job listings<br/>[jobs.js]"]
  node_applicationroutes["Applications<br/>[applications.js]"]
  node_adminroutes["Administration<br/>[admin.js]"]
  node_autoroutes["Auto Apply<br/>[autoApply.js]"]
  node_externalroutes["External listings<br/>[externalJobs.js]"]
  node_trackingroutes["External tracking"]
  node_centerroute["Candidate center<br/>[jobseekerCenter.js]"]
end

subgraph group_recruitment["Recruitment workflows"]
  node_matching["Weighted matching<br/>[matchingEngine.js]"]
  node_profile["Profile readiness"]
end

subgraph group_discovery["Discovery and tracking"]
  node_jobsservice["Job discovery"]
  node_sources["Source registry"]
  node_externalservice["External activity"]
end

subgraph group_persistence["Persistence"]
  node_models["Domain models<br/>[index.js]"]
  node_applicationsmodel["Native applications<br/>[Application.js]"]
  node_database[("MySQL<br/>[database.js]")]
  node_schema["Schema setup<br/>[schemaManager.js]"]
end

node_jobseeker(("Jobseeker"))
node_employer(("Recruiter"))
node_admin(("Administrator"))
node_serpapi["SerpAPI"]

node_jobseeker -->|"uses"| node_webapp
node_employer -->|"uses"| node_webapp
node_admin -->|"uses"| node_webapp
node_webapp -->|"provides session"| node_authstate
node_webapp -->|"requests data"| node_apiclient
node_apiclient -->|"sends REST requests"| node_server
node_server -->|"mounts"| node_authroutes
node_server -->|"mounts"| node_jobroutes
node_server -->|"mounts"| node_applicationroutes
node_server -->|"mounts"| node_adminroutes
node_server -->|"mounts"| node_autoroutes
node_server -->|"mounts"| node_externalroutes
node_server -->|"mounts"| node_trackingroutes
node_server -->|"mounts"| node_centerroute
node_server -->|"initializes schema"| node_schema
node_applicationroutes -->|"creates matched application"| node_matching
node_matching -->|"creates application"| node_applicationsmodel
node_applicationroutes -->|"reads and updates"| node_applicationsmodel
node_autoroutes -->|"requests auto apply"| node_matching
node_centerroute -->|"requests matches"| node_matching
node_centerroute -->|"checks readiness"| node_profile
node_externalroutes -->|"searches listings"| node_jobsservice
node_jobsservice -->|"validates sources"| node_sources
node_jobsservice -.->|"queries provider"| node_serpapi
node_trackingroutes -->|"tracks activity"| node_externalservice
node_externalservice -->|"repairs schema"| node_schema
node_externalservice -->|"reads and writes"| node_models
node_matching -->|"loads candidate and jobs"| node_models
node_applicationsmodel -->|"persists records"| node_database
node_models -->|"stores domain data"| node_database
node_schema -->|"prepares schema"| node_database

click node_webapp "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/client/src/App.jsx"
click node_authstate "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/client/src/context/AuthContext.jsx"
click node_apiclient "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/client/src/api.js"
click node_server "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/server.js"
click node_authroutes "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/auth.js"
click node_jobroutes "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/jobs.js"
click node_applicationroutes "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/applications.js"
click node_adminroutes "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/admin.js"
click node_autoroutes "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/autoApply.js"
click node_externalroutes "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/externalJobs.js"
click node_trackingroutes "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/externalApplications.js"
click node_centerroute "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/jobseekerCenter.js"
click node_matching "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/services/matchingEngine.js"
click node_profile "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/services/profileReadiness.js"
click node_jobsservice "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/services/externalJobsService.js"
click node_sources "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/services/jobSourceRegistry.js"
click node_externalservice "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/services/externalApplicationService.js"
click node_models "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/models/index.js"
click node_applicationsmodel "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/models/Application.js"
click node_database "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/config/database.js"
click node_schema "https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/schemaManager.js"

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_webapp,node_authstate,node_apiclient toneBlue
class node_server,node_authroutes,node_jobroutes,node_applicationroutes,node_adminroutes,node_autoroutes,node_externalroutes,node_trackingroutes,node_centerroute toneAmber
class node_matching,node_profile,node_serpapi toneMint
class node_jobsservice,node_sources,node_externalservice toneRose
class node_models,node_applicationsmodel,node_database,node_schema,node_jobseeker,node_employer,node_admin toneIndigo
```

## Components

### Web client

- [Role dashboards](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/client/src/App.jsx): `client/src/App.jsx`
- [Session state](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/client/src/context/AuthContext.jsx): `client/src/context/AuthContext.jsx`
- [API client](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/client/src/api.js): `client/src/api.js`

### REST API

- [Express app](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/server.js): `server/src/server.js`
- [Accounts](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/auth.js): `server/src/routes/auth.js`
- [Job listings](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/jobs.js): `server/src/routes/jobs.js`
- [Applications](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/applications.js): `server/src/routes/applications.js`
- [Administration](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/admin.js): `server/src/routes/admin.js`
- [Auto Apply](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/autoApply.js): `server/src/routes/autoApply.js`
- [External listings](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/externalJobs.js): `server/src/routes/externalJobs.js`
- [External tracking](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/externalApplications.js): `server/src/routes/externalApplications.js`
- [Candidate center](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/routes/jobseekerCenter.js): `server/src/routes/jobseekerCenter.js`

### Recruitment workflows

- [Weighted matching](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/services/matchingEngine.js): `server/src/services/matchingEngine.js`
- [Profile readiness](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/services/profileReadiness.js): `server/src/services/profileReadiness.js`

### Discovery and tracking

- [Job discovery](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/services/externalJobsService.js): `server/src/services/externalJobsService.js`
- [Source registry](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/services/jobSourceRegistry.js): `server/src/services/jobSourceRegistry.js`
- [External activity](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/services/externalApplicationService.js): `server/src/services/externalApplicationService.js`

### Persistence

- [Domain models](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/models/index.js): `server/src/models/index.js`
- [Native applications](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/models/Application.js): `server/src/models/Application.js`
- [MySQL](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/config/database.js): `server/src/config/database.js`
- [Schema setup](https://github.com/gopivemuri-tech/hirehub-smart-recruitment-platform/blob/main/server/src/schemaManager.js): `server/src/schemaManager.js`

### Other components

- **Jobseeker**
- **Recruiter**
- **Administrator**
- **SerpAPI**

## Connections

- Jobseeker → Role dashboards: uses
- Recruiter → Role dashboards: uses
- Administrator → Role dashboards: uses
- Role dashboards → Session state: provides session
- Role dashboards → API client: requests data
- API client → Express app: sends REST requests
- Express app → Accounts: mounts
- Express app → Job listings: mounts
- Express app → Applications: mounts
- Express app → Administration: mounts
- Express app → Auto Apply: mounts
- Express app → External listings: mounts
- Express app → External tracking: mounts
- Express app → Candidate center: mounts
- Express app → Schema setup: initializes schema
- Applications → Weighted matching: creates matched application
- Weighted matching → Native applications: creates application
- Applications → Native applications: reads and updates
- Auto Apply → Weighted matching: requests auto apply
- Candidate center → Weighted matching: requests matches
- Candidate center → Profile readiness: checks readiness
- External listings → Job discovery: searches listings
- Job discovery → Source registry: validates sources
- Job discovery → SerpAPI: queries provider
- External tracking → External activity: tracks activity
- External activity → Schema setup: repairs schema
- External activity → Domain models: reads and writes
- Weighted matching → Domain models: loads candidate and jobs
- Native applications → MySQL: persists records
- Domain models → MySQL: stores domain data
- Schema setup → MySQL: prepares schema
