From 16393b2554a8434f2cd077637fd165d36cae357f Mon Sep 17 00:00:00 2001 From: YeonGyu-Kim Date: Fri, 12 Dec 2025 23:26:53 +0900 Subject: [PATCH] fix(antigravity-auth): apply auth headers in pass-through path MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Pass-through path (non-string body) now preserves Authorization header. This ensures authentication works even when request transformation is bypassed. 🤖 GENERATED WITH ASSISTANCE OF [OhMyOpenCode](https://github.com/code-yeongyu/oh-my-opencode) --- src/auth/antigravity/fetch.ts | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/auth/antigravity/fetch.ts b/src/auth/antigravity/fetch.ts index 6a12298..80f6f2f 100644 --- a/src/auth/antigravity/fetch.ts +++ b/src/auth/antigravity/fetch.ts @@ -318,8 +318,12 @@ export function createAntigravityFetch( ) if (response === "pass-through") { - debugLog("Non-string body detected, passing through to original fetch") - return fetch(url, init) + debugLog("Non-string body detected, passing through with auth headers") + const headersWithAuth = { + ...init.headers, + Authorization: `Bearer ${cachedTokens.access_token}`, + } + return fetch(url, { ...init, headers: headersWithAuth }) } if (response) {