# monoxti/monoxproperty architecture

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

- Interactive diagram: https://gitdiagram.com/monoxti/monoxproperty
- Repository: https://github.com/monoxti/monoxproperty

## Overview

Monox Property is a property-management application for managing properties, tenants, leases, expenses, rent payments, and financial reporting. Users navigate the React client to maintain records, track payments, and view reports; the client communicates with an ASP.NET Core API whose domain services process requests and persist data through Entity Framework. The README also documents JWT authentication and role-based access. Some client-to-API wiring and unsampled service internals are not shown, so those relationships are omitted unless documented.

Main entry points: [`Monokoane Property/Client/src/App.jsx`](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Client/src/App.jsx) (React client), [`Monokoane Property/Models/ApplicationDbContext.cs`](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Models/ApplicationDbContext.cs) (Entity Framework context), [`Monokoane Property/Controllers/PaymentController.cs`](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Controllers/PaymentController.cs) (Payment API), [`Monokoane Property/Controllers/AuthController.cs`](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Controllers/AuthController.cs) (Authentication API)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_client["Web client"]
  node_client["React client<br/>[App.jsx]"]
  node_authui["Sign-in pages"]
  node_propertyui["Property pages"]
  node_tenantui["Tenant pages"]
  node_leaseui["Lease pages"]
  node_financeui["Payments and reports"]
end

subgraph group_api["API workflows"]
  node_authapi["Authentication API<br/>[AuthController.cs]"]
  node_propertyapi["Property API<br/>[PropControllers.cs]"]
  node_tenantapi["Tenant API"]
  node_leaseapi["Lease API<br/>[LeaseController.cs]"]
  node_expenseapi["Expense API"]
  node_paymentapi["Payment API"]
  node_reportapi["Report API"]
end

subgraph group_domain["Domain services"]
  node_authservice["Authentication service<br/>[AuthService.cs]"]
  node_propertyservice["Property service<br/>[PropertyService.cs]"]
  node_tenantservice["Tenant service<br/>[TenantService.cs]"]
  node_paymentservice["Payment and tracking<br/>[PaymentService.cs]"]
  node_reportservice["Reporting and export"]
end

subgraph group_data["Persistence"]
  node_userrepo["User repository<br/>[UserRepo.cs]"]
  node_dbcontext[("Entity Framework context")]
end

node_manager(("Property user"))

node_manager -->|"uses"| node_client
node_client -->|"routes to"| node_authui
node_client -->|"routes to"| node_propertyui
node_client -->|"routes to"| node_tenantui
node_client -->|"routes to"| node_leaseui
node_client -->|"routes to"| node_financeui
node_client -.->|"calls REST API"| node_authapi
node_client -.->|"calls REST API"| node_propertyapi
node_client -.->|"calls REST API"| node_tenantapi
node_client -.->|"calls REST API"| node_leaseapi
node_client -.->|"calls REST API"| node_expenseapi
node_client -.->|"calls REST API"| node_paymentapi
node_client -.->|"calls REST API"| node_reportapi
node_authapi -->|"delegates to"| node_authservice
node_authservice -->|"reads and creates"| node_userrepo
node_propertyapi -->|"delegates to"| node_propertyservice
node_tenantapi -->|"delegates to"| node_tenantservice
node_leaseapi -.->|"service wiring unknown"| node_dbcontext
node_expenseapi -.->|"service wiring unknown"| node_dbcontext
node_paymentapi -->|"delegates to"| node_paymentservice
node_paymentapi -->|"reads properties"| node_dbcontext
node_reportapi -->|"delegates to"| node_reportservice
node_paymentservice -->|"queries and writes"| node_dbcontext
node_reportservice -->|"stores and reads reports"| node_dbcontext

