# manojspatil18/internship-portal architecture

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

- Interactive diagram: https://gitdiagram.com/manojspatil18/internship-portal
- Repository: https://github.com/manojspatil18/internship-portal

## Overview

InternHub is a student internship portal with student and recruiter experiences. Students register or sign in, browse listings, apply with a cover letter or resume, and track application status; companies register or sign in, post internships, review applicants, and update decisions. The React app routes role-protected pages to an Express API, whose routes use JWT middleware and a JSON-file store. The README documents search, filtering, and status tracking; some page implementations were not sampled, so their specific API connections are not asserted.

Main entry points: [`frontend/src/App.jsx`](https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/App.jsx) (Route application), [`backend/routes/applications.js`](https://github.com/manojspatil18/internship-portal/blob/main/backend/routes/applications.js) (Application routes), [`frontend/src/api/axios.js`](https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/api/axios.js) (HTTP client), [`backend/server.js`](https://github.com/manojspatil18/internship-portal/blob/main/backend/server.js) (Express server)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_web["Web application"]
  node_app["Route application<br/>[App.jsx]"]
  node_authctx["Session context<br/>[AuthContext.jsx]"]
  node_http["HTTP client<br/>[axios.js]"]
end

subgraph group_recruit["Student experience"]
  node_home["Portal home<br/>[Home.jsx]"]
  node_studentauth["Student access"]
  node_studentdash["Student dashboard"]
  node_browse["Browse listings"]
  node_myapps["Track applications<br/>[MyApplications.jsx]"]
end

subgraph group_employer["Company experience"]
  node_companyauth["Company access"]
  node_companydash["Manage listings"]
  node_post["Post internship<br/>[PostInternship.jsx]"]
  node_review["Review applicants"]
end

subgraph group_api["API and persistence"]
  node_server["Express server<br/>[server.js]"]
  node_authroutes["Authentication routes<br/>[auth.js]"]
  node_internroutes["Internship routes<br/>[internships.js]"]
  node_approutes["Application routes<br/>[applications.js]"]
  node_jwt["JWT verification<br/>[auth.js]"]
  node_store[("JSON data store<br/>[db.js]")]
  node_models["Domain records"]
  node_uploads["Resume files"]
end

node_visitor(("Student or recruiter"))

node_visitor -->|"opens"| node_app
node_app -->|"routes to"| node_home
node_app -->|"routes to"| node_studentauth
node_app -->|"protects route"| node_studentdash
node_app -->|"protects route"| node_browse
node_app -->|"protects route"| node_myapps
node_app -->|"routes to"| node_companyauth
node_app -->|"protects route"| node_companydash
node_app -->|"protects route"| node_post
node_app -->|"protects route"| node_review
node_app -->|"provides session"| node_authctx
node_studentdash -->|"reads session"| node_authctx
node_companydash -->|"reads session"| node_authctx
node_studentdash -->|"requests data"| node_http
node_companydash -->|"requests listings"| node_http
node_post -->|"sends listing"| node_http
node_review -->|"loads and updates"| node_http
node_server -->|"mounts"| node_authroutes
node_server -->|"mounts"| node_internroutes
node_server -->|"mounts"| node_approutes
node_authroutes -->|"reads and writes"| node_store
node_internroutes -->|"reads and writes"| node_store
node_approutes -->|"reads and writes"| node_store
node_internroutes -->|"verifies protected requests"| node_jwt
node_approutes -->|"verifies protected requests"| node_jwt
node_approutes -->|"stores resumes"| node_uploads

click node_app "https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/App.jsx"
click node_authctx "https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/context/AuthContext.jsx"
click node_http "https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/api/axios.js"
click node_home "https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/pages/Home.jsx"
click node_studentauth "https://github.com/manojspatil18/internship-portal/tree/main/frontend/src/pages/student"
click node_studentdash "https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/pages/student/StudentDashboard.jsx"
click node_browse "https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/pages/student/BrowseInternships.jsx"
click node_myapps "https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/pages/student/MyApplications.jsx"
click node_companyauth "https://github.com/manojspatil18/internship-portal/tree/main/frontend/src/pages/company"
click node_companydash "https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/pages/company/CompanyDashboard.jsx"
click node_post "https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/pages/company/PostInternship.jsx"
click node_review "https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/pages/company/ViewApplications.jsx"
click node_server "https://github.com/manojspatil18/internship-portal/blob/main/backend/server.js"
click node_authroutes "https://github.com/manojspatil18/internship-portal/blob/main/backend/routes/auth.js"
click node_internroutes "https://github.com/manojspatil18/internship-portal/blob/main/backend/routes/internships.js"
click node_approutes "https://github.com/manojspatil18/internship-portal/blob/main/backend/routes/applications.js"
click node_jwt "https://github.com/manojspatil18/internship-portal/blob/main/backend/middleware/auth.js"
click node_store "https://github.com/manojspatil18/internship-portal/blob/main/backend/data/db.js"
click node_models "https://github.com/manojspatil18/internship-portal/tree/main/backend/models"
click node_uploads "https://github.com/manojspatil18/internship-portal/tree/main/backend/uploads"

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_app,node_authctx,node_http toneBlue
class node_home,node_studentauth,node_studentdash,node_browse,node_myapps toneAmber
class node_companyauth,node_companydash,node_post,node_review toneMint
class node_server,node_authroutes,node_internroutes,node_approutes,node_jwt,node_store,node_models,node_uploads toneRose
class node_visitor toneIndigo
```

## Components

### Web application

- [Route application](https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/App.jsx): `frontend/src/App.jsx`
- [Session context](https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/context/AuthContext.jsx): `frontend/src/context/AuthContext.jsx`
- [HTTP client](https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/api/axios.js): `frontend/src/api/axios.js`

### Student experience

- [Portal home](https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/pages/Home.jsx): `frontend/src/pages/Home.jsx`
- [Student access](https://github.com/manojspatil18/internship-portal/tree/main/frontend/src/pages/student): `frontend/src/pages/student`
- [Student dashboard](https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/pages/student/StudentDashboard.jsx): `frontend/src/pages/student/StudentDashboard.jsx`
- [Browse listings](https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/pages/student/BrowseInternships.jsx): `frontend/src/pages/student/BrowseInternships.jsx`
- [Track applications](https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/pages/student/MyApplications.jsx): `frontend/src/pages/student/MyApplications.jsx`

### Company experience

- [Company access](https://github.com/manojspatil18/internship-portal/tree/main/frontend/src/pages/company): `frontend/src/pages/company`
- [Manage listings](https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/pages/company/CompanyDashboard.jsx): `frontend/src/pages/company/CompanyDashboard.jsx`
- [Post internship](https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/pages/company/PostInternship.jsx): `frontend/src/pages/company/PostInternship.jsx`
- [Review applicants](https://github.com/manojspatil18/internship-portal/blob/main/frontend/src/pages/company/ViewApplications.jsx): `frontend/src/pages/company/ViewApplications.jsx`

### API and persistence

- [Express server](https://github.com/manojspatil18/internship-portal/blob/main/backend/server.js): `backend/server.js`
- [Authentication routes](https://github.com/manojspatil18/internship-portal/blob/main/backend/routes/auth.js): `backend/routes/auth.js`
- [Internship routes](https://github.com/manojspatil18/internship-portal/blob/main/backend/routes/internships.js): `backend/routes/internships.js`
- [Application routes](https://github.com/manojspatil18/internship-portal/blob/main/backend/routes/applications.js): `backend/routes/applications.js`
- [JWT verification](https://github.com/manojspatil18/internship-portal/blob/main/backend/middleware/auth.js): `backend/middleware/auth.js`
- [JSON data store](https://github.com/manojspatil18/internship-portal/blob/main/backend/data/db.js): `backend/data/db.js`
- [Domain records](https://github.com/manojspatil18/internship-portal/tree/main/backend/models): `backend/models`
- [Resume files](https://github.com/manojspatil18/internship-portal/tree/main/backend/uploads): `backend/uploads`

### Other components

- **Student or recruiter**

## Connections

- Student or recruiter → Route application: opens (evidence: `README.md`)
- Route application → Portal home: routes to (evidence: `frontend/src/App.jsx`)
- Route application → Student access: routes to (evidence: `frontend/src/App.jsx`)
- Route application → Student dashboard: protects route (evidence: `frontend/src/App.jsx`)
- Route application → Browse listings: protects route (evidence: `frontend/src/App.jsx`)
- Route application → Track applications: protects route (evidence: `frontend/src/App.jsx`)
- Route application → Company access: routes to (evidence: `frontend/src/App.jsx`)
- Route application → Manage listings: protects route (evidence: `frontend/src/App.jsx`)
- Route application → Post internship: protects route (evidence: `frontend/src/App.jsx`)
- Route application → Review applicants: protects route (evidence: `frontend/src/App.jsx`)
- Route application → Session context: provides session (evidence: `frontend/src/App.jsx`)
- Student dashboard → Session context: reads session (evidence: `frontend/src/pages/student/StudentDashboard.jsx`)
- Manage listings → Session context: reads session (evidence: `frontend/src/pages/company/CompanyDashboard.jsx`)
- Student dashboard → HTTP client: requests data (evidence: `frontend/src/pages/student/StudentDashboard.jsx`)
- Manage listings → HTTP client: requests listings (evidence: `frontend/src/pages/company/CompanyDashboard.jsx`)
- Post internship → HTTP client: sends listing (evidence: `frontend/src/pages/company/PostInternship.jsx`)
- Review applicants → HTTP client: loads and updates (evidence: `frontend/src/pages/company/ViewApplications.jsx`)
- Express server → Authentication routes: mounts (evidence: `backend/server.js`)
- Express server → Internship routes: mounts (evidence: `backend/server.js`)
- Express server → Application routes: mounts (evidence: `backend/server.js`)
- Authentication routes → JSON data store: reads and writes (evidence: `backend/routes/auth.js`)
- Internship routes → JSON data store: reads and writes (evidence: `backend/routes/internships.js`)
- Application routes → JSON data store: reads and writes (evidence: `backend/routes/applications.js`)
- Internship routes → JWT verification: verifies protected requests (evidence: `backend/routes/internships.js`)
- Application routes → JWT verification: verifies protected requests (evidence: `backend/routes/applications.js`)
- Application routes → Resume files: stores resumes (evidence: `backend/routes/applications.js`)
