antigravity-cli: support Google AI subscription login (no API key)
Maintainers usually reply within 1 day
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 25/100
- Issue type
- Feature
- Clarity
- Clearly specified
- Activity status
- Stale
- Tech stack
- python
- Domain
- authentication, backend
Research direction
Start by tracing check_model_credentials and the antigravity-cli settings and environment setup; compare how CLAUDE_FORCE_OAUTH, CODEX_FORCE_AUTH_JSON, and GEMINI_FORCE_OAUTH are handled. The issue specifies the two agy credential files and the proposed opt-in behavior. A pull request is already open, so check its status and discussion before taking this on.
Written by the indexing model from the issue text.
Description
Problem
antigravity-cli supports a Gemini API key, enterprise ADC (AGY_ADC_AUTH) and an LLM gateway. There is no headless path for a personal Google AI subscription (Google account sign-in), although Harbor has one for Claude Code (CLAUDE_FORCE_OAUTH), Codex (CODEX_FORCE_AUTH_JSON / CODEX_AUTH_JSON_PATH) and Gemini CLI (GEMINI_FORCE_OAUTH / GEMINI_OAUTH_CREDS_PATH).
Found while running Harbor 0.27.0 with agy 1.5.21 for a benchmark run.
What works with agy 1.5.21
On macOS agy stores the login in the Keychain, which a container cannot read. A one-time interactive agy sign-in in a Linux container (no system keyring) writes the login to two plain files:
~/.gemini/antigravity-cli/antigravity-oauth-token~/.config/antigravity/credential-user-scope
Uploading both into a task container (mode 600) lets headless agy --print runs use the subscription. Two things in Harbor get in the way:
check_model_credentialsrequiresGEMINI_API_KEY/GOOGLE_API_KEYunlessAGY_ADC_AUTHis set.- If a key is present anywhere,
settings.jsongets"modelProvider": "gemini", and agy then insists on the key instead of the uploaded login:modelProvider is set to "gemini" in settings.json, but the GEMINI_API_KEY environment variable is not set.
Repro
# no GEMINI_API_KEY / GOOGLE_API_KEY, signed-in login files available
harbor run -p <task> -a antigravity-cli -m gemini/gemini-3-flash-preview --ak version=1.5.21
# -> credential preflight fails: antigravity-cli: set GEMINI_API_KEY or GOOGLE_API_KEY ...
Proposal
An opt-in subscription mode in the style of the other agents, e.g. AGY_FORCE_OAUTH=true (use the host's agy login files) and AGY_OAUTH_DIR=<dir> (a directory holding both files, for hosts where agy keeps the login in a keyring). In that mode Harbor skips the API-key preflight, uploads the files, leaves modelProvider unset and keeps API keys out of the agy environment.
History
A token-file path existed before (AGY_AUTH_JSON_PATH / AGY_FORCE_AUTH_JSON, #2254) and was removed in #2776 in favour of the documented API-key and ADC paths. #2905 and #3963 tried to bring it back and were closed by their authors. Neither documented path covers a personal subscription, which is why this is being raised again. Current agy also needs credential-user-scope next to the token.
A PR follows.
Drafted with AI assistance (Claude Code) and reviewed before posting.
- Dominant language
- Python
- Stars
- 5.6k
- Forks
- 1.9k
- Avg merge
- 1d 17h
- Merged PRs (30d)
- 156
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from harbor-framework/harbor
-
Trial runs the agent's `populate_context_post_run` on the event loop, so trials that end together stall the orchestrator for secondsPossibly taken A pull request linked to this issue is open or already merged. Open
Difficulty 2/5 1-3 hours Newbie friendliness 77/100
harbor-framework/harbor#4652 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
harbor-framework/harbor#4494 · 1 comment ·
Maintainers usually reply within 1 day
-
step workdir upload resets the work folder's owner and permissions in ModalPossibly taken @Sauvi72 claimed this 8 days ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
harbor-framework/harbor#4487 · 3 comments ·
Maintainers usually reply within 1 day
-
Docker: verifier log mounts are chmod 777 (no sticky), so rewardkit sandboxed graders die before writing a rewardPossibly taken @yuyz-cyber claimed this 6 days ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
harbor-framework/harbor#4469 · 1 comment ·
Maintainers usually reply within 1 day
-
Compare and Pareto hide total token usage when the cached token count is missingPossibly taken @Aafimalek claimed this 10 days ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
harbor-framework/harbor#4448 ·
Maintainers usually reply within 1 day
All issues in harbor-framework/harbor
Similar issues
-
soup prune-prompt exits 1 after writing its output on a file over 100,000 rows, and reports a capped row count otherwisePossibly taken @abdulwaarith0 claimed this today. Openneeds-triage
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
MakazhanAlpamys/Soup#3690 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
bug data-types native-format
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
ClickHouse/clickhouse-connect#1320 ·
Maintainers usually reply within 1 day
-
accepted
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
future-agi/future-agi#6392 ·
Maintainers usually reply within 1 day