Skip to content

Commit bbcf56a

Browse files
committed
feat: add vertex API key support and refactor provider handlers
- Add vertexApiKey field to ProviderSettings for simplified authentication - Refactor VertexHandler to be fully independent from GeminiHandler - Remove inheritance dependency and vertex-specific logic from GeminiHandler - Implement standalone VertexHandler with vertex-only authentication methods - Add comprehensive debug logging for model selection and API flow - Update vertex provider UI to include API key input field - Add i18n support for vertex API key label and placeholder - Fix vertex tests to use correct default model (claude-sonnet-4@20250514) - Ensure proper model selection and fallback logic for both providers Breaking changes: - VertexHandler no longer inherits from GeminiHandler - Each provider now has completely separate model sets and authentication Closes: #TBD
1 parent 62a09a2 commit bbcf56a

File tree

10 files changed

+1077
-211
lines changed

10 files changed

+1077
-211
lines changed

packages/types/src/provider-settings.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,7 @@ const bedrockSchema = apiModelIdProviderModelSchema.extend({
106106
})
107107

108108
const vertexSchema = apiModelIdProviderModelSchema.extend({
109+
vertexApiKey: z.string().optional(),
109110
vertexKeyFile: z.string().optional(),
110111
vertexJsonCredentials: z.string().optional(),
111112
vertexProjectId: z.string().optional(),
@@ -290,6 +291,7 @@ export const PROVIDER_SETTINGS_KEYS = keysOf<ProviderSettings>()([
290291
"awsBedrockEndpointEnabled",
291292
"awsBedrockEndpoint",
292293
// Google Vertex
294+
"vertexApiKey",
293295
"vertexKeyFile",
294296
"vertexJsonCredentials",
295297
"vertexProjectId",

packages/types/src/providers/vertex.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -233,4 +233,5 @@ export const VERTEX_REGIONS = [
233233
{ value: "europe-west1", label: "europe-west1" },
234234
{ value: "europe-west4", label: "europe-west4" },
235235
{ value: "asia-southeast1", label: "asia-southeast1" },
236+
{ value: "global", label: "global" },
236237
]

0 commit comments

Comments
 (0)