Skip to main content

Overview

Antigravity Manager provides first-class integration with OpenCode through automatic configuration sync and provider management.
OpenCode integration was significantly enhanced in v4.1.16 with support for custom base URLs and environment variable-based configuration.

Prerequisites

  • Antigravity Manager installed and configured
  • OpenCode installed (npm install -g opencode)
  • At least one active account in Antigravity

Configuration sync

1

Open sync dialog

  1. Navigate to API ProxyExternal Providers
  2. Click the OpenCode Sync card
2

Click Sync button

Antigravity will automatically:
  • Generate ~/.config/opencode/opencode.json
  • Create antigravity-manager provider
  • Preserve existing Google/Anthropic providers
3

Optional: Sync accounts

Check Sync accounts to export:
  • antigravity-accounts.json (plugin-compatible v3 format)
  • Allows OpenCode plugin to import accounts directly
Windows users: Configuration path is C:\Users\<username>\.config\opencode\

Provider configuration

The sync creates an antigravity-manager provider with these properties:

Custom base URL

For Docker or remote deployments, set a custom base URL:
1

Open settings

In the OpenCode Sync dialog, find Custom Manager BaseURL
2

Enter URL

3

Sync configuration

Click Sync to apply the custom URL

Usage examples

Basic usage

Model variants

Antigravity supports OpenCode’s variant system:
Routes to Pro/Ultra tier accounts with maximum quota.

Thinking models

Antigravity automatically handles thinking budget conversion between OpenCode’s format and Gemini’s internal format.

Configuration management

Clear configuration

Remove Antigravity configuration and legacy entries:
This removes:
  • antigravity-manager provider
  • Legacy plugin configurations
  • Temporary sync files

Restore from backup

If sync creates issues:
Restores the previous opencode.json from automatic backup.

Manual configuration

You can also edit ~/.config/opencode/opencode.json directly:

Docker/remote deployment

Docker Compose setup

For Docker Compose networks:
In OpenCode sync:
  1. Set Custom Manager BaseURL: http://antigravity:8045
  2. Sync configuration

Remote server

For servers on different machines:
Ensure the Antigravity proxy is configured to allow LAN access:
  • Enable Allow LAN Access in API Proxy settings
  • Or set ABV_BIND_LOCAL_ONLY=false for Docker

Troubleshooting

Problem: Error: Provider 'antigravity-manager' not foundSolutions:
  1. Verify sync completed successfully
  2. Check file exists: ~/.config/opencode/opencode.json
  3. Run sync again from Antigravity UI
  4. Verify JSON syntax is valid
Problem: ECONNREFUSED when calling modelsSolutions:
  1. Verify Antigravity proxy is running
  2. Check base URL matches actual server address
  3. For Docker: use container name, not localhost
  4. Test with: curl http://127.0.0.1:8045/health
Problem: AI_UnsupportedFunctionalityError: 'thinking requires a budget'Solutions:
  1. Upgrade to Antigravity v4.1.27 or later
  2. Verify thinking model names include -thinking suffix
  3. Check account supports thinking-capable models
  4. Review Antigravity logs for conversion details
Problem: Model listed but returns 404Solutions:
  1. Check model is available in Antigravity dashboard
  2. Refresh account quotas in Antigravity
  3. Verify model name spelling (case-sensitive)
  4. Check custom model mappings in Antigravity

Best practices

  1. Use automatic sync: Let Antigravity manage the configuration
  2. Multiple providers: Keep both antigravity-manager and native providers for flexibility
  3. Environment-specific URLs: Use custom URLs for dev/staging/production
  4. Regular updates: Re-sync after adding new models or accounts
  5. Backup configs: Antigravity creates automatic backups before each sync

Advanced features

Account export

When Sync accounts is enabled, Antigravity exports:
This allows OpenCode plugins to:
  • Display account information
  • Show quota status
  • Enable account-specific features

Coexisting with native providers

Antigravity sync preserves existing providers:
Use whichever fits your needs: