Docs for SCORPIOX CODE @ 13253cf

Enterprise Google Cloud Vertex AI in SCORPIOX CODE

Direct Google Cloud Vertex AI publisher endpoint via API key authentication and multi-account rotation.

You have a Google Cloud project, a billing account, and a Google Cloud API key — and you want SCORPIOX CODE running Gemini models against your own project, on your own quotas, billed per token to you instead of drawn down from a consumer subscription. Set PROVIDER=gemini_vertex, put the key in VERTEX_API_KEY, and name the model in both VERTEX_MODEL and MODEL. After that it is ordinary SCORPIOX CODE: the same agent loop, the same tools, the same local traffic capture.

This page walks through the configuration keys and the way the two model slots interact, multi-account rotation with profiles (/profile and /use), the helper that lists the models your key can reach, and how direct enterprise billing differs from the consumer Antigravity OAuth quota.

Docs for SCORPIOX CODE @ 13253cf.

The whole idea in one line: a Google Cloud API key in VERTEX_API_KEY plus PROVIDER=gemini_vertex turns SCORPIOX CODE into a Vertex AI client against the publisher endpoint — pay-per-use against your project, no OAuth login, no token refresh, no subscription quota to share with anyone.


When to use this provider

ScenarioExample
You have a Google Cloud project and a billing accountDirect pay-per-use; every request bills to your project
You need dedicated, predictable quotasYour project's rate limits are yours alone — no shared consumer pool
You run several GCP accounts or projectsOne key per team or environment, rotated with profiles
You already hold a Google Cloud API keyThe key is the whole credential — no login flow to run

If you do not have a Google Cloud project and key, and you instead use a Google / Antigravity subscription, use PROVIDER=google_gemini or PROVIDER=google_claude — see Using Google Antigravity CLI Subscription in SCORPIOX CODE. The two paths run overlapping Gemini models on completely different billing and quota models; Enterprise GCP billing vs. consumer Antigravity quota below compares them.

API key, not OAuth. This provider authenticates with a Google Cloud API key and bills per token against your GCP billing account. It does not use the Antigravity sign-in and does not touch consumer subscription quota.


The headline: three keys

Everything is a KEY=VALUE pair in the configuration cascade. The minimal working set is:

PROVIDER=gemini_vertex
VERTEX_API_KEY=your-google-cloud-api-key
MODEL=gemini-3.7-flash
VERTEX_MODEL=gemini-3.7-flash

PROVIDER selects the Vertex AI path, VERTEX_API_KEY carries the credential, and the two model keys name the model. This page assumes you already have the project, billing, and the key — the setup happens on the Google side, and the key is the only thing SCORPIOX CODE needs from it.

Configuration keys

All keys can live in any cascade tier of scorpiox-env.txt, in a named profile, or as OS environment variables. See Configuration and Profiles for the full cascade and precedence rules.

KeyTypeDefaultDescription
PROVIDERchoice(install default)Set to gemini_vertex to activate this provider.
VERTEX_API_KEYtext(empty)Required. Your Google Cloud API key. Every request fails without it.
VERTEX_MODELtextgemini-3.1-pro-previewThe provider's own model slot. Accepts a full gemini-* ID (for example gemini-3.7-flash, gemini-3.8-flash) or a short alias.
MODELtextsonnetThe generic model slot shared by every provider. This is the value that ultimately names the model on the wire. Set it to the same value as VERTEX_MODEL.

Set both MODEL and VERTEX_MODEL. They are read at different points in the stack, and MODEL is the one that wins. Keeping the two identical — gemini-3.7-flash in both, or gemini-3.8-flash in both — is what makes model selection reliable; see the next section for exactly why.

How the two model keys interact

There are two model settings because there are two layers, and they do different jobs:

KeyRole
VERTEX_MODELThe provider-specific slot. It is what the config editor offers when this provider is selected, and the value the provider picks up first.
MODELThe generic slot every provider shares. It is applied after the provider-specific slot, and it is what actually names the model sent to the endpoint.

Both accept the same values, so the fix for disagreement is easy — but the disagreement itself is silent. MODEL=opus with VERTEX_MODEL=gemini-3.8-flash does not send gemini-3.8-flash; it sends the model the opus alias maps to. The status bar happily shows opus while the request goes somewhere you did not intend. Set both keys to the same full ID and every path agrees.

Short aliases and pass-through

Values are resolved before the request is sent:

ValueResolves to
opus or progemini-3.1-pro-preview
sonnet or flashgemini-3-flash-preview
haikugemini-3.1-flash-lite-preview
any gemini-* IDpassed through unchanged — gemini-3.7-flash and gemini-3.8-flash reach the endpoint exactly as written
anything elsefalls back to gemini-3.1-pro-preview

The config editor offers five suggestions when this provider is selected — gemini-3.1-pro-preview, gemini-3.1-flash-lite-preview, gemini-3-flash-preview, gemini-2.5-pro, and gemini-2.5-flash — but a file or an environment variable accepts any gemini-* ID. Prefer the full ID: it is unambiguous, it is what the status bar shows, and it is what the endpoint receives.


Setting the keys

In scorpiox-env.txt (any cascade tier)

PROVIDER=gemini_vertex
VERTEX_API_KEY=your-google-cloud-api-key
MODEL=gemini-3.7-flash
VERTEX_MODEL=gemini-3.7-flash

Profiles keep a key out of any file you might commit, and give you one switch per account. Create ~/.claude/scorpiox-env/gemini-vertex-flash-a.txt:

PROVIDER=gemini_vertex
VERTEX_API_KEY=your-google-cloud-api-key
MODEL=gemini-3.7-flash
VERTEX_MODEL=gemini-3.7-flash

Activate it persistently or for a single session:

# Persistent (survives restarts — written to the user tier)
/profile gemini-vertex-flash-a

# Session-only (no file change)
/use gemini-vertex-flash-a

See Multi-account rotation with profiles for the full pattern.

As OS environment variables

export PROVIDER=gemini_vertex
export VERTEX_API_KEY=your-google-cloud-api-key
export MODEL=gemini-3.7-flash
export VERTEX_MODEL=gemini-3.7-flash

Environment variables sit above every file tier, including the active profile. That makes them the right tool for one-off runs and CI, and the classic trap everywhere else — an exported VERTEX_API_KEY from last week's experiment silently outranks the profile you are looking at. When a value "will not stick", check the environment before blaming the file.

Confirm what is actually configured

scorpiox-config            # interactive config editor; the Vertex keys appear when this provider is selected
scorpiox-config --verbose  # resolved values (PROVIDER, MODEL, ACTIVE_PROFILE, ...) with the tier each came from

--verbose shows the resolved provider and model with their source tier, so you know which file won before a long run. The Vertex-specific keys only show in the editor once PROVIDER=gemini_vertex is set, which is itself a useful check that the provider value took.


Multi-account rotation with profiles

Vertex AI is the natural fit for running several Google Cloud accounts side by side — one per team, one per environment, one per billing project. Give each account its own named profile and hop between them live; the gemini-vertex-flash-* naming convention keeps them easy to scan in a picker:

# ~/.claude/scorpiox-env/gemini-vertex-flash-a.txt
PROVIDER=gemini_vertex
VERTEX_API_KEY=your-google-cloud-api-key
MODEL=gemini-3.7-flash
VERTEX_MODEL=gemini-3.7-flash
# ~/.claude/scorpiox-env/gemini-vertex-flash-b.txt
PROVIDER=gemini_vertex
VERTEX_API_KEY=your-other-google-cloud-api-key
MODEL=gemini-3.8-flash
VERTEX_MODEL=gemini-3.8-flash

Switch at runtime:

/profile gemini-vertex-flash-a    # persist it — survives restarts
/profile gemini-vertex-flash-b    # switch account and model, hot-reloads
/use    gemini-vertex-flash-a    # this session only, nothing written
/profile off                      # drop back to the base cascade
/model  gemini-3.8-flash         # swap models in-session without touching files

Both /profile and /use reload the provider in place — new key, new model, no restart, no lost session. If a profile cannot initialize (a missing or rejected key, for instance), the switch reverts to what was running and tells you, so you are never left half-switched. The difference between the two commands is scope only: /profile writes ACTIVE_PROFILE and survives restarts; /use is an in-session switch that disappears when the session ends. See Configuration and Profiles for the full switching semantics.

A few habits that make rotation painless:


Inspecting available models

The scorpiox-vertex-models CLI lists the Gemini models your key can reach. It reads VERTEX_API_KEY from the environment or from your SCORPIOX CODE configuration, prints raw JSON to stdout, and reports errors on stderr:

# List every model the key can see
scorpiox-vertex-models

# Details for a single model
scorpiox-vertex-models gemini-3.7-flash

# Pick out just the names
scorpiox-vertex-models | jq -r '.models[].name'

With no key configured it fails fast and tells you:

error: VERTEX_API_KEY not set
Set via environment or in scorpiox-env.txt

Use it to confirm a model ID exists before you pin it in VERTEX_MODEL, and to check that a rotated profile's key still sees the models you expect. The listing comes from Google's model-listing endpoint, so treat its output as the candidate list: a model that appears there is worth trying, and the last word on what works is a real turn against the publisher endpoint.


What a request looks like

For each turn SCORPIOX CODE builds one request and sends it to the Vertex AI publisher endpoint for the model you named, translating between SCORPIOX CODE's wire format and Gemini's request and response shapes for you. Nothing to configure; the consequences are what you can see:


Enterprise GCP billing vs. consumer Antigravity quota

Both paths reach Gemini models, and mixing them up is easy because the model names overlap. The difference is who pays and which pool the request draws from:

Vertex AI (this page)Antigravity providers (consumer)
PROVIDER valuegemini_vertexgoogle_gemini / google_claude
AuthenticationGoogle Cloud API key (VERTEX_API_KEY)OAuth session login (scorpiox-antigravity-login)
BillingPay-per-token against your own GCP billing accountYour Google / Antigravity subscription allowance
Google Cloud projectYour own project, with its own billing accountNone of yours — consumer accounts bill against a shared Google-side project
Token lifecycleStatic API key — nothing to refreshShort-lived access token, refreshed automatically from a stored refresh token
QuotasDedicated to your projectShared consumer pool, throttled per model per window
Model familiesGemini via the Vertex AI publisher endpointGemini and Claude-via-Google
Best forGCP workloads that need dedicated quotas and per-token accountingPeople with a Google / Antigravity subscription and no GCP project

Rule of thumb: you have a Google Cloud project and an API key, use gemini_vertex. You only have a Google / Antigravity subscription, use google_gemini or google_claude.

The practical difference is quota isolation. The consumer Antigravity profiles the OAuth login writes (the supergoogle-* family — antigravity and antigravity-claude at this commit) draw on a shared pool where a busy window is everyone's busy window, and scorpiox-google-quota tells you how much of it is left. gemini_vertex bills and meters against your own project instead: the throughput ceiling and the rate limits are yours alone, and the cost lands on your invoice rather than on a subscription allowance.


Gotchas


Reference


See also