Skip to main content

Google Gemini

Connect the Google Gemini API to let agents send completions to Gemini models and generate embeddings through the vault.

Prerequisites

Getting Your API Key

  1. Go to aistudio.google.com/apikey
  2. Click Create API key
  3. Select or create a Google Cloud project
  4. Copy the key (starts with AIza...)

Connecting

  1. Go to Connections in the dashboard
  2. Select the LLM Access tab
  3. Click Connect Google Gemini
  4. Paste your API key
  5. Click Connect
Singleton

Gemini is a singleton service -- only one connection per workspace. Agents use service: "gemini" instead of a connection ID.

Vault API Usage

vault_execute({
service: "gemini",
method: "POST",
url: "https://generativelanguage.googleapis.com/v1beta/models/gemini-2.0-flash:generateContent",
body: {
contents: [{ parts: [{ text: "Hello!" }] }]
}
})

The vault automatically adds the x-goog-api-key header.

Available Endpoints

MethodURL PathDescription
POST/v1beta/models/{model}:generateContentGenerate content
POST/v1beta/models/{model}:embedContentGenerate embeddings
GET/v1beta/modelsList available models