### Install and Develop Server and Web Source: https://github.com/whiteminds/liveautorecord/blob/master/CLAUDE.md Installs dependencies and starts the server and web development environments. Includes automatic dependency compilation and Vite development server. ```bash pnpm install pnpm dev:server # 自动编译依赖 + 启动 http-server(tsup watch) pnpm dev:web # Vite dev server ``` -------------------------------- ### Start Server and Web Preview Source: https://github.com/whiteminds/liveautorecord/blob/master/README.md Commands to start the http-server and preview the web application. ```shell pnpm -F @autorecord/http-server start pnpm -F @autorecord/web preview ``` -------------------------------- ### Install and Develop Electron Client Source: https://github.com/whiteminds/liveautorecord/blob/master/CLAUDE.md Installs dependencies and starts the Electron client in development mode. Turborepo manages dependency compilation and parallel execution. ```bash pnpm install # Turborepo 自动按拓扑排序编译所有依赖,然后并行运行 http-server watch + electron-vite dev pnpm app:dev ``` -------------------------------- ### Clone and Install Server Dependencies Source: https://github.com/whiteminds/liveautorecord/blob/master/README.md Steps to clone the repository, install server dependencies, and build all packages for the server. ```shell git clone git@github.com:WhiteMinds/LiveAutoRecord.git && cd LiveAutoRecord pnpm install pnpm build ``` -------------------------------- ### Install and Develop CLI Source: https://github.com/whiteminds/liveautorecord/blob/master/CLAUDE.md Installs dependencies and builds/runs the command-line interface. Includes instructions for running help and listing items. ```bash pnpm install pnpm dev:cli # 自动编译所有依赖 + cli # 运行 node apps/cli/lib/bin.js --help node apps/cli/lib/bin.js list --json ``` -------------------------------- ### Install and Develop Electron Client Source: https://github.com/whiteminds/liveautorecord/blob/master/README.md Commands to install dependencies, run the development server, and build the Electron application for the client. ```bash pnpm install pnpm app:dev pnpm app:build ``` -------------------------------- ### Start Recording Manually Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Manually triggers a recorder to start recording. ```APIDOC ## POST /api/recorders/:id/start_record ### Description Manually triggers a recorder to start recording. If the recorder is already recording, this action has no effect. ### Method POST ### Endpoint /api/recorders/:id/start_record #### Path Parameters - **id** (string) - Required - The ID of the recorder ### Response #### Success Response (200) - **payload** (ClientRecorder) - The recorder object after the start command. #### Error Response - **Error('404')** - Thrown if the recorder does not exist. ``` -------------------------------- ### Browser Login Response Example Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Example JSON response after a successful browser login, including the authentication configuration and status. ```json { "payload": { "authConfig": { "cookie": "SESSDATA=xxx; bili_jct=xxx; DedeUserID=xxx; ..." }, "status": { "isAuthenticated": true, "description": "用户名" } } } ``` -------------------------------- ### Lerna Bootstrap Alternative Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/pnpm-migration-plan.md pnpm install replaces 'lerna bootstrap' for installing dependencies in a pnpm workspace. ```bash pnpm install ``` -------------------------------- ### Provider List Response Example Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Example JSON response for the provider list endpoint, showing details for Bilibili and DouYu providers. ```json { "payload": [ { "id": "Bilibili", "name": "Bilibili", "siteURL": "https://live.bilibili.com/", "authFields": [ { "key": "cookie", "label": "Cookie", "type": "textarea", "required": false, "placeholder": "SESSDATA=xxx; bili_jct=xxx; DedeUserID=xxx; ...", "description": "从浏览器获取 B站登录 Cookie,用于获取原画等高画质直播流" } ], "hasAuthFlow": true }, { "id": "DouYu", "name": "DouYu", "siteURL": "https://www.douyu.com/" } ] } ``` -------------------------------- ### Production Deployment for Server and Web Source: https://github.com/whiteminds/liveautorecord/blob/master/README.md Commands for building and starting the production server and building the web application. ```bash pnpm build pnpm -F @autorecord/http-server start pnpm -F @autorecord/web build ``` -------------------------------- ### Manually Start Recording API Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Trigger a specific recorder to start recording immediately. If already recording, this action has no effect. Requires the recorder ID. ```http POST /api/recorders/:id/start_record ``` -------------------------------- ### Register Plugin in HTTP Server Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/providers.md Example of how to register a new recorder provider in the HTTP server's recorder manager. Ensure the provider is imported correctly. ```typescript import { provider as providerForMyPlatform } from '@autorecord/my-platform-recorder' export const recorderManager = createRecorderManager({ providers: [ providerForDouYu, providerForBilibili, providerForHuYa, providerForDouYin, providerForMyPlatform, // <-- 新增 ], }) ``` -------------------------------- ### Set Provider Authentication Request Body Example Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Example JSON request body for setting provider authentication, containing a 'cookie' field. ```json { "config": { "cookie": "SESSDATA=xxx; bili_jct=xxx; DedeUserID=xxx" } } ``` -------------------------------- ### Initiate Browser Login Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Starts a browser-based login flow for a provider. This is a long-polling request that completes when the user logs in or times out. ```APIDOC ## POST /api/providers/:id/auth/login ### Description Initiates a browser-based login flow for the provider. This is a long-polling request that returns only after the user completes the login or the request times out (default 5 minutes). ### Method POST ### Endpoint /api/providers/:id/auth/login ### Parameters #### Path Parameters - **id** (string) - Required - The Provider ID. ### Response #### Success Response (200) - **payload** (object) - **authConfig** (object) - The authentication configuration, including the cookie. - **cookie** (string) - The authentication cookie. - **status** (object) - The authentication status. - **isAuthenticated** (boolean) - Indicates if the user is authenticated. - **description** (string, optional) - A description of the authenticated user (e.g., username). ### Response Example ```json { "payload": { "authConfig": { "cookie": "SESSDATA=xxx; bili_jct=xxx; DedeUserID=xxx; ..." }, "status": { "isAuthenticated": true, "description": "用户名" } } } ``` ### Behavior Notes - **Electron Mode**: Opens a `BrowserWindow` for login. - **HTTP Server Mode**: Uses Playwright to open a Chromium browser. - If the server does not have an `executeAuthFlow` callback configured, it returns HTTP 501 (Not Implemented). - If the client disconnects (`req.on('close')`), the login process is automatically canceled, and the browser is closed. - Timeout is 5 minutes by default. ### Error Handling - Provider not found or does not support browser login: HTTP 400/404. - `executeAuthFlow` callback not configured: HTTP 501. - Login timeout or user closes the browser: HTTP 500. ``` -------------------------------- ### Provider Authentication Status Response (Not Authenticated) Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Example JSON response indicating that the user is not authenticated for the provider. ```json { "payload": { "isAuthenticated": false } } ``` -------------------------------- ### Provider Authentication Status Response (Authenticated) Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Example JSON response indicating that the user is authenticated for the provider. ```json { "payload": { "isAuthenticated": true, "description": "用户名" } } ``` -------------------------------- ### Browser Login Authentication Test Plan Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/cli.md Steps to test authentication using the browser login method, including Playwright installation and the login command. ```bash # 1. 安装 Playwright(如未安装) pnpm add playwright && npx playwright install chromium # 2. 浏览器登录 node apps/cli/lib/bin.js auth login Bilibili # 3. 验证登录状态 node apps/cli/lib/bin.js auth list --json ``` -------------------------------- ### Initiate Browser Login Flow Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Starts a browser-based login process for a provider. This is a long-polling request that completes upon user login or timeout. ```http POST /api/providers/:id/auth/login ``` -------------------------------- ### Get Recorders List Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Retrieves a list of all recorders with optional pagination. ```APIDOC ## GET /api/recorders ### Description Retrieves a list of recorders with optional pagination. ### Method GET ### Endpoint /api/recorders #### Query Parameters - **page** (number) - Optional - Page number, defaults to 1 - **pageSize** (number) - Optional - Number of items per page, defaults to 10 ### Response #### Success Response (200) - **payload** (object) - Contains pagination info and a list of recorder items. ### Response Example ```json { "payload": { "page": 1, "pageSize": 10, "total": 3, "totalPage": 1, "items": [ { "id": "1", "providerId": "Bilibili", "channelId": "12345", "remarks": "某主播", "disableAutoCheck": false, "quality": "highest", "streamPriorities": [], "sourcePriorities": [], "extra": { "createTimestamp": 1708000000000 }, "availableStreams": ["flv", "hls"], "availableSources": ["cn-gotcha01"], "usedStream": "flv", "usedSource": "cn-gotcha01", "state": "recording", "channelURL": "https://live.bilibili.com/12345", "recordHandle": { "id": "rec_abc123", "stream": "flv", "source": "cn-gotcha01", "url": "https://...", "savePath": "/data/Bilibili/某主播/2026-02-15 20-00-00 直播标题.mp4" } } ] } } ``` ``` -------------------------------- ### Get Provider List Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Retrieves a list of all registered providers, including their authentication field declarations and browser login support information. ```http GET /api/providers ``` -------------------------------- ### Get Provider List Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Retrieves a list of all registered providers, including their authentication field declarations and browser login support information. ```APIDOC ## GET /api/providers ### Description Returns a list of all registered providers, including authentication field declarations and browser login support information. ### Method GET ### Endpoint /api/providers ### Response #### Success Response (200) - **payload** (array) - A list of provider objects. - **id** (string) - Unique identifier for the provider. - **name** (string) - Display name of the provider. - **siteURL** (string) - The platform's website URL. - **authFields** (array, optional) - Declarations for authentication fields (returned only for providers that support authentication). - **key** (string) - The key for the authentication field. - **label** (string) - The user-facing label for the authentication field. - **type** (string) - The input type for the field (e.g., "textarea"). - **required** (boolean) - Whether the field is required. - **placeholder** (string) - Placeholder text for the input field. - **description** (string) - Description of the authentication field. - **hasAuthFlow** (boolean, optional) - Indicates if browser-based authentication is supported (true if supported). ### Response Example ```json { "payload": [ { "id": "Bilibili", "name": "Bilibili", "siteURL": "https://live.bilibili.com/", "authFields": [ { "key": "cookie", "label": "Cookie", "type": "textarea", "required": false, "placeholder": "SESSDATA=xxx; bili_jct=xxx; DedeUserID=xxx; ...", "description": "从浏览器获取 B站登录 Cookie,用于获取原画等高画质直播流" } ], "hasAuthFlow": true }, { "id": "DouYu", "name": "DouYu", "siteURL": "https://www.douyu.com/" } ] } ``` ``` -------------------------------- ### Login via Browser Scan Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/cli.md Initiates a browser-based login flow for a provider, requiring Playwright. It opens a browser, navigates to the login page, and automatically extracts the cookie upon successful login. Ensure Playwright and its browser binaries are installed. ```bash pnpm add playwright npx playwright install chromium ``` ```bash lar auth login Bilibili ``` -------------------------------- ### ClientRecord Interface Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Represents a record object visible to the client, including its ID, associated recorder ID, save path, and timestamps for start and stop. ```APIDOC ## ClientRecord ### Description Client-visible record object. ### Interface Definition ```typescript interface ClientRecord { id: string // Record ID (consistent with RecordHandle.id) recorderId: string // Associated recorder ID savePath: string // Video file save path startTimestamp: number // Record start timestamp (milliseconds) stopTimestamp?: number // Record stop timestamp (milliseconds) stopReason?: string // Reason for stopping (e.g., 'manual stop') isFileExists?: boolean // Whether the video file exists (only returned by list interface) } ``` ``` -------------------------------- ### Get Single Recorder API Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Retrieve details for a specific recorder using its ID. Returns an error if the recorder does not exist. ```http GET /api/recorders/:id ``` -------------------------------- ### Develop Server and Web Components Source: https://github.com/whiteminds/liveautorecord/blob/master/README.md Commands for developing the server and web components, including auto-building dependencies. ```bash pnpm install pnpm dev:server pnpm dev:web ``` -------------------------------- ### Build Project Source: https://github.com/whiteminds/liveautorecord/blob/master/CLAUDE.md Performs a full project build using Turborepo for dependency management. Includes commands for Electron packaging and server production deployment. ```bash # 全量构建(Turborepo 自动拓扑排序 + 缓存) pnpm build # Electron 打包(输出 .exe / .dmg) pnpm app:build # 服务端生产部署 pnpm -F @autorecord/http-server build && pnpm -F @autorecord/http-server start pnpm -F @autorecord/web build # 通过 nginx 等提供静态文件 ``` -------------------------------- ### FFmpeg Recording Command Construction Source: https://github.com/whiteminds/liveautorecord/blob/master/CLAUDE.md Illustrates the construction of an FFmpeg recording command using fluent-ffmpeg, defaulting to fmp4 format with fragmented keyframes. ```javascript # 默认 fmp4 格式(`-movflags frag_keyframe`) ``` -------------------------------- ### Get Provider Authentication Status Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Checks the authentication status for a specific provider. ```APIDOC ## GET /api/providers/:id/auth ### Description Retrieves the authentication status for a specific provider. ### Method GET ### Endpoint /api/providers/:id/auth ### Parameters #### Path Parameters - **id** (string) - Required - The unique identifier of the Provider (e.g., `Bilibili`). ### Response #### Success Response (200) - **payload** (object) - **isAuthenticated** (boolean) - Indicates if the user is currently authenticated. - **description** (string, optional) - A description of the authenticated user (e.g., username). ### Response Example (Authenticated) ```json { "payload": { "isAuthenticated": true, "description": "用户名" } } ``` ### Response Example (Not Authenticated) ```json { "payload": { "isAuthenticated": false } } ``` ### Error Handling - Provider not found or does not support authentication: Returns 404. ``` -------------------------------- ### Get Recorder by ID Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Retrieves details for a specific recorder using its ID. ```APIDOC ## GET /api/recorders/:id ### Description Retrieves the details of a specific recorder. ### Method GET ### Endpoint /api/recorders/:id #### Path Parameters - **id** (string) - Required - The ID of the recorder ### Response #### Success Response (200) - **payload** (ClientRecorder) - The recorder object. #### Error Response - **Error('404')** - Thrown if the recorder does not exist. ``` -------------------------------- ### Electron 模式通信流程 Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/architecture.md 展示了 Electron 应用的 Main 进程启动 HTTP Server,Renderer 进程通过 HTTP 与之通信,并接收 SSE 事件流。 ```mermaid graph TD subgraph Electron 进程 A[Main 进程] B[Renderer 进程 (Web 前端)] end A -- startServer (:8085) --> B B -- Axios → localhost:8085 --> A B -- RxJS SSE 事件流 --> A A -- 系统托盘 --> C(系统托盘) A -- 单实例锁 --> D(单实例锁) E(ffmpeg-static) --> A ``` -------------------------------- ### CLI 模式通信流程 Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/architecture.md 展示了 CLI 如何直接导入 Manager 模块及其 Providers,并接收事件。此模式无 HTTP 层。 ```mermaid graph LR A[lar 命令行 commander consola] -- 直接导入 --> B(Manager + Providers + lowdb) B -- 事件 --> A ``` -------------------------------- ### Electron Integration Components Source: https://github.com/whiteminds/liveautorecord/blob/master/CLAUDE.md Highlights the integration of an embedded HTTP server, electron-vite build process, ffmpeg-static for FFmpeg binaries, and system tray support. ```plaintext - 内嵌 HTTP Server(localhost:8085) - electron-vite 三段构建:main、preload、renderer - ffmpeg-static 提供捆绑的 FFmpeg 二进制 - 系统托盘支持 ``` -------------------------------- ### Create Bilibili Recorder Instance Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/providers.md Creates a recorder instance by injecting the provider ID and delegating to an internal createRecorder function. This ensures the provider context is correctly set. ```typescript createRecorder(opts) { return createRecorder({ providerId: provider.id, ...opts }) } ``` -------------------------------- ### Configure pnpm Workspace Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/pnpm-migration-plan.md Create a pnpm-workspace.yaml file to define the root of your workspaces. This tells pnpm where to find your packages. ```yaml packages: - 'packages/*' ``` -------------------------------- ### Get Provider Authentication Status Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Checks the authentication status for a specific provider. Requires the provider's ID as a path parameter. ```http GET /api/providers/:id/auth ``` -------------------------------- ### Lerna Publish Alternative Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/pnpm-migration-plan.md Use 'changeset publish' or 'pnpm publish --filter' as alternatives to 'lerna publish'. ```bash pnpm publish --filter ``` -------------------------------- ### Create Recorder Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Adds a new recorder to the system. ```APIDOC ## POST /api/recorders ### Description Adds a new recorder to the system. ### Method POST ### Endpoint /api/recorders #### Request Body - **providerId** (string) - Required - Platform Provider ID (e.g., `Bilibili`, `DouYu`, `HuYa`, `DouYin`) - **channelId** (string) - Required - Channel ID (room number corresponding to the platform) - **remarks** (string) - Optional - Remarks information (e.g., streamer name) - **disableAutoCheck** (boolean) - Optional - Whether to disable automatic checking - **quality** (Quality) - Optional - Preferred recording quality - **streamPriorities** (string[]) - Optional - List of stream priorities - **sourcePriorities** (string[]) - Optional - List of source (CDN) priorities - **extra** (object) - Optional - Extra extension fields ### Request Example ```json { "providerId": "Bilibili", "channelId": "12345", "remarks": "某主播", "quality": "highest", "streamPriorities": [], "sourcePriorities": [] } ``` ### Response #### Success Response (200) - **payload** (ClientRecorder) - The newly created recorder, including an auto-assigned `id`. ``` -------------------------------- ### Add Dependency to package.json Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/providers.md Shows how to add a new recorder provider package as a dependency in the project's package.json file. ```json { "dependencies": { "@autorecord/my-platform-recorder": "workspace:^" } } ``` -------------------------------- ### CLI Architecture Components Source: https://github.com/whiteminds/liveautorecord/blob/master/CLAUDE.md Details the CLI framework (commander, consola, console-table-printer), shared dependencies, data directory, and global JSON output option. ```plaintext - 命令名 `lar`,基于 commander@14 + consola@3 + console-table-printer@2 - 直接导入 manager + 4 个 recorder provider,无需启动 HTTP Server - 与 http-server/electron 共享同一数据目录(`env-paths('live-auto-record')`),通过 `@autorecord/core` 共享 env/lowdb/类型定义/工具函数 - 所有命令支持 `--json` 全局开关,输出结构化 JSON(Agent 友好) - 11 个命令:`resolve`、`list`、`add`、`remove`、`status`、`start`、`stop`、`check`、`watch`、`config`、`records` - 详见 `docs/cli.md` ``` -------------------------------- ### Authentication Configuration Persistence Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/cli.md Demonstrates how authentication configurations are stored in manager.json, allowing them to persist across application restarts. ```json { "providerAuthConfigs": { "Bilibili": { "cookie": "SESSDATA=xxx; bili_jct=xxx; DedeUserID=xxx; ..." } } } ``` -------------------------------- ### Publish Changesets Source: https://github.com/whiteminds/liveautorecord/blob/master/CLAUDE.md Creates a changeset for publishing packages and checks the status of pending changes. ```bash pnpm changeset # 创建 changeset(交互式选择包和版本类型) pnpm changeset status # 查看待发布的变更 # version-packages 和 release 由 CI 自动执行,一般不需要手动运行 ``` -------------------------------- ### List Authentication Status Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/cli.md Lists the authentication status for all configured providers. Use --json for machine-readable output. ```bash lar auth list ``` ```bash lar auth list --json ``` -------------------------------- ### Persistence Authentication Test Plan Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/cli.md Tests the persistence of authentication configurations across application restarts by setting a cookie and then verifying its presence after restarting the application. ```bash # 1. 设置 Cookie node apps/cli/lib/bin.js auth set Bilibili --cookie "SESSDATA=xxx" # 2. 重新启动应用,验证鉴权仍然存在 node apps/cli/lib/bin.js auth list --json ``` -------------------------------- ### Data Persistence Configuration Source: https://github.com/whiteminds/liveautorecord/blob/master/CLAUDE.md Specifies the template for saving recorded files, including platform, owner, date, time, and title. ```plaintext {platform}/{owner}/{year}-{month}-{date} {hour}-{min}-{sec} {title}.mp4 ``` -------------------------------- ### Lerna Run Alternative Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/pnpm-migration-plan.md Use 'pnpm -r run' to execute scripts across all workspaces, similar to 'lerna run'. ```bash pnpm -r run ``` -------------------------------- ### Settings Interface Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Defines application-wide settings, including options for window behavior, notifications, debug mode, and localization. ```typescript interface Settings { notExitOnAllWindowsClosed: boolean // 关闭所有窗口时不退出(Electron) noticeOnRecordStart: boolean // 录制开始时发送通知 noticeFormat?: string // 通知消息格式模板 debugMode?: boolean // 调试模式 autoGenerateSRTOnRecordStop?: boolean // 录制停止后自动生成 SRT autoRemoveRecordWhenTinySize?: boolean // 自动删除空文件录制记录 locale?: string // 界面语言 sortMode?: string // 排序方式 } ``` -------------------------------- ### Manual Cookie Authentication Test Plan Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/cli.md A sequence of commands to test manual cookie authentication, including setting cookies, verifying status, recording with high quality, and clearing authentication. ```bash # 1. 设置 B站 Cookie node apps/cli/lib/bin.js auth set Bilibili --cookie "SESSDATA=xxx; bili_jct=xxx" # 2. 验证登录状态 node apps/cli/lib/bin.js auth list --json # 3. 录制高画质直播流(设置画质为 highest) node apps/cli/lib/bin.js add https://live.bilibili.com/12345 -q highest node apps/cli/lib/bin.js start 1 # 4. 清除鉴权 node apps/cli/lib/bin.js auth clear Bilibili node apps/cli/lib/bin.js auth list --json ``` -------------------------------- ### Clean Project Source: https://github.com/whiteminds/liveautorecord/blob/master/CLAUDE.md Cleans the project by removing node_modules and build artifacts. ```bash pnpm clean # 删除所有 node_modules、lib、dist、.turbo ``` -------------------------------- ### HTTP Server 模式通信流程 Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/architecture.md 展示了 Web 前端如何通过 Axios 和 RxJS 与 Express API 通信,并接收 SSE 事件流。Express API 再直接调用 Manager 模块。 ```mermaid graph LR A[Web 前端 (Vue 3)] -- HTTP REST /api/* --> B(Express API :8085) B -- 直接调用 --> C(Manager + Providers + lowdb) A -- SSE --> B B -- SSE 推送 /api/events --> A C -- 事件 --> B ``` -------------------------------- ### Settings Interface Source: https://github.com/whiteminds/liveautorecord/blob/master/docs/api.md Application settings object, controlling behavior like exiting on window close, notifications, debug mode, and automatic file removal. ```APIDOC ## Settings ### Description Application settings object. ### Interface Definition ```typescript interface Settings { notExitOnAllWindowsClosed: boolean // Do not exit when all windows are closed (Electron) noticeOnRecordStart: boolean // Send notification when recording starts noticeFormat?: string // Notification message format template debugMode?: boolean // Debug mode autoGenerateSRTOnRecordStop?: boolean // Automatically generate SRT after recording stops autoRemoveRecordWhenTinySize?: boolean // Automatically remove empty file records locale?: string // UI language sortMode?: string // Sort mode } ``` ``` -------------------------------- ### Web Frontend Architecture Components Source: https://github.com/whiteminds/liveautorecord/blob/master/CLAUDE.md Lists the key technologies and libraries used in the web frontend, including Vue 3, Pinia, Vue Router, Vuetify, Tailwind CSS, Axios, RxJS, vue-i18n, and DPlayer. ```plaintext - Vue 3 `