Skip to content

v1.6.4 — OpenClaw OAuth Login Hotfix, 8,192 Message Limit & Accurate Image Token Usage

Choose a tag to compare

@ShawTim ShawTim released this 21 Nov 15:28
· 43 commits to main since this release

Highlights

  • Critical OpenClaw OAuth Login Hotfix (openclaw-gemini-app@0.1.5):
    • Fixed OAuth login displaying visit: undefined by reading session.authorizationUrl from startLoopbackLogin() (with an explicit non-empty URL guard).
    • Added the required post-login scoped token exchange (refreshNativeCredential(config, tokens.refreshToken)) to acquire assistant/gemini scopes before terms acceptance, quota/tier detection, and generation.
    • Fixed swapped (cred.refresh, config) arguments in refreshOpenClawOAuth, covered by a real-loopback + real-refresh integration test (test/openclaw-extension.test.mjs).
  • Long-Session Message Limit (MAX_MESSAGES = 8,192): Raised MAX_MESSAGES from 1,024 to 8,192 and requestBudget() JSON node limit from 32,768 to 131,072 (src/openai-contract.mjs), returning standard 413 REQUEST_TOO_LARGE (param: "messages" / "input") on overflow instead of misleading 400 MESSAGES_REQUIRED.
  • Accurate Image Token Estimation (pi-gemini-app@0.1.9, Gateway & OpenClaw): Excluded base64 image_url / input_image data strings from promptChars and billed a fixed 258 tokens per image (src/openai-usage.mjs, src/gateway/app.mjs, src/gateway/response-delivery.mjs, extensions/pi/stream.js) so multi-screenshot sessions no longer inflate usage.prompt_tokens.

Packages & Docker

  • Gateway: gemini-app2api@1.6.4 · ghcr.io/shawtim/gemini-app2api:v1.6.4 (linux/amd64, linux/arm64)
  • OpenClaw Plugin: openclaw-gemini-app@0.1.5
  • Pi Extension: pi-gemini-app@0.1.9

Full Changelog: v1.6.3...v1.6.4