Overview
This guide walks you through deploying an AI assistant powered by Google Gemini using Local Deployment. You'll configure the provider, set up the deployment environment, and get your assistant running.
Why Google Gemini?
- 1M token context window
- Multimodal understanding
- Fast inference
Why Local Deployment?
- Simplest setup
- No network exposure
- Full control
Requirements
- Node.js 22+: Node.js version 22 or higher is required
- macOS, Linux, or WSL2: Supported operating systems
- npm or pnpm: Package manager for installation
- Google Gemini credentials: API key or authentication
Step 1: Configure Google Gemini
Google AI API key
- Go to ai.google.dev
- Create or select a project
- Enable the Gemini API
- Generate an API key
- Set GOOGLE_API_KEY environment variable
Environment Variable:
GOOGLE_API_KEY Step 2: Prepare Local Deployment Environment
- Install OpenClaw: Install OpenClaw globally via npm or the installer script
curl -fsSL https://openclaw.bot/install.sh | bash - Run Onboarding: Complete the setup wizard
openclaw onboard --install-daemon - Configure Providers: Add your AI provider credentials during onboarding or manually
- Start Gateway: Start the Gateway service
openclaw gateway start - Verify Status: Check that everything is running correctly
openclaw status
Step 3: Configuration
Create your openclaw.json configuration:
{
"agents": {
"defaults": {
"model": {
"primary": "google-gemini/gemini-2.0-flash-exp"
}
}
},
"models": {
"providers": {
"google-gemini": {
"models": {
"providers": {
"google-gemini": {
"apiKey": "${GOOGLE_API_KEY}
}
}
} Step 4: Deploy
{
"gateway": {
"mode": "local",
"bind": "loopback",
"port": 18789,
"auth": {
"mode": "token",
"allowTailscale": false
}
}
} Step 5: Verify
# Check deployment status
openclaw status
# View logs
openclaw logs --follow
# Test with a message
openclaw test "Hello, are you working?" Connect to Channels
Now connect your deployed Google Gemini assistant to messaging channels:
Connect AI to WhatsApp via Baileys protocol
Telegram
Full-featured Telegram bot with commands and reactions
Discord
Discord bot with slash commands and threads
Slack
Slack app with Block Kit and threads
Signal
Encrypted messaging via signal-cli daemon
iMessage
Apple iMessage integration (macOS only)