Skip to content

Releases: muyouzhi6/flow2api-host-agent

Flow2API Host Agent v0.2.8

22 Mar 04:48

Choose a tag to compare

本次更新

  • 修复异常认证页场景下的假成功/假失败:当 Host Agent 通过插件同款的临时 Flow 页面恢复拿到新的 session-token 时,不再因为当前页面落在 accountchooser/signin 而提前拒绝同步。
  • aggressive 预热改为更接近浏览器插件的行为:打开临时 https://labs.google/fx/vi/tools/flow 页面、等待加载和 settle,再关闭页面后读取最新 cookie。
  • 修复去重误判:如果 ST 指纹没变,但 Flow2API 侧写入状态不匹配或 AT 已过期,Host Agent 会继续尝试修复,而不是直接把这次刷新记成成功。
  • 增强本地写后校验:支持按 emailst 回查 Flow2API 数据库,并显式判断 at_expires 是否仍然有效。
  • 新增状态提示:当 session-token 已同步成功,但下游 AT 仍然过期时,会明确给出 warning,避免把 Host Agent 同步问题和 Flow2API 后端 AT 刷新问题混在一起。

验证

  • 已在真实部署环境执行 run-once 验证。
  • 返回结果包含 success=trueupdate_status=200write_verification.verified=true
  • 验证通过后,Flow2API 库内 ST 指纹已更新到最新值。

Flow2API Host Agent v0.2.7

21 Mar 06:08

Choose a tag to compare

What's Changed

  • add one controlled aggressive recovery attempt when the browser is stuck on Google auth redirect pages
  • keep recovery intent visible in state reporting so the dashboard reflects what the daemon actually tried
  • improve the login page for mobile/public access with direct noVNC open actions
  • remove legacy watchdog units during install to stop useless failed timer noise

Upgrade Notes

  • if the browser is already stuck on accountchooser or sessionexpired, this release will try one safe recovery pass first
  • if Google still keeps the browser on an abnormal auth page after that recovery pass, you still need to log in manually once to restore the session

Flow2API Host Agent v0.2.6

10 Mar 13:58

Choose a tag to compare

  • Improve long-run cookie sync stability
    • Prefer soft prewarm (avoid forced navigation that can bump the login session)
    • Smarter ST cookie selection when multiple session cookies exist
    • Guardrail: refuse to overwrite Flow2API token when browser is on abnormal auth/chooser pages
    • Dedup: skip update when ST fingerprint unchanged (reduce churn) while keeping heartbeat fresh
    • Rate-limit aggressive prewarm when ST is missing

v0.2.5

09 Mar 05:41

Choose a tag to compare

更新内容

  • Web UI 新增 GitHub Release 检查更新
  • 支持 一键更新到最新 release
  • 更新前自动备份当前项目目录
  • 更新失败自动回滚
  • 更新后自动重启 UI / daemon,并执行本地探活校验
  • 配置页新增 GitHub 仓库 配置项
  • README 补充更新机制与长期运行建议

适用场景

适合长期无人托管运行的 Host Agent 场景:

  • 面板内直接查看当前版本 / 最新 release
  • 发现新版本后可在 38110 面板内直接升级
  • 升级异常时自动回滚,降低维护风险

Flow2API Host Agent v0.2.4

09 Mar 03:59

Choose a tag to compare

稳定性改进

  • Chromium 改为普通服务用户运行,降低 Google 登录风控敏感度
  • 移除 --no-sandbox,避免登录页出现 unsupported command line flag 警告
  • browser service 改为独立 systemd 持续托管,不再是 oneshot 放飞子进程
  • 登录页“重新启动浏览器”按钮统一改为重启 browser service,避免状态不一致
  • 保留并验证 token 自动刷新链路:run-once 成功、update-token 成功、写库校验成功

验证

  • 确认运行中的 Chromium 不再带 --no-sandbox
  • GET /login 返回 200
  • POST /action/launch-browser 返回 303 且 browser service 确实重启
  • run-once 成功,update_api_success=truewrite_verification.verified=true

包含提交

  • $(git rev-parse --short HEAD) feat(stability): run Chromium as non-root with sandbox-friendly services

Flow2API Host Agent v0.2.3

09 Mar 02:44

Choose a tag to compare

修复

  • 修复 /login 页面 500:为模板补充 health 上下文,解决 health is undefined
  • 补充 python-multipart 依赖,避免首次安装后 FastAPI 表单功能不可用

验证

  • 本机测试 GET /login 返回 200
  • 页面可正常渲染

包含提交

  • 3f1abb7 fix(web): pass health to login template and add multipart dep

