# pruthvimax/manikya_chitfund_official architecture

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

- Interactive diagram: https://gitdiagram.com/pruthvimax/manikya_chitfund_official
- Repository: https://github.com/pruthvimax/manikya_chitfund_official

## Overview

Manikya Chits is a mobile and backend system for administering chit-fund memberships and operations. Members enter through the mobile app to access account, group, payment, and auction features; employees handle enrollments, collections, and daily work; administrators manage people, schemes, groups, and operational requests. The backend exposes these capabilities through an Express API, with controllers operating on MongoDB-backed models. README capabilities and the tree support the broad subsystem map; only enrollment, group, notification, and bid implementation details were sampled, so other internal wiring is left unspecified.

Main entry points: [`backend/index.js`](https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/index.js) (Express server), [`backend/models`](https://github.com/pruthvimax/manikya_chitfund_official/tree/main/backend/models) (Mongoose models), [`backend/controllers`](https://github.com/pruthvimax/manikya_chitfund_official/tree/main/backend/controllers) (Domain controllers), [`app/index.tsx`](https://github.com/pruthvimax/manikya_chitfund_official/blob/main/app/index.tsx) (Mobile entry)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_mobile["Mobile app"]
  node_mobile_home["Mobile entry<br/>[index.tsx]"]
  node_member_pages["Member features"]
  node_employee_pages["Employee portal"]
  node_admin_pages["Admin portal"]
end

subgraph group_api["API entry"]
  node_server["Express server<br/>[index.js]"]
  node_enrollment_api["Enrollment API"]
  node_group_api["Group API<br/>[groupRoutes.js]"]
  node_notification_api["Notification API"]
  node_member_api["Member API<br/>[memberRoutes.js]"]
  node_domain_controllers["Domain controllers"]
end

subgraph group_operations["Chit operations"]
  node_schemes_groups["Schemes and groups<br/>[groupController.js]"]
  node_auctions["Auctions and bids<br/>[bidController.js]"]
  node_vacancies["Vacancy joining"]
end

subgraph group_people["People workflows"]
  node_enrollments["Enrollment workflow"]
  node_member_records["Member records"]
  node_other_workflows["Operational workflows"]
end

subgraph group_persistence["Persistence"]
  node_mongo[("MongoDB<br/>[db.js]")]
  node_models[("Mongoose models")]
  node_messaging["WhatsApp messaging<br/>[sendWhatsapp.js]"]
end

node_member(("Member"))
node_employee(("Employee"))
node_admin(("Administrator"))

node_member -->|"opens app"| node_mobile_home
node_employee -->|"uses portal"| node_employee_pages
node_admin -->|"uses portal"| node_admin_pages
node_mobile_home -->|"navigates"| node_member_pages
node_mobile_home -.->|"API access"| node_server
node_employee_pages -.->|"API access"| node_server
node_admin_pages -.->|"API access"| node_server
node_server -->|"mounts routes"| node_enrollment_api
node_server -->|"mounts routes"| node_group_api
node_server -->|"mounts routes"| node_notification_api
node_server -->|"mounts routes"| node_member_api
node_server -->|"connects"| node_mongo
node_enrollment_api -->|"dispatches"| node_domain_controllers
node_group_api -->|"dispatches"| node_schemes_groups
node_notification_api -->|"dispatches"| node_domain_controllers
node_member_api -->|"dispatches"| node_domain_controllers
node_domain_controllers -->|"handles enrollment"| node_enrollments
node_domain_controllers -->|"handles members"| node_member_records
node_domain_controllers -->|"handles operations"| node_other_workflows
node_enrollments -->|"reads and writes"| node_models
node_schemes_groups -->|"reads and writes"| node_models
node_auctions -->|"reads and writes"| node_models
node_vacancies -->|"reads and writes"| node_models
node_member_records -->|"reads and writes"| node_models
node_other_workflows -->|"reads and writes"| node_models
node_models -->|"persists records"| node_mongo
node_auctions -.->|"messaging integration"| node_messaging

click node_mobile_home "https://github.com/pruthvimax/manikya_chitfund_official/blob/main/app/index.tsx"
click node_member_pages "https://github.com/pruthvimax/manikya_chitfund_official/tree/main/app"
click node_employee_pages "https://github.com/pruthvimax/manikya_chitfund_official/tree/main/app/employee"
click node_admin_pages "https://github.com/pruthvimax/manikya_chitfund_official/tree/main/app/admin"
click node_server "https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/index.js"
click node_enrollment_api "https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/routes/enrollmentRoutes.js"
click node_group_api "https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/routes/groupRoutes.js"
click node_notification_api "https://github.com/pruthvimax/manikya_chitfund_official/blob/main/routes/notificationRoutes.js"
click node_member_api "https://github.com/pruthvimax/manikya_chitfund_official/blob/main/routes/memberRoutes.js"
click node_domain_controllers "https://github.com/pruthvimax/manikya_chitfund_official/tree/main/backend/controllers"
click node_schemes_groups "https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/controllers/groupController.js"
click node_auctions "https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/controllers/bidController.js"
click node_vacancies "https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/controllers/vacancyController.js"
click node_enrollments "https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/controllers/enrollmentController.js"
click node_member_records "https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/controllers/memberController.js"
click node_other_workflows "https://github.com/pruthvimax/manikya_chitfund_official/tree/main/backend/controllers"
click node_mongo "https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/config/db.js"
click node_models "https://github.com/pruthvimax/manikya_chitfund_official/tree/main/backend/models"
click node_messaging "https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/utils/sendWhatsapp.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_mobile_home,node_member_pages,node_employee_pages,node_admin_pages toneBlue
class node_server,node_enrollment_api,node_group_api,node_notification_api,node_member_api,node_domain_controllers toneAmber
class node_schemes_groups,node_auctions,node_vacancies toneMint
class node_enrollments,node_member_records,node_other_workflows toneRose
class node_mongo,node_models,node_messaging,node_member,node_employee,node_admin toneIndigo
```

## Components

### Mobile app

- [Mobile entry](https://github.com/pruthvimax/manikya_chitfund_official/blob/main/app/index.tsx): `app/index.tsx`
- [Member features](https://github.com/pruthvimax/manikya_chitfund_official/tree/main/app): `app`
- [Employee portal](https://github.com/pruthvimax/manikya_chitfund_official/tree/main/app/employee): `app/employee`
- [Admin portal](https://github.com/pruthvimax/manikya_chitfund_official/tree/main/app/admin): `app/admin`

### API entry

- [Express server](https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/index.js): `backend/index.js`
- [Enrollment API](https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/routes/enrollmentRoutes.js): `backend/routes/enrollmentRoutes.js`
- [Group API](https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/routes/groupRoutes.js): `backend/routes/groupRoutes.js`
- [Notification API](https://github.com/pruthvimax/manikya_chitfund_official/blob/main/routes/notificationRoutes.js): `routes/notificationRoutes.js`
- [Member API](https://github.com/pruthvimax/manikya_chitfund_official/blob/main/routes/memberRoutes.js): `routes/memberRoutes.js`
- [Domain controllers](https://github.com/pruthvimax/manikya_chitfund_official/tree/main/backend/controllers): `backend/controllers`

### Chit operations

- [Schemes and groups](https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/controllers/groupController.js): `backend/controllers/groupController.js`
- [Auctions and bids](https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/controllers/bidController.js): `backend/controllers/bidController.js`
- [Vacancy joining](https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/controllers/vacancyController.js): `backend/controllers/vacancyController.js`

### People workflows

- [Enrollment workflow](https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/controllers/enrollmentController.js): `backend/controllers/enrollmentController.js`
- [Member records](https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/controllers/memberController.js): `backend/controllers/memberController.js`
- [Operational workflows](https://github.com/pruthvimax/manikya_chitfund_official/tree/main/backend/controllers): `backend/controllers`

### Persistence

- [MongoDB](https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/config/db.js): `backend/config/db.js`
- [Mongoose models](https://github.com/pruthvimax/manikya_chitfund_official/tree/main/backend/models): `backend/models`
- [WhatsApp messaging](https://github.com/pruthvimax/manikya_chitfund_official/blob/main/backend/utils/sendWhatsapp.js): `backend/utils/sendWhatsapp.js`

### Other components

- **Member**
- **Employee**
- **Administrator**

## Connections

- Member → Mobile entry: opens app
- Employee → Employee portal: uses portal
- Administrator → Admin portal: uses portal
- Mobile entry → Member features: navigates
- Mobile entry → Express server: API access
- Employee portal → Express server: API access
- Admin portal → Express server: API access
- Express server → Enrollment API: mounts routes
- Express server → Group API: mounts routes
- Express server → Notification API: mounts routes
- Express server → Member API: mounts routes
- Express server → MongoDB: connects
- Enrollment API → Domain controllers: dispatches
- Group API → Schemes and groups: dispatches
- Notification API → Domain controllers: dispatches
- Member API → Domain controllers: dispatches
- Domain controllers → Enrollment workflow: handles enrollment
- Domain controllers → Member records: handles members
- Domain controllers → Operational workflows: handles operations
- Enrollment workflow → Mongoose models: reads and writes
- Schemes and groups → Mongoose models: reads and writes
- Auctions and bids → Mongoose models: reads and writes
- Vacancy joining → Mongoose models: reads and writes
- Member records → Mongoose models: reads and writes
- Operational workflows → Mongoose models: reads and writes
- Mongoose models → MongoDB: persists records
- Auctions and bids → WhatsApp messaging: messaging integration
