github-actions[bot]
16713d9a67
chore: sync VERSION file with release v1.1.293 [skip ci]
v1.1.293
2026-03-14 04:05:08 +00:00
shaw
48c14f4e1b
fix: 移除1m模型限制和配套的apikey功能
2026-03-14 12:04:45 +08:00
github-actions[bot]
5c0a1fc276
chore: sync VERSION file with release v1.1.292 [skip ci]
v1.1.292
2026-03-10 01:56:40 +00:00
shaw
666ec2c368
feat: add gpt-5.3-codex-spark, gpt-5.4, gpt-5.4-pro model definitions
2026-03-10 09:56:02 +08:00
shaw
cc5e1db259
feat: support service_tier priority pricing for OpenAI Responses endpoint
...
Preserve service_tier from request body before field stripping and pass
it through the cost calculation chain. When service_tier is "priority"
and the model has supports_service_tier in pricing data, use *_priority
price fields with automatic fallback to standard pricing.
2026-03-10 09:55:32 +08:00
github-actions[bot]
3dfb8fa83e
chore: sync VERSION file with release v1.1.291 [skip ci]
v1.1.291
2026-03-05 07:29:56 +00:00
Wesley Liddick
e60ab15395
Merge pull request #1054 from michaelx1993/fix/team-account-type-detection
...
fix: team accounts misidentified as free, blocking Opus model access
2026-03-05 15:29:41 +08:00
bill
78649cad3b
Revert "chore: change default service port from 3000 to 3001"
...
This reverts commit 0cf4eac0be .
2026-03-04 21:21:33 -08:00
a
0cf4eac0be
chore: change default service port from 3000 to 3001
...
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com >
2026-03-03 20:18:19 -08:00
a
82dc9f23ef
fix: team accounts misidentified as free, blocking Opus model access
...
The account type fallthrough defaulted to 'free' when neither has_claude_max
nor has_claude_pro was true, causing team accounts to be filtered out for
Opus requests. Changed default to 'claude_max' so unrecognized subscription
types are not incorrectly restricted.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com >
2026-03-03 20:10:53 -08:00
github-actions[bot]
7963628754
chore: sync VERSION file with release v1.1.290 [skip ci]
v1.1.290
2026-03-04 01:01:08 +00:00
Wesley Liddick
6c8698f6f9
Merge pull request #1049 from PatchouliTC/fix/allow1mContext-edit-not-save
...
fix: allow1mContext parameter not saved and not add to validated in API key service
2026-03-04 09:00:50 +08:00
PatchouliTC
19e879062e
fix:validateApiKey allow1mContext param
2026-03-03 17:05:19 +08:00
PatchouliTC
aea75b3d8b
fix not save bug:Add 'allow1mContext' to API key service parameters
2026-03-03 16:33:00 +08:00
github-actions[bot]
5fd7bff5a0
chore: sync VERSION file with release v1.1.289 [skip ci]
v1.1.289
2026-03-03 06:34:17 +00:00
shaw
ca02246592
fix: 修复api-stats页面测试返回E015的问题
2026-03-03 14:33:55 +08:00
github-actions[bot]
e5d47edff6
chore: sync VERSION file with release v1.1.288 [skip ci]
v1.1.288
2026-03-03 06:14:25 +00:00
shaw
f0b21fdcc4
fix: 阻止客户端 accept-encoding: zstd 透传到上游导致 JSON 解析失败
...
客户端(Claude Code CLI)发送的 accept-encoding 含 zstd,被透传到上游后
返回 zstd 压缩响应,Node.js 18 无法解压导致 "Failed to parse JSON"。
- headerFilter: 从 filterForClaude 白名单移除 accept-encoding
- claudeCodeHeadersService: 从捕获列表移除 accept-encoding
- claudeRelayService: spread 后强制覆盖 accept-encoding 为 identity,
防御 Redis 旧缓存残留覆盖
2026-03-03 14:12:34 +08:00
shaw
b0842ca927
fix: 修复Extra usage 429标记账号限流的问题
2026-03-03 13:50:47 +08:00
shaw
99dd19b32d
fix: 修复1h缓存定价与sub2api项目对齐
2026-03-03 11:08:13 +08:00
Wesley Liddick
d7b4a54a4c
Merge pull request #1047 from X-Zero-L/fix/claude-account-routing-state-20260302 [skip ci]
...
fix: surface full account routing-block reasons and configurable temp TTL
2026-03-03 08:23:34 +08:00
X-Zero-L
614daec032
style: apply prettier formatting for config example
2026-03-02 22:33:51 +08:00
X-Zero-L
cdaf55bb14
docs: clarify temp-unavailable TTL defaults and account overrides
2026-03-02 22:23:58 +08:00
X-Zero-L
87cbd1897d
refactor: extract temp-unavailable policy and reusable account UI
2026-03-02 22:17:00 +08:00
X-Zero-L
e611f97dae
fix: expose cooldown details and make 503 backoff configurable
2026-03-02 21:53:18 +08:00
X-Zero-L
96706c27f6
fix: surface account routing-block reasons and harden claude reset-state
2026-03-02 21:43:16 +08:00
Wesley Liddick
b38a92106c
Merge pull request #1046 from yptse123/feat/per-key-1m-context-control [skip ci]
...
feat: 按 API Key 控制 1M 上下文窗口访问权限
2026-03-02 20:43:52 +08:00
Wesley Liddick
4f0487981e
Merge pull request #1042 from learnerLj/fix/claude-console-test-model [skip ci]
...
fix: respect selected model in claude-console connectivity test
2026-03-02 20:28:20 +08:00
yptse123
b2e4187ea3
fix: 移除 1M 上下文的账户类型限制,信任 admin 的 allow1mContext 授权
...
部分 Claude 订阅类型(Pro/Team/Enterprise)原生支持 1M 上下文,
之前的实现仅允许 Bedrock 账户类型通过,过于保守。
现在当 admin 为 API Key 启用 allow1mContext 后,任何账户类型
(claude-official、claude-console、bedrock)均可使用 1M 上下文。
2026-03-02 17:12:44 +08:00
yptse123
5d3456911b
feat: 支持按 API Key 控制 1M 上下文窗口访问
...
改进 PR #1016 的全局拦截逻辑,将 1M 上下文窗口(context-1m)的拦截
从全局一刀切改为按 API Key 精细控制。
新增 `allow1mContext` 布尔字段,默认 false(向后兼容)。管理员可在
创建/编辑 API Key 时为需要的用户单独开启 1M 上下文窗口权限。
双层保护机制:
- 第一层:API Key 未启用 allow1mContext 时直接返回 403
- 第二层:已启用但调度到的账户类型不支持 1M(非 Bedrock)时返回 403
修改文件:
- src/models/redis.js: 新增 allow1mContext 布尔字段解析
- src/services/apiKeyService.js: 创建 Key 时支持 allow1mContext 参数
- src/middleware/auth.js: 将 allow1mContext 附加到 req.apiKey
- src/routes/admin/apiKeys.js: 创建/批量创建/更新/批量更新接口支持
- src/routes/api.js: 替换全局拦截为按 Key + 账户类型双层检查
- CreateApiKeyModal.vue: 新增"允许 1M 上下文"复选框
- EditApiKeyModal.vue: 新增复选框,支持从已有数据加载
- BatchEditApiKeyModal.vue: 新增三态单选(启用/禁用/不修改)
2026-03-02 17:08:17 +08:00
Wesley Liddick
bdbe728e9a
Merge pull request #1041 from X-Zero-L/feat/codex-api-configurable-endpoint [skip ci]
...
feat: configurable provider endpoint for codex-api accounts
2026-03-02 16:23:55 +08:00
Jiahao Luo
c31b4f4504
test: fix eslint arrow-body-style in claude-console account tests
2026-03-02 16:10:34 +08:00
Jiahao Luo
b78cd35f8b
style: format claude-console relay changes
2026-03-02 15:35:56 +08:00
Jiahao Luo
1813d6f6f6
feat: add claude sonnet 4.6 model option for tests
2026-03-02 15:34:56 +08:00
Jiahao Luo
b8c38adf70
fix: align claude-console test auth with relay logic
2026-03-02 15:34:56 +08:00
Jiahao Luo
f77a76ce1d
test: make claude-console relay test portable
2026-03-02 15:34:56 +08:00
Jiahao Luo
adf2dd61e0
fix: use selected model in claude-console connectivity test payload
2026-03-02 15:34:56 +08:00
Jiahao Luo
75515f92e6
test: cover claude-console test route model pass-through
2026-03-02 15:34:56 +08:00
Jiahao Luo
2263977cef
fix: require model for claude-console account test endpoint
2026-03-02 15:34:56 +08:00
Zero
90209455ac
Merge branch 'Wei-Shaw:main' into feat/codex-api-configurable-endpoint
2026-03-02 14:57:42 +08:00
X-Zero-L
8fed791702
fix: use template literal to satisfy ESLint prefer-template rule
...
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com >
2026-03-02 14:52:16 +08:00
github-actions[bot]
bf0f365cff
chore: sync VERSION file with release v1.1.287 [skip ci]
v1.1.287
2026-03-02 06:29:01 +00:00
Wesley Liddick
7832571e8f
Merge pull request #1039 from atian8179/fix/sse-stream-gzip-corruption
...
fix: prevent SSE stream corruption by requesting identity encoding
2026-03-02 14:28:49 +08:00
X-Zero-L
8c332086ba
fix: harden provider endpoint - remove broken completions mode, add validation
...
- Remove `completions` option (path-only change without body conversion causes 400)
- Add server-side enum validation for providerEndpoint in create/update
- Use exact path matching instead of broad `.includes()` in relay service
- Fix test endpoint to respect providerEndpoint config and /v1 dedup
- Improve /v1 dedup with null-safe baseApi access
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com >
2026-03-01 20:33:26 +08:00
X-Zero-L
0831739f4b
feat: add configurable provider endpoint for codex-api accounts
...
Add providerEndpoint field (responses/completions/auto) to openai-responses
accounts, allowing admins to specify which API endpoint format the provider
supports. The relay service normalizes request paths based on this config:
- responses (default): routes all requests to /v1/responses
- completions: routes all requests to /v1/chat/completions
- auto: preserves the original request path
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com >
2026-03-01 19:48:17 +08:00
atian8179
4d5ea4e0bc
fix: prevent SSE stream corruption by requesting identity encoding
...
Add 'accept-encoding: identity' to upstream request headers to prevent
Cloudflare/Anthropic CDN from returning gzip-compressed SSE responses.
When the upstream returns gzip data without a Content-Encoding header
(observed with some CDN edge configurations), the stream handler's
chunk.toString() call decodes raw gzip bytes as UTF-8, replacing any
byte >= 0x80 that isn't valid UTF-8 with U+FFFD (ef bf bd). This
silently corrupts the entire SSE stream.
Explicitly requesting identity encoding is the simplest and most
reliable fix — it prevents compression at the source rather than
trying to detect and decompress it after the fact.
Closes #1030
2026-03-01 15:19:38 +08:00
github-actions[bot]
0871101f27
chore: sync VERSION file with release v1.1.286 [skip ci]
v1.1.286
2026-02-27 05:43:33 +00:00
shaw
02f3e3335c
chore: remove files
2026-02-27 13:43:12 +08:00
github-actions[bot]
ef4de775f0
chore: sync VERSION file with release v1.1.285 [skip ci]
v1.1.285
2026-02-27 03:43:23 +00:00
Wesley Liddick
f603510240
Merge pull request #1028 from nanobanana123/fix/stream-gzip-decompression
...
fix: 解压 streaming 响应的 gzip 压缩,修复 SSE 数据损坏
2026-02-27 11:43:09 +08:00