fix: 修正小米 Mimo API 端点地址

- 正确的端点是 https://api.xiaomimimo.com/v1/chat/completions
- 移除错误的自定义端点提示
- 恢复默认端点配置
This commit is contained in:
2026-01-26 14:25:10 +08:00
parent eabf13a374
commit 3794f37618

View File

@@ -8804,7 +8804,7 @@ function argon_ajax_test_unified_api() {
'openai' => 'https://api.openai.com/v1/chat/completions', 'openai' => 'https://api.openai.com/v1/chat/completions',
'anthropic' => 'https://api.anthropic.com/v1/messages', 'anthropic' => 'https://api.anthropic.com/v1/messages',
'deepseek' => 'https://api.deepseek.com/v1/chat/completions', 'deepseek' => 'https://api.deepseek.com/v1/chat/completions',
'xiaomi' => '', // 小米 Mimo 需要在平台获取自定义端点 'xiaomi' => 'https://api.xiaomimimo.com/v1/chat/completions',
'qianwen' => 'https://dashscope.aliyuncs.com/compatible-mode/v1/chat/completions', 'qianwen' => 'https://dashscope.aliyuncs.com/compatible-mode/v1/chat/completions',
'wenxin' => 'https://aip.baidubce.com/rpc/2.0/ai_custom/v1/wenxinworkshop/chat/completions', 'wenxin' => 'https://aip.baidubce.com/rpc/2.0/ai_custom/v1/wenxinworkshop/chat/completions',
'doubao' => 'https://ark.cn-beijing.volces.com/api/v3/chat/completions', 'doubao' => 'https://ark.cn-beijing.volces.com/api/v3/chat/completions',
@@ -8816,11 +8816,7 @@ function argon_ajax_test_unified_api() {
$api_endpoint = !empty($api['api_endpoint']) ? $api['api_endpoint'] : (isset($default_endpoints[$api['provider']]) ? $default_endpoints[$api['provider']] : ''); $api_endpoint = !empty($api['api_endpoint']) ? $api['api_endpoint'] : (isset($default_endpoints[$api['provider']]) ? $default_endpoints[$api['provider']] : '');
if (empty($api_endpoint)) { if (empty($api_endpoint)) {
if ($api['provider'] === 'xiaomi') { wp_send_json_error('未配置 API 端点');
wp_send_json_error('小米 Mimo 需要配置自定义 API 端点。请访问 https://platform.xiaomimimo.com 获取您的专属端点地址');
} else {
wp_send_json_error('未配置 API 端点');
}
return; return;
} }