feat: 优化 Model 连接测试,支持阿里云 DashScope

- 添加阿里云 provider 支持
- 添加连接超时 (10s)
- 优化 URL 构建逻辑
- 默认状态改为 inactive
- 添加详细日志

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-07 16:21:29 +08:00
parent 9908ba7237
commit 25d3781f06
3 changed files with 44 additions and 8 deletions

View File

@@ -39,6 +39,7 @@ type CreateModelRequest struct {
APIKey string `json:"api_key" binding:"required"`
BaseURL string `json:"base_url" binding:"required"`
APIEndpoint string `json:"api_endpoint"`
Status string `json:"status"`
}
// UpdateModelRequest 更新模型请求