# waw1311/wawtopup architecture

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

- Interactive diagram: https://gitdiagram.com/waw1311/wawtopup
- Repository: https://github.com/waw1311/wawtopup

## Overview

This Laravel application provides a game-top-up storefront: customers choose a product, submit player and payment details, pay through Tripay, and receive order fulfillment/status from VIP Reseller. It also exposes account registration/login and administrative product, cart, and order-history screens. The graph follows documented routes and sampled controller calls; relationships for unsampled route destinations and job behavior are omitted rather than inferred.

Main entry points: [`routes/web.php`](https://github.com/waw1311/wawtopup/blob/main/routes/web.php) (Web routes), [`app/Http/Controllers/dashboardController.php`](https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/dashboardController.php) (Admin dashboard), [`app/Http/Controllers/handlercontroller.php`](https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/handlercontroller.php) (Order handling), [`app/Models/cart_user.php`](https://github.com/waw1311/wawtopup/blob/main/app/Models/cart_user.php) (Orders and carts)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_web["Web and accounts"]
  node_storefront["Storefront"]
  node_pages["Static pages"]
  node_login["Login"]
  node_registration["Registration"]
  node_user[("User accounts<br/>[User.php]")]
  node_storeviews["Storefront screens<br/>[index.blade.php]"]
end

subgraph group_catalog["Catalog management"]
  node_dashboard["Admin dashboard"]
  node_catalogdata[("Product catalog<br/>[product.php]")]
  node_categories[("Categories<br/>[category.php]")]
  node_subproducts[("Top-up options<br/>[sub_product.php]")]
  node_adminviews["Dashboard screens"]
end

subgraph group_orders["Orders and payments"]
  node_cart[("Orders and carts<br/>[cart_user.php]")]
  node_orderflow["Order handling"]
  node_tripay["Tripay payments"]
  node_vip["VIP fulfillment"]
end

subgraph group_runtime["Laravel runtime"]
  node_routes["Web routes<br/>[web.php]"]
  node_http["HTTP kernel<br/>[Kernel.php]"]
end

node_customer(("Customer"))
node_tripayservice["Tripay gateway"]
node_vipservice["VIP Reseller API"]
node_whatsapp["WhatsApp service"]

node_customer -->|"requests pages"| node_routes
node_routes -->|"routes requests"| node_storefront
node_routes -->|"routes pages"| node_pages
node_routes -->|"routes login"| node_login
node_routes -->|"routes registration"| node_registration
node_routes -->|"routes dashboard"| node_dashboard
node_storefront -->|"renders storefront"| node_storeviews
node_storefront -->|"loads catalog"| node_categories
node_storefront -.->|"handles orders"| node_orderflow
node_registration -->|"creates account"| node_user
node_dashboard -->|"manages products"| node_catalogdata
node_dashboard -->|"loads options"| node_subproducts
node_dashboard -->|"loads categories"| node_categories
node_dashboard -->|"loads cart data"| node_cart
node_dashboard -->|"renders dashboard"| node_adminviews
node_orderflow -->|"creates order"| node_cart
node_orderflow -->|"creates payment"| node_tripay
node_tripay -->|"calls gateway"| node_tripayservice
node_tripay -->|"updates payment status"| node_cart
node_orderflow -->|"requests fulfillment"| node_vip
node_orderflow -->|"records fulfillment"| node_cart
node_vip -->|"calls reseller API"| node_vipservice
node_orderflow -->|"sends order message"| node_whatsapp
node_http -->|"loads routes"| node_routes

click node_routes "https://github.com/waw1311/wawtopup/blob/main/routes/web.php"
click node_http "https://github.com/waw1311/wawtopup/blob/main/app/Http/Kernel.php"
click node_storefront "https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/handlercontroller.php"
click node_pages "https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/PagesController.php"
click node_login "https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/LoginController.php"
click node_registration "https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/RegisterController.php"
click node_user "https://github.com/waw1311/wawtopup/blob/main/app/Models/User.php"
click node_dashboard "https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/dashboardController.php"
click node_catalogdata "https://github.com/waw1311/wawtopup/blob/main/app/Models/product.php"
click node_categories "https://github.com/waw1311/wawtopup/blob/main/app/Models/category.php"
click node_subproducts "https://github.com/waw1311/wawtopup/blob/main/app/Models/sub_product.php"
click node_cart "https://github.com/waw1311/wawtopup/blob/main/app/Models/cart_user.php"
click node_orderflow "https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/handlercontroller.php"
click node_tripay "https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/TripayController.php"
click node_vip "https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/VipPaymentController.php"
click node_adminviews "https://github.com/waw1311/wawtopup/tree/main/resources/views/dashboard"
click node_storeviews "https://github.com/waw1311/wawtopup/blob/main/resources/views/index.blade.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_storefront,node_pages,node_login,node_registration,node_user,node_storeviews toneBlue
class node_dashboard,node_catalogdata,node_categories,node_subproducts,node_adminviews toneAmber
class node_cart,node_orderflow,node_tripay,node_vip,node_vipservice toneMint
class node_routes,node_http toneRose
class node_customer,node_tripayservice,node_whatsapp toneIndigo
```

## Components

### Web and accounts

- [Storefront](https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/handlercontroller.php): `app/Http/Controllers/handlercontroller.php`
- [Static pages](https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/PagesController.php): `app/Http/Controllers/PagesController.php`
- [Login](https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/LoginController.php): `app/Http/Controllers/LoginController.php`
- [Registration](https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/RegisterController.php): `app/Http/Controllers/RegisterController.php`
- [User accounts](https://github.com/waw1311/wawtopup/blob/main/app/Models/User.php): `app/Models/User.php`
- [Storefront screens](https://github.com/waw1311/wawtopup/blob/main/resources/views/index.blade.php): `resources/views/index.blade.php`

### Catalog management

- [Admin dashboard](https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/dashboardController.php): `app/Http/Controllers/dashboardController.php`
- [Product catalog](https://github.com/waw1311/wawtopup/blob/main/app/Models/product.php): `app/Models/product.php`
- [Categories](https://github.com/waw1311/wawtopup/blob/main/app/Models/category.php): `app/Models/category.php`
- [Top-up options](https://github.com/waw1311/wawtopup/blob/main/app/Models/sub_product.php): `app/Models/sub_product.php`
- [Dashboard screens](https://github.com/waw1311/wawtopup/tree/main/resources/views/dashboard): `resources/views/dashboard`

### Orders and payments

- [Orders and carts](https://github.com/waw1311/wawtopup/blob/main/app/Models/cart_user.php): `app/Models/cart_user.php`
- [Order handling](https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/handlercontroller.php): `app/Http/Controllers/handlercontroller.php`
- [Tripay payments](https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/TripayController.php): `app/Http/Controllers/TripayController.php`
- [VIP fulfillment](https://github.com/waw1311/wawtopup/blob/main/app/Http/Controllers/VipPaymentController.php): `app/Http/Controllers/VipPaymentController.php`

### Laravel runtime

- [Web routes](https://github.com/waw1311/wawtopup/blob/main/routes/web.php): `routes/web.php`
- [HTTP kernel](https://github.com/waw1311/wawtopup/blob/main/app/Http/Kernel.php): `app/Http/Kernel.php`

### Other components

- **Customer**
- **Tripay gateway**
- **VIP Reseller API**
- **WhatsApp service**

## Connections

- Customer → Web routes: requests pages (evidence: `routes/web.php`)
- Web routes → Storefront: routes requests (evidence: `routes/web.php`)
- Web routes → Static pages: routes pages (evidence: `routes/web.php`)
- Web routes → Login: routes login (evidence: `routes/web.php`)
- Web routes → Registration: routes registration (evidence: `routes/web.php`)
- Web routes → Admin dashboard: routes dashboard (evidence: `routes/web.php`)
- Storefront → Storefront screens: renders storefront (evidence: `app/Http/Controllers/handlercontroller.php`)
- Storefront → Categories: loads catalog (evidence: `app/Http/Controllers/handlercontroller.php`)
- Storefront → Order handling: handles orders (evidence: `app/Http/Controllers/handlercontroller.php`)
- Registration → User accounts: creates account (evidence: `app/Http/Controllers/RegisterController.php`)
- Admin dashboard → Product catalog: manages products (evidence: `app/Http/Controllers/dashboardController.php`)
- Admin dashboard → Top-up options: loads options (evidence: `app/Http/Controllers/dashboardController.php`)
- Admin dashboard → Categories: loads categories (evidence: `app/Http/Controllers/dashboardController.php`)
- Admin dashboard → Orders and carts: loads cart data (evidence: `app/Http/Controllers/dashboardController.php`)
- Admin dashboard → Dashboard screens: renders dashboard (evidence: `app/Http/Controllers/dashboardController.php`)
- Order handling → Orders and carts: creates order (evidence: `app/Http/Controllers/handlercontroller.php`)
- Order handling → Tripay payments: creates payment (evidence: `app/Http/Controllers/handlercontroller.php`)
- Tripay payments → Tripay gateway: calls gateway (evidence: `app/Http/Controllers/TripayController.php`)
- Tripay payments → Orders and carts: updates payment status (evidence: `app/Http/Controllers/TripayController.php`)
- Order handling → VIP fulfillment: requests fulfillment (evidence: `app/Http/Controllers/handlercontroller.php`)
- Order handling → Orders and carts: records fulfillment (evidence: `app/Http/Controllers/handlercontroller.php`)
- VIP fulfillment → VIP Reseller API: calls reseller API (evidence: `app/Http/Controllers/VipPaymentController.php`)
- Order handling → WhatsApp service: sends order message
- HTTP kernel → Web routes: loads routes
