# ihmily/streamcap architecture

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

- Interactive diagram: https://gitdiagram.com/ihmily/streamcap
- Repository: https://github.com/ihmily/streamcap

## Overview

StreamCap is a cross-platform live-stream recording client. Users configure stream URLs and monitoring options in the app; the recording manager checks live status, obtains platform stream information, and starts recordings, with files saved in selected formats. The README also describes scheduled and batch monitoring, automatic MP4 transcoding, and live-status notifications. The graph includes UI, recording, platform, and runtime layers; several UI and integration links are based on README or import-index evidence because their implementations were not sampled.

Main entry points: [`app/app_manager.py`](https://github.com/ihmily/streamcap/blob/main/app/app_manager.py) (App Manager), [`app/core/recording/record_manager.py`](https://github.com/ihmily/streamcap/blob/main/app/core/recording/record_manager.py) (Recording Manager), [`app/core/recording/stream_manager.py`](https://github.com/ihmily/streamcap/blob/main/app/core/recording/stream_manager.py) (Stream Manager), [`app/ui/components/business/recording_card.py`](https://github.com/ihmily/streamcap/blob/main/app/ui/components/business/recording_card.py) (Recording UI)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_ui["Application UI"]
  node_app["App Manager<br/>[app_manager.py]"]
  node_views["App Views"]
  node_recording_ui["Recording UI<br/>[recording_card.py]"]
  node_player["Video Player<br/>[video_player.py]"]
  node_storage["Storage Browser<br/>[storage_view.py]"]
  node_auth["Web Authentication<br/>[auth_manager.py]"]
end

subgraph group_recording["Recording Workflow"]
  node_record_manager["Recording Manager<br/>[record_manager.py]"]
  node_recording_model["Recording State<br/>[recording_model.py]"]
  node_stream_manager["Stream Manager<br/>[stream_manager.py]"]
  node_platform_handlers["Platform Handlers<br/>[handlers.py]"]
  node_ffmpeg["FFmpeg Builders"]
  node_direct_download["Direct Downloader"]
end

subgraph group_runtime["Backend Runtime"]
  node_backend["Backend Services"]
  node_process_manager["Process Manager<br/>[process_manager.py]"]
end

subgraph group_support["Configuration And Services"]
  node_config["Configuration<br/>[config_manager.py]"]
  node_notifications["Notifications<br/>[message_pusher.py]"]
  node_notification_service["Push Service"]
  node_installation["Environment Setup"]
  node_update_checker["Update Checker<br/>[update_checker.py]"]
  node_video_api["Video Stream API"]
end

node_user(("User"))

node_user -->|"configures streams"| node_views
node_app -->|"loads views"| node_views
node_app -->|"uses services"| node_backend
node_app -->|"updates cards"| node_recording_ui
node_app -->|"checks environment"| node_installation
node_app -->|"checks updates"| node_update_checker
node_views -.->|"presents recordings"| node_recording_ui
node_recording_ui -->|"displays state"| node_recording_model
node_recording_ui -->|"opens playback"| node_player
node_storage -.->|"requests playback"| node_video_api
node_backend -->|"initializes settings"| node_config
node_backend -->|"creates manager"| node_record_manager
node_record_manager -->|"stores recordings"| node_recording_model
node_record_manager -->|"starts stream work"| node_stream_manager
node_record_manager -->|"sends status updates"| node_notifications
node_stream_manager -->|"gets stream info"| node_platform_handlers
node_stream_manager -->|"builds commands"| node_ffmpeg
node_stream_manager -->|"downloads directly"| node_direct_download
node_stream_manager -->|"tracks processes"| node_process_manager
node_notifications -->|"dispatches pushes"| node_notification_service
node_user -->|"authenticates"| node_auth
node_user -->|"browses recordings"| node_storage
node_record_manager -->|"persists records"| node_recording_model

click node_app "https://github.com/ihmily/streamcap/blob/main/app/app_manager.py"
click node_views "https://github.com/ihmily/streamcap/tree/main/app/ui/views"
click node_recording_ui "https://github.com/ihmily/streamcap/blob/main/app/ui/components/business/recording_card.py"
click node_player "https://github.com/ihmily/streamcap/blob/main/app/ui/components/business/video_player.py"
click node_storage "https://github.com/ihmily/streamcap/blob/main/app/ui/views/storage_view.py"
click node_auth "https://github.com/ihmily/streamcap/blob/main/app/auth/auth_manager.py"
click node_backend "https://github.com/ihmily/streamcap/blob/main/app/core/runtime/backend_services.py"
click node_record_manager "https://github.com/ihmily/streamcap/blob/main/app/core/recording/record_manager.py"
click node_recording_model "https://github.com/ihmily/streamcap/blob/main/app/models/recording/recording_model.py"
click node_stream_manager "https://github.com/ihmily/streamcap/blob/main/app/core/recording/stream_manager.py"
click node_platform_handlers "https://github.com/ihmily/streamcap/blob/main/app/core/platforms/platform_handlers/handlers.py"
click node_ffmpeg "https://github.com/ihmily/streamcap/tree/main/app/core/media/ffmpeg_builders"
click node_direct_download "https://github.com/ihmily/streamcap/blob/main/app/core/media/direct_downloader.py"
click node_process_manager "https://github.com/ihmily/streamcap/blob/main/app/core/runtime/process_manager.py"
click node_config "https://github.com/ihmily/streamcap/blob/main/app/core/config/config_manager.py"
click node_notifications "https://github.com/ihmily/streamcap/blob/main/app/messages/message_pusher.py"
click node_notification_service "https://github.com/ihmily/streamcap/blob/main/app/messages/notification_service.py"
click node_installation "https://github.com/ihmily/streamcap/blob/main/app/initialization/installation_manager.py"
click node_update_checker "https://github.com/ihmily/streamcap/blob/main/app/core/update/update_checker.py"
click node_video_api "https://github.com/ihmily/streamcap/blob/main/app/api/video_stream_service.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_app,node_views,node_recording_ui,node_player,node_storage,node_auth,node_user toneBlue
class node_record_manager,node_recording_model,node_stream_manager,node_platform_handlers,node_ffmpeg,node_direct_download toneAmber
class node_backend,node_process_manager toneMint
class node_config,node_notifications,node_notification_service,node_installation,node_update_checker,node_video_api toneRose
```

## Components

### Application UI

- [App Manager](https://github.com/ihmily/streamcap/blob/main/app/app_manager.py): `app/app_manager.py`
- [App Views](https://github.com/ihmily/streamcap/tree/main/app/ui/views): `app/ui/views`
- [Recording UI](https://github.com/ihmily/streamcap/blob/main/app/ui/components/business/recording_card.py): `app/ui/components/business/recording_card.py`
- [Video Player](https://github.com/ihmily/streamcap/blob/main/app/ui/components/business/video_player.py): `app/ui/components/business/video_player.py`
- [Storage Browser](https://github.com/ihmily/streamcap/blob/main/app/ui/views/storage_view.py): `app/ui/views/storage_view.py`
- [Web Authentication](https://github.com/ihmily/streamcap/blob/main/app/auth/auth_manager.py): `app/auth/auth_manager.py`

### Recording Workflow

- [Recording Manager](https://github.com/ihmily/streamcap/blob/main/app/core/recording/record_manager.py): `app/core/recording/record_manager.py`
- [Recording State](https://github.com/ihmily/streamcap/blob/main/app/models/recording/recording_model.py): `app/models/recording/recording_model.py`
- [Stream Manager](https://github.com/ihmily/streamcap/blob/main/app/core/recording/stream_manager.py): `app/core/recording/stream_manager.py`
- [Platform Handlers](https://github.com/ihmily/streamcap/blob/main/app/core/platforms/platform_handlers/handlers.py): `app/core/platforms/platform_handlers/handlers.py`
- [FFmpeg Builders](https://github.com/ihmily/streamcap/tree/main/app/core/media/ffmpeg_builders): `app/core/media/ffmpeg_builders`
- [Direct Downloader](https://github.com/ihmily/streamcap/blob/main/app/core/media/direct_downloader.py): `app/core/media/direct_downloader.py`

### Backend Runtime

- [Backend Services](https://github.com/ihmily/streamcap/blob/main/app/core/runtime/backend_services.py): `app/core/runtime/backend_services.py`
- [Process Manager](https://github.com/ihmily/streamcap/blob/main/app/core/runtime/process_manager.py): `app/core/runtime/process_manager.py`

### Configuration And Services

- [Configuration](https://github.com/ihmily/streamcap/blob/main/app/core/config/config_manager.py): `app/core/config/config_manager.py`
- [Notifications](https://github.com/ihmily/streamcap/blob/main/app/messages/message_pusher.py): `app/messages/message_pusher.py`
- [Push Service](https://github.com/ihmily/streamcap/blob/main/app/messages/notification_service.py): `app/messages/notification_service.py`
- [Environment Setup](https://github.com/ihmily/streamcap/blob/main/app/initialization/installation_manager.py): `app/initialization/installation_manager.py`
- [Update Checker](https://github.com/ihmily/streamcap/blob/main/app/core/update/update_checker.py): `app/core/update/update_checker.py`
- [Video Stream API](https://github.com/ihmily/streamcap/blob/main/app/api/video_stream_service.py): `app/api/video_stream_service.py`

### Other components

- **User**

## Connections

- User → App Views: configures streams
- App Manager → App Views: loads views (evidence: `app/app_manager.py`)
- App Manager → Backend Services: uses services (evidence: `app/app_manager.py`)
- App Manager → Recording UI: updates cards (evidence: `app/app_manager.py`)
- App Manager → Environment Setup: checks environment (evidence: `app/app_manager.py`)
- App Manager → Update Checker: checks updates (evidence: `app/app_manager.py`)
- App Views → Recording UI: presents recordings (evidence: `app/ui/components/business/recording_card.py`)
- Recording UI → Recording State: displays state (evidence: `app/ui/components/business/recording_card.py`)
- Recording UI → Video Player: opens playback (evidence: `app/ui/components/business/recording_card.py`)
- Storage Browser → Video Stream API: requests playback
- Backend Services → Configuration: initializes settings (evidence: `app/core/runtime/backend_services.py`)
- Backend Services → Recording Manager: creates manager (evidence: `app/core/runtime/backend_services.py`)
- Recording Manager → Recording State: stores recordings (evidence: `app/core/recording/record_manager.py`)
- Recording Manager → Stream Manager: starts stream work (evidence: `app/core/recording/record_manager.py`)
- Recording Manager → Notifications: sends status updates (evidence: `app/core/recording/record_manager.py`)
- Stream Manager → Platform Handlers: gets stream info (evidence: `app/core/recording/stream_manager.py`)
- Stream Manager → FFmpeg Builders: builds commands (evidence: `app/core/recording/stream_manager.py`)
- Stream Manager → Direct Downloader: downloads directly (evidence: `app/core/recording/stream_manager.py`)
- Stream Manager → Process Manager: tracks processes (evidence: `app/core/recording/stream_manager.py`)
- Notifications → Push Service: dispatches pushes (evidence: `app/messages/message_pusher.py`)
- User → Web Authentication: authenticates
- User → Storage Browser: browses recordings
- Recording Manager → Recording State: persists records (evidence: `app/core/recording/record_manager.py`)
