Summary: With BYOK enabled, `POST /api/v1/copilot/app/complete` consistently returns `HTTP 500 Internal Server Error`, regardless of provider or model. The non-BYOK path is healthy. The Anna team has confirmed this is a platform-side bug and a fix is in progress — posting here so the context and fix updates live in one thread (as Jiao suggested by email).
Environment:
- Account: qingyu_ge@foxmail.com (user_id 368)
- App slug: anna-truman-director
- BYOK providers registered (all show “verified” in Settings → LLM):
-
DeepSeek — official endpoint `api.deepseek.com/v1`
-
GLM — Coding Plan endpoint `open.bigmodel.cn/api/coding/paas/v4` (the standard `/api/paas/v4` has no balance for this key)
-
MiniMax — `api.minimaxi.com/v1`
- “Apps / plugins may use my API key” switch: ON
Reproduction (dev session, kind=complete):
1. `POST /api/v1/anna-apps/dev/session/mint` → **200 OK** (token carries quota caps: 4096 tok/call, 1000 calls/day)
2. `POST /api/v1/copilot/app/complete` with a minimal body (`Say OK`, max_tokens 32) → **HTTP 500 `Internal Server Error`** (plain text, no JSON detail)
Test matrix:
| Preferred model | Switch | Result |
|—|—|—|
| byok:glm/glm-5.3 (reasoning model) | ON | 500 |
| byok:minimax/MiniMax-M3 (reasoning model) | ON | 500 |
| byok:deepseek/deepseek-v4-flash (non-reasoning) | ON | 500 |
| Qwen3.7 Max (platform model) | OFF | normal 429 subscription JSON (code -32015) — non-BYOK path healthy |
Additional isolation:
- Each provider key tested directly against its own endpoint returns **200 OK** with correct completions — provider configs are clean
- Direct key test details: GLM coding endpoint returns proper completions incl. `reasoning_content`; provider “Test & Save” verification passes for all three
- Failure is isolated to the platform’s BYOK forwarding on app/complete, independent of provider and reasoning vs non-reasoning models
Impact: Blocks real-LLM end-to-end verification for apps whose developer quota is expired (the BYOK path is the recommended route for builders per the team).
Happy to add more details or re-test against a fix. Thanks!