# beastfrompretoriaeast/osc architecture

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

- Interactive diagram: https://gitdiagram.com/beastfrompretoriaeast/osc
- Repository: https://github.com/beastfrompretoriaeast/osc

## Overview

This Laravel application provides account access and profile management, plus CRUD for sites and site services; service creation also provisions a Stripe product and price. The principal workflow is an authenticated user creating a site service, which the controller validates, creates in Stripe, and saves locally. Authentication and verification are distinct supporting flows. The source excerpts establish controller/model calls and route dispatch, but several referenced views and route targets are absent from the tree, so those links are omitted.

Main entry points: [`routes/auth.php`](https://github.com/beastfrompretoriaeast/osc/blob/main/routes/auth.php) (Auth routes), [`routes/web.php`](https://github.com/beastfrompretoriaeast/osc/blob/main/routes/web.php) (Web routes), [`app/Http/Controllers/ServiceController.php`](https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/ServiceController.php) (Service management), [`app/Http/Controllers/Auth/RegisteredUserController.php`](https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/Auth/RegisteredUserController.php) (Registration)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_routing["HTTP routing"]
  node_web_routes["Web routes<br/>[web.php]"]
  node_auth_routes["Auth routes<br/>[auth.php]"]
end

subgraph group_accounts["Accounts"]
  node_registration["Registration"]
  node_sessions["Sessions"]
  node_login_request["Login validation<br/>[LoginRequest.php]"]
  node_verification_prompt["Verification prompt"]
  node_verification_send["Verification notices"]
  node_verification_confirm["Email verification"]
  node_profile["Profile management"]
  node_profile_request["Profile validation"]
  node_user_model[("User account<br/>[User.php]")]
end

subgraph group_sites["Site services"]
  node_sites_controller["Site management<br/>[SiteController.php]"]
  node_site_model[("Site record<br/>[Site.php]")]
  node_services_controller["Service management"]
  node_service_model[("Service record<br/>[Service.php]")]
end

subgraph group_presentation["User interface"]
  node_profile_view["Profile form<br/>[edit.blade.php]"]
  node_registration_view["Registration form<br/>[register.blade.php]"]
  node_dashboard_view["Admin dashboard"]
end

node_user(("User"))
node_stripe["Stripe"]

node_user -->|"sends requests"| node_web_routes
node_user -->|"authenticates"| node_auth_routes
node_web_routes -->|"dispatches"| node_profile
node_web_routes -->|"dispatches"| node_sites_controller
node_web_routes -->|"dispatches"| node_services_controller
node_auth_routes -->|"dispatches"| node_registration
node_auth_routes -->|"dispatches"| node_sessions
node_auth_routes -->|"dispatches"| node_verification_prompt
node_auth_routes -->|"dispatches"| node_verification_send
node_auth_routes -->|"dispatches"| node_verification_confirm
node_registration -->|"creates account"| node_user_model
node_registration -->|"renders"| node_registration_view
node_sessions -->|"authenticates with"| node_login_request
node_sessions -->|"manages session"| node_user
node_profile -->|"validates with"| node_profile_request
node_profile -->|"renders"| node_profile_view
node_sites_controller -->|"reads and writes"| node_site_model
node_services_controller -->|"uses site"| node_site_model
node_services_controller -->|"creates and updates"| node_service_model
node_services_controller -->|"creates product and price"| node_stripe
node_service_model -->|"belongs to"| node_site_model

click node_web_routes "https://github.com/beastfrompretoriaeast/osc/blob/main/routes/web.php"
click node_auth_routes "https://github.com/beastfrompretoriaeast/osc/blob/main/routes/auth.php"
click node_registration "https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/Auth/RegisteredUserController.php"
click node_sessions "https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/Auth/AuthenticatedSessionController.php"
click node_login_request "https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Requests/Auth/LoginRequest.php"
click node_verification_prompt "https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/Auth/EmailVerificationPromptController.php"
click node_verification_send "https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/Auth/EmailVerificationNotificationController.php"
click node_verification_confirm "https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/Auth/VerifyEmailController.php"
click node_profile "https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/ProfileController.php"
click node_profile_request "https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Requests/ProfileUpdateRequest.php"
click node_user_model "https://github.com/beastfrompretoriaeast/osc/blob/main/app/Models/User.php"
click node_sites_controller "https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/SiteController.php"
click node_site_model "https://github.com/beastfrompretoriaeast/osc/blob/main/app/Models/Site.php"
click node_services_controller "https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/ServiceController.php"
click node_service_model "https://github.com/beastfrompretoriaeast/osc/blob/main/app/Models/Service.php"
click node_profile_view "https://github.com/beastfrompretoriaeast/osc/blob/main/resources/views/profile/edit.blade.php"
click node_registration_view "https://github.com/beastfrompretoriaeast/osc/blob/main/resources/views/auth/register.blade.php"
click node_dashboard_view "https://github.com/beastfrompretoriaeast/osc/blob/main/resources/views/backend/dashboard/dashboard.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_web_routes,node_auth_routes,node_user toneBlue
class node_registration,node_sessions,node_login_request,node_verification_prompt,node_verification_send,node_verification_confirm,node_profile,node_profile_request,node_user_model toneAmber
class node_sites_controller,node_site_model,node_services_controller,node_service_model toneMint
class node_profile_view,node_registration_view,node_dashboard_view toneRose
class node_stripe toneIndigo
```

## Components

### HTTP routing

- [Web routes](https://github.com/beastfrompretoriaeast/osc/blob/main/routes/web.php): `routes/web.php`
- [Auth routes](https://github.com/beastfrompretoriaeast/osc/blob/main/routes/auth.php): `routes/auth.php`

### Accounts

- [Registration](https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/Auth/RegisteredUserController.php): `app/Http/Controllers/Auth/RegisteredUserController.php`
- [Sessions](https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/Auth/AuthenticatedSessionController.php): `app/Http/Controllers/Auth/AuthenticatedSessionController.php`
- [Login validation](https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Requests/Auth/LoginRequest.php): `app/Http/Requests/Auth/LoginRequest.php`
- [Verification prompt](https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/Auth/EmailVerificationPromptController.php): `app/Http/Controllers/Auth/EmailVerificationPromptController.php`
- [Verification notices](https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/Auth/EmailVerificationNotificationController.php): `app/Http/Controllers/Auth/EmailVerificationNotificationController.php`
- [Email verification](https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/Auth/VerifyEmailController.php): `app/Http/Controllers/Auth/VerifyEmailController.php`
- [Profile management](https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/ProfileController.php): `app/Http/Controllers/ProfileController.php`
- [Profile validation](https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Requests/ProfileUpdateRequest.php): `app/Http/Requests/ProfileUpdateRequest.php`
- [User account](https://github.com/beastfrompretoriaeast/osc/blob/main/app/Models/User.php): `app/Models/User.php`

### Site services

- [Site management](https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/SiteController.php): `app/Http/Controllers/SiteController.php`
- [Site record](https://github.com/beastfrompretoriaeast/osc/blob/main/app/Models/Site.php): `app/Models/Site.php`
- [Service management](https://github.com/beastfrompretoriaeast/osc/blob/main/app/Http/Controllers/ServiceController.php): `app/Http/Controllers/ServiceController.php`
- [Service record](https://github.com/beastfrompretoriaeast/osc/blob/main/app/Models/Service.php): `app/Models/Service.php`

### User interface

- [Profile form](https://github.com/beastfrompretoriaeast/osc/blob/main/resources/views/profile/edit.blade.php): `resources/views/profile/edit.blade.php`
- [Registration form](https://github.com/beastfrompretoriaeast/osc/blob/main/resources/views/auth/register.blade.php): `resources/views/auth/register.blade.php`
- [Admin dashboard](https://github.com/beastfrompretoriaeast/osc/blob/main/resources/views/backend/dashboard/dashboard.blade.php): `resources/views/backend/dashboard/dashboard.blade.php`

### Other components

- **User**
- **Stripe**

## Connections

- User → Web routes: sends requests (evidence: `routes/web.php`)
- User → Auth routes: authenticates (evidence: `routes/auth.php`)
- Web routes → Profile management: dispatches (evidence: `routes/web.php`)
- Web routes → Site management: dispatches (evidence: `routes/web.php`)
- Web routes → Service management: dispatches (evidence: `routes/web.php`)
- Auth routes → Registration: dispatches (evidence: `routes/auth.php`)
- Auth routes → Sessions: dispatches (evidence: `routes/auth.php`)
- Auth routes → Verification prompt: dispatches (evidence: `routes/auth.php`)
- Auth routes → Verification notices: dispatches (evidence: `routes/auth.php`)
- Auth routes → Email verification: dispatches (evidence: `routes/auth.php`)
- Registration → User account: creates account (evidence: `app/Http/Controllers/Auth/RegisteredUserController.php`)
- Registration → Registration form: renders (evidence: `app/Http/Controllers/Auth/RegisteredUserController.php`)
- Sessions → Login validation: authenticates with (evidence: `app/Http/Controllers/Auth/AuthenticatedSessionController.php`)
- Sessions → User: manages session (evidence: `app/Http/Controllers/Auth/AuthenticatedSessionController.php`)
- Profile management → Profile validation: validates with (evidence: `app/Http/Controllers/ProfileController.php`)
- Profile management → Profile form: renders (evidence: `app/Http/Controllers/ProfileController.php`)
- Site management → Site record: reads and writes (evidence: `app/Http/Controllers/SiteController.php`)
- Service management → Site record: uses site (evidence: `app/Http/Controllers/ServiceController.php`)
- Service management → Service record: creates and updates (evidence: `app/Http/Controllers/ServiceController.php`)
- Service management → Stripe: creates product and price (evidence: `app/Http/Controllers/ServiceController.php`)
- Service record → Site record: belongs to (evidence: `app/Models/Service.php`)
