Skip to content

Commit c10600e

Browse files
authored
Pass baseURL to Gemini API if googleGeminiBaseUrl is set (#2776)
1 parent b8b9073 commit c10600e

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

.changeset/stale-bikes-jam.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"roo-cline": patch
3+
---
4+
5+
Allow custom URLs for Gemini provider

src/api/providers/gemini.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,9 @@ export class GeminiHandler extends BaseProvider implements SingleCompletionHandl
3030
model,
3131
contents: messages.map(convertAnthropicMessageToGemini),
3232
config: {
33+
httpOptions: this.options.googleGeminiBaseUrl
34+
? { baseUrl: this.options.googleGeminiBaseUrl }
35+
: undefined,
3336
thinkingConfig,
3437
maxOutputTokens,
3538
temperature: this.options.modelTemperature ?? 0,

0 commit comments

Comments
 (0)