feat(ai): added OpenCode Zen provider and updated AI model configurations
- Added OpenCode Zen provider with API key-based authentication supporting multiple AI models. - Added four new free models via OpenCode provider: glm-4.7-free, kimi-k2.5-free, minimax-m2.1-free, and trinity-large-preview-free. - Added glm-4.7-flash model via Zai provider. - Updated pricing and configuration for multiple models across Kimi, MiniMax, OpenRouter, Anthropic, Vercel AI Gateway, and Zai providers. - Removed google/gemini-2.0-flash-exp:free from OpenRouter and stealth models from Vercel AI Gateway.
This commit is contained in:
@@ -19,6 +19,7 @@ import {
|
||||
loginGitHubCopilot,
|
||||
loginKimi,
|
||||
loginOpenAICodex,
|
||||
loginOpenCode,
|
||||
type OAuthController,
|
||||
type OAuthCredentials,
|
||||
type OAuthProvider,
|
||||
@@ -782,6 +783,11 @@ export class AuthStorage {
|
||||
ctrl.onProgress ? () => ctrl.onProgress?.("Waiting for browser authentication...") : undefined,
|
||||
);
|
||||
break;
|
||||
case "opencode": {
|
||||
const apiKey = await loginOpenCode(ctrl);
|
||||
credentials = { access: apiKey, refresh: apiKey, expires: Number.MAX_SAFE_INTEGER };
|
||||
break;
|
||||
}
|
||||
default:
|
||||
throw new Error(`Unknown OAuth provider: ${provider}`);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user