Skip to content

feat: add custom AI Studio app URL configuration - #267

Merged
bbbugg merged 3 commits into
mainfrom
feat/custom-ai-studio-app-url
Sep 12, 2026
Merged

bbbugg merged 3 commits into
mainfrom
feat/custom-ai-studio-app-url

Conversation

@bbbugg

@bbbugg bbbugg commented Sep 12, 2026

Copy link
Copy Markdown
Member

This pull request introduces support for configuring a custom AI Studio App URL, allowing users to specify their own app instead of the built-in default. It adds environment variable and documentation support for this feature, validates the provided URL, and updates the startup log to display the active app URL. Additionally, new guides (in both English and Chinese) are included to help users create and configure their own AI Studio App.
此拉取请求引入了对配置自定义 AI Studio 应用 URL 的支持,允许用户指定自己的应用,而非使用内置的默认应用。该功能增加了对环境变量和文档的支持,验证了所提供的 URL,并更新了启动日志以显示当前生效的应用 URL。此外,还包含了新的指南(中英文版本),旨在帮助用户创建并配置其专属的 AI Studio 应用。

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The critical logging issue must be fixed, and the environment-file documentation should be clarified.

Get a fresh assessment by requesting another Copilot review.

Pull request overview

Adds configurable custom AI Studio App URLs with validation, fallback behavior, startup logging, and bilingual documentation.

Changes:

  • Adds AI_STUDIO_APP_URL configuration and validation.
  • Uses the configured URL in BrowserManager.
  • Updates environment examples, READMEs, and setup guides.
File summaries
File Summary
src/utils/ConfigLoader.js Critical (1 vote): rejected environment values may expose credentials or inject log lines; log only a generic or sanitized validation failure.
src/core/BrowserManager.js Uses the configured AI Studio App URL for navigation.
README.md Documents the custom URL configuration in Chinese.
README_EN.md Documents the custom URL configuration in English.
docs/zh/create-ai-studio-app.md Nit (1 vote): document both .env and .env.development for development usage and restart instructions.
docs/en/create-ai-studio-app.md Nit (1 vote): document both .env and .env.development for development usage and restart instructions.
.env.example Adds the AI_STUDIO_APP_URL example configuration.
Review details

Suppressed comments (2)

docs/en/create-ai-studio-app.md:65

  • This guide only tells users to write .env, but main.js loads .env.development for non-production runs (including the documented npm run dev path). Following this guide in development therefore leaves AI_STUDIO_APP_URL unset and silently uses the built-in app; document both environment files here and in the restart instruction.
Add the complete link to the `.env` file in the project root:

```env
AI_STUDIO_APP_URL=https://ai.studio/apps/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx

docs/zh/create-ai-studio-app.md:65

  • 本教程只要求写入 .env,但 main.js 在非生产环境(包括文档中的 npm run dev)会读取 .env.development。用户按此步骤在开发环境配置时,AI_STUDIO_APP_URL 会被忽略并静默使用内置应用;这里以及后面的重启说明应同时写明两个环境文件。
将完整链接写入项目根目录的 `.env`:

```env
AI_STUDIO_APP_URL=https://ai.studio/apps/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
  • Files reviewed: 7/12 changed files
  • Comments generated: 1
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread src/utils/ConfigLoader.js
Comment on lines +83 to +84
`[Config] Invalid AI_STUDIO_APP_URL "${process.env.AI_STUDIO_APP_URL}". ` +
`Expected https://ai.studio/apps/<app-id>; using the default app.`
@bbbugg
bbbugg merged commit aba6011 into main Sep 12, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Allow configuring the AI Studio Build App URL Make targetUrl configurable via environment variable

2 participants