# rdethei/neston architecture

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

- Interactive diagram: https://gitdiagram.com/rdethei/neston
- Repository: https://github.com/rdethei/neston

## Overview

NESTON is a Laravel smart-parking system. Staff and drivers use its web/API endpoints to register vehicles, check vehicles into mapped slots, record check-out transactions, and collect payment; users can also reserve slots and view parking information. The README additionally documents ANPR, RFID, WhatsApp notifications, real-time maps, and role-specific dashboards. The graph reflects these documented capabilities, while source-level links are limited to relationships shown in excerpts or the SOURCE INDEX; unsampled integrations are shown as unverified.

Main entry points: [`routes`](https://github.com/rdethei/neston/tree/main/routes) (Web/API routing), [`app/Models/Transaksi.php`](https://github.com/rdethei/neston/blob/main/app/Models/Transaksi.php) (Parking transactions), [`app/Http/Controllers/TransaksiController.php`](https://github.com/rdethei/neston/blob/main/app/Http/Controllers/TransaksiController.php) (Check-in/out), [`app/Http/Controllers/ParkingSlotController.php`](https://github.com/rdethei/neston/blob/main/app/Http/Controllers/ParkingSlotController.php) (Slot map & booking)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_access["Access &amp; Dashboards"]
  node_login["Authentication"]
  node_dashboards["Role dashboards"]
  node_routes["Web/API routing"]
end

subgraph group_parking["Parking Operations"]
  node_transactions["Check-in/out"]
  node_slot_map["Slot map &amp; booking"]
  node_rfid["RFID access"]
end

subgraph group_payments["Payments &amp; Balance"]
  node_payment["Payment processing"]
  node_cashier["Cashier payment"]
  node_balance["NestonPay balance"]
end

subgraph group_integrations["Recognition &amp; Notifications"]
  node_anpr["ANPR scanning<br/>[ANPRController.php]"]
  node_plate_recognizer["Recognizer client"]
  node_whatsapp["WhatsApp notifications"]
  node_events["Parking events"]
end

subgraph group_records["Domain Records"]
  node_transaction_record[("Parking transactions<br/>[Transaksi.php]")]
  node_users[("Users &amp; roles<br/>[User.php]")]
  node_vehicles[("Vehicles<br/>[Kendaraan.php]")]
  node_areas[("Parking areas<br/>[AreaParkir.php]")]
  node_slots[("Map slots &amp; reservations<br/>[ParkingMapSlot.php]")]
  node_tariffs[("Tariffs<br/>[Tarif.php]")]
  node_payments_record[("Payment records<br/>[Pembayaran.php]")]
  node_activity["Activity logging<br/>[LogsActivity.php]"]
end

node_driver(("Drivers"))
node_staff(("Parking staff"))
node_midtrans{{"Midtrans"}}
node_plate_service{{"Plate recognition API"}}
node_wa_service{{"WhatsApp gateway"}}

node_driver -->|"uses"| node_routes
node_staff -->|"uses"| node_routes
node_routes -->|"routes to"| node_login
node_routes -->|"routes to"| node_dashboards
node_routes -->|"routes to"| node_slot_map
node_routes -->|"routes to"| node_rfid
node_routes -->|"routes to"| node_payment
node_transactions -->|"creates and updates"| node_transaction_record
node_transactions -->|"queries"| node_vehicles
node_transactions -->|"queries"| node_tariffs
node_transactions -->|"queries"| node_areas
node_transactions -->|"checks availability"| node_slots
node_slot_map -->|"selects area"| node_areas
node_slot_map -->|"reads slot state"| node_slots
node_slot_map -->|"reads occupancy"| node_transaction_record
node_transaction_record -->|"references"| node_slots
node_transaction_record -->|"references"| node_vehicles
node_transaction_record -->|"references"| node_tariffs
node_login -->|"authenticates"| node_users
node_login -->|"logs activity"| node_activity
node_payment -->|"loads and updates"| node_transaction_record
node_payment -->|"creates payment"| node_payments_record
node_payment -.->|"requests status"| node_midtrans
node_cashier -.->|"records cash"| node_payments_record
node_balance -.->|"updates balance"| node_users
node_anpr -.->|"submits plate scan"| node_plate_recognizer
node_rfid -->|"identifies vehicle"| node_vehicles
node_rfid -->|"checks tag owner"| node_users
node_transactions -.->|"emits lifecycle events"| node_events
node_events -.->|"triggers notifications"| node_whatsapp
node_whatsapp -.->|"sends messages"| node_wa_service
node_dashboards -.->|"summarizes activity"| node_transaction_record

click node_login "https://github.com/rdethei/neston/blob/main/app/Http/Controllers/Auth/LoginController.php"
click node_dashboards "https://github.com/rdethei/neston/tree/main/app/Http/Controllers"
click node_routes "https://github.com/rdethei/neston/tree/main/routes"
click node_transactions "https://github.com/rdethei/neston/blob/main/app/Http/Controllers/TransaksiController.php"
click node_slot_map "https://github.com/rdethei/neston/blob/main/app/Http/Controllers/ParkingSlotController.php"
click node_rfid "https://github.com/rdethei/neston/blob/main/app/Http/Controllers/RfidParkingController.php"
click node_anpr "https://github.com/rdethei/neston/blob/main/app/Http/Controllers/ANPRController.php"
click node_plate_recognizer "https://github.com/rdethei/neston/blob/main/app/Services/PlateRecognizerService.php"
click node_payment "https://github.com/rdethei/neston/blob/main/app/Http/Controllers/PaymentController.php"
click node_cashier "https://github.com/rdethei/neston/blob/main/app/Http/Controllers/CashPaymentController.php"
click node_balance "https://github.com/rdethei/neston/blob/main/app/Http/Controllers/SaldoController.php"
click node_whatsapp "https://github.com/rdethei/neston/blob/main/app/Services/WhatsAppGateway.php"
click node_events "https://github.com/rdethei/neston/tree/main/app/Events"
click node_transaction_record "https://github.com/rdethei/neston/blob/main/app/Models/Transaksi.php"
click node_users "https://github.com/rdethei/neston/blob/main/app/Models/User.php"
click node_vehicles "https://github.com/rdethei/neston/blob/main/app/Models/Kendaraan.php"
click node_areas "https://github.com/rdethei/neston/blob/main/app/Models/AreaParkir.php"
click node_slots "https://github.com/rdethei/neston/blob/main/app/Models/ParkingMapSlot.php"
click node_tariffs "https://github.com/rdethei/neston/blob/main/app/Models/Tarif.php"
click node_payments_record "https://github.com/rdethei/neston/blob/main/app/Models/Pembayaran.php"
click node_activity "https://github.com/rdethei/neston/blob/main/app/Traits/LogsActivity.php"

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_login,node_dashboards,node_routes toneBlue
class node_transactions,node_slot_map,node_rfid toneAmber
class node_payment,node_cashier,node_balance,node_plate_service toneMint
class node_anpr,node_plate_recognizer,node_whatsapp,node_events toneRose
class node_transaction_record,node_users,node_vehicles,node_areas,node_slots,node_tariffs,node_payments_record,node_activity,node_driver,node_staff,node_midtrans,node_wa_service toneIndigo
```

## Components

### Access & Dashboards

- [Authentication](https://github.com/rdethei/neston/blob/main/app/Http/Controllers/Auth/LoginController.php): `app/Http/Controllers/Auth/LoginController.php`
- [Role dashboards](https://github.com/rdethei/neston/tree/main/app/Http/Controllers): `app/Http/Controllers`
- [Web/API routing](https://github.com/rdethei/neston/tree/main/routes): `routes`

### Parking Operations

- [Check-in/out](https://github.com/rdethei/neston/blob/main/app/Http/Controllers/TransaksiController.php): `app/Http/Controllers/TransaksiController.php`
- [Slot map & booking](https://github.com/rdethei/neston/blob/main/app/Http/Controllers/ParkingSlotController.php): `app/Http/Controllers/ParkingSlotController.php`
- [RFID access](https://github.com/rdethei/neston/blob/main/app/Http/Controllers/RfidParkingController.php): `app/Http/Controllers/RfidParkingController.php`

### Payments & Balance

- [Payment processing](https://github.com/rdethei/neston/blob/main/app/Http/Controllers/PaymentController.php): `app/Http/Controllers/PaymentController.php`
- [Cashier payment](https://github.com/rdethei/neston/blob/main/app/Http/Controllers/CashPaymentController.php): `app/Http/Controllers/CashPaymentController.php`
- [NestonPay balance](https://github.com/rdethei/neston/blob/main/app/Http/Controllers/SaldoController.php): `app/Http/Controllers/SaldoController.php`

### Recognition & Notifications

- [ANPR scanning](https://github.com/rdethei/neston/blob/main/app/Http/Controllers/ANPRController.php): `app/Http/Controllers/ANPRController.php`
- [Recognizer client](https://github.com/rdethei/neston/blob/main/app/Services/PlateRecognizerService.php): `app/Services/PlateRecognizerService.php`
- [WhatsApp notifications](https://github.com/rdethei/neston/blob/main/app/Services/WhatsAppGateway.php): `app/Services/WhatsAppGateway.php`
- [Parking events](https://github.com/rdethei/neston/tree/main/app/Events): `app/Events`

### Domain Records

- [Parking transactions](https://github.com/rdethei/neston/blob/main/app/Models/Transaksi.php): `app/Models/Transaksi.php`
- [Users & roles](https://github.com/rdethei/neston/blob/main/app/Models/User.php): `app/Models/User.php`
- [Vehicles](https://github.com/rdethei/neston/blob/main/app/Models/Kendaraan.php): `app/Models/Kendaraan.php`
- [Parking areas](https://github.com/rdethei/neston/blob/main/app/Models/AreaParkir.php): `app/Models/AreaParkir.php`
- [Map slots & reservations](https://github.com/rdethei/neston/blob/main/app/Models/ParkingMapSlot.php): `app/Models/ParkingMapSlot.php`
- [Tariffs](https://github.com/rdethei/neston/blob/main/app/Models/Tarif.php): `app/Models/Tarif.php`
- [Payment records](https://github.com/rdethei/neston/blob/main/app/Models/Pembayaran.php): `app/Models/Pembayaran.php`
- [Activity logging](https://github.com/rdethei/neston/blob/main/app/Traits/LogsActivity.php): `app/Traits/LogsActivity.php`

### Other components

- **Drivers**
- **Parking staff**
- **Midtrans**
- **Plate recognition API**
- **WhatsApp gateway**

## Connections

- Drivers → Web/API routing: uses (evidence: `routes/web.php`)
- Parking staff → Web/API routing: uses (evidence: `routes/web.php`)
- Web/API routing → Authentication: routes to (evidence: `routes/web.php`)
- Web/API routing → Role dashboards: routes to (evidence: `routes/web.php`)
- Web/API routing → Slot map & booking: routes to (evidence: `routes/web.php`)
- Web/API routing → RFID access: routes to (evidence: `routes/web.php`)
- Web/API routing → Payment processing: routes to (evidence: `routes/web.php`)
- Check-in/out → Parking transactions: creates and updates (evidence: `app/Http/Controllers/TransaksiController.php`)
- Check-in/out → Vehicles: queries (evidence: `app/Http/Controllers/TransaksiController.php`)
- Check-in/out → Tariffs: queries (evidence: `app/Http/Controllers/TransaksiController.php`)
- Check-in/out → Parking areas: queries (evidence: `app/Http/Controllers/TransaksiController.php`)
- Check-in/out → Map slots & reservations: checks availability (evidence: `app/Http/Controllers/TransaksiController.php`)
- Slot map & booking → Parking areas: selects area (evidence: `app/Http/Controllers/ParkingSlotController.php`)
- Slot map & booking → Map slots & reservations: reads slot state (evidence: `app/Http/Controllers/ParkingSlotController.php`)
- Slot map & booking → Parking transactions: reads occupancy (evidence: `app/Http/Controllers/ParkingSlotController.php`)
- Parking transactions → Map slots & reservations: references (evidence: `app/Models/Transaksi.php`)
- Parking transactions → Vehicles: references (evidence: `app/Models/Transaksi.php`)
- Parking transactions → Tariffs: references (evidence: `app/Models/Transaksi.php`)
- Authentication → Users & roles: authenticates (evidence: `app/Http/Controllers/Auth/LoginController.php`)
- Authentication → Activity logging: logs activity (evidence: `app/Http/Controllers/Auth/LoginController.php`)
- Payment processing → Parking transactions: loads and updates (evidence: `app/Http/Controllers/PaymentController.php`)
- Payment processing → Payment records: creates payment (evidence: `app/Http/Controllers/PaymentController.php`)
- Payment processing → Midtrans: requests status
- Cashier payment → Payment records: records cash
- NestonPay balance → Users & roles: updates balance
- ANPR scanning → Recognizer client: submits plate scan
- RFID access → Vehicles: identifies vehicle
- RFID access → Users & roles: checks tag owner
- Check-in/out → Parking events: emits lifecycle events
- Parking events → WhatsApp notifications: triggers notifications
- WhatsApp notifications → WhatsApp gateway: sends messages
- Role dashboards → Parking transactions: summarizes activity (evidence: `app/Http/Controllers/PaymentController.php`)
