You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(zoo-gateway): provider types, handler, and model fetcher (#344)
* feat(zoo-gateway): add provider types, handler, and model fetcher
Co-authored-by: Cursor <cursoragent@cursor.com>
* fix(zoo-gateway): respect readonly client, real version header, safer fetch
- Stop reassigning RouterProvider.client; thread Zoo enrichment headers
through openAiHeaders so a single OpenAI client is used.
- Replace npm_package_version (never populated at extension runtime)
with Package.version from the shared package shim.
- Default the model list to [] on a structurally broken response so we
log and recover instead of crashing on response.data.data being
undefined.
- Bypass inFlightRefresh de-duplication for zoo-gateway: a refresh
triggered after sign-out/sign-in must not return the previous user's
in-flight response.
- Add fetcher unit tests covering auth header, timeout, error
redaction, and bad-response handling.
Co-authored-by: Cursor <cursoragent@cursor.com>
* fix(types): include zoo-gateway key in requestRouterModels record so RouterName stays exhaustive
Co-authored-by: Cursor <cursoragent@cursor.com>
* test(router-models): expect zoo-gateway in requestRouterModels responses
Co-authored-by: Cursor <cursoragent@cursor.com>
* test(zoo-gateway): add ZooGatewayHandler unit tests for codecov patch
Cover constructor auth guard, base URL resolution, streaming, task/mode headers, temperature, cache breakpoints, tool calls, and completePrompt.
Co-authored-by: Cursor <cursoragent@cursor.com>
* test(zoo-gateway): mock cached-token + clear-token auth helpers
The downstream stack (settings-ui) calls getCachedZooCodeToken and
clearZooCodeToken from the auth handler. CI on stacked PRs merges base
into head so this spec runs against the cached-token-aware handler;
expand the auth module mock so the auth guard test exercises the real
throw path instead of vitest's missing-mock-export error.
Co-authored-by: Cursor <cursoragent@cursor.com>
* test(zoo-gateway): align expected OpenAI headers with Zoo Code branding
Co-authored-by: Cursor <cursoragent@cursor.com>
* fix(zoo-gateway): defer auth check, fail-closed models, reuse Vercel schemas
Co-authored-by: Cursor <cursoragent@cursor.com>
* fix(zoo-gateway): accept models list without created/description fields
Co-authored-by: Cursor <cursoragent@cursor.com>
* refactor(zoo-gateway): centralize auth-scoped cache-skip via AUTH_SCOPED_PROVIDERS
Co-authored-by: Cursor <cursoragent@cursor.com>
* chore(types): drop retired 'roo' provider from getApiProtocol allowlist
Co-authored-by: Cursor <cursoragent@cursor.com>
---------
Co-authored-by: James Mtendamema <jmtendamema@geologicai.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
"Claude Sonnet 4 significantly improves on Sonnet 3.7's industry-leading capabilities, excelling in coding with a state-of-the-art 72.7% on SWE-bench. The model balances performance and efficiency for internal and external use cases, with enhanced steerability for greater control over implementations.",
0 commit comments