yera.providers.gemini_common

Common infrastructure for accessing Gemini services.

Symbols

def get_gemini_client — Build a Gemini client from a configured connection.

get_gemini_client

get_gemini_client(
    connection: GeminiConnection,
    secret_store: SecretStore | None = None,
) → genai.Client

Build a Gemini client from a configured connection.

Parameters

connection
type: GeminiConnection

Gemini connection containing an API-key reference.

secret_store
type: SecretStore | None = None

Optional store override for resolving a stored key.

Returns

type: genai.Client

Gemini client authenticated with the resolved API key.

Raises

ProviderCredentialError

If the referenced API key cannot be resolved.