Skip to content

Google (Gemini & Vertex AI)

Gemini is available two ways: through Google AI (google, an API key) or through Vertex AI / Agent Platform (google-vertex, Application Default Credentials). Pick whichever matches how your org buys Google models.

The quickest path: a single API key.

  1. Create a key in Google AI Studio.
  2. Store it as GEMINI_API_KEY.
.crabd.yml
model: google/gemini-2.5-pro
providers:
allowlist: [google]
workflow
- uses: louisescher/crabd@v0
with:
model: google/gemini-2.5-pro
env:
GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }}

Use google-vertex when you want Gemini billed and governed through Google Cloud. It authenticates with Application Default Credentials, a service-account key the runner can read.

  1. Create a service account with Vertex AI access and download its JSON key (or use google-github-actions/auth to provide ADC).
  2. Provide the ADC file path and your project/location via env.
.crabd.yml
model: google-vertex/gemini-2.5-pro
providers:
allowlist: [google-vertex]
workflow
- uses: google-github-actions/auth@v2
with:
credentials_json: ${{ secrets.GCP_SA_KEY }}
- uses: louisescher/crabd@v0
with:
model: google-vertex/gemini-2.5-pro
env:
GOOGLE_APPLICATION_CREDENTIALS: ${{ steps.auth.outputs.credentials_file_path }}
GOOGLE_CLOUD_PROJECT: my-gcp-project
GOOGLE_CLOUD_LOCATION: us-central1