# dev-adeshina/pudo architecture

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

- Interactive diagram: https://gitdiagram.com/dev-adeshina/pudo
- Repository: https://github.com/dev-adeshina/pudo

## Overview

This is a Laravel API for identity and profile management, KYC, marketplace fulfilment, ride delivery, Vride trips, and wallet operations. The principal workflow is an authenticated user entering through the DoorWay API, receiving an account/profile result, then using verified identity to access mobility, search, or wallet capabilities. Sampled code directly confirms authentication, account loading, profile upgrades, KYC submission, marketplace search/pricing, nearby-driver matching, and wallet retrieval/creation. Several listed domain services and integrations were not sampled, so their internal wiring is intentionally limited.

Main entry points: [`app/Http/Responses/ApiResponse.php`](https://github.com/dev-adeshina/pudo/blob/main/app/Http/Responses/ApiResponse.php) (API Response), [`app/Http/Controllers/Delivery/NearestRideController.php`](https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/Delivery/NearestRideController.php) (Nearby Ride), [`app/Http/Controllers/DoorWay/LoginController.php`](https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/DoorWay/LoginController.php) (Login Controller), [`app/Http/Controllers/General/AccountController.php`](https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/General/AccountController.php) (Account Controller)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_api["API Access"]
  node_login["Login Controller"]
  node_account["Account Controller"]
  node_user_resource["User Resource<br/>[UserResource.php]"]
end

subgraph group_identity["Identity KYC"]
  node_user[("User Account<br/>[User.php]")]
  node_profile_upgrade["Profile Upgrades"]
  node_identity_models[("Identity Models<br/>[Actor.php]")]
  node_kyc_controller["Document KYC"]
  node_kyc_action["KYC Action"]
  node_kyc_services["KYC Services"]
end

subgraph group_mobility["Mobility Fulfilment"]
  node_price_search["Price Search"]
  node_item_catalog[("Item Catalog<br/>[Item.php]")]
  node_ride_search["Nearby Ride"]
  node_delivery[("Delivery Ride<br/>[Delivery.php]")]
  node_trip_controller["Trip Controller<br/>[TripController.php]"]
  node_trip_action["Trip Action<br/>[TripAction.php]"]
  node_vride_profile["Vride Upgrade"]
end

subgraph group_wallet["Wallet Finance"]
  node_wallet_controller["Wallet Controller"]
  node_wallet_service["Wallet Service<br/>[WalletService.php]"]
  node_wallet_store[("Wallet Store<br/>[Wallet.php]")]
  node_wallet_onboarding["Wallet Onboarding"]
  node_anchor_services["Anchor Services"]
end

subgraph group_shared["Shared Platform"]
  node_redis[("Redis State")]
  node_api_response["API Response<br/>[ApiResponse.php]"]
end

node_user_actor(("User"))
node_anchor_bank{{"Anchor Banking"}}

node_user_actor -->|"submits credentials"| node_login
node_login -->|"reads account"| node_user
node_login -->|"formats result"| node_user_resource
node_login -->|"returns token"| node_api_response
node_user_actor -->|"requests account"| node_account
node_account -->|"loads account"| node_user
node_account -->|"formats result"| node_user_resource
node_account -->|"returns profile"| node_api_response
node_user_actor -->|"submits upgrade"| node_profile_upgrade
node_profile_upgrade -->|"checks profile"| node_user
node_profile_upgrade -->|"creates identity"| node_identity_models
node_profile_upgrade -->|"returns upgrade"| node_api_response
node_user_actor -->|"submits document"| node_kyc_controller
node_kyc_controller -->|"executes verification"| node_kyc_action
node_kyc_action -->|"verifies document"| node_kyc_services
node_kyc_controller -->|"returns status"| node_api_response
node_user_actor -->|"searches prices"| node_price_search
node_price_search -->|"queries items"| node_item_catalog
node_price_search -->|"returns prices"| node_api_response
node_user_actor -->|"requests ride"| node_ride_search
node_ride_search -->|"finds nearby drivers"| node_redis
node_ride_search -->|"creates ride"| node_delivery
node_ride_search -->|"stores assignment"| node_redis
node_ride_search -->|"returns ride"| node_api_response
node_user_actor -->|"creates trip"| node_trip_controller
node_trip_controller -->|"executes trip"| node_trip_action
node_trip_controller -->|"returns trip"| node_api_response
node_user_actor -->|"upgrades Vride"| node_vride_profile
node_vride_profile -->|"checks profile"| node_user
node_vride_profile -->|"creates Vride"| node_identity_models
node_vride_profile -->|"returns upgrade"| node_api_response
node_user_actor -->|"opens wallet"| node_wallet_controller
node_wallet_controller -->|"requests wallet"| node_wallet_service
node_wallet_service -->|"reads or creates"| node_wallet_store
node_wallet_controller -->|"returns wallet"| node_api_response
node_wallet_onboarding -.->|"onboards customer"| node_anchor_services
node_anchor_services -.->|"uses banking API"| node_anchor_bank

click node_login "https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/DoorWay/LoginController.php"
click node_account "https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/General/AccountController.php"
click node_user "https://github.com/dev-adeshina/pudo/blob/main/app/Models/User.php"
click node_user_resource "https://github.com/dev-adeshina/pudo/blob/main/app/Http/Resources/UserResource.php"
click node_profile_upgrade "https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/DoorWay/Errand/ProfileUpgradeController.php"
click node_identity_models "https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Identity/Models/Actor.php"
click node_kyc_controller "https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/Kyc/VerifyByDocumentController.php"
click node_kyc_action "https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Kyc/Actions/VerificationLevelTwoAction.php"
click node_kyc_services "https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Kyc/Services/DocumentVerificationService.php"
click node_price_search "https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/Search/PriceController.php"
click node_item_catalog "https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Fulfilment/Items/Models/Item.php"
click node_ride_search "https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/Delivery/NearestRideController.php"
click node_delivery "https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Fulfilment/Delivery/Models/Delivery.php"
click node_trip_controller "https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/Vride/TripController.php"
click node_trip_action "https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Vride/Actions/TripAction.php"
click node_vride_profile "https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/DoorWay/Vride/ProfileUpgradeController.php"
click node_wallet_controller "https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/Wallet/WalletController.php"
click node_wallet_service "https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Wallet/Services/WalletService.php"
click node_wallet_store "https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Wallet/Models/Wallet.php"
click node_wallet_onboarding "https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Wallet/Workflows/OnboardCustomer/OnboardCustomersWorkflow.php"
click node_anchor_services "https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Wallet/Services/Anchor/AnchorCustomerService.php"
click node_api_response "https://github.com/dev-adeshina/pudo/blob/main/app/Http/Responses/ApiResponse.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_account,node_user_resource,node_user_actor toneBlue
class node_user,node_profile_upgrade,node_identity_models,node_kyc_controller,node_kyc_action,node_kyc_services toneAmber
class node_price_search,node_item_catalog,node_ride_search,node_delivery,node_trip_controller,node_trip_action,node_vride_profile toneMint
class node_wallet_controller,node_wallet_service,node_wallet_store,node_wallet_onboarding,node_anchor_services toneRose
class node_redis,node_api_response,node_anchor_bank toneIndigo
```

## Components

### API Access

- [Login Controller](https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/DoorWay/LoginController.php): `app/Http/Controllers/DoorWay/LoginController.php`
- [Account Controller](https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/General/AccountController.php): `app/Http/Controllers/General/AccountController.php`
- [User Resource](https://github.com/dev-adeshina/pudo/blob/main/app/Http/Resources/UserResource.php): `app/Http/Resources/UserResource.php`

### Identity KYC

- [User Account](https://github.com/dev-adeshina/pudo/blob/main/app/Models/User.php): `app/Models/User.php`
- [Profile Upgrades](https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/DoorWay/Errand/ProfileUpgradeController.php): `app/Http/Controllers/DoorWay/Errand/ProfileUpgradeController.php`
- [Identity Models](https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Identity/Models/Actor.php): `app/Domains/Identity/Models/Actor.php`
- [Document KYC](https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/Kyc/VerifyByDocumentController.php): `app/Http/Controllers/Kyc/VerifyByDocumentController.php`
- [KYC Action](https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Kyc/Actions/VerificationLevelTwoAction.php): `app/Domains/Kyc/Actions/VerificationLevelTwoAction.php`
- [KYC Services](https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Kyc/Services/DocumentVerificationService.php): `app/Domains/Kyc/Services/DocumentVerificationService.php`

### Mobility Fulfilment

- [Price Search](https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/Search/PriceController.php): `app/Http/Controllers/Search/PriceController.php`
- [Item Catalog](https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Fulfilment/Items/Models/Item.php): `app/Domains/Fulfilment/Items/Models/Item.php`
- [Nearby Ride](https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/Delivery/NearestRideController.php): `app/Http/Controllers/Delivery/NearestRideController.php`
- [Delivery Ride](https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Fulfilment/Delivery/Models/Delivery.php): `app/Domains/Fulfilment/Delivery/Models/Delivery.php`
- [Trip Controller](https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/Vride/TripController.php): `app/Http/Controllers/Vride/TripController.php`
- [Trip Action](https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Vride/Actions/TripAction.php): `app/Domains/Vride/Actions/TripAction.php`
- [Vride Upgrade](https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/DoorWay/Vride/ProfileUpgradeController.php): `app/Http/Controllers/DoorWay/Vride/ProfileUpgradeController.php`

### Wallet Finance

- [Wallet Controller](https://github.com/dev-adeshina/pudo/blob/main/app/Http/Controllers/Wallet/WalletController.php): `app/Http/Controllers/Wallet/WalletController.php`
- [Wallet Service](https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Wallet/Services/WalletService.php): `app/Domains/Wallet/Services/WalletService.php`
- [Wallet Store](https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Wallet/Models/Wallet.php): `app/Domains/Wallet/Models/Wallet.php`
- [Wallet Onboarding](https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Wallet/Workflows/OnboardCustomer/OnboardCustomersWorkflow.php): `app/Domains/Wallet/Workflows/OnboardCustomer/OnboardCustomersWorkflow.php`
- [Anchor Services](https://github.com/dev-adeshina/pudo/blob/main/app/Domains/Wallet/Services/Anchor/AnchorCustomerService.php): `app/Domains/Wallet/Services/Anchor/AnchorCustomerService.php`

### Shared Platform

- **Redis State**
- [API Response](https://github.com/dev-adeshina/pudo/blob/main/app/Http/Responses/ApiResponse.php): `app/Http/Responses/ApiResponse.php`

### Other components

- **User**
- **Anchor Banking**

## Connections

- User → Login Controller: submits credentials
- Login Controller → User Account: reads account
- Login Controller → User Resource: formats result
- Login Controller → API Response: returns token
- User → Account Controller: requests account
- Account Controller → User Account: loads account
- Account Controller → User Resource: formats result
- Account Controller → API Response: returns profile
- User → Profile Upgrades: submits upgrade
- Profile Upgrades → User Account: checks profile
- Profile Upgrades → Identity Models: creates identity
- Profile Upgrades → API Response: returns upgrade
- User → Document KYC: submits document
- Document KYC → KYC Action: executes verification
- KYC Action → KYC Services: verifies document
- Document KYC → API Response: returns status
- User → Price Search: searches prices
- Price Search → Item Catalog: queries items
- Price Search → API Response: returns prices
- User → Nearby Ride: requests ride
- Nearby Ride → Redis State: finds nearby drivers
- Nearby Ride → Delivery Ride: creates ride
- Nearby Ride → Redis State: stores assignment
- Nearby Ride → API Response: returns ride
- User → Trip Controller: creates trip
- Trip Controller → Trip Action: executes trip
- Trip Controller → API Response: returns trip
- User → Vride Upgrade: upgrades Vride
- Vride Upgrade → User Account: checks profile
- Vride Upgrade → Identity Models: creates Vride
- Vride Upgrade → API Response: returns upgrade
- User → Wallet Controller: opens wallet
- Wallet Controller → Wallet Service: requests wallet
- Wallet Service → Wallet Store: reads or creates
- Wallet Controller → API Response: returns wallet
- Wallet Onboarding → Anchor Services: onboards customer
- Anchor Services → Anchor Banking: uses banking API
