hide generate mcp token when mcp is not enabled

This commit is contained in:
MaysWind
2025-07-07 22:28:00 +08:00
parent 5cb129311a
commit 07477eb5f8
18 changed files with 38 additions and 1 deletions
+1
View File
@@ -39,6 +39,7 @@ const (
NormalSubcategoryPicture = 11
NormalSubcategoryConverter = 12
NormalSubcategoryUserCustomExchangeRate = 13
NormalSubcategoryModelContextProtocol = 14
)
// Error represents the specific error returned to user
+8
View File
@@ -0,0 +1,8 @@
package errs
import "net/http"
// Error codes related to model context protocol server
var (
ErrMCPServerNotEnabled = NewNormalError(NormalSubcategoryModelContextProtocol, 0, http.StatusBadRequest, "mcp server is not enabled")
)