fix(siliconflow): update baseUrl .cn -> .com + curate verified model list

Switch all siliconflow endpoints from api.siliconflow.cn to .com (chat,
validate, test, models) — the .cn host rejected valid .com-issued keys.
Replace the model list with 13 strong models verified live against the API.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Phuc Le
2026-06-13 11:37:36 +07:00
committed by decolua
co-authored by Cursor
parent b33cbb0280
commit e6bac77696
5 changed files with 21 additions and 15 deletions
+1 -1
View File
@@ -232,7 +232,7 @@ const PROVIDER_MODELS_CONFIG = {
cerebras: createOpenAIModelsConfig("https://api.cerebras.ai/v1/models"),
cohere: createOpenAIModelsConfig("https://api.cohere.ai/v1/models"),
nebius: createOpenAIModelsConfig("https://api.studio.nebius.ai/v1/models"),
siliconflow: createOpenAIModelsConfig("https://api.siliconflow.cn/v1/models"),
siliconflow: createOpenAIModelsConfig("https://api.siliconflow.com/v1/models"),
hyperbolic: createOpenAIModelsConfig("https://api.hyperbolic.xyz/v1/models"),
ollama: createOpenAIModelsConfig("https://ollama.com/api/tags"),
// ollama-local: url resolved dynamically below via providerSpecificData.baseUrl
+1 -1
View File
@@ -527,7 +527,7 @@ async function testApiKeyConnection(connection, effectiveProxy = null) {
return { valid: res.ok, error: res.ok ? null : "Invalid API key" };
}
case "siliconflow": {
const res = await fetchWithConnectionProxy("https://api.siliconflow.cn/v1/models", { headers: { Authorization: `Bearer ${connection.apiKey}` } }, effectiveProxy);
const res = await fetchWithConnectionProxy("https://api.siliconflow.com/v1/models", { headers: { Authorization: `Bearer ${connection.apiKey}` } }, effectiveProxy);
return { valid: res.ok, error: res.ok ? null : "Invalid API key" };
}
case "hyperbolic": {
+1 -1
View File
@@ -373,7 +373,7 @@ export async function POST(request) {
cerebras: "https://api.cerebras.ai/v1/models",
cohere: "https://api.cohere.ai/v1/models",
nebius: "https://api.studio.nebius.ai/v1/models",
siliconflow: "https://api.siliconflow.cn/v1/models",
siliconflow: "https://api.siliconflow.com/v1/models",
hyperbolic: "https://api.hyperbolic.xyz/v1/models",
ollama: "https://ollama.com/api/tags",
"ollama-local": `${resolveOllamaLocalHost({ providerSpecificData })}/api/tags`,