From 617ae12d57309ac62234f09112054f63677eca67 Mon Sep 17 00:00:00 2001 From: kim Date: Sat, 17 Oct 2026 20:45:41 +0900 Subject: [PATCH] =?UTF-8?q?provider=20=ED=82=A4=20=ED=95=B4=EC=84=9D:=20an?= =?UTF-8?q?thropic/openai=EB=8F=84=20vault:=20=EC=B0=B8=EC=A1=B0=EB=A5=BC?= =?UTF-8?q?=20=ED=92=80=EB=8F=84=EB=A1=9D(google=EA=B3=BC=20=EB=8F=99?= =?UTF-8?q?=EC=9D=BC)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Sonnet 5.5 --- src/providers/factory.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/providers/factory.ts b/src/providers/factory.ts index 5b13cc6..b1a7107 100644 --- a/src/providers/factory.ts +++ b/src/providers/factory.ts @@ -178,7 +178,7 @@ function buildProvider(id: ProviderID, providers: any): LLMProvider { case 'openai': { const cfg = providers.openai || {}; - const apiKey = resolveEnvKey(cfg.api_key); + const apiKey = resolveEnvKey(getConfig().resolveSecret(cfg.api_key)); // vault: 참조도 풀어야 한다(google과 동일) if (!apiKey) throw new Error('OpenAI API key not configured. Add it in Settings -> Models.'); return new OpenAICompatAdapter({ endpoint: 'https://api.openai.com', @@ -209,7 +209,8 @@ function buildProvider(id: ProviderID, providers: any): LLMProvider { case 'anthropic': { const cfg = providers.anthropic || {}; - const apiKey = resolveEnvKey(cfg.api_key); + // vault:anthropic.api_key 같은 참조는 resolveEnvKey만으로는 풀리지 않아 키가 있어도 "not configured"가 됐다(2026-10-17) + const apiKey = resolveEnvKey(getConfig().resolveSecret(cfg.api_key)); if (!apiKey) throw new Error('Anthropic API key not configured. Add it in Settings -> Models.'); return new AnthropicAdapter(apiKey, cfg.endpoint); }