9router/open-sse/services
Z User 8daa953ef6 fix(oauth): align antigravity OAuth metadata with official client headers
Fixes #1226

The Antigravity OAuth flow sent inconsistent client metadata between
the token acquisition phase and the API usage phase. String enum values
(IDE_UNSPECIFIED, PLATFORM_UNSPECIFIED) were used during OAuth token
exchange + loadCodeAssist + onboardUser, while numeric enums (ideType: 9,
platform: <computed>, pluginType: 2) were used in runtime API calls.
Google detected this fingerprint mismatch and blocked 9router accounts.

Replace all string enum occurrences with the correct numeric values:

- src/lib/oauth/constants/oauth.js: loadCodeAssistClientMetadata now
  uses getOAuthPlatformEnum() for platform and numeric 9/2 for
  ideType/pluginType, matching getOAuthClientMetadata()
- src/lib/oauth/services/antigravity.js: getMetadata() now delegates
  to getOAuthClientMetadata() instead of returning hardcoded strings
- src/lib/oauth/providers.js: postExchange metadata now uses
  getOAuthClientMetadata() instead of inline string enums
- open-sse/services/usage.js: getGeminiSubscriptionInfo body now uses
  CLIENT_METADATA (already imported from appConstants.js) instead of
  inline string enums
2026-05-18 15:23:37 +07:00
..
accountFallback.js fix: update backoff configuration and improve CLI detection messages 2026-04-17 12:54:50 +07:00
combo.js Add sticky round-robin for combos (#831) 2026-05-01 16:36:36 +07:00
compact.js Feat : Auto restart after crash 2026-03-14 09:37:29 +07:00
kiroModels.js https://github.com/decolua/9router/pull/1167 2026-05-16 11:20:08 +07:00
model.js Add Vercel AI Gateway provider support (#1183) 2026-05-17 15:16:25 +07:00
projectId.js Add proactive token refresh lead times for providers and implement Codex proxy management 2026-04-14 11:41:06 +07:00
provider.js feat: Add Google Cloud Vertex AI provider support (vertex, vertex-partner) 2026-03-14 11:37:23 +07:00
tokenRefresh.js Enhance token refresh logic and improve MITM server handling 2026-05-03 22:10:03 +07:00
usage.js fix(oauth): align antigravity OAuth metadata with official client headers 2026-05-18 15:23:37 +07:00