openclaw-vertex-setup
Configure OpenClaw to use Google Vertex AI Gemini models so normal OpenClaw startup, Gateway service startup, and TUI usage all work without manual shell setup, and keep the Gateway service aligned with the globally installed npm OpenClaw binary. Covers gcloud ADC login, project and location setup, OpenClaw model defaults, shared env wiring, auth profile fixes, npm upgrade hygiene, and end-to-end verification.
Install via CLI (Recommended)
clawhub install openclaw/skills/skills/bhrum/openclaw-vertex-setupOpenClaw Vertex Setup
Use this skill when the task is to configure or repair OpenClaw so it uses Vertex AI models such as google-vertex/gemini-3.1-pro-preview, and the result must work from normal openclaw commands instead of only from a manually prepared shell. Also use it when the user's openclaw tui or Gateway service is broken after upgrading the globally installed npm package.
Target outcome:
openclaw models statusrecognizes Vertexopenclaw gateway startoropenclaw gateway restartworksopenclaw tuican chat through Vertex without manually exporting env vars first- Gateway LaunchAgent points at the same global npm
openclawbinary thatwhich openclawresolves to
Keep the workflow minimal and verify each layer separately:
- Vertex itself
- OpenClaw model discovery
- OpenClaw local agent execution
- Gateway and TUI execution
What to inspect first
- User config:
~/.openclaw/openclaw.json - Shared OpenClaw env:
~/.openclaw/.env - Agent auth store:
~/.openclaw/agents/main/agent/auth-profiles.json - Active CLI path:
which -a openclaw - Gateway service wiring:
openclaw gateway status --deep - launchd service file:
~/Library/LaunchAgents/ai.openclaw.gateway.plist - Shell env:
~/.zshrc - ADC file:
~/.config/gcloud/application_default_credentials.json
Confirm the default OpenClaw model points at Vertex:
{
"agents": {
"defaults": {
"model": {
"primary": "google-vertex/gemini-3.1-pro-preview"
}
}
}
}
Important model note:
- In current OpenClaw builds,
google-vertex/gemini-3.1-pro-previewis the config id commonly exposed by the CLI. - In Google Vertex AI docs, the corresponding preview family is documented as
gemini-3-pro-preview. - Treat
3.1 prohere as a preview track, not the latest stable track.
Required environment
Ensure these are available to the process that launches the Gateway:
export GOOGLE_CLOUD_PROJECT="<project-id>"
export GOOGLE_CLOUD_LOCATION="global"
export GOOGLE_APPLICATION_CREDENTIALS="$HOME/.config/gcloud/application_default_credentials.json"
ADC must exist at the standard path, or GOOGLE_APPLICATION_CREDENTIALS must point to it:
gcloud auth application-default login
gcloud config set project <project-id>
gcloud auth application-default set-quota-project <project-id>
If gcloud cannot be installed via dl.google.com, the Google Cloud CLI tarball can be downloaded from storage.googleapis.com/cloud-sdk-release/.
Make normal startup work
Do not rely only on the interactive shell. Put the Vertex env into OpenClaw's shared env file so launchd/systemd and plain openclaw commands see the same values:
~/.openclaw/.env
Example:
GOOGLE_CLOUD_PROJECT=<project-id>
GOOGLE_CLOUD_LOCATION=global
GOOGLE_APPLICATION_CREDENTIALS=/Users/<user>/.config/gcloud/application_default_credentials.json
This is the most reliable fix for:
Metadata
Not sure this is the right skill?
Describe what you want to build — we'll match you to the best skill from 16,000+ options.
Find the right skillPaste this into your clawhub.json to enable this plugin.
{
"plugins": {
"official-bhrum-openclaw-vertex-setup": {
"enabled": true,
"auto_update": true
}
}
}