click node_client "https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Client/src/App.jsx"
click node_authui "https://github.com/monoxti/monoxproperty/tree/main/Monokoane%20Property/Client/src/Pages"
click node_propertyui "https://github.com/monoxti/monoxproperty/tree/main/Monokoane%20Property/Client/src/Pages"
click node_tenantui "https://github.com/monoxti/monoxproperty/tree/main/Monokoane%20Property/Client/src/Pages"
click node_leaseui "https://github.com/monoxti/monoxproperty/tree/main/Monokoane%20Property/Client/src/Pages"
click node_financeui "https://github.com/monoxti/monoxproperty/tree/main/Monokoane%20Property/Client/src/Pages"
click node_authapi "https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Controllers/AuthController.cs"
click node_propertyapi "https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Controllers/PropControllers.cs"
click node_tenantapi "https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Controllers/TenantController.cs"
click node_leaseapi "https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Controllers/LeaseController.cs"
click node_expenseapi "https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Controllers/ExpenseController.cs"
click node_paymentapi "https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Controllers/PaymentController.cs"
click node_reportapi "https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Controllers/ReportController.cs"
click node_authservice "https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Models/Services/AuthService.cs"
click node_propertyservice "https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Models/Services/PropertyService.cs"
click node_tenantservice "https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Models/Services/TenantService.cs"
click node_paymentservice "https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Models/Services/PaymentService.cs"
click node_reportservice "https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Models/Services/PropertyReportService.cs"
click node_userrepo "https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Models/Repo/UserRepo.cs"
click node_dbcontext "https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Models/ApplicationDbContext.cs"

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_client,node_authui,node_propertyui,node_tenantui,node_leaseui,node_financeui,node_manager toneBlue
class node_authapi,node_propertyapi,node_tenantapi,node_leaseapi,node_expenseapi,node_paymentapi,node_reportapi toneAmber
class node_authservice,node_propertyservice,node_tenantservice,node_paymentservice,node_reportservice toneMint
class node_userrepo,node_dbcontext toneRose
```

## Components

### Web client

- [React client](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Client/src/App.jsx): `Monokoane Property/Client/src/App.jsx`
- [Sign-in pages](https://github.com/monoxti/monoxproperty/tree/main/Monokoane%20Property/Client/src/Pages): `Monokoane Property/Client/src/Pages`
- [Property pages](https://github.com/monoxti/monoxproperty/tree/main/Monokoane%20Property/Client/src/Pages): `Monokoane Property/Client/src/Pages`
- [Tenant pages](https://github.com/monoxti/monoxproperty/tree/main/Monokoane%20Property/Client/src/Pages): `Monokoane Property/Client/src/Pages`
- [Lease pages](https://github.com/monoxti/monoxproperty/tree/main/Monokoane%20Property/Client/src/Pages): `Monokoane Property/Client/src/Pages`
- [Payments and reports](https://github.com/monoxti/monoxproperty/tree/main/Monokoane%20Property/Client/src/Pages): `Monokoane Property/Client/src/Pages`

### API workflows

- [Authentication API](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Controllers/AuthController.cs): `Monokoane Property/Controllers/AuthController.cs`
- [Property API](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Controllers/PropControllers.cs): `Monokoane Property/Controllers/PropControllers.cs`
- [Tenant API](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Controllers/TenantController.cs): `Monokoane Property/Controllers/TenantController.cs`
- [Lease API](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Controllers/LeaseController.cs): `Monokoane Property/Controllers/LeaseController.cs`
- [Expense API](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Controllers/ExpenseController.cs): `Monokoane Property/Controllers/ExpenseController.cs`
- [Payment API](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Controllers/PaymentController.cs): `Monokoane Property/Controllers/PaymentController.cs`
- [Report API](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Controllers/ReportController.cs): `Monokoane Property/Controllers/ReportController.cs`

### Domain services

- [Authentication service](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Models/Services/AuthService.cs): `Monokoane Property/Models/Services/AuthService.cs`
- [Property service](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Models/Services/PropertyService.cs): `Monokoane Property/Models/Services/PropertyService.cs`
- [Tenant service](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Models/Services/TenantService.cs): `Monokoane Property/Models/Services/TenantService.cs`
- [Payment and tracking](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Models/Services/PaymentService.cs): `Monokoane Property/Models/Services/PaymentService.cs`
- [Reporting and export](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Models/Services/PropertyReportService.cs): `Monokoane Property/Models/Services/PropertyReportService.cs`

### Persistence

- [User repository](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Models/Repo/UserRepo.cs): `Monokoane Property/Models/Repo/UserRepo.cs`
- [Entity Framework context](https://github.com/monoxti/monoxproperty/blob/main/Monokoane%20Property/Models/ApplicationDbContext.cs): `Monokoane Property/Models/ApplicationDbContext.cs`

### Other components

- **Property user**

## Connections

- Property user → React client: uses
- React client → Sign-in pages: routes to (evidence: `Monokoane Property/Client/src/App.jsx`)
- React client → Property pages: routes to (evidence: `Monokoane Property/Client/src/App.jsx`)
- React client → Tenant pages: routes to (evidence: `Monokoane Property/Client/src/App.jsx`)
- React client → Lease pages: routes to (evidence: `Monokoane Property/Client/src/App.jsx`)
- React client → Payments and reports: routes to (evidence: `Monokoane Property/Client/src/App.jsx`)
- React client → Authentication API: calls REST API
- React client → Property API: calls REST API
- React client → Tenant API: calls REST API
- React client → Lease API: calls REST API
- React client → Expense API: calls REST API
- React client → Payment API: calls REST API
- React client → Report API: calls REST API
- Authentication API → Authentication service: delegates to (evidence: `Monokoane Property/Controllers/AuthController.cs`)
- Authentication service → User repository: reads and creates (evidence: `Monokoane Property/Models/Services/AuthService.cs`)
- Property API → Property service: delegates to (evidence: `Monokoane Property/Controllers/PropControllers.cs`)
- Tenant API → Tenant service: delegates to (evidence: `Monokoane Property/Controllers/TenantController.cs`)
- Lease API → Entity Framework context: service wiring unknown
- Expense API → Entity Framework context: service wiring unknown
- Payment API → Payment and tracking: delegates to (evidence: `Monokoane Property/Controllers/PaymentController.cs`)
- Payment API → Entity Framework context: reads properties (evidence: `Monokoane Property/Controllers/PaymentController.cs`)
- Report API → Reporting and export: delegates to (evidence: `Monokoane Property/Controllers/ReportController.cs`)
- Payment and tracking → Entity Framework context: queries and writes (evidence: `Monokoane Property/Models/Services/PaymentService.cs`)
- Reporting and export → Entity Framework context: stores and reads reports (evidence: `Monokoane Property/Models/Services/PropertyReportService.cs`)
