provider 키 해석: anthropic/openai도 vault: 참조를 풀도록(google과 동일)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
3c1018f33f
commit
617ae12d57
1 file changed
+3
-2
@@ -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);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user