Use Google Antigravity Models in Any AI Coding Tool for Free

AICodeKinggo watch the original →

CLIProxyAPI acts as a local middleware server that exposes Google's Antigravity IDE models (including Claude 3.5/Opus 4.6 and Gemini 3.1) to any OpenAI-compatible AI coding tool.

The Breakthrough

CLIProxyAPI enables the use of premium, gated models from Google's Antigravity IDE—specifically Claude 3.5 Sonnet, Claude Opus 4.6 Thinking, and Gemini 3.1 Pro—within third-party coding environments like Claude Code, Cline, and RooCode by abstracting them into a local OpenAI-compatible API endpoint.

What Actually Worked

  • Installation: Install the proxy via Homebrew (brew install CLIProxyAPI), the provided Linux bash script, or by downloading the Windows executable from GitHub.
  • Authentication: Run CLIProxyAPI --anti-gravity login to authenticate via OAuth, which saves the token locally and handles background refreshes.
  • Configuration: Set a custom API key in the config.yml file (located in the home directory or /etc/) to secure the local endpoint, which defaults to http://localhost:8317.
  • Integration: Redirect coding tools to the proxy by setting environment variables or config file fields. For Claude Code, export the following variables:
    export ANTHROPIC_BASE_URL="http://localhost:8317"
    export ANTHROPIC_API_KEY="your-custom-key"
    export CLAUDE_OPUS_MODEL="claude-opus-4.6-thinking"
    export CLAUDE_SONNET_MODEL="claude-sonnet-4.6"
    
  • Management: Use the built-in web management UI to monitor usage, manage keys, and track rate limits across connected providers.

Context

Google's Antigravity IDE provides free access to high-end frontier models, but these models are typically restricted to the IDE's internal interface. Developers often prefer specialized coding harnesses like Claude Code or Cline for their specific workflows. CLIProxyAPI bridges this gap by acting as a local server that translates requests from these tools into the format expected by the Antigravity backend, allowing users to leverage expensive models without incurring direct API costs.

Content References

  • #tutorial
  • #ai
  • #dev-tooling

summary by google/gemini-3.1-flash-lite. probably wrong about something. check the source.