A CLI toolkit to manage Google Antigravity IDE authentication profiles. Seamlessly switch between multiple Google accounts without the hassle of signing in and out.
- π Multi-account support - Manage multiple Google accounts for Antigravity IDE
- β‘ Quick switching - Switch between profiles in seconds
- πΎ Profile backup - Each profile is stored separately with all settings intact
- π₯οΈ Cross-platform - Works on macOS, Linux, and Windows
- π OAuth authentication - Secure Google sign-in with automatic token storage
- π Quota monitoring - Real-time quota tracking with auto-refresh
- π Keychain storage - Secure token storage in macOS Keychain
# Using npm
npm install -g antigravity-kit
# Using pnpm
pnpm add -g antigravity-kit
# Using yarn
yarn global add antigravity-kit# Interactive menu - select from available actions
agk auth
# Or use direct commands:
agk auth add # Add your first account
agk auth list # List all profiles
agk auth switch # Switch to a different profile
agk auth quota # Monitor quota usage
agk upgrade # Upgrade to latest versionThe CLI can be invoked using any of these aliases:
antigravity-kitantigravikitagk(recommended - shortest)
Add a new Google Antigravity account profile.
# Default: OAuth sign-in (opens browser)
agk auth add
# Manual: IDE-based login
agk auth add --manual
# Force file storage instead of Keychain
agk auth add --insecureOptions:
| Flag | Description |
|---|---|
--manual |
Use manual IDE login instead of OAuth (opens Antigravity IDE) |
--insecure |
Store tokens in local file instead of macOS Keychain |
How it works:
OAuth Flow (default):
- Opens your browser for Google sign-in
- Captures authentication and creates a profile
- Stores refresh token securely (Keychain on macOS)
- Shows available quota for the account
Manual Flow (--manual):
- If an existing Antigravity login is detected, you'll be prompted to add it as a profile
- If no login exists, Antigravity IDE will open for you to sign in
- The CLI watches for authentication and saves your profile automatically
Example output:
β Add a new account
This will:
1. Open your browser for Google sign-in
2. Capture your login and create a profile
3. Store tokens for quota checking
π Tokens will be stored in macOS Keychain
Saving profile...
β Profile Created ββββββββββββββββββββββββββββββ
β β
β Email: user@gmail.com β
β Profile: ~/.antigravity-kit/profiles/... β
β Status: Active β
β Quota: 5 models available β
β β
ββββββββββββββββββββββββββββββββββββββββββββββββ
β Account user@gmail.com added successfully!
List all saved Google Antigravity profiles.
agk auth listExample output:
β Saved Profiles
Email OAuth Storage Claude Gemini Size Created
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β user@gmail.com β π 100% 80% (2h45m) 45.2 MB Dec 15, 2024
β work@company.com β π β β 38.7 MB Dec 10, 2024
β personal@gmail.com β β β β 42.1 MB Nov 28, 2024
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Active: user@gmail.com
Legend: β Active β OAuth π Keychain N% Quota (reset)
Total: 3 profiles
β³ Auto-refresh in 30s | Press 'r' to reload | Press 'q' to exit
Legend:
β(green) - Active profileβ(dim) - Inactive profileβ- OAuth token stored (quota checking enabled)β- No OAuth token (added with--manual)π- Token stored in KeychainN%- Quota usage percentage (with reset time if available)
Switch between Google Antigravity profiles.
# Interactive selection
agk auth switch
# With workspace options
agk auth switch --workspace select # Choose workspace interactively
agk auth switch -w my-project # Open specific workspace by nameOptions:
| Flag | Alias | Description |
|---|---|---|
--workspace <name> |
-w |
Specify a workspace to open. Use select to choose interactively. |
How it works:
- Displays a list of all saved profiles
- Select the profile you want to switch to
- OAuth check: If the profile has no OAuth token, you'll be prompted to sign in
- If Antigravity is running, you'll be prompted to close it
- Profile data is restored and Antigravity can be launched
- Workspace persistence: Your previously open workspace is remembered and reopened automatically
Example output:
β Switch Profile
Current profile: user@gmail.com
? Select a profile to switch to:
β user@gmail.com (active)
β work@company.com
β personal@gmail.com
β work@company.com has no OAuth token. Quota checking won't work.
? What would you like to do?
βΊ Sign in with OAuth first
Continue without OAuth
Cancel
Antigravity is currently running. Close it to continue? β¦ yes
Closing Antigravity...
? Launch Antigravity with the new profile? β¦ yes
β Switched to work@company.com and opened my-project
Remove a Google Antigravity profile.
agk auth removeHow it works:
- Displays a list of all saved profiles with sizes
- Select the profile to remove
- Confirm deletion (shows disk space that will be freed)
- If the active profile is removed, another profile becomes active
Example output:
β Remove Profile
? Select a profile to remove:
β user@gmail.com (active) 45.2 MB
β work@company.com 38.7 MB
? Are you sure you want to remove work@company.com?
This will free up 38.7 MB of disk space. β¦ yes
Removing profile...
β Profile work@company.com removed
Monitor quota usage for Google Antigravity accounts in real-time.
# Check quota for active profile
agk auth quota
# Check quota for specific account
agk auth quota --account user@gmail.com
# Set custom refresh interval (seconds)
agk auth quota --interval 60Options:
| Flag | Alias | Description |
|---|---|---|
--account <email> |
-a |
Email of the account to check (defaults to active profile) |
--interval <seconds> |
-i |
Auto-refresh interval in seconds (default: 30, min: 10) |
Interactive Controls:
- Press
rto manually reload quota data - Press
qto exit the monitor
Example output:
β Quota Monitor
Monitoring quota for user@gmail.com
Refresh interval: 30s
π Quota Status - user@gmail.com
π Subscription: Gemini Business
ββββββββββββββββββββββββββββββ¬βββββββββββββββββββ¬ββββββββββββββββ
β Model β Quota β Reset Time β
ββββββββββββββββββββββββββββββΌβββββββββββββββββββΌββββββββββββββββ€
β gemini-2.0-flash β ββββββββββ 80% β in 2h 45m β
β gemini-2.0-pro β ββββββββββ 60% β in 2h 45m β
β claude-3.5-sonnet β ββββββββββ 100% β β β
ββββββββββββββββββββββββββββββ΄βββββββββββββββββββ΄ββββββββββββββββ
β³ Auto-refresh in 28s | Press 'r' to reload | Press 'q' to exit
Requirements:
- OAuth token must be stored for the account
- Use
agk auth add(without--manual) to enable quota checking
Upgrade antigravity-kit to the latest version.
# Interactive check and upgrade
agk upgrade
# Upgrade to latest stable version
agk upgrade --latest
# Upgrade to latest beta version
agk upgrade --beta
# Check for updates only
agk upgrade --checkOptions:
| Flag | Description |
|---|---|
--latest |
Upgrade to the latest stable version |
--beta |
Upgrade to the latest beta version |
--check |
Check for updates without installing |
How it works:
- Checks npm registry for new versions.
- Compares with your current installed version.
- Allows interactive selection of version (Stable vs Beta) if not specified via flag.
- Runs
npm install -g antigravity-kit@<version>to perform the upgrade.
Antigravity Kit supports secure token storage for OAuth authentication:
| Platform | Storage Method | Notes |
|---|---|---|
| macOS | Keychain | Default. Uses macOS Keychain for secure storage |
| Linux | File | Stored in ~/.antigravity-kit/tokens/ |
| Windows | File | Stored in ~/.antigravity-kit/tokens/ |
Flags:
- Use
--insecurewithauth addto force file-based storage on macOS - Keychain storage may require user permission on first use
| Platform | Status | Notes |
|---|---|---|
| macOS | β | Looks for Antigravity.app in /Applications or ~/Applications |
| Linux | β | Uses antigravity command or checks /usr/bin, /usr/local/bin |
| Windows | β | Supports Git Bash, MSYS, Cygwin. Looks in Program Files |
Profiles are stored in ~/.antigravity-kit/profiles/. Each profile contains a complete copy of the Antigravity user data directory, including:
- Authentication tokens
- Settings and preferences
- Extensions (if any)
- Workspace data
- Node.js >= 18.0.0
- Antigravity IDE installed on your system
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'feat: add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE.md file for details.
- Built with citty for CLI framework
- Interactive prompts powered by @clack/prompts
- Beautiful gradients with gradient-string
Made with β€οΈ by duongductrong
