fix(kimi-coding): set anthropic_messages api_mode for /coding endpoint

This commit is contained in:
王强 2026-04-18 17:23:12 +08:00 committed by Teknium
parent bad5471409
commit 46d680125e

View file

@ -1322,6 +1322,9 @@ def _resolve_delegation_credentials(cfg: dict, parent_agent) -> dict:
elif base_url_hostname(configured_base_url) == "api.anthropic.com":
provider = "anthropic"
api_mode = "anthropic_messages"
elif "api.kimi.com/coding" in base_lower:
provider = "custom"
api_mode = "anthropic_messages"
return {
"model": configured_model,