Skip to content

feat(antigravity): add OAuth-backed remote usage when the IDE is closed#635

Open
abnormal749 wants to merge 2 commits intosteipete:mainfrom
abnormal749:antigravity-without-IDE-open
Open

feat(antigravity): add OAuth-backed remote usage when the IDE is closed#635
abnormal749 wants to merge 2 commits intosteipete:mainfrom
abnormal749:antigravity-without-IDE-open

Conversation

@abnormal749
Copy link
Copy Markdown

Summary

Add remote Antigravity usage support to CodexBar so usage can still be fetched when the local IDE API is unavailable.

The implementation stays within CodexBar. The remote flow was referenced from antigravity-usage, then adapted to fit CodexBar’s existing provider, settings, and runtime patterns.

What changed

  • added an Antigravity remote usage fetcher for the Cloud Code / Antigravity backend
  • added Antigravity OAuth credential storage under ~/.codexbar/antigravity/oauth_creds.json
  • added first-time Antigravity login support in CodexBar
  • added Antigravity provider settings UI:
    • usage source picker: Auto, Google OAuth, Local IDE API
    • Google OAuth login / re-authenticate action
  • updated Antigravity source handling so Auto uses:
    • local IDE API first
    • remote OAuth path when the IDE is closed
  • added model/quota parsing and Antigravity lane mapping for the menubar snapshot
  • added fallback handling for remote quota endpoints that may return 403 PERMISSION_DENIED
  • resolved the OAuth client from the installed Antigravity.app bundle, with env vars available as an override:
    • ANTIGRAVITY_OAUTH_CLIENT_ID
    • ANTIGRAVITY_OAUTH_CLIENT_SECRET

Notes

  • this does not modify antigravity-usage
  • if Antigravity.app is installed, CodexBar can discover the OAuth client locally
  • if it is not installed, env vars can be used as an override

Testing

  • swift build --scratch-path /tmp/codexbar-swiftpm-scratch

Prepared with Codex.

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: afc6eede32

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

@abnormal749
Copy link
Copy Markdown
Author

@codex review

@chatgpt-codex-connector
Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Keep it up!

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant