feat(providers): add Minimax Coding (China) provider

- Add minimax-cn provider with China endpoint (api.minimaxi.com)
- Add provider icon and configuration
- Add validation and test support
- Add API configuration in open-sse

Co-authored-by: Blade096 <46746496+Blade096@users.noreply.github.com>
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Blade096
2026-02-06 15:10:57 +07:00
committed by decolua
parent 8c6e3b8b62
commit 7c609d7a3e
8 changed files with 23 additions and 3 deletions

View File

@@ -120,6 +120,14 @@ export const PROVIDERS = {
"Anthropic-Beta": "claude-code-20250219,interleaved-thinking-2025-05-14"
}
},
"minimax-cn": {
baseUrl: "https://api.minimaxi.com/anthropic/v1/messages",
format: "claude",
headers: {
"Anthropic-Version": "2023-06-01",
"Anthropic-Beta": "claude-code-20250219,interleaved-thinking-2025-05-14"
}
},
github: {
baseUrl: "https://api.githubcopilot.com/chat/completions", // GitHub Copilot API endpoint for chat
format: "openai", // GitHub Copilot uses OpenAI-compatible format

View File

@@ -189,6 +189,7 @@ export const PROVIDER_ID_TO_ALIAS = {
glm: "glm",
kimi: "kimi",
minimax: "minimax",
"minimax-cn": "minimax",
};
export function getModelsByProviderId(providerId) {

View File

@@ -23,6 +23,7 @@ export class DefaultExecutor extends BaseExecutor {
case "glm":
case "kimi":
case "minimax":
case "minimax-cn":
return `${this.config.baseUrl}?beta=true`;
case "gemini":
return `${this.config.baseUrl}/${model}:${stream ? "streamGenerateContent?alt=sse" : "generateContent"}`;
@@ -44,6 +45,7 @@ export class DefaultExecutor extends BaseExecutor {
case "glm":
case "kimi":
case "minimax":
case "minimax-cn":
headers["x-api-key"] = credentials.apiKey;
break;
default: