# anujworld10/rps_school_roh architecture

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

- Interactive diagram: https://gitdiagram.com/anujworld10/rps_school_roh
- Repository: https://github.com/anujworld10/rps_school_roh

## Overview

This is a school management system with a React frontend and FastAPI backend. Public applicants submit inquiries and track or update them; staff review inquiries, schedule interviews, create admissions, verify required documents, and enroll approved applicants as students. Staff also manage classes, subjects, teachers, fees, and academic results, while role-specific portals expose teaching and student workflows. The README documents attendance and salary capabilities, though the frontend pages remain placeholders. Backend route excerpts show service dispatch, but most service and persistence relationships were not sampled, so those links are omitted rather than inferred.

Main entry points: [`app/db/session.py`](https://github.com/anujworld10/rps_school_roh/blob/main/app/db/session.py) (SQL database), [`frontend/src/App.tsx`](https://github.com/anujworld10/rps_school_roh/blob/main/frontend/src/App.tsx) (Web routes), [`frontend/src/lib/api/api-client.ts`](https://github.com/anujworld10/rps_school_roh/blob/main/frontend/src/lib/api/api-client.ts) (API client), [`app/api/v1/admissions/routes.py`](https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/admissions/routes.py) (Admission routes)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_frontend["Web application"]
  node_web["Web routes<br/>[App.tsx]"]
  node_public_pages["Public application"]
  node_student_pages["Student workflows"]
  node_staff_pages["Staff workflows"]
  node_role_pages["Role portals"]
  node_api_client["API client<br/>[api-client.ts]"]
end

subgraph group_intake["Inquiry and admissions"]
  node_public_routes["Public intake routes<br/>[routes.py]"]
  node_inquiry_routes["Inquiry routes<br/>[routes.py]"]
  node_inquiry_service["Inquiry service<br/>[inquiries.py]"]
  node_interviews["Interviews<br/>[routes.py]"]
  node_admission_routes["Admission routes<br/>[routes.py]"]
  node_admission_service["Admission processing"]
  node_enrollment["Enrollment<br/>[enrollment.py]"]
end

subgraph group_school["School operations"]
  node_students["Student records<br/>[routes.py]"]
  node_classes["Classes<br/>[routes.py]"]
  node_teachers["Teachers<br/>[routes.py]"]
  node_academics["Academics<br/>[routes.py]"]
  node_fees["Fees<br/>[routes.py]"]
  node_role_portal["Role portal<br/>[routes.py]"]
  node_dashboard["Dashboard<br/>[routes.py]"]
end

subgraph group_platform["API and identity"]
  node_api["FastAPI service<br/>[main.py]"]
  node_auth_routes["Authentication<br/>[routes.py]"]
  node_auth_service["Auth service<br/>[auth.py]"]
end

subgraph group_data["Persistence"]
  node_database[("SQL database<br/>[session.py]")]
  node_uploads["Admission documents<br/>[file_storage.py]"]
end

node_applicant(("Applicant"))
node_staff(("School staff"))

node_applicant -->|"submits or tracks"| node_public_pages
node_staff -->|"manages records"| node_staff_pages
node_staff -->|"uses portal"| node_role_pages
node_web -->|"routes to"| node_public_pages
node_web -->|"routes to"| node_student_pages
node_web -->|"routes to"| node_staff_pages
node_web -->|"routes to"| node_role_pages
node_public_pages -.->|"calls API"| node_api_client
node_staff_pages -.->|"calls API"| node_api_client
node_role_pages -.->|"calls API"| node_api_client
node_api_client -.->|"sends requests"| node_api
node_api -->|"checks readiness"| node_database
node_api -.->|"mounts routes"| node_public_routes
node_auth_routes -->|"dispatches auth"| node_auth_service
node_public_routes -->|"handles inquiries"| node_inquiry_service
node_inquiry_routes -->|"dispatches inquiries"| node_inquiry_service
node_admission_routes -->|"processes admissions"| node_admission_service
node_admission_routes -.->|"enrolls approved"| node_enrollment
node_students -->|"uses session"| node_database
node_classes -->|"uses session"| node_database
node_teachers -.->|"uses session"| node_database
node_academics -->|"uses session"| node_database
node_fees -.->|"uses session"| node_database
node_role_portal -->|"uses session"| node_database
node_admission_routes -->|"serves document"| node_uploads

click node_web "https://github.com/anujworld10/rps_school_roh/blob/main/frontend/src/App.tsx"
click node_public_pages "https://github.com/anujworld10/rps_school_roh/blob/main/frontend/src/pages/public-admissions-pages.tsx"
click node_student_pages "https://github.com/anujworld10/rps_school_roh/blob/main/frontend/src/pages/student-registration-page.tsx"
click node_staff_pages "https://github.com/anujworld10/rps_school_roh/blob/main/frontend/src/pages/admissions-page.tsx"
click node_role_pages "https://github.com/anujworld10/rps_school_roh/blob/main/frontend/src/pages/role-portal-page.tsx"
click node_api_client "https://github.com/anujworld10/rps_school_roh/blob/main/frontend/src/lib/api/api-client.ts"
click node_api "https://github.com/anujworld10/rps_school_roh/blob/main/app/main.py"
click node_auth_routes "https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/auth/routes.py"
click node_auth_service "https://github.com/anujworld10/rps_school_roh/blob/main/app/services/auth.py"
click node_public_routes "https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/public/student/routes.py"
click node_inquiry_routes "https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/inquiries/routes.py"
click node_inquiry_service "https://github.com/anujworld10/rps_school_roh/blob/main/app/services/inquiries.py"
click node_interviews "https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/interviews/routes.py"
click node_admission_routes "https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/admissions/routes.py"
click node_admission_service "https://github.com/anujworld10/rps_school_roh/blob/main/app/services/inquiry_admissions.py"
click node_enrollment "https://github.com/anujworld10/rps_school_roh/blob/main/app/services/enrollment.py"
click node_students "https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/students/routes.py"
click node_classes "https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/classes/routes.py"
click node_teachers "https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/teachers/routes.py"
click node_academics "https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/academics/routes.py"
click node_fees "https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/fees/routes.py"
click node_role_portal "https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/role_portal/routes.py"
click node_dashboard "https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/dashboard/routes.py"
click node_database "https://github.com/anujworld10/rps_school_roh/blob/main/app/db/session.py"
click node_uploads "https://github.com/anujworld10/rps_school_roh/blob/main/app/utils/file_storage.py"

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_web,node_public_pages,node_student_pages,node_staff_pages,node_role_pages,node_api_client toneBlue
class node_public_routes,node_inquiry_routes,node_inquiry_service,node_interviews,node_admission_routes,node_admission_service,node_enrollment toneAmber
class node_students,node_classes,node_teachers,node_academics,node_fees,node_role_portal,node_dashboard toneMint
class node_api,node_auth_routes,node_auth_service toneRose
class node_database,node_uploads,node_applicant,node_staff toneIndigo
```

## Components

### Web application

- [Web routes](https://github.com/anujworld10/rps_school_roh/blob/main/frontend/src/App.tsx): `frontend/src/App.tsx`
- [Public application](https://github.com/anujworld10/rps_school_roh/blob/main/frontend/src/pages/public-admissions-pages.tsx): `frontend/src/pages/public-admissions-pages.tsx`
- [Student workflows](https://github.com/anujworld10/rps_school_roh/blob/main/frontend/src/pages/student-registration-page.tsx): `frontend/src/pages/student-registration-page.tsx`
- [Staff workflows](https://github.com/anujworld10/rps_school_roh/blob/main/frontend/src/pages/admissions-page.tsx): `frontend/src/pages/admissions-page.tsx`
- [Role portals](https://github.com/anujworld10/rps_school_roh/blob/main/frontend/src/pages/role-portal-page.tsx): `frontend/src/pages/role-portal-page.tsx`
- [API client](https://github.com/anujworld10/rps_school_roh/blob/main/frontend/src/lib/api/api-client.ts): `frontend/src/lib/api/api-client.ts`

### Inquiry and admissions

- [Public intake routes](https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/public/student/routes.py): `app/api/v1/public/student/routes.py`
- [Inquiry routes](https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/inquiries/routes.py): `app/api/v1/inquiries/routes.py`
- [Inquiry service](https://github.com/anujworld10/rps_school_roh/blob/main/app/services/inquiries.py): `app/services/inquiries.py`
- [Interviews](https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/interviews/routes.py): `app/api/v1/interviews/routes.py`
- [Admission routes](https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/admissions/routes.py): `app/api/v1/admissions/routes.py`
- [Admission processing](https://github.com/anujworld10/rps_school_roh/blob/main/app/services/inquiry_admissions.py): `app/services/inquiry_admissions.py`
- [Enrollment](https://github.com/anujworld10/rps_school_roh/blob/main/app/services/enrollment.py): `app/services/enrollment.py`

### School operations

- [Student records](https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/students/routes.py): `app/api/v1/students/routes.py`
- [Classes](https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/classes/routes.py): `app/api/v1/classes/routes.py`
- [Teachers](https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/teachers/routes.py): `app/api/v1/teachers/routes.py`
- [Academics](https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/academics/routes.py): `app/api/v1/academics/routes.py`
- [Fees](https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/fees/routes.py): `app/api/v1/fees/routes.py`
- [Role portal](https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/role_portal/routes.py): `app/api/v1/role_portal/routes.py`
- [Dashboard](https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/dashboard/routes.py): `app/api/v1/dashboard/routes.py`

### API and identity

- [FastAPI service](https://github.com/anujworld10/rps_school_roh/blob/main/app/main.py): `app/main.py`
- [Authentication](https://github.com/anujworld10/rps_school_roh/blob/main/app/api/v1/auth/routes.py): `app/api/v1/auth/routes.py`
- [Auth service](https://github.com/anujworld10/rps_school_roh/blob/main/app/services/auth.py): `app/services/auth.py`

### Persistence

- [SQL database](https://github.com/anujworld10/rps_school_roh/blob/main/app/db/session.py): `app/db/session.py`
- [Admission documents](https://github.com/anujworld10/rps_school_roh/blob/main/app/utils/file_storage.py): `app/utils/file_storage.py`

### Other components

- **Applicant**
- **School staff**

## Connections

- Applicant → Public application: submits or tracks
- School staff → Staff workflows: manages records
- School staff → Role portals: uses portal
- Web routes → Public application: routes to (evidence: `frontend/src/App.tsx`)
- Web routes → Student workflows: routes to (evidence: `frontend/src/App.tsx`)
- Web routes → Staff workflows: routes to (evidence: `frontend/src/App.tsx`)
- Web routes → Role portals: routes to (evidence: `frontend/src/App.tsx`)
- Public application → API client: calls API
- Staff workflows → API client: calls API
- Role portals → API client: calls API
- API client → FastAPI service: sends requests
- FastAPI service → SQL database: checks readiness (evidence: `app/main.py`)
- FastAPI service → Public intake routes: mounts routes
- Authentication → Auth service: dispatches auth (evidence: `app/api/v1/auth/routes.py`)
- Public intake routes → Inquiry service: handles inquiries (evidence: `app/api/v1/public/student/routes.py`)
- Inquiry routes → Inquiry service: dispatches inquiries (evidence: `app/api/v1/inquiries/routes.py`)
- Admission routes → Admission processing: processes admissions (evidence: `app/api/v1/admissions/routes.py`)
- Admission routes → Enrollment: enrolls approved (evidence: `app/api/v1/admissions/routes.py`)
- Student records → SQL database: uses session (evidence: `app/api/v1/students/routes.py`)
- Classes → SQL database: uses session (evidence: `app/api/v1/classes/routes.py`)
- Teachers → SQL database: uses session (evidence: `app/api/v1/teachers/routes.py`)
- Academics → SQL database: uses session (evidence: `app/api/v1/academics/routes.py`)
- Fees → SQL database: uses session (evidence: `app/api/v1/fees/routes.py`)
- Role portal → SQL database: uses session (evidence: `app/api/v1/role_portal/routes.py`)
- Admission routes → Admission documents: serves document (evidence: `app/api/v1/admissions/routes.py`)
