Go CLI: refactor commands (#16447)

### Summary

1. Move debug commands to dev file.
2. Refactor some commands syntax

---------

Signed-off-by: Jin Hai <haijin.chn@gmail.com>
This commit is contained in:
Jin Hai
2026-06-29 17:03:26 +08:00
committed by GitHub
parent ec5cd6b1c0
commit 3202ec6abf
12 changed files with 999 additions and 1022 deletions

View File

@@ -584,8 +584,8 @@ func (h *Handler) CheckProviderConnection(c *gin.Context) {
}
type AlterProviderInstanceRequest struct {
ModelName string `json:"model_name"`
APIKey string `json:"api_key"`
InstanceName string `json:"instance_name"`
APIKey string `json:"api_key"`
}
func (h *Handler) AlterProviderInstance(c *gin.Context) {
@@ -625,7 +625,7 @@ func (h *Handler) AlterProviderInstance(c *gin.Context) {
return
}
result, err := h.service.AlterProviderInstance(userID, providerName, instanceName, req.ModelName, req.APIKey)
result, err := h.service.AlterProviderInstance(userID, providerName, instanceName, req.InstanceName, req.APIKey)
if err != nil {
errorResponse(c, err.Error(), 500)
return