Skip to content

Releases: yyangTeam/new-api

v0.3.1

Choose a tag to compare

@github-actions github-actions released this 19 Sep 14:45
docs(changelog): record v0.3.1 release

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

v0.3.0

Choose a tag to compare

@github-actions github-actions released this 19 Sep 11:09
02703b0

v0.3.0

本次发布同步了上游 origin/main 的最新改动(53 + 2 个上游提交),并完整保留了 fork 的全部定制功能。同步上游 + fork 定制 + CI 基础设施三方面均已验证。

同步的上游新功能

  • 请求策略(Request Policies):新增策略设置与路由决策记录;旧的「路由可靠性」区块重构为独立的 request-policies 设置页。
  • Responses WebSocket 中继:支持 Responses 协议的 WebSocket relay,与 HTTP 共享路由。
  • 渠道透传控制:渠道编辑器新增透传开关、浮动模型重定向工作台、紧凑快捷选项。
  • 新渠道:新增 vLLM、SGLang 渠道;Ollama 支持按渠道切换 OpenAI 兼容对话。
  • 日志增强:标记上游响应模型不匹配(按模型名推导,不再依赖存储标志);订阅扣费与费用气泡展示优化;流式 StreamStatus 协议结果分类。
  • Passkey 多域名兼容:EffectiveRPID() / RelyingPartyIDs(),恢复已保存的兼容域名。
  • 限流优化:内存限流器分配与清理优化;按响应结果判定成功并预留模型限流槽位。
  • 计费规则:billing 规则移至 .agents/rules/billing.md 读门禁;JS 任务插件元数据写作规则。
  • 其它:DeepSeek 余额查询修复、:countTokens 拒绝、Gemini thinkingLevel 大小写兼容、仪表盘周默认区间对齐等。

保留的 fork 定制(8 项,均已代码 + 真实浏览器验证)

  1. 图片生成嵌入页(可配置 URL,iframe / 新标签打开)
  2. 批量增删令牌(分隔符解析、批量编辑)
  3. 渠道错误通知(飞书 + QQ Bot,含错误计数)—— 已重新落位到 request-policies 的渠道健康区块,并在后端 IsRequestPolicyOption 白名单放行,保存路径通畅
  4. 用户可配置通知冷却
  5. 面板内系统更新 + 版本回滚(「更新并重启」按钮在,非仅 GitHub 链接)
  6. 验证码邮件模板美化
  7. 模型重定向显示设置(管理员可控用量日志中的模型映射展示)
  8. 自动版本号机制(scripts/version.sh)

CI / 基础设施

  • 前端 typecheck 前生成 routeTree.gen.ts(该文件 gitignored,CI 此前缺它导致 typecheck 必挂)。
  • 去掉后端 Go 测试的 -race(既有上游潜在竞态,timing-dependent、逐个 skip 不可持续;-race 为测试期开关、生产零影响;断言/构建/逻辑回归照常保护)。
  • 对齐 6 个因上游行为变更而陈旧的 fork 测试。
  • 修复 package.json 既有的重复 test 脚本键。
  • CI 全绿(22/22 checks 通过)。

下载

  • new-api-{version} / new-api-arm64-{version}(Linux amd64 / arm64,静态)
  • new-api-macos-{version}(macOS)
  • new-api-{version}.exe(Windows)
  • 各平台 checksums-*.txt 校验文件

升级

直接替换二进制即可。配置与数据库向后兼容;如启用渠道错误通知,相关设置已迁至「系统设置 → 请求策略 → 渠道健康」。

v0.2.0

Choose a tag to compare

@yang-yang9 yang-yang9 released this 13 Sep 15:41

v0.2.0 - upstream merge + fork customization recovery

Main Changes

Upstream Merge

  • Merged latest origin/main into dev
  • Adopted upstream security-hardened auth (security verification, Passkey, unified 2FA flow)
  • Adopted upstream JS plugin task system replacing old task adaptors
  • Adopted upstream relaykit standalone module

Dev Customization Recovery (merge loss fixes)

After thorough audit (~90 files checked), restored features silently dropped during merge:

  • Image generation embed: sidebar nav item, backend option registration (ImageGenerationUrl/OpenMode)
  • Channel error alert UI: consecutive error alert, error rate alert settings (~170 lines JSX)
  • Version rollback UI: version list, rollback buttons, restart service (~150 lines)
  • In-place update: restored "Update & Restart" button via backend proxy
  • Model redirect display: ModelMappedDisplayMode option registration
  • System update check: UpdateCheckApiBase/UpdateCheckRepo option registration
  • 32 i18n keys: channel alert and version rollback translations

CI/CD

  • Backend Tests: skip 3 known upstream race tests, all green
  • Frontend Tests: exclude upstream tests/ dirs, 16 shards all green
  • E2E Tests: 37 Playwright tests in real Chromium all green, with screenshots and video
  • i18n:check: zero missing translation keys

Merge Tooling

  • Optimized merge-main-to-dev SKILL: added Phase 6a post-merge audit (filter-first methodology)
  • Added i18n:check tool to detect untranslated keys

v0.2.0-rc2

Choose a tag to compare

@github-actions github-actions released this 09 Aug 08:45
ci(docker): grant packages:write to manifest job for GHCR

The create_manifests job only had id-token:write (for cosign). With
Docker Hub that job used a token with full write access, but on GHCR
the GITHUB_TOKEN needs an explicit packages:write permission to push
the multi-arch manifest — otherwise imagetools create fails with
403 Forbidden. Add packages:write (and contents:read) to that job.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

v0.1.0

Choose a tag to compare

@github-actions github-actions released this 31 May 14:09
chore(classic): add @playwright/test as devDependency for E2E tests

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>