Flow2API Host Agent v0.2.2

08 Mar 06:17

Choose a tag to compare

变更说明

这次版本重点是把 Host Agent 从“能跑”提升到“更适合长期无人值守运行”。

核心增强

  • 软预热优先:默认优先复用浏览器现有登录态,避免频繁触发 Google 重新登录
  • 激进兜底:只有拿不到 __Secure-next-auth.session-token 时,才主动打开/刷新 Flow 页面
  • 写后强校验:不再只看 /api/plugin/update-token 返回 200,而是回读 Flow2API 数据库确认写入成功
  • ST 指纹比对:对比当前 ST 与库内 ST,避免“假成功”
  • 异常页面告警:对 signin / callback error / account chooser 等页面显式标记 warning
  • 自动重试:失败自动重试一次,降低偶发波动影响

Web UI 增强

  • 仪表盘新增写后校验、AT 过期时间、页面状态、重试次数、指纹比对等关键信息
  • 保留下次刷新时间与倒计时展示
  • 配置页保存后自动重启 daemon
  • 增强健康检查与运行时一致性

运维增强

  • 每日低峰自愈重启 timer(self-heal)
  • 更适合长期运行的 README 与使用说明

适合谁升级

  • 已部署 Flow2API,并希望在 Linux 宿主机长期自动维护 Google Labs / Flow 登录态的用户

v0.2.1

08 Mar 02:28

Choose a tag to compare

Flow2API Host Agent v0.2.1

This release improves day-to-day usability for the Host Agent dashboard and fixes a real-world config pitfall.

Highlights

  • Saving settings now automatically restarts the daemon so new refresh intervals take effect immediately
  • Dashboard now shows the next scheduled refresh time and a live countdown
  • Refresh timestamps are now displayed in UTC+8 for easier day-to-day use

What's changed

UX improvements

  • Added Next Auto Refresh to the dashboard
  • Added a live countdown timer so users can see when the next automatic sync will happen
  • Changed displayed refresh times to UTC+8 instead of raw server-time ambiguity

Config behavior fix

  • Saving settings from the Web UI now automatically runs:
    • systemctl restart flow2api-host-agent.service
  • This fixes the previous issue where the UI showed a new interval value but the daemon was still running with the old interval until manually restarted

Why this release

Users could be confused when:

  • the dashboard appeared to use a different timezone than expected
  • changing refresh interval in the UI did not immediately affect the running daemon
  • it was unclear when the next automatic refresh would occur

This release resolves those pain points directly.

v0.2.0

07 Mar 15:47

Choose a tag to compare

Flow2API Host Agent v0.2.0

This release focuses on hardening the project for real-world deployment and reducing common setup mistakes.

Highlights

  • Unified runtime handling across Web UI, daemon, and one-shot commands
  • Added /api/health for layered diagnostics
  • Prevented common misconfiguration of Connection Token
  • Improved installer to use project-local virtualenv (.venv)
  • Expanded README with troubleshooting and deployment guidance

What's changed

Runtime hardening

  • Web UI now uses the project virtualenv instead of relying on system python3
  • Reduced false-negative status reporting such as "Chrome not running" when the daemon is actually healthy

Better diagnostics

  • Added health command in scripts/agent.py
  • Added health_report() in scripts/core.py
  • Added GET /api/health in the Web UI
  • Dashboard now shows layered health info instead of a single vague status

Safer configuration UX

  • Improved Connection Token guidance in the settings page
  • Added validation to block URL-shaped values from being saved as token strings
  • Improved login page hints for token / noVNC related pitfalls

Installer improvements

  • install-systemd.sh now creates and uses a local .venv
  • systemd services now use pinned virtualenv Python / uvicorn paths
  • Improved log path conventions and post-install guidance

Documentation

  • README refreshed with production-oriented guidance
  • Added API / health check usage
  • Added troubleshooting for common deployment errors

Upgrade notes

If you already deployed an older version:

  1. Pull the latest code
  2. Re-run bash install-systemd.sh
  3. Restart services:
    • systemctl restart flow2api-host-agent-ui
    • systemctl restart flow2api-host-agent
  4. Verify health:
    • curl http://127.0.0.1:38110/api/health

Previous release

  • v0.1.0

v0.1.0

06 Mar 08:49

Choose a tag to compare

Initial public release of Flow2API Host Agent.

Includes:

  • Linux host-side token auto-refresh daemon
  • Web UI with dashboard / login guide / settings / help
  • noVNC-based login flow
  • systemd services and optional daily maintenance timer
  • README and example config for standalone deployment