Commit a3df0bd
fix: resolve base URL in createLanguageModel for API gateway support (#565)
createLanguageModel() resolved API keys from env vars but not base URLs.
This caused dedup LLM calls to bypass API gateways (GOOGLE_API_URL, etc.)
and hit provider endpoints directly, failing with "API key not valid"
when using gateway-issued keys.
Add resolveBaseUrl() mirroring the env-var resolution already used by
ProbeAgent and FallbackManager, and pass it to createProviderInstance().
Fixes #564
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>1 parent 124a819 commit a3df0bd
1 file changed
Lines changed: 26 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
84 | 84 | | |
85 | 85 | | |
86 | 86 | | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
87 | 110 | | |
88 | 111 | | |
89 | | - | |
| 112 | + | |
90 | 113 | | |
91 | 114 | | |
92 | 115 | | |
| |||
98 | 121 | | |
99 | 122 | | |
100 | 123 | | |
101 | | - | |
| 124 | + | |
| 125 | + | |
102 | 126 | | |
103 | 127 | | |
104 | 128 | | |
| |||
0 commit comments