GeminiConfig
Defined in: core/src/providers/gemini.ts:33
Standard options that any provider config can accept to configure fallbacks inline.
Extends
Section titled “Extends”Properties
Section titled “Properties”apiKey
Section titled “apiKey”apiKey: string;Defined in: core/src/providers/gemini.ts:34
baseUrl?
Section titled “baseUrl?”optional baseUrl?: string;Defined in: core/src/providers/gemini.ts:38
Any endpoint speaking the Generative Language REST dialect, including a proxy or gateway. Defaults to the Generative Language API.
bearer?
Section titled “bearer?”optional bearer?: boolean;Defined in: core/src/providers/gemini.ts:44
Send the credential as Authorization: Bearer instead of x-goog-api-key
(Antigravity OAuth).
effort?
Section titled “effort?”optional effort?: "none" | "low" | "medium" | "high" | "max";Defined in: core/src/providers/gemini.ts:54
Bound default; a per-call effort overrides it.
fallbackOptions?
Section titled “fallbackOptions?”optional fallbackOptions?: FallbackOptions<Provider>;Defined in: core/src/fallback.ts:94
Custom cooldown or telemetry options for the fallback pool.
Inherited from
Section titled “Inherited from”ProviderFallbackConfig.fallbackOptions
fallbacks?
Section titled “fallbacks?”optional fallbacks?: readonly FallbackCandidate[];Defined in: core/src/fallback.ts:88
Secondary and tertiary providers to try if this provider fails/exhausts:
hand-built Providers, preset-id FallbackSpecs, or both.
Inherited from
Section titled “Inherited from”ProviderFallbackConfig.fallbacks
fetchImpl?
Section titled “fetchImpl?”optional fetchImpl?: (input, init?) => Promise<Response>;Defined in: core/src/providers/gemini.ts:65
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
input |
RequestInfo | URL |
init? |
RequestInit |
Returns
Section titled “Returns”Promise<Response>
headers?
Section titled “headers?”optional headers?: Record<string, string>;Defined in: core/src/providers/gemini.ts:66
optional id?: string;Defined in: core/src/providers/gemini.ts:52
Names the provider in errors and logs.
instanceSessionId?
Section titled “instanceSessionId?”optional instanceSessionId?: string;Defined in: core/src/providers/gemini.ts:50
The id sessionHeader carries when a call has no sessionId.
jsonWithTools?
Section titled “jsonWithTools?”optional jsonWithTools?: JsonWithTools;Defined in: core/src/providers/gemini.ts:63
How the schema rides on a call that also carries tools. See
JsonWithTools. Note that it is the model’s answer, not the
endpoint’s: measured 2026-09-07, gemini-3.5-flash and
gemini-3.5-flash-lite called their tool under responseJsonSchema every
time, while gemini-3.8-flash managed 3/10. probeJsonWithTools asks the
one you actually serve. Overridable per call.
maxTokens?
Section titled “maxTokens?”optional maxTokens?: number;Defined in: core/src/providers/gemini.ts:64
model: string;Defined in: core/src/providers/gemini.ts:35
optional path?: string;Defined in: core/src/providers/gemini.ts:41
Explicit path override when a backend has custom routing (Antigravity:
/v1internal:streamGenerateContent?alt=sse).
projectId?
Section titled “projectId?”optional projectId?: string;Defined in: core/src/providers/gemini.ts:46
Google Antigravity (Cloud Code Assist) project id for the request envelope.
sessionHeader?
Section titled “sessionHeader?”optional sessionHeader?: string;Defined in: core/src/providers/gemini.ts:48
Header that carries StreamOptions.sessionId.
watchdog?
Section titled “watchdog?”optional watchdog?: WatchdogOptions;Defined in: core/src/fallback.ts:92
Watch every candidate separately. A silent candidate then times out and rotates; wrapping the completed pool would abort the whole chain instead. Fallback specs inherit this unless they set their own watchdog.