databricks-code is a lightweight launcher for running Codex, Claude Code, and Gemini CLI through Databricks.
It is designed for a simple setup flow:
git clone <repo-url>
cd databricks-code
pipx install .
databricks-codeOn first run, databricks-code handles local bootstrap, prompts for your Databricks workspace, configures the selected coding tool, and launches it.
- Minimal setup for Databricks-backed coding tools
- One workspace configuration shared across Codex, Claude Code, and Gemini CLI
- Automatic Databricks authentication handoff
- Managed local config files with restore support through
databricks-code logout - Built-in AI Gateway usage reporting with
databricks-code usage
- Codex
- Claude Code
- Gemini CLI
Install and launch:
git clone <repo-url>
cd databricks-code
pipx install .
databricks-codeOn first launch, databricks-code will:
- Install missing local dependencies it manages:
databricks,codex,claude,gemini - Prompt for your Databricks workspace URL
- Ask whether you want to use Databricks AI Gateway V2
- Run Databricks login
- Write managed tool configuration files
- Launch the selected tool
After setup, normal usage is simple:
databricks-code
databricks-code --tool codex
databricks-code --tool claude
databricks-code --tool geminiUse configure to update workspace settings or saved models:
databricks-code configureThe interactive flow supports:
WorkspaceReconfigure the Databricks workspace for all toolsModelsChoose the saved launch model for Claude Code or Gemini CLI
Examples:
databricks-code --tool claude --model databricks-claude-opus-4-6
databricks-code --tool gemini --model databricks-gemini-2-5-proNotes:
- Codex model selection remains inside Codex via
/model - Claude and Gemini can use saved models or an explicit
--model - Normal launches do not query the workspace model list unless you are configuring models
databricks-code configure
databricks-code status
databricks-code usage
databricks-code logoutconfigureConfigure workspace settings or saved Claude/Gemini modelsstatusShow the current workspace, base URLs, managed config files, and selected modelsusageShow a fixed AI Gateway usage summary for the current userlogoutClear saved state and restore any backed-up local config files
databricks-code usageusage requires Databricks AI Gateway V2. When enabled, it queries system.ai_gateway.usage and shows:
- token totals for today, the last 7 days, and the last 30 days
- active tools this week
- top models this week
- a 7-day breakdown for Codex, Claude Code, and Gemini CLI
If the workspace is not configured for AI Gateway V2, databricks-code usage will stop early and tell you to re-run databricks-code configure.
databricks-code manages these local files:
~/.codex/config.toml~/.claude/settings.json~/.gemini/.env
If one of these files already exists, databricks-code creates a backup before writing its managed version. databricks-code logout restores the backup.
- Databricks authentication always uses the workspace URL you configured
- If AI Gateway V2 is enabled, tool base URLs point to the AI Gateway hostname while authentication still uses the original workspace URL
- Codex and Claude use a Databricks token helper instead of storing a fixed token
- Gemini refreshes its Databricks bearer token automatically while launched through
databricks-code databricks-code usagefetches a fresh Databricks token on each run
- Databricks AI Gateway overview
- Databricks AI Gateway coding agent integration
- Databricks CLI authentication
- Monitor AI Gateway usage with
system.ai_gateway.usage
- Python 3.12+
pipx(recommended) orpipnpmif tool CLIs need to be installed automatically