# freed1234/vshop architecture

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

- Interactive diagram: https://gitdiagram.com/freed1234/vshop
- Repository: https://github.com/freed1234/vshop

## Overview

VShop Personal is a Windows desktop client for viewing VALORANT’s daily shop, Night Market, bundles, and VP/RP balances, with upgrade-video previews. The main workflow is region selection and Riot login, followed by token-based shop and wallet requests and display in three tabs; users can refresh or open a skin preview. The implementation is concentrated in app.py, with launcher.py setting startup diagnostics and rendering options. Several domain responsibilities below are separated conceptually despite sharing that file; unsampled internals are not inferred beyond the README and shown excerpts.

Main entry points: [`app.py`](https://github.com/freed1234/vshop/blob/main/app.py) (Shop and wallet fetch), [`launcher.py`](https://github.com/freed1234/vshop/blob/main/launcher.py) (Application launcher)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_startup["Startup"]
  node_launcher["Application launcher<br/>[launcher.py]"]
  node_main["Main window<br/>[app.py]"]
end

subgraph group_identity["Login"]
  node_login_view["Login WebView<br/>[app.py]"]
  node_token_flow["Token handling<br/>[app.py]"]
  node_riot_auth{{"Riot authentication"}}
end

subgraph group_shop["Shop and Balances"]
  node_shop_fetch["Shop and wallet fetch<br/>[app.py]"]
  node_riot_store{{"Riot game services"}}
  node_daily["Daily offers<br/>[app.py]"]
  node_night_market["Night Market<br/>[app.py]"]
  node_bundles["Bundle offers<br/>[app.py]"]
  node_skin_assets["Skin asset lookup<br/>[app.py]"]
  node_shop_ui["Shop tabs and cards<br/>[app.py]"]
end

subgraph group_preview["Skin Preview"]
  node_catalog["Skin upgrade catalog<br/>[app.py]"]
  node_public_api{{"VALORANT public API"}}
  node_preview_dialog["Upgrade preview dialog<br/>[app.py]"]
  node_video_host{{"Public video host"}}
  node_video_player["Video playback and cleanup<br/>[app.py]"]
end

node_user(("Riot account user"))

node_user -->|"uses"| node_main
node_launcher -->|"starts"| node_main
node_main -->|"shows login"| node_login_view
node_login_view -->|"authenticates"| node_riot_auth
node_login_view -->|"redirects token"| node_token_flow
node_token_flow -->|"requests entitlement"| node_riot_auth
node_main -->|"loads or refreshes"| node_shop_fetch
node_shop_fetch -->|"requests offers and wallet"| node_riot_store
node_shop_fetch -->|"extracts offers"| node_daily
node_shop_fetch -->|"extracts offers"| node_night_market
node_shop_fetch -->|"extracts bundles"| node_bundles
node_shop_fetch -->|"looks up skin data"| node_skin_assets
node_skin_assets -->|"requests assets"| node_public_api
node_daily -->|"displays"| node_shop_ui
node_night_market -->|"displays"| node_shop_ui
node_bundles -->|"displays"| node_shop_ui
node_main -->|"updates balances"| node_shop_ui
node_shop_ui -->|"opens preview"| node_preview_dialog
node_preview_dialog -->|"loads upgrade levels"| node_catalog
node_catalog -->|"requests skin data"| node_public_api
node_catalog -->|"provides public video URL"| node_video_host
node_preview_dialog -->|"controls playback"| node_video_player
node_video_host -->|"supplies video"| node_video_player

click node_launcher "https://github.com/freed1234/vshop/blob/main/launcher.py"
click node_main "https://github.com/freed1234/vshop/blob/main/app.py"
click node_login_view "https://github.com/freed1234/vshop/blob/main/app.py"
click node_token_flow "https://github.com/freed1234/vshop/blob/main/app.py"
click node_shop_fetch "https://github.com/freed1234/vshop/blob/main/app.py"
click node_daily "https://github.com/freed1234/vshop/blob/main/app.py"
click node_night_market "https://github.com/freed1234/vshop/blob/main/app.py"
click node_bundles "https://github.com/freed1234/vshop/blob/main/app.py"
click node_skin_assets "https://github.com/freed1234/vshop/blob/main/app.py"
click node_shop_ui "https://github.com/freed1234/vshop/blob/main/app.py"
click node_catalog "https://github.com/freed1234/vshop/blob/main/app.py"
click node_preview_dialog "https://github.com/freed1234/vshop/blob/main/app.py"
click node_video_player "https://github.com/freed1234/vshop/blob/main/app.py"

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_launcher,node_main,node_user toneBlue
class node_login_view,node_token_flow,node_riot_auth toneAmber
class node_shop_fetch,node_riot_store,node_daily,node_night_market,node_bundles,node_skin_assets,node_shop_ui toneMint
class node_catalog,node_public_api,node_preview_dialog,node_video_host,node_video_player toneRose
```

## Components

### Startup

- [Application launcher](https://github.com/freed1234/vshop/blob/main/launcher.py): `launcher.py`
- [Main window](https://github.com/freed1234/vshop/blob/main/app.py): `app.py`

### Login

- [Login WebView](https://github.com/freed1234/vshop/blob/main/app.py): `app.py`
- [Token handling](https://github.com/freed1234/vshop/blob/main/app.py): `app.py`
- **Riot authentication**

### Shop and Balances

- [Shop and wallet fetch](https://github.com/freed1234/vshop/blob/main/app.py): `app.py`
- **Riot game services**
- [Daily offers](https://github.com/freed1234/vshop/blob/main/app.py): `app.py`
- [Night Market](https://github.com/freed1234/vshop/blob/main/app.py): `app.py`
- [Bundle offers](https://github.com/freed1234/vshop/blob/main/app.py): `app.py`
- [Skin asset lookup](https://github.com/freed1234/vshop/blob/main/app.py): `app.py`
- [Shop tabs and cards](https://github.com/freed1234/vshop/blob/main/app.py): `app.py`

### Skin Preview

- [Skin upgrade catalog](https://github.com/freed1234/vshop/blob/main/app.py): `app.py`
- **VALORANT public API**
- [Upgrade preview dialog](https://github.com/freed1234/vshop/blob/main/app.py): `app.py`
- **Public video host**
- [Video playback and cleanup](https://github.com/freed1234/vshop/blob/main/app.py): `app.py`

### Other components

- **Riot account user**

## Connections

- Riot account user → Main window: uses (evidence: `README.md`)
- Application launcher → Main window: starts (evidence: `launcher.py`)
- Main window → Login WebView: shows login (evidence: `app.py`)
- Login WebView → Riot authentication: authenticates (evidence: `app.py`)
- Login WebView → Token handling: redirects token (evidence: `app.py`)
- Token handling → Riot authentication: requests entitlement (evidence: `app.py`)
- Main window → Shop and wallet fetch: loads or refreshes (evidence: `app.py`)
- Shop and wallet fetch → Riot game services: requests offers and wallet (evidence: `app.py`)
- Shop and wallet fetch → Daily offers: extracts offers (evidence: `app.py`)
- Shop and wallet fetch → Night Market: extracts offers (evidence: `README.md`)
- Shop and wallet fetch → Bundle offers: extracts bundles (evidence: `app.py`)
- Shop and wallet fetch → Skin asset lookup: looks up skin data (evidence: `app.py`)
- Skin asset lookup → VALORANT public API: requests assets (evidence: `app.py`)
- Daily offers → Shop tabs and cards: displays (evidence: `README.md`)
- Night Market → Shop tabs and cards: displays (evidence: `README.md`)
- Bundle offers → Shop tabs and cards: displays (evidence: `README.md`)
- Main window → Shop tabs and cards: updates balances (evidence: `README.md`)
- Shop tabs and cards → Upgrade preview dialog: opens preview (evidence: `README.md`)
- Upgrade preview dialog → Skin upgrade catalog: loads upgrade levels (evidence: `app.py`)
- Skin upgrade catalog → VALORANT public API: requests skin data (evidence: `app.py`)
- Skin upgrade catalog → Public video host: provides public video URL (evidence: `app.py`)
- Upgrade preview dialog → Video playback and cleanup: controls playback (evidence: `README.md`)
- Public video host → Video playback and cleanup: supplies video (evidence: `README.md`